Daily bump.
[official-gcc.git] / gcc / ChangeLog
blobcc88c72432076398a71dc2ee4a97a5f887aa8620
1 2023-12-18  Vladimir N. Makarov  <vmakarov@redhat.com>
3         PR rtl-optimization/112918
4         * lra-constraints.cc (SMALL_REGISTER_CLASS_P): Move before in_class_p.
5         (in_class_p): Restrict condition for narrowing class in case of
6         allow_all_reload_class_changes_p.
7         (process_alt_operands): Pass true for
8         allow_all_reload_class_changes_p in calls of in_class_p.
9         (curr_insn_transform): Ditto for reg operand win.
11 2023-12-18  Uros Bizjak  <ubizjak@gmail.com>
13         * config/i386/i386.md (redundant compare peephole2):
14         New peephole2 pattern.
16 2023-12-18  Andreas Krebbel  <krebbel@linux.ibm.com>
18         * config/s390/s390.cc (s390_encode_section_info): Replace
19         SYMBOL_REF_LOCAL_P with decl_binds_to_current_def_p.
21 2023-12-18  Andrew Pinski  <quic_apinski@quicinc.com>
23         PR tree-optimization/113054
24         * gimple-ssa-sccopy.cc: Wrap the local types
25         with an anonymous namespace.
27 2023-12-18  Richard Biener  <rguenther@suse.de>
29         PR middle-end/111975
30         * tree-pretty-print.cc (dump_generic_node): Dump
31         sizetype as __SIZETYPE__ with TDF_GIMPLE.
32         Dump unnamed vector types as T [[gnu::vector_size(n)]] with
33         TDF_GIMPLE.
34         * tree-ssa-address.cc (create_mem_ref_raw): Never generate
35         a NULL STEP when INDEX is specified.
37 2023-12-18  Gerald Pfeifer  <gerald@pfeifer.com>
39         PR target/69374
40         * doc/install.texi (Specific) <hppa*-hp-hpux10>: Remove section.
41         (Specific) <hppa*-hp-hpux11>: Remove references to GCC 2.95 and
42         3.0. Also libffi has been ported now.
44 2023-12-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
46         PR target/112432
47         * config/riscv/riscv.md (none,W21,W42,W84,W43,W86,W87): Add W0.
48         (none,W21,W42,W84,W43,W86,W87,W0): Ditto.
49         * config/riscv/vector.md: Ditto.
51 2023-12-18  Richard Biener  <rguenther@suse.de>
53         PR c/111975
54         * tree-pretty-print.cc (dump_mem_ref): Use TDF_GIMPLE path
55         also for TARGET_MEM_REF and amend it.
57 2023-12-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
59         * config/riscv/riscv.cc (riscv_regmode_natural_size): Fix ICE for
60         FIXED-VLMAX of -march=rv32gc_zve32f.
62 2023-12-18  Jakub Jelinek  <jakub@redhat.com>
64         PR tree-optimization/113013
65         * tree-object-size.cc (alloc_object_size): Return size_unknown if
66         corresponding argument(s) don't have integral type or have integral
67         type with higher precision than sizetype.  Don't check arg1 >= 0
68         uselessly.  Compare argument indexes against gimple_call_num_args
69         in unsigned type rather than int.  Formatting fixes.
71 2023-12-18  Pan Li  <pan2.li@intel.com>
73         * config/riscv/riscv-v.cc (expand_const_vector): Take step2
74         instead of step1 for second series.
76 2023-12-18  liushuyu  <liushuyu011@gmail.com>
78         * config.gcc: Add loongarch-d.o to d_target_objs for LoongArch
79         architecture.
80         * config/loongarch/t-loongarch: Add object target for loongarch-d.cc.
81         * config/loongarch/loongarch-d.cc
82         (loongarch_d_target_versions): add interface function to define builtin
83         D versions for LoongArch architecture.
84         (loongarch_d_handle_target_float_abi): add interface function to define
85         builtin D traits for LoongArch architecture.
86         (loongarch_d_register_target_info): add interface function to register
87         loongarch_d_handle_target_float_abi function.
88         * config/loongarch/loongarch-d.h
89         (loongarch_d_target_versions): add function prototype.
90         (loongarch_d_register_target_info): Likewise.
92 2023-12-18  xuli  <xuli1@eswincomputing.com>
94         * config/riscv/vector.md: Add viota avl_type attribute.
96 2023-12-18  Pan Li  <pan2.li@intel.com>
98         * config/riscv/riscv.cc (riscv_expand_mult_with_const_int):
99         Change int into HOST_WIDE_INT.
100         (riscv_legitimize_poly_move): Ditto.
102 2023-12-17  Xi Ruoyao  <xry111@xry111.site>
104         * config/loongarch/loongarch.md (alslsi3_extend): New
105         define_insn.
107 2023-12-17  Xi Ruoyao  <xry111@xry111.site>
109         PR target/112936
110         * config/loongarch/loongarch-def.cc
111         (loongarch_rtx_cost_data::loongarch_rtx_cost_data): Update
112         instruction costs per micro-benchmark results.
113         (loongarch_rtx_cost_optimize_size): Set all instruction costs
114         to (COSTS_N_INSNS (1) + 1).
115         * config/loongarch/loongarch.cc (loongarch_rtx_costs): Remove
116         special case for multiplication when optimizing for size.
117         Adjust division cost when TARGET_64BIT && !TARGET_DIV32.
118         Account the extra cost when TARGET_CHECK_ZERO_DIV and
119         optimizing for speed.
121 2023-12-17  Xi Ruoyao  <xry111@xry111.site>
123         * config/loongarch/loongarch-def.cc (rtl.h): Include.
124         (COSTS_N_INSNS): Remove the macro definition.
126 2023-12-17  Gerald Pfeifer  <gerald@pfeifer.com>
128         PR target/69374
129         * doc/install.texi (Specific) <hppa*-hp-hpux*>: Remove a note on
130         GCC 4.3.
131         Remove details on how the HP assembler, which we document as not
132         working, breaks.
133         <hppa*-hp-hpux11>: Note that only the HP linker is supported.
135 2023-12-17  Gerald Pfeifer  <gerald@pfeifer.com>
137         PR other/69374
138         * doc/install.texi (Installing GCC): Remove reference to
139         buildstat.html.
140         (Testing): Ditto.
141         (Final install): Remove section on submitting information for
142         buildstat.html. Adjust the request for feedback.
144 2023-12-16  David Malcolm  <dmalcolm@redhat.com>
146         * json.cc (print_escaped_json_string): New, taken from
147         string::print.
148         (object::print): Use it for printing keys.
149         (string::print): Move implementation to
150         print_escaped_json_string.
151         (selftest::test_writing_objects): Add a key containing
152         quote, backslash, and control characters.
154 2023-12-16  Andrew Carlotti  <andrew.carlotti@arm.com>
156         * config/aarch64/aarch64-feature-deps.h (fmv_deps_<FEAT_NAME>):
157         Define aarch64_feature_flags mask foreach FMV feature.
158         * config/aarch64/aarch64-option-extensions.def: Use new macros
159         to define FMV feature extensions.
160         * config/aarch64/aarch64.cc (aarch64_option_valid_attribute_p):
161         Check for target_version attribute after processing target
162         attribute.
163         (aarch64_fmv_feature_data): New.
164         (aarch64_parse_fmv_features): New.
165         (aarch64_process_target_version_attr): New.
166         (aarch64_option_valid_version_attribute_p): New.
167         (get_feature_mask_for_version): New.
168         (compare_feature_masks): New.
169         (aarch64_compare_version_priority): New.
170         (build_ifunc_arg_type): New.
171         (make_resolver_func): New.
172         (add_condition_to_bb): New.
173         (dispatch_function_versions): New.
174         (aarch64_generate_version_dispatcher_body): New.
175         (aarch64_get_function_versions_dispatcher): New.
176         (aarch64_common_function_versions): New.
177         (aarch64_mangle_decl_assembler_name): New.
178         (TARGET_OPTION_VALID_VERSION_ATTRIBUTE_P): New implementation.
179         (TARGET_OPTION_EXPANDED_CLONES_ATTRIBUTE): New implementation.
180         (TARGET_OPTION_FUNCTION_VERSIONS): New implementation.
181         (TARGET_COMPARE_VERSION_PRIORITY): New implementation.
182         (TARGET_GENERATE_VERSION_DISPATCHER_BODY): New implementation.
183         (TARGET_GET_FUNCTION_VERSIONS_DISPATCHER): New implementation.
184         (TARGET_MANGLE_DECL_ASSEMBLER_NAME): New implementation.
185         * config/aarch64/aarch64.h (TARGET_HAS_FMV_TARGET_ATTRIBUTE):
186         Set target macro.
187         * config/arm/aarch-common.h (enum aarch_parse_opt_result): Add
188         new value to report duplicate FMV feature.
189         * common/config/aarch64/cpuinfo.h: New file.
191 2023-12-16  Andrew Carlotti  <andrew.carlotti@arm.com>
193         * attribs.cc (decl_attributes): Pass attribute name to target.
194         (is_function_default_version): Update comment to specify
195         incompatibility with target_version attributes.
196         * cgraphclones.cc (cgraph_node::create_version_clone_with_body):
197         Call valid_version_attribute_p for target_version attributes.
198         * defaults.h (TARGET_HAS_FMV_TARGET_ATTRIBUTE): New macro.
199         * target.def (valid_version_attribute_p): New hook.
200         * doc/tm.texi.in: Add new hook.
201         * doc/tm.texi: Regenerate.
202         * multiple_target.cc (create_dispatcher_calls): Remove redundant
203         is_function_default_version check.
204         (expand_target_clones): Use target macro to pick attribute name.
205         * targhooks.cc (default_target_option_valid_version_attribute_p):
206         New.
207         * targhooks.h (default_target_option_valid_version_attribute_p):
208         New.
209         * tree.h (DECL_FUNCTION_VERSIONED): Update comment to include
210         target_version attributes.
212 2023-12-16  Andrew Carlotti  <andrew.carlotti@arm.com>
214         * common/config/aarch64/aarch64-common.cc
215         (struct aarch64_option_extension): Remove unused field.
216         (all_extensions): Ditto.
217         (aarch64_get_extension_string_for_isa_flags): Remove filtering
218         of features without native detection.
219         * config/aarch64/driver-aarch64.cc (host_detect_local_cpu):
220         Explicitly add expected features that lack cpuinfo detection.
222 2023-12-16  Andrew Carlotti  <andrew.carlotti@arm.com>
224         * common/config/aarch64/aarch64-common.cc
225         (aarch64_get_extension_string_for_isa_flags): Fix generation of
226         the "+nocrypto" extension.
227         * config/aarch64/aarch64.h (AARCH64_ISA_CRYPTO): Remove.
228         (TARGET_CRYPTO): Remove.
229         * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins):
230         Don't use TARGET_CRYPTO.
232 2023-12-15  Mary Bennett  <mary.bennett@embecosm.com>
234         * config/riscv/constraints.md: CVP2 -> CV_alu_pow2.
235         * config/riscv/corev.md: Likewise.
237 2023-12-15  Mary Bennett  <mary.bennett@embecosm.com>
239         * common/config/riscv/riscv-common.cc: Add XCVelw.
240         * config/riscv/corev.def: Likewise.
241         * config/riscv/corev.md: Likewise.
242         * config/riscv/riscv-builtins.cc (AVAIL): Likewise.
243         * config/riscv/riscv-ftypes.def: Likewise.
244         * config/riscv/riscv.opt: Likewise.
245         * doc/extend.texi: Add XCVelw builtin documentation.
246         * doc/sourcebuild.texi: Likewise.
248 2023-12-15  Jeff Law  <jlaw@ventanamicro.com>
250         PR target/110201
251         * config/riscv/constraints.md (D03, DsA): Remove unused constraints.
252         * config/riscv/predicates.md (const_0_3_operand): New predicate.
253         (const_0_10_operand): Likewise.
254         * config/riscv/crypto.md (riscv_aes32dsi): Use new predicate.  Drop
255         unnecessary constraint.
256         (riscv_aes32dsmi, riscv_aes64im, riscv_aes32esi): Likewise.
257         (riscv_aes32esmi, *riscv_<sm4_op>_si): Likewise.
258         (riscv_<sm4_op>_di_extend, riscv_<sm4_op>_si): Likewise.
260 2023-12-15  Alex Coplan  <alex.coplan@arm.com>
262         * config.gcc: Add aarch64-ldp-fusion.o to extra_objs for aarch64.
263         * config/aarch64/aarch64-passes.def: Add copies of pass_ldp_fusion
264         before and after RA.
265         * config/aarch64/aarch64-protos.h (make_pass_ldp_fusion): Declare.
266         * config/aarch64/aarch64.opt (-mearly-ldp-fusion): New.
267         (-mlate-ldp-fusion): New.
268         (--param=aarch64-ldp-alias-check-limit): New.
269         (--param=aarch64-ldp-writeback): New.
270         * config/aarch64/t-aarch64: Add rule for aarch64-ldp-fusion.o.
271         * config/aarch64/aarch64-ldp-fusion.cc: New file.
272         * doc/invoke.texi (AArch64 Options): Document new
273         -m{early,late}-ldp-fusion options.
275 2023-12-15  Alex Coplan  <alex.coplan@arm.com>
277         * config/aarch64/aarch64-ldpstp.md: Abstract ldp/stp
278         representation from peepholes, allowing use of new form.
279         * config/aarch64/aarch64-modes.def (V2x4QImode): Define.
280         * config/aarch64/aarch64-protos.h
281         (aarch64_finish_ldpstp_peephole): Declare.
282         (aarch64_swap_ldrstr_operands): Delete declaration.
283         (aarch64_gen_load_pair): Adjust parameters.
284         (aarch64_gen_store_pair): Likewise.
285         * config/aarch64/aarch64-simd.md (load_pair<DREG:mode><DREG2:mode>):
286         Delete.
287         (vec_store_pair<DREG:mode><DREG2:mode>): Delete.
288         (load_pair<VQ:mode><VQ2:mode>): Delete.
289         (vec_store_pair<VQ:mode><VQ2:mode>): Delete.
290         * config/aarch64/aarch64.cc (aarch64_pair_mode_for_mode): New.
291         (aarch64_gen_store_pair): Adjust to use new unspec form of stp.
292         Drop second mem from parameters.
293         (aarch64_gen_load_pair): Likewise.
294         (aarch64_pair_mem_from_base): New.
295         (aarch64_save_callee_saves): Emit REG_CFA_OFFSET notes for
296         frame-related saves.  Adjust call to aarch64_gen_store_pair
297         (aarch64_restore_callee_saves): Adjust calls to
298         aarch64_gen_load_pair to account for change in interface.
299         (aarch64_process_components): Likewise.
300         (aarch64_classify_address): Handle 32-byte pair mems in
301         LDP_STP_N case.
302         (aarch64_print_operand): Likewise.
303         (aarch64_copy_one_block_and_progress_pointers): Adjust calls to
304         account for change in aarch64_gen_{load,store}_pair interface.
305         (aarch64_set_one_block_and_progress_pointer): Likewise.
306         (aarch64_finish_ldpstp_peephole): New.
307         (aarch64_gen_adjusted_ldpstp): Adjust to use generation helper.
308         * config/aarch64/aarch64.md (ldpstp): New attribute.
309         (load_pair_sw_<SX:mode><SX2:mode>): Delete.
310         (load_pair_dw_<DX:mode><DX2:mode>): Delete.
311         (load_pair_dw_<TX:mode><TX2:mode>): Delete.
312         (*load_pair_<ldst_sz>): New.
313         (*load_pair_16): New.
314         (store_pair_sw_<SX:mode><SX2:mode>): Delete.
315         (store_pair_dw_<DX:mode><DX2:mode>): Delete.
316         (store_pair_dw_<TX:mode><TX2:mode>): Delete.
317         (*store_pair_<ldst_sz>): New.
318         (*store_pair_16): New.
319         (*load_pair_extendsidi2_aarch64): Adjust to use new form.
320         (*zero_extendsidi2_aarch64): Likewise.
321         * config/aarch64/iterators.md (VPAIR): New.
322         * config/aarch64/predicates.md (aarch64_mem_pair_operand): Change to
323         a special predicate derived from aarch64_mem_pair_operator.
325 2023-12-15  Alex Coplan  <alex.coplan@arm.com>
327         * config/aarch64/aarch64-protos.h (aarch64_ldpstp_operand_mode_p): Declare.
328         * config/aarch64/aarch64.cc (aarch64_gen_storewb_pair): Build RTL
329         directly instead of invoking named pattern.
330         (aarch64_gen_loadwb_pair): Likewise.
331         (aarch64_ldpstp_operand_mode_p): New.
332         * config/aarch64/aarch64.md (loadwb_pair<GPI:mode>_<P:mode>): Replace with
333         ...
334         (*loadwb_post_pair_<ldst_sz>): ... this. Generalize as described
335         in cover letter.
336         (loadwb_pair<GPF:mode>_<P:mode>): Delete (superseded by the
337         above).
338         (*loadwb_post_pair_16): New.
339         (*loadwb_pre_pair_<ldst_sz>): New.
340         (loadwb_pair<TX:mode>_<P:mode>): Delete.
341         (*loadwb_pre_pair_16): New.
342         (storewb_pair<GPI:mode>_<P:mode>): Replace with ...
343         (*storewb_pre_pair_<ldst_sz>): ... this.  Generalize as
344         described in cover letter.
345         (*storewb_pre_pair_16): New.
346         (storewb_pair<GPF:mode>_<P:mode>): Delete.
347         (*storewb_post_pair_<ldst_sz>): New.
348         (storewb_pair<TX:mode>_<P:mode>): Delete.
349         (*storewb_post_pair_16): New.
350         * config/aarch64/predicates.md (aarch64_mem_pair_operator): New.
351         (pmode_plus_operator): New.
352         (aarch64_ldp_reg_operand): New.
353         (aarch64_stp_reg_operand): New.
355 2023-12-15  Alex Coplan  <alex.coplan@arm.com>
357         * config/aarch64/aarch64.cc (aarch64_print_address_internal): Handle SVE
358         modes when printing ldp/stp addresses.
360 2023-12-15  Alex Coplan  <alex.coplan@arm.com>
362         * config/aarch64/aarch64-protos.h (aarch64_const_zero_rtx_p): New.
363         * config/aarch64/aarch64.cc (aarch64_const_zero_rtx_p): New.
364         Use it ...
365         (aarch64_print_operand): ... here.  Recognize CONST0_RTXes in
366         modes other than VOIDmode.
368 2023-12-15  Xiao Zeng  <zengxiao@eswincomputing.com>
370         * common/config/riscv/riscv-common.cc:
371         (riscv_implied_info): Add zvfbfmin item.
372         (riscv_ext_version_table): Ditto.
373         (riscv_ext_flag_table): Ditto.
374         * config/riscv/riscv.opt:
375         (MASK_ZVFBFMIN): New macro.
376         (MASK_VECTOR_ELEN_BF_16): Ditto.
377         (TARGET_ZVFBFMIN): Ditto.
379 2023-12-15  Wilco Dijkstra  <wilco.dijkstra@arm.com>
381         * config/aarch64/aarch64.opt (aarch64_mops_memmove_size_threshold):
382         Change default.
383         * config/aarch64/aarch64.md (cpymemdi): Add a parameter.
384         (movmemdi): Call aarch64_expand_cpymem.
385         * config/aarch64/aarch64.cc (aarch64_copy_one_block): Rename function,
386         simplify, support storing generated loads/stores.
387         (aarch64_expand_cpymem): Support expansion of memmove.
388         * config/aarch64/aarch64-protos.h (aarch64_expand_cpymem): Add bool arg.
390 2023-12-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
392         * config/riscv/riscv-v.cc (shuffle_merge_patterns): Fix bug.
394 2023-12-15  Jakub Jelinek  <jakub@redhat.com>
396         * target.h (struct bitint_info): Add abi_limb_mode member, adjust
397         comment.
398         * target.def (bitint_type_info): Mention abi_limb_mode instead of
399         limb_mode.
400         * varasm.cc (output_constant): Use abi_limb_mode rather than
401         limb_mode.
402         * stor-layout.cc (finish_bitfield_representative): Likewise.  Assert
403         that if precision is smaller or equal to abi_limb_mode precision or
404         if info.big_endian is different from WORDS_BIG_ENDIAN, info.limb_mode
405         must be the same as info.abi_limb_mode.
406         (layout_type): Use abi_limb_mode rather than limb_mode.
407         * gimple-fold.cc (clear_padding_bitint_needs_padding_p): Likewise.
408         (clear_padding_type): Likewise.
409         * config/i386/i386.cc (ix86_bitint_type_info): Also set
410         info->abi_limb_mode.
411         * doc/tm.texi: Regenerated.
413 2023-12-15  Julian Brown  <julian@codesourcery.com>
415         * gimplify.cc (extract_base_bit_offset): Add VARIABLE_OFFSET parameter.
416         (omp_get_attachment, omp_group_last, omp_group_base,
417         omp_directive_maps_explicitly): Add GOMP_MAP_STRUCT_UNORD support.
418         (omp_accumulate_sibling_list): Update calls to extract_base_bit_offset.
419         Support GOMP_MAP_STRUCT_UNORD.
420         (omp_build_struct_sibling_lists, gimplify_scan_omp_clauses,
421         gimplify_adjust_omp_clauses, gimplify_omp_target_update): Add
422         GOMP_MAP_STRUCT_UNORD support.
423         * omp-low.cc (lower_omp_target): Add GOMP_MAP_STRUCT_UNORD support.
424         * tree-pretty-print.cc (dump_omp_clause): Likewise.
426 2023-12-15  Alex Coplan  <alex.coplan@arm.com>
428         PR target/112906
429         * config/aarch64/aarch64-sve.md (@aarch64_vec_duplicate_vq<mode>_le):
430         Use force_reload_address to reload addresses that aren't suitable for
431         ld1rq in the pre-RA splitter.
433 2023-12-15  Alex Coplan  <alex.coplan@arm.com>
435         PR target/112906
436         * emit-rtl.cc (address_reload_context::emit_autoinc): New.
437         (force_reload_address): New.
438         * emit-rtl.h (struct address_reload_context): Declare.
439         (force_reload_address): Declare.
440         * lra-constraints.cc (class lra_autoinc_reload_context): New.
441         (emit_inc): Drop IN parameter, invoke
442         code moved to emit-rtl.cc:address_reload_context::emit_autoinc.
443         (curr_insn_transform): Drop redundant IN parameter in call to
444         emit_inc.
445         * recog.h (class recog_data_saver): New.
447 2023-12-15  Jakub Jelinek  <jakub@redhat.com>
449         PR tree-optimization/113024
450         * match.pd (two conversions in a row): Simplify scalar integer
451         sign-extension followed by truncation.
453 2023-12-15  Jakub Jelinek  <jakub@redhat.com>
455         PR tree-optimization/113003
456         * gimple-lower-bitint.cc (arith_overflow_arg_kind): New function.
457         (gimple_lower_bitint): Use it to catch .{ADD,SUB,MUL}_OVERFLOW
458         calls with large/huge INTEGER_CST arguments.
460 2023-12-15  Gerald Pfeifer  <gerald@pfeifer.com>
462         * doc/install.texi (Specific) <nvptx-*-none>: Update nvptx-tools
463         Github link.
465 2023-12-15  Hongyu Wang  <hongyu.wang@intel.com>
467         PR target/112824
468         * config/i386/i386-options.cc (ix86_option_override_internal):
469         Sync ix86_move_max/ix86_store_max with prefer_vector_width when
470         it is explicitly set.
472 2023-12-15  Haochen Jiang  <haochen.jiang@intel.com>
474         * config/i386/driver-i386.cc (host_detect_local_cpu): Do not
475         set Grand Ridge depending on RAO-INT.
476         * config/i386/i386.h: Remove PTA_RAOINT from PTA_GRANDRIDGE.
477         * doc/invoke.texi: Adjust documentation.
479 2023-12-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
481         PR target/112387
482         * config/riscv/riscv.cc: Adapt generic cost model same ARM SVE.
484 2023-12-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
486         PR target/111153
487         * tree-vect-loop.cc (vect_estimate_min_profitable_iters):
488         Remove address cost for select_vl/decrement IV.
490 2023-12-14  Andrew Pinski  <quic_apinski@quicinc.com>
492         PR middle-end/111260
493         * optabs.cc (emit_conditional_move): Change the modes to be
494         equal before forcing the constant to a register.
496 2023-12-14  Di Zhao  <dizhao@os.amperecomputing.com>
498         PR tree-optimization/110279
499         * doc/invoke.texi: New parameter fully-pipelined-fma.
500         * params.opt: New parameter fully-pipelined-fma.
501         * tree-ssa-reassoc.cc (get_mult_latency_consider_fma): Return
502         the latency of MULT_EXPRs that can't be hidden by the FMAs.
503         (get_reassociation_width): Search for a smaller width
504         considering the benefit of fully pipelined FMA.
505         (rank_ops_for_fma): Return the number of MULT_EXPRs.
506         (reassociate_bb): Pass the number of MULT_EXPRs to
507         get_reassociation_width; avoid calling
508         get_reassociation_width twice.
510 2023-12-14  Robin Dapp  <rdapp@ventanamicro.com>
512         PR target/112999
513         * expmed.cc (extract_bit_field_1):  Ensure better mode
514         has fitting unit_precision.
516 2023-12-14  Robin Dapp  <rdapp@ventanamicro.com>
518         PR target/112773
519         * config/riscv/autovec.md (vec_extract<mode>bi): New expander
520         calling vec_extract<mode>qi.
521         * config/riscv/riscv-protos.h (riscv_legitimize_poly_move):
522         Export.
523         (emit_vec_extract): Change argument from poly_int64 to rtx.
524         * config/riscv/riscv-v.cc (shuffle_extract_and_slide1up_patterns):
525         Ditto.
526         * config/riscv/riscv.cc (riscv_legitimize_poly_move): Export.
527         (riscv_legitimize_move): Use rtx instead of poly_int64.
528         * expmed.cc (store_bit_field_1): Change BITSIZE to PRECISION.
529         (extract_bit_field_1): Change BITSIZE to PRECISION and use
530         return mode from insn_data as target mode.
532 2023-12-14  Alex Coplan  <alex.coplan@arm.com>
534         * doc/extend.texi: Document AArch64 Operand Modifiers.
536 2023-12-14  Richard Biener  <rguenther@suse.de>
538         PR tree-optimization/113018
539         * tree-vect-slp.cc (vect_slp_check_for_roots): Only start
540         SLP discovery from stmts with a LHS.
542 2023-12-14  Richard Biener  <rguenther@suse.de>
544         PR tree-optimization/112793
545         * tree-vect-slp.cc (vect_schedule_slp_node): Already
546         code-generated constant/external nodes are OK.
548 2023-12-14  Richard Sandiford  <richard.sandiford@arm.com>
550         * config/aarch64/aarch64-early-ra.cc (allocno_info::is_equiv): New
551         member variable.
552         (allocno_info::equiv_allocno): Replace with...
553         (allocno_info::related_allocno): ...this member variable.
554         (allocno_info::chain_prev): Put into an enum with...
555         (allocno_info::last_use_point): ...this new member variable.
556         (color_info::num_fpr_preferences): New member variable.
557         (early_ra::m_shared_allocnos): Likewise.
558         (allocno_info::is_shared): New member function.
559         (allocno_info::is_equiv_to): Likewise.
560         (early_ra::dump_allocnos): Dump sharing information.  Tweak column
561         widths.
562         (early_ra::fpr_preference): Check ALLOWS_NONFPR before returning -2.
563         (early_ra::start_new_region): Handle m_shared_allocnos.
564         (early_ra::create_allocno_group): Set related_allocno rather than
565         equiv_allocno.
566         (early_ra::record_allocno_use): Likewise.  Detect multiple calls
567         for the same program point.  Update last_use_point and is_equiv.
568         Clear is_strong_copy_src rather than is_strong_copy_dest.
569         (early_ra::record_allocno_def): Use related_allocno rather than
570         equiv_allocno.  Update last_use_point.
571         (early_ra::valid_equivalence_p): Replace with...
572         (early_ra::find_related_start): ...this new function.
573         (early_ra::record_copy): Look for cases where a destination copy chain
574         can be shared with the source allocno.
575         (early_ra::find_strided_accesses): Update for equiv_allocno->
576         related_allocno change.  Only call consider_strong_copy_src_chain
577         at the head of a copy chain.
578         (early_ra::is_chain_candidate): Skip shared allocnos.  Update for
579         new representation of equivalent allocnos.
580         (early_ra::chain_allocnos): Update for new representation of
581         equivalent allocnos.
582         (early_ra::try_to_chain_allocnos): Likewise.
583         (early_ra::merge_fpr_info): New function, split out from...
584         (early_ra::set_single_color_rep): ...here.
585         (early_ra::form_chains): Handle shared allocnos.
586         (early_ra::process_copies): Count the number of FPR preferences.
587         (early_ra::cmp_decreasing_size): Rename to...
588         (early_ra::cmp_allocation_order): ...this.  Sort equal-sized groups
589         by the number of FPR preferences.
590         (early_ra::finalize_allocation): Handle shared allocnos.
591         (early_ra::process_region): Reset chain_prev as well as chain_next.
593 2023-12-14  Alexandre Oliva  <oliva@adacore.com>
595         PR middle-end/112938
596         * ipa-strub.cc (pass_ipa_strub::execute): Pass volatile args
597         by reference to internal strub wrapped bodies.
599 2023-12-14  Alexandre Oliva  <oliva@adacore.com>
601         PR middle-end/112938
602         * ipa-strub.cc (pass_ipa_strub::execute): Handle promoted
603         volatile args in internal strub.  Simplify.
605 2023-12-14  Thomas Schwinge  <thomas@codesourcery.com>
607         * gimple-ssa-sccopy.cc: '#define INCLUDE_ALGORITHM' instead of
608         '#include <algorithm>'.
610 2023-12-14  Feng Wang  <wangfeng@eswincomputing.com>
612         Revert:
613         2023-12-12  Feng Wang  <wangfeng@eswincomputing.com>
615         * config/riscv/riscv-vector-builtins-functions.def (DEF_RVV_FUNCTION):
616                                                         Add AVAIL argument.
617         (read_vl): Using AVAIL argument default value.
618         (vlenb): Ditto.
619         (vsetvl): Ditto.
620         (vsetvlmax): Ditto.
621         (vle): Ditto.
622         (vse): Ditto.
623         (vlm): Ditto.
624         (vsm): Ditto.
625         (vlse): Ditto.
626         (vsse): Ditto.
627         (vluxei8): Ditto.
628         (vluxei16): Ditto.
629         (vluxei32): Ditto.
630         (vluxei64): Ditto.
631         (vloxei8): Ditto.
632         (vloxei16): Ditto.
633         (vloxei32): Ditto.
634         (vloxei64): Ditto.
635         (vsuxei8): Ditto.
636         (vsuxei16): Ditto.
637         (vsuxei32): Ditto.
638         (vsuxei64): Ditto.
639         (vsoxei8): Ditto.
640         (vsoxei16): Ditto.
641         (vsoxei32): Ditto.
642         (vsoxei64): Ditto.
643         (vleff): Ditto.
644         (vadd): Ditto.
645         (vsub): Ditto.
646         (vrsub): Ditto.
647         (vneg): Ditto.
648         (vwaddu): Ditto.
649         (vwsubu): Ditto.
650         (vwadd): Ditto.
651         (vwsub): Ditto.
652         (vwcvt_x): Ditto.
653         (vwcvtu_x): Ditto.
654         (vzext): Ditto.
655         (vsext): Ditto.
656         (vadc): Ditto.
657         (vmadc): Ditto.
658         (vsbc): Ditto.
659         (vmsbc): Ditto.
660         (vand): Ditto.
661         (vor): Ditto.
662         (vxor): Ditto.
663         (vnot): Ditto.
664         (vsll): Ditto.
665         (vsra): Ditto.
666         (vsrl): Ditto.
667         (vnsrl): Ditto.
668         (vnsra): Ditto.
669         (vncvt_x): Ditto.
670         (vmseq): Ditto.
671         (vmsne): Ditto.
672         (vmsltu): Ditto.
673         (vmslt): Ditto.
674         (vmsleu): Ditto.
675         (vmsle): Ditto.
676         (vmsgtu): Ditto.
677         (vmsgt): Ditto.
678         (vmsgeu): Ditto.
679         (vmsge): Ditto.
680         (vminu): Ditto.
681         (vmin): Ditto.
682         (vmaxu): Ditto.
683         (vmax): Ditto.
684         (vmul): Ditto.
685         (vmulh): Ditto.
686         (vmulhu): Ditto.
687         (vmulhsu): Ditto.
688         (vdivu): Ditto.
689         (vdiv): Ditto.
690         (vremu): Ditto.
691         (vrem): Ditto.
692         (vwmul): Ditto.
693         (vwmulu): Ditto.
694         (vwmulsu): Ditto.
695         (vmacc): Ditto.
696         (vnmsac): Ditto.
697         (vmadd): Ditto.
698         (vnmsub): Ditto.
699         (vwmaccu): Ditto.
700         (vwmacc): Ditto.
701         (vwmaccsu): Ditto.
702         (vwmaccus): Ditto.
703         (vmerge): Ditto.
704         (vmv_v): Ditto.
705         (vsaddu): Ditto.
706         (vsadd): Ditto.
707         (vssubu): Ditto.
708         (vssub): Ditto.
709         (vaaddu): Ditto.
710         (vaadd): Ditto.
711         (vasubu): Ditto.
712         (vasub): Ditto.
713         (vsmul): Ditto.
714         (vssrl): Ditto.
715         (vssra): Ditto.
716         (vnclipu): Ditto.
717         (vnclip): Ditto.
718         (vfadd): Ditto.
719         (vfsub): Ditto.
720         (vfrsub): Ditto.
721         (vfadd_frm): Ditto.
722         (vfsub_frm): Ditto.
723         (vfrsub_frm): Ditto.
724         (vfwadd): Ditto.
725         (vfwsub): Ditto.
726         (vfwadd_frm): Ditto.
727         (vfwsub_frm): Ditto.
728         (vfmul): Ditto.
729         (vfdiv): Ditto.
730         (vfrdiv): Ditto.
731         (vfmul_frm): Ditto.
732         (vfdiv_frm): Ditto.
733         (vfrdiv_frm): Ditto.
734         (vfwmul): Ditto.
735         (vfwmul_frm): Ditto.
736         (vfmacc): Ditto.
737         (vfnmsac): Ditto.
738         (vfmadd): Ditto.
739         (vfnmsub): Ditto.
740         (vfnmacc): Ditto.
741         (vfmsac): Ditto.
742         (vfnmadd): Ditto.
743         (vfmsub): Ditto.
744         (vfmacc_frm): Ditto.
745         (vfnmacc_frm): Ditto.
746         (vfmsac_frm): Ditto.
747         (vfnmsac_frm): Ditto.
748         (vfmadd_frm): Ditto.
749         (vfnmadd_frm): Ditto.
750         (vfmsub_frm): Ditto.
751         (vfnmsub_frm): Ditto.
752         (vfwmacc): Ditto.
753         (vfwnmacc): Ditto.
754         (vfwmsac): Ditto.
755         (vfwnmsac): Ditto.
756         (vfwmacc_frm): Ditto.
757         (vfwnmacc_frm): Ditto.
758         (vfwmsac_frm): Ditto.
759         (vfwnmsac_frm): Ditto.
760         (vfsqrt): Ditto.
761         (vfsqrt_frm): Ditto.
762         (vfrsqrt7): Ditto.
763         (vfrec7): Ditto.
764         (vfrec7_frm): Ditto.
765         (vfmin): Ditto.
766         (vfmax): Ditto.
767         (vfsgnj): Ditto.
768         (vfsgnjn): Ditto.
769         (vfsgnjx): Ditto.
770         (vfneg): Ditto.
771         (vfabs): Ditto.
772         (vmfeq): Ditto.
773         (vmfne): Ditto.
774         (vmflt): Ditto.
775         (vmfle): Ditto.
776         (vmfgt): Ditto.
777         (vmfge): Ditto.
778         (vfclass): Ditto.
779         (vfmerge): Ditto.
780         (vfmv_v): Ditto.
781         (vfcvt_x): Ditto.
782         (vfcvt_xu): Ditto.
783         (vfcvt_rtz_x): Ditto.
784         (vfcvt_rtz_xu): Ditto.
785         (vfcvt_f): Ditto.
786         (vfcvt_x_frm): Ditto.
787         (vfcvt_xu_frm): Ditto.
788         (vfcvt_f_frm): Ditto.
789         (vfwcvt_x): Ditto.
790         (vfwcvt_xu): Ditto.
791         (vfwcvt_rtz_x): Ditto.
792         (vfwcvt_rtz_xu) Ditto.:
793         (vfwcvt_f): Ditto.
794         (vfwcvt_x_frm): Ditto.
795         (vfwcvt_xu_frm) Ditto.:
796         (vfncvt_x): Ditto.
797         (vfncvt_xu): Ditto.
798         (vfncvt_rtz_x): Ditto.
799         (vfncvt_rtz_xu): Ditto.
800         (vfncvt_f): Ditto.
801         (vfncvt_rod_f): Ditto.
802         (vfncvt_x_frm): Ditto.
803         (vfncvt_xu_frm): Ditto.
804         (vfncvt_f_frm): Ditto.
805         (vredsum): Ditto.
806         (vredmaxu): Ditto.
807         (vredmax): Ditto.
808         (vredminu): Ditto.
809         (vredmin): Ditto.
810         (vredand): Ditto.
811         (vredor): Ditto.
812         (vredxor): Ditto.
813         (vwredsum): Ditto.
814         (vwredsumu): Ditto.
815         (vfredusum): Ditto.
816         (vfredosum): Ditto.
817         (vfredmax): Ditto.
818         (vfredmin): Ditto.
819         (vfredusum_frm): Ditto.
820         (vfredosum_frm): Ditto.
821         (vfwredosum): Ditto.
822         (vfwredusum): Ditto.
823         (vfwredosum_frm): Ditto.
824         (vfwredusum_frm): Ditto.
825         (vmand): Ditto.
826         (vmnand): Ditto.
827         (vmandn): Ditto.
828         (vmxor): Ditto.
829         (vmor): Ditto.
830         (vmnor): Ditto.
831         (vmorn): Ditto.
832         (vmxnor): Ditto.
833         (vmmv): Ditto.
834         (vmclr): Ditto.
835         (vmset): Ditto.
836         (vmnot): Ditto.
837         (vcpop): Ditto.
838         (vfirst): Ditto.
839         (vmsbf): Ditto.
840         (vmsif): Ditto.
841         (vmsof): Ditto.
842         (viota): Ditto.
843         (vid): Ditto.
844         (vmv_x): Ditto.
845         (vmv_s): Ditto.
846         (vfmv_f): Ditto.
847         (vfmv_s): Ditto.
848         (vslideup): Ditto.
849         (vslidedown): Ditto.
850         (vslide1up): Ditto.
851         (vslide1down): Ditto.
852         (vfslide1up): Ditto.
853         (vfslide1down): Ditto.
854         (vrgather): Ditto.
855         (vrgatherei16): Ditto.
856         (vcompress): Ditto.
857         (vundefined): Ditto.
858         (vreinterpret): Ditto.
859         (vlmul_ext): Ditto.
860         (vlmul_trunc): Ditto.
861         (vset): Ditto.
862         (vget): Ditto.
863         (vcreate): Ditto.
864         (vlseg): Ditto.
865         (vsseg): Ditto.
866         (vlsseg): Ditto.
867         (vssseg): Ditto.
868         (vluxseg): Ditto.
869         (vloxseg): Ditto.
870         (vsuxseg): Ditto.
871         (vsoxseg): Ditto.
872         (vlsegff): Ditto.
873         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_FUNCTION): Using variadic macro.
874         * config/riscv/riscv-vector-builtins.h (struct function_group_info):
875                                         Add avail function interface into struct.
876         * config/riscv/t-riscv: Add dependency
877         * config/riscv/riscv-vector-builtins-avail.h: New file.The definition of AVAIL marco.
879 2023-12-14  Jakub Jelinek  <jakub@redhat.com>
881         PR tree-optimization/112994
882         * match.pd ((t * u) / (t * v) -> (u / v)): New simplification.
884 2023-12-14  Jakub Jelinek  <jakub@redhat.com>
886         PR tree-optimization/112994
887         * match.pd ((t * 2) / 2 -> t): Adjust comment to use u instead of 2.
888         Punt without range checks if TYPE_OVERFLOW_SANITIZED.
889         ((t * u) / v -> t * (u / v)): New simplification.
891 2023-12-14  Filip Kastl  <fkastl@suse.cz>
893         * Makefile.in: Added sccopy pass.
894         * passes.def: Added sccopy pass before LTO streaming and before
895         RTL expansion.
896         * tree-pass.h (make_pass_sccopy): Added sccopy pass.
897         * gimple-ssa-sccopy.cc: New file.
899 2023-12-14  Martin Jambor  <mjambor@suse.cz>
901         PR tree-optimization/111807
902         * tree-sra.cc (build_ref_for_model): Allow offset smaller than
903         model->offset when gsi is non-NULL.  Adjust function comment.
905 2023-12-14  liuhongt  <hongtao.liu@intel.com>
907         PR target/112992
908         * config/i386/i386-expand.cc
909         (ix86_convert_const_wide_int_to_broadcast): Don't convert to
910         broadcast for vec_dup{v4di,v8si} when TARGET_AVX2 is not
911         available.
912         (ix86_broadcast_from_constant): Allow broadcast for V4DI/V8SI
913         when !TARGET_AVX2 since it will be forced to memory later.
914         (ix86_expand_vector_move): Force constant to mem for
915         vec_dup{vssi,v4di} when TARGET_AVX2 is not available.
917 2023-12-14  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
919         PR target/111153
920         * config/riscv/riscv-protos.h (struct common_vector_cost): New struct.
921         (struct scalable_vector_cost): Ditto.
922         (struct cpu_vector_cost): Ditto.
923         * config/riscv/riscv-vector-costs.cc (costs::add_stmt_cost): Add RVV
924         builtin vectorization cost
925         * config/riscv/riscv.cc (struct riscv_tune_param): Ditto.
926         (get_common_costs): New function.
927         (riscv_builtin_vectorization_cost): Ditto.
928         (TARGET_VECTORIZE_BUILTIN_VECTORIZATION_COST): New targethook.
930 2023-12-13  Richard Ball  <richard.ball@arm.com>
932         * config.gcc: Adds new header to config.
933         * config/aarch64/aarch64-builtins.cc (enum aarch64_type_qualifiers):
934         Moved to header file.
935         (ENTRY): Likewise.
936         (enum aarch64_simd_type): Likewise.
937         (struct aarch64_simd_type_info): Remove static.
938         (GTY): Likewise.
939         * config/aarch64/aarch64-c.cc (aarch64_pragma_aarch64):
940         Defines pragma for arm_neon_sve_bridge.h.
941         * config/aarch64/aarch64-protos.h:
942         Add handle_arm_neon_sve_bridge_h
943         * config/aarch64/aarch64-sve-builtins-base.h: New intrinsics.
944         * config/aarch64/aarch64-sve-builtins-base.cc
945         (class svget_neonq_impl): New intrinsic implementation.
946         (class svset_neonq_impl): Likewise.
947         (class svdup_neonq_impl): Likewise.
948         (NEON_SVE_BRIDGE_FUNCTION): New intrinsics.
949         * config/aarch64/aarch64-sve-builtins-functions.h
950         (NEON_SVE_BRIDGE_FUNCTION): Defines macro for NEON_SVE_BRIDGE
951         functions.
952         * config/aarch64/aarch64-sve-builtins-shapes.h: New shapes.
953         * config/aarch64/aarch64-sve-builtins-shapes.cc
954         (parse_element_type): Add NEON element types.
955         (parse_type): Likewise.
956         (struct get_neonq_def): Defines function shape for get_neonq.
957         (struct set_neonq_def): Defines function shape for set_neonq.
958         (struct dup_neonq_def): Defines function shape for dup_neonq.
959         * config/aarch64/aarch64-sve-builtins.cc
960         (DEF_SVE_TYPE_SUFFIX): Changed to be called through
961         SVE_NEON macro.
962         (DEF_SVE_NEON_TYPE_SUFFIX): Defines
963         macro for NEON_SVE_BRIDGE type suffixes.
964         (DEF_NEON_SVE_FUNCTION): Defines
965         macro for NEON_SVE_BRIDGE functions.
966         (function_resolver::infer_neon128_vector_type): Infers type suffix
967         for overloaded functions.
968         (handle_arm_neon_sve_bridge_h): Handles #pragma arm_neon_sve_bridge.h.
969         * config/aarch64/aarch64-sve-builtins.def
970         (DEF_SVE_NEON_TYPE_SUFFIX): Macro for handling neon_sve type suffixes.
971         (bf16): Replace entry with neon-sve entry.
972         (f16): Likewise.
973         (f32): Likewise.
974         (f64): Likewise.
975         (s8): Likewise.
976         (s16): Likewise.
977         (s32): Likewise.
978         (s64): Likewise.
979         (u8): Likewise.
980         (u16): Likewise.
981         (u32): Likewise.
982         (u64): Likewise.
983         * config/aarch64/aarch64-sve-builtins.h
984         (GCC_AARCH64_SVE_BUILTINS_H): Include aarch64-builtins.h.
985         (ENTRY): Add aarch64_simd_type definiton.
986         (enum aarch64_simd_type): Add neon information to type_suffix_info.
987         (struct type_suffix_info): New function.
988         * config/aarch64/aarch64-sve.md
989         (@aarch64_sve_get_neonq_<mode>): New intrinsic insn for big endian.
990         (@aarch64_sve_set_neonq_<mode>): Likewise.
991         * config/aarch64/iterators.md: Add UNSPEC_SET_NEONQ.
992         * config/aarch64/aarch64-builtins.h: New file.
993         * config/aarch64/aarch64-neon-sve-bridge-builtins.def: New file.
994         * config/aarch64/arm_neon_sve_bridge.h: New file.
996 2023-12-13  Patrick Palka  <ppalka@redhat.com>
998         * doc/invoke.texi (C++ Dialect Options): Document
999         -fdiagnostics-all-candidates.
1001 2023-12-13  Julian Brown  <julian@codesourcery.com>
1003         * gimplify.cc (omp_map_clause_descriptor_p): New function.
1004         (build_omp_struct_comp_nodes, omp_get_attachment, omp_group_base): Use
1005         above function.
1006         (omp_tsort_mapping_groups): Process nodes that have
1007         OMP_CLAUSE_MAP_RUNTIME_IMPLICIT_P set after those that don't.  Add
1008         enter_exit_data parameter.
1009         (omp_resolve_clause_dependencies): Remove GOMP_MAP_TO_PSET mappings if
1010         we're mapping the whole containing derived-type variable.
1011         (omp_accumulate_sibling_list): Adjust GOMP_MAP_TO_PSET handling.
1012         Remove GOMP_MAP_ALWAYS_POINTER handling.
1013         (gimplify_scan_omp_clauses): Pass enter_exit argument to
1014         omp_tsort_mapping_groups.  Don't adjust/remove GOMP_MAP_TO_PSET
1015         mappings for derived-type components here.
1016         * tree.h (OMP_CLAUSE_RELEASE_DESCRIPTOR): New macro.
1017         * tree-pretty-print.cc (dump_omp_clause): Show
1018         OMP_CLAUSE_RELEASE_DESCRIPTOR in dump output (with
1019         GOMP_MAP_TO_PSET-like syntax).
1021 2023-12-13  Julian Brown  <julian@codesourcery.com>
1023         * gimplify.cc (build_struct_comp_nodes): Don't process
1024         GOMP_MAP_ATTACH_DETACH "middle" nodes here.
1025         (omp_mapping_group): Add REPROCESS_STRUCT and FRAGILE booleans for
1026         nested struct handling.
1027         (omp_strip_components_and_deref, omp_strip_indirections): Remove
1028         functions.
1029         (omp_get_attachment): Handle GOMP_MAP_DETACH here.
1030         (omp_group_last): Handle GOMP_MAP_*, GOMP_MAP_DETACH,
1031         GOMP_MAP_ATTACH_DETACH groups for "exit data" of reference-to-pointer
1032         component array sections.
1033         (omp_gather_mapping_groups_1): Initialise reprocess_struct and fragile
1034         fields.
1035         (omp_group_base): Handle GOMP_MAP_ATTACH_DETACH after GOMP_MAP_STRUCT.
1036         (omp_index_mapping_groups_1): Skip reprocess_struct groups.
1037         (omp_get_nonfirstprivate_group, omp_directive_maps_explicitly,
1038         omp_resolve_clause_dependencies, omp_first_chained_access_token): New
1039         functions.
1040         (omp_check_mapping_compatibility): Adjust accepted node combinations
1041         for "from" clauses using release instead of alloc.
1042         (omp_accumulate_sibling_list): Add GROUP_MAP, ADDR_TOKENS, FRAGILE_P,
1043         REPROCESSING_STRUCT, ADDED_TAIL parameters.  Use OMP address tokenizer
1044         to analyze addresses.  Reimplement nested struct handling, and
1045         implement "fragile groups".
1046         (omp_build_struct_sibling_lists): Adjust for changes to
1047         omp_accumulate_sibling_list.  Recalculate bias for ATTACH_DETACH nodes
1048         after GOMP_MAP_STRUCT nodes.
1049         (gimplify_scan_omp_clauses): Call omp_resolve_clause_dependencies.  Use
1050         OMP address tokenizer.
1051         (gimplify_adjust_omp_clauses_1): Use build_fold_indirect_ref_loc
1052         instead of build_simple_mem_ref_loc.
1053         * omp-general.cc (omp-general.h, tree-pretty-print.h): Include.
1054         (omp_addr_tokenizer): New namespace.
1055         (omp_addr_tokenizer::omp_addr_token): New.
1056         (omp_addr_tokenizer::omp_parse_component_selector,
1057         omp_addr_tokenizer::omp_parse_ref,
1058         omp_addr_tokenizer::omp_parse_pointer,
1059         omp_addr_tokenizer::omp_parse_access_method,
1060         omp_addr_tokenizer::omp_parse_access_methods,
1061         omp_addr_tokenizer::omp_parse_structure_base,
1062         omp_addr_tokenizer::omp_parse_structured_expr,
1063         omp_addr_tokenizer::omp_parse_array_expr,
1064         omp_addr_tokenizer::omp_access_chain_p,
1065         omp_addr_tokenizer::omp_accessed_addr): New functions.
1066         (omp_parse_expr, debug_omp_tokenized_addr): New functions.
1067         * omp-general.h (omp_addr_tokenizer::access_method_kinds,
1068         omp_addr_tokenizer::structure_base_kinds,
1069         omp_addr_tokenizer::token_type,
1070         omp_addr_tokenizer::omp_addr_token,
1071         omp_addr_tokenizer::omp_access_chain_p,
1072         omp_addr_tokenizer::omp_accessed_addr): New.
1073         (omp_addr_token, omp_parse_expr): New.
1074         * omp-low.cc (scan_sharing_clauses): Skip error check for references
1075         to pointers.
1076         * tree.h (OMP_CLAUSE_ATTACHMENT_MAPPING_ERASED): New macro.
1078 2023-12-13  Andrew Stubbs  <ams@codesourcery.com>
1080         * config/gcn/gcn-hsa.h (NO_XNACK): Change the defaults.
1081         * config/gcn/gcn-opts.h (enum hsaco_attr_type): Add HSACO_ATTR_DEFAULT.
1082         * config/gcn/gcn.cc (gcn_option_override): Set the default flag_xnack.
1083         * config/gcn/gcn.opt: Add -mxnack=default.
1084         * doc/invoke.texi: Document the -mxnack default.
1086 2023-12-13  Andrew Stubbs  <ams@codesourcery.com>
1088         * config/gcn/gcn-hsa.h (NO_XNACK): Ignore missing -march.
1089         (XNACKOPT): Match on/off; ignore any.
1090         * config/gcn/gcn-valu.md (gather<mode>_insn_1offset<exec>):
1091         Add xnack compatible alternatives.
1092         (gather<mode>_insn_2offsets<exec>): Likewise.
1093         * config/gcn/gcn.cc (gcn_option_override): Permit -mxnack for devices
1094         other than Fiji and gfx1030.
1095         (gcn_expand_epilogue): Remove early-clobber problems.
1096         (gcn_hsa_declare_function_name): Obey -mxnack setting.
1097         * config/gcn/gcn.md (xnack): New attribute.
1098         (enabled): Rework to include "xnack" attribute.
1099         (*movbi): Add xnack compatible alternatives.
1100         (*mov<mode>_insn): Likewise.
1101         (*mov<mode>_insn): Likewise.
1102         (*mov<mode>_insn): Likewise.
1103         (*movti_insn): Likewise.
1104         * config/gcn/gcn.opt (-mxnack): Change the default to "any".
1105         * doc/invoke.texi: Remove placeholder notice for -mxnack.
1107 2023-12-13  Andrew Carlotti  <andrew.carlotti@arm.com>
1109         * config/aarch64/x-aarch64: Add missing dependencies.
1111 2023-12-13  Roger Sayle  <roger@nextmovesoftware.com>
1112             Jeff Law  <jlaw@ventanamicro.com>
1114         * config/arc/arc.md (*extvsi_n_0): New define_insn_and_split to
1115         implement SImode sign extract using a AND, XOR and MINUS sequence.
1117 2023-12-13  Feng Wang  <wangfeng@eswincomputing.com>
1119         * common/config/riscv/riscv-common.cc: Modify implied ISA info.
1120         * config/riscv/arch-canonicalize: Add crypto vector implied info.
1122 2023-12-13  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1124         PR target/112929
1125         PR target/112988
1126         * config/riscv/riscv-vsetvl.cc
1127         (pre_vsetvl::compute_lcm_local_properties): Remove full available.
1128         (pre_vsetvl::pre_global_vsetvl_info): Add full available optimization.
1130 2023-12-13  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1132         PR target/111317
1133         * tree-vect-loop.cc (vect_estimate_min_profitable_iters): Adjust for COST for decrement IV.
1135 2023-12-13  Jakub Jelinek  <jakub@redhat.com>
1137         PR tree-optimization/112940
1138         * gimple-lower-bitint.cc (struct bitint_large_huge): Add another
1139         argument to prepare_data_in_out method defaulted to NULL_TREE.
1140         (bitint_large_huge::handle_operand): Pass another argument to
1141         prepare_data_in_out instead of emitting an assignment to set it.
1142         (bitint_large_huge::prepare_data_in_out): Add VAL_OUT argument.
1143         If non-NULL, use it as PHI argument instead of creating a new
1144         SSA_NAME.
1145         (bitint_large_huge::handle_cast): Pass rext as another argument
1146         to 2 prepare_data_in_out calls instead of emitting assignments
1147         to set them.
1149 2023-12-13  Jakub Jelinek  <jakub@redhat.com>
1151         PR middle-end/112953
1152         * attribs.cc (free_attr_data): Use delete x rather than delete[] x.
1154 2023-12-13  Jakub Jelinek  <jakub@redhat.com>
1156         PR target/112962
1157         * config/i386/i386.cc (ix86_gimple_fold_builtin): For shifts
1158         and abs without lhs replace with nop.
1160 2023-12-13  Richard Biener  <rguenther@suse.de>
1162         * emit-rtl.cc (set_mem_attributes_minus_bitpos): Preserve
1163         the offset when rewriting an exising MEM_REF base for
1164         stack slot sharing.
1166 2023-12-13  Richard Biener  <rguenther@suse.de>
1168         PR tree-optimization/112991
1169         PR tree-optimization/112961
1170         * tree-ssa-sccvn.h (do_rpo_vn): Add skip_entry_phis argument.
1171         * tree-ssa-sccvn.cc (do_rpo_vn): Likewise.
1172         (do_rpo_vn_1): Likewise, merge with auto-processing.
1173         (run_rpo_vn): Adjust.
1174         (pass_fre::execute): Likewise.
1175         * tree-if-conv.cc (tree_if_conversion): Revert last change.
1176         Value-number latch block but disable value-numbering of
1177         entry PHIs.
1178         * tree-ssa-uninit.cc (execute_early_warn_uninitialized): Adjust.
1180 2023-12-13  Richard Biener  <rguenther@suse.de>
1182         PR tree-optimization/112990
1183         * match.pd (bit_insert @0 (BIT_FIELD_REF @1 ..) ..):
1184         Restrict to vector modes after lowering.
1186 2023-12-13  Richard Biener  <rguenther@suse.de>
1188         PR middle-end/111591
1189         * cfgexpand.cc (update_alias_info_with_stack_vars): Document
1190         why not adjusting TBAA info on accesses is OK.
1192 2023-12-13  Alexandre Oliva  <oliva@adacore.com>
1194         * doc/invoke.texi (multiflags): Drop extraneous period, use
1195         @pxref instead.
1197 2023-12-13  Victor Do Nascimento  <victor.donascimento@arm.com>
1199         * config/aarch64/aarch64-builtins.cc:
1200         (AARCH64_PLD): New enum aarch64_builtins entry.
1201         (AARCH64_PLDX): Likewise.
1202         (AARCH64_PLI): Likewise.
1203         (AARCH64_PLIX): Likewise.
1204         (aarch64_init_prefetch_builtin): New.
1205         (aarch64_general_init_builtins): Call prefetch init function.
1206         (aarch64_expand_prefetch_builtin): New.
1207         (aarch64_general_expand_builtin):  Add prefetch expansion.
1208         (require_const_argument): New.
1209         * config/aarch64/aarch64.md (UNSPEC_PLDX): New.
1210         (aarch64_pldx): Likewise.
1211         * config/aarch64/arm_acle.h (__pld): Likewise.
1212         (__pli): Likewise.
1213         (__plix): Likewise.
1214         (__pldx): Likewise.
1216 2023-12-13  Kewen Lin  <linkw@linux.ibm.com>
1218         PR tree-optimization/112788
1219         * value-range.h (range_compatible_p): Workaround same type mode but
1220         different type precision issue for rs6000 scalar float types
1221         _Float128 and long double.
1223 2023-12-13  Jiufu Guo  <guojiufu@linux.ibm.com>
1225         * config/rs6000/rs6000.cc (rs6000_emit_set_long_const): Add code to use
1226         pli for 34bit constant.
1228 2023-12-13  Jiufu Guo  <guojiufu@linux.ibm.com>
1230         * config/rs6000/rs6000.cc (rs6000_emit_set_long_const): Add new
1231         parameter to record number of instructions to build the constant.
1232         (num_insns_constant_gpr): Call rs6000_emit_set_long_const to compute
1233         num_insn.
1235 2023-12-12  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1237         * config/riscv/riscv-vector-costs.cc (costs::analyze_loop_vinfo): New function.
1238         (costs::record_potential_vls_unrolling): Ditto.
1239         (costs::prefer_unrolled_loop): Ditto.
1240         (costs::better_main_loop_than_p): Ditto.
1241         (costs::add_stmt_cost): Ditto.
1242         * config/riscv/riscv-vector-costs.h (enum cost_type_enum): New enum.
1243         * config/riscv/t-riscv: Add new include files.
1245 2023-12-12  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1247         * config/riscv/riscv-vector-costs.cc (get_current_lmul): Remove it.
1248         (compute_estimated_lmul): New function.
1249         (costs::costs): Refactor.
1250         (costs::preferred_new_lmul_p): Ditto.
1251         (preferred_new_lmul_p): Ditto.
1252         (costs::better_main_loop_than_p): Ditto.
1253         * config/riscv/riscv-vector-costs.h (struct autovec_info): Remove it.
1255 2023-12-12  Martin Jambor  <mjambor@suse.cz>
1257         PR tree-optimization/112822
1258         * tree-sra.cc (load_assign_lhs_subreplacements): Invoke
1259         force_gimple_operand_gsi also when LHS has partial stores and RHS is a
1260         VIEW_CONVERT_EXPR.
1262 2023-12-12  Jason Merrill  <jason@redhat.com>
1263             Nathaniel Shead   <nathanieloshead@gmail.com>
1265         * tree-core.h (enum clobber_kind): Rename CLOBBER_EOL to
1266         CLOBBER_STORAGE_END.  Add CLOBBER_STORAGE_BEGIN,
1267         CLOBBER_OBJECT_BEGIN, CLOBBER_OBJECT_END.
1268         * gimple-lower-bitint.cc
1269         * gimple-ssa-warn-access.cc
1270         * gimplify.cc
1271         * tree-inline.cc
1272         * tree-ssa-ccp.cc: Adjust for rename.
1273         * tree-pretty-print.cc: And handle new values.
1275 2023-12-12  Szabolcs Nagy  <szabolcs.nagy@arm.com>
1277         * config/aarch64/aarch64.cc (aarch64_override_options): Update.
1278         (aarch64_handle_attr_branch_protection): Update.
1279         * config/arm/aarch-common-protos.h (aarch_parse_branch_protection):
1280         Remove.
1281         (aarch_validate_mbranch_protection): Add new argument.
1282         * config/arm/aarch-common.cc (aarch_handle_no_branch_protection):
1283         Update.
1284         (aarch_handle_standard_branch_protection): Update.
1285         (aarch_handle_pac_ret_protection): Update.
1286         (aarch_handle_pac_ret_leaf): Update.
1287         (aarch_handle_pac_ret_b_key): Update.
1288         (aarch_handle_bti_protection): Update.
1289         (aarch_parse_branch_protection): Remove.
1290         (next_tok): New.
1291         (aarch_validate_mbranch_protection): Rewrite.
1292         * config/arm/aarch-common.h (struct aarch_branch_protect_type):
1293         Add field "alone".
1294         * config/arm/arm.cc (arm_configure_build_target): Update.
1296 2023-12-12  Szabolcs Nagy  <szabolcs.nagy@arm.com>
1298         * config/aarch64/aarch64.cc (aarch64_override_options_after_change_1):
1299         Do not override branch_protection options.
1300         (aarch64_override_options): Remove accepted_branch_protection_string.
1301         * config/arm/aarch-common.cc (BRANCH_PROTECT_STR_MAX): Remove.
1302         (aarch_parse_branch_protection): Remove
1303         accepted_branch_protection_string.
1304         * config/arm/arm.cc: Likewise.
1306 2023-12-12  Richard Biener  <rguenther@suse.de>
1308         PR tree-optimization/112736
1309         * tree-vect-stmts.cc (vectorizable_load): Extend optimization
1310         to avoid peeling for gaps to handle single-element non-groups
1311         we now allow with SLP.
1313 2023-12-12  Richard Biener  <rguenther@suse.de>
1315         PR ipa/92606
1316         * ipa-icf.cc (sem_item_optimizer::merge_classes): Check
1317         both source and alias for the no_icf attribute.
1318         * doc/extend.texi (no_icf): Document variable attribute.
1320 2023-12-12  Richard Biener  <rguenther@suse.de>
1322         PR tree-optimization/112961
1323         * tree-if-conv.cc (tree_if_conversion): Instead of excluding
1324         the latch block from VN, add a fake entry edge.
1326 2023-12-12  Xi Ruoyao  <xry111@xry111.site>
1328         PR middle-end/107723
1329         * convert.cc (convert_to_integer_1) [case BUILT_IN_TRUNC]: Break
1330         early if !flag_fp_int_builtin_inexact and flag_trapping_math.
1332 2023-12-12  Pan Li  <pan2.li@intel.com>
1334         * config/riscv/riscv-avlprop.cc (avl_can_be_propagated_p):
1335         Disable the avl propogation for the vcompress.
1337 2023-12-12  Xi Ruoyao  <xry111@xry111.site>
1339         * config/loongarch/loongarch-opts.h (la_target): Move into #if
1340         for loongarch-def.h.
1341         (loongarch_init_target): Likewise.
1342         (loongarch_config_target): Likewise.
1343         (loongarch_update_gcc_opt_status): Likewise.
1345 2023-12-12  Xi Ruoyao  <xry111@xry111.site>
1347         * config/loongarch/loongarch.cc (loongarch_explicit_relocs_p):
1348         Return true for SYMBOL_PCREL64.  Return true for SYMBOL_GOT_DISP
1349         if TARGET_CMODEL_EXTREME.
1350         (loongarch_split_symbol): Check for la_opt_explicit_relocs !=
1351         EXPLICIT_RELOCS_NONE instead of TARGET_EXPLICIT_RELOCS.
1352         (loongarch_print_operand_reloc): Likewise.
1353         (loongarch_option_override_internal): Likewise.
1354         (loongarch_handle_model_attribute): Likewise.
1355         * doc/invoke.texi (-mcmodel=extreme): Update the compatibility
1356         between it and -mexplicit-relocs=.
1358 2023-12-12  Richard Biener  <rguenther@suse.de>
1360         PR tree-optimization/112939
1361         * tree-ssa-sccvn.cc (visit_phi): When all args are undefined
1362         make sure we end up with a value that was visited, otherwise
1363         fall back to .VN_TOP.
1365 2023-12-12  liuhongt  <hongtao.liu@intel.com>
1367         PR target/112891
1368         * config/i386/i386.cc (ix86_avx_u128_mode_after): Return
1369         AVX_U128_ANY if callee_abi doesn't clobber all_sse_regs to
1370         align with ix86_avx_u128_mode_needed.
1371         (ix86_avx_u128_mode_needed): Return AVX_U128_ClEAN for
1372         sibling_call.
1374 2023-12-12  Alexandre Oliva  <oliva@adacore.com>
1376         PR target/112334
1377         * builtins.h (target_builtins): Add fields for apply_args_size
1378         and apply_result_size.
1379         * builtins.cc (apply_args_size, apply_result_size): Cache
1380         results in fields rather than in static variables.
1381         (get_apply_args_size, set_apply_args_size): New.
1382         (get_apply_result_size, set_apply_result_size): New.
1384 2023-12-12  Hongyu Wang  <hongyu.wang@intel.com>
1386         PR target/112943
1387         * config/i386/i386.md (ashl<mode>3): Add TARGET_APX_NDD to
1388         ix86_expand_binary_operator call.
1389         (<insn><mode>3): Likewise for rshift.
1390         (<insn>di3): Likewise for DImode rotate.
1391         (<insn><mode>3): Likewise for SWI124 rotate.
1393 2023-12-12  Feng Wang  <wangfeng@eswincomputing.com>
1395         * config/riscv/riscv-vector-builtins-functions.def (DEF_RVV_FUNCTION):
1396                                                         Add AVAIL argument.
1397         (read_vl): Using AVAIL argument default value.
1398         (vlenb): Ditto.
1399         (vsetvl): Ditto.
1400         (vsetvlmax): Ditto.
1401         (vle): Ditto.
1402         (vse): Ditto.
1403         (vlm): Ditto.
1404         (vsm): Ditto.
1405         (vlse): Ditto.
1406         (vsse): Ditto.
1407         (vluxei8): Ditto.
1408         (vluxei16): Ditto.
1409         (vluxei32): Ditto.
1410         (vluxei64): Ditto.
1411         (vloxei8): Ditto.
1412         (vloxei16): Ditto.
1413         (vloxei32): Ditto.
1414         (vloxei64): Ditto.
1415         (vsuxei8): Ditto.
1416         (vsuxei16): Ditto.
1417         (vsuxei32): Ditto.
1418         (vsuxei64): Ditto.
1419         (vsoxei8): Ditto.
1420         (vsoxei16): Ditto.
1421         (vsoxei32): Ditto.
1422         (vsoxei64): Ditto.
1423         (vleff): Ditto.
1424         (vadd): Ditto.
1425         (vsub): Ditto.
1426         (vrsub): Ditto.
1427         (vneg): Ditto.
1428         (vwaddu): Ditto.
1429         (vwsubu): Ditto.
1430         (vwadd): Ditto.
1431         (vwsub): Ditto.
1432         (vwcvt_x): Ditto.
1433         (vwcvtu_x): Ditto.
1434         (vzext): Ditto.
1435         (vsext): Ditto.
1436         (vadc): Ditto.
1437         (vmadc): Ditto.
1438         (vsbc): Ditto.
1439         (vmsbc): Ditto.
1440         (vand): Ditto.
1441         (vor): Ditto.
1442         (vxor): Ditto.
1443         (vnot): Ditto.
1444         (vsll): Ditto.
1445         (vsra): Ditto.
1446         (vsrl): Ditto.
1447         (vnsrl): Ditto.
1448         (vnsra): Ditto.
1449         (vncvt_x): Ditto.
1450         (vmseq): Ditto.
1451         (vmsne): Ditto.
1452         (vmsltu): Ditto.
1453         (vmslt): Ditto.
1454         (vmsleu): Ditto.
1455         (vmsle): Ditto.
1456         (vmsgtu): Ditto.
1457         (vmsgt): Ditto.
1458         (vmsgeu): Ditto.
1459         (vmsge): Ditto.
1460         (vminu): Ditto.
1461         (vmin): Ditto.
1462         (vmaxu): Ditto.
1463         (vmax): Ditto.
1464         (vmul): Ditto.
1465         (vmulh): Ditto.
1466         (vmulhu): Ditto.
1467         (vmulhsu): Ditto.
1468         (vdivu): Ditto.
1469         (vdiv): Ditto.
1470         (vremu): Ditto.
1471         (vrem): Ditto.
1472         (vwmul): Ditto.
1473         (vwmulu): Ditto.
1474         (vwmulsu): Ditto.
1475         (vmacc): Ditto.
1476         (vnmsac): Ditto.
1477         (vmadd): Ditto.
1478         (vnmsub): Ditto.
1479         (vwmaccu): Ditto.
1480         (vwmacc): Ditto.
1481         (vwmaccsu): Ditto.
1482         (vwmaccus): Ditto.
1483         (vmerge): Ditto.
1484         (vmv_v): Ditto.
1485         (vsaddu): Ditto.
1486         (vsadd): Ditto.
1487         (vssubu): Ditto.
1488         (vssub): Ditto.
1489         (vaaddu): Ditto.
1490         (vaadd): Ditto.
1491         (vasubu): Ditto.
1492         (vasub): Ditto.
1493         (vsmul): Ditto.
1494         (vssrl): Ditto.
1495         (vssra): Ditto.
1496         (vnclipu): Ditto.
1497         (vnclip): Ditto.
1498         (vfadd): Ditto.
1499         (vfsub): Ditto.
1500         (vfrsub): Ditto.
1501         (vfadd_frm): Ditto.
1502         (vfsub_frm): Ditto.
1503         (vfrsub_frm): Ditto.
1504         (vfwadd): Ditto.
1505         (vfwsub): Ditto.
1506         (vfwadd_frm): Ditto.
1507         (vfwsub_frm): Ditto.
1508         (vfmul): Ditto.
1509         (vfdiv): Ditto.
1510         (vfrdiv): Ditto.
1511         (vfmul_frm): Ditto.
1512         (vfdiv_frm): Ditto.
1513         (vfrdiv_frm): Ditto.
1514         (vfwmul): Ditto.
1515         (vfwmul_frm): Ditto.
1516         (vfmacc): Ditto.
1517         (vfnmsac): Ditto.
1518         (vfmadd): Ditto.
1519         (vfnmsub): Ditto.
1520         (vfnmacc): Ditto.
1521         (vfmsac): Ditto.
1522         (vfnmadd): Ditto.
1523         (vfmsub): Ditto.
1524         (vfmacc_frm): Ditto.
1525         (vfnmacc_frm): Ditto.
1526         (vfmsac_frm): Ditto.
1527         (vfnmsac_frm): Ditto.
1528         (vfmadd_frm): Ditto.
1529         (vfnmadd_frm): Ditto.
1530         (vfmsub_frm): Ditto.
1531         (vfnmsub_frm): Ditto.
1532         (vfwmacc): Ditto.
1533         (vfwnmacc): Ditto.
1534         (vfwmsac): Ditto.
1535         (vfwnmsac): Ditto.
1536         (vfwmacc_frm): Ditto.
1537         (vfwnmacc_frm): Ditto.
1538         (vfwmsac_frm): Ditto.
1539         (vfwnmsac_frm): Ditto.
1540         (vfsqrt): Ditto.
1541         (vfsqrt_frm): Ditto.
1542         (vfrsqrt7): Ditto.
1543         (vfrec7): Ditto.
1544         (vfrec7_frm): Ditto.
1545         (vfmin): Ditto.
1546         (vfmax): Ditto.
1547         (vfsgnj): Ditto.
1548         (vfsgnjn): Ditto.
1549         (vfsgnjx): Ditto.
1550         (vfneg): Ditto.
1551         (vfabs): Ditto.
1552         (vmfeq): Ditto.
1553         (vmfne): Ditto.
1554         (vmflt): Ditto.
1555         (vmfle): Ditto.
1556         (vmfgt): Ditto.
1557         (vmfge): Ditto.
1558         (vfclass): Ditto.
1559         (vfmerge): Ditto.
1560         (vfmv_v): Ditto.
1561         (vfcvt_x): Ditto.
1562         (vfcvt_xu): Ditto.
1563         (vfcvt_rtz_x): Ditto.
1564         (vfcvt_rtz_xu): Ditto.
1565         (vfcvt_f): Ditto.
1566         (vfcvt_x_frm): Ditto.
1567         (vfcvt_xu_frm): Ditto.
1568         (vfcvt_f_frm): Ditto.
1569         (vfwcvt_x): Ditto.
1570         (vfwcvt_xu): Ditto.
1571         (vfwcvt_rtz_x): Ditto.
1572         (vfwcvt_rtz_xu) Ditto.:
1573         (vfwcvt_f): Ditto.
1574         (vfwcvt_x_frm): Ditto.
1575         (vfwcvt_xu_frm) Ditto.:
1576         (vfncvt_x): Ditto.
1577         (vfncvt_xu): Ditto.
1578         (vfncvt_rtz_x): Ditto.
1579         (vfncvt_rtz_xu): Ditto.
1580         (vfncvt_f): Ditto.
1581         (vfncvt_rod_f): Ditto.
1582         (vfncvt_x_frm): Ditto.
1583         (vfncvt_xu_frm): Ditto.
1584         (vfncvt_f_frm): Ditto.
1585         (vredsum): Ditto.
1586         (vredmaxu): Ditto.
1587         (vredmax): Ditto.
1588         (vredminu): Ditto.
1589         (vredmin): Ditto.
1590         (vredand): Ditto.
1591         (vredor): Ditto.
1592         (vredxor): Ditto.
1593         (vwredsum): Ditto.
1594         (vwredsumu): Ditto.
1595         (vfredusum): Ditto.
1596         (vfredosum): Ditto.
1597         (vfredmax): Ditto.
1598         (vfredmin): Ditto.
1599         (vfredusum_frm): Ditto.
1600         (vfredosum_frm): Ditto.
1601         (vfwredosum): Ditto.
1602         (vfwredusum): Ditto.
1603         (vfwredosum_frm): Ditto.
1604         (vfwredusum_frm): Ditto.
1605         (vmand): Ditto.
1606         (vmnand): Ditto.
1607         (vmandn): Ditto.
1608         (vmxor): Ditto.
1609         (vmor): Ditto.
1610         (vmnor): Ditto.
1611         (vmorn): Ditto.
1612         (vmxnor): Ditto.
1613         (vmmv): Ditto.
1614         (vmclr): Ditto.
1615         (vmset): Ditto.
1616         (vmnot): Ditto.
1617         (vcpop): Ditto.
1618         (vfirst): Ditto.
1619         (vmsbf): Ditto.
1620         (vmsif): Ditto.
1621         (vmsof): Ditto.
1622         (viota): Ditto.
1623         (vid): Ditto.
1624         (vmv_x): Ditto.
1625         (vmv_s): Ditto.
1626         (vfmv_f): Ditto.
1627         (vfmv_s): Ditto.
1628         (vslideup): Ditto.
1629         (vslidedown): Ditto.
1630         (vslide1up): Ditto.
1631         (vslide1down): Ditto.
1632         (vfslide1up): Ditto.
1633         (vfslide1down): Ditto.
1634         (vrgather): Ditto.
1635         (vrgatherei16): Ditto.
1636         (vcompress): Ditto.
1637         (vundefined): Ditto.
1638         (vreinterpret): Ditto.
1639         (vlmul_ext): Ditto.
1640         (vlmul_trunc): Ditto.
1641         (vset): Ditto.
1642         (vget): Ditto.
1643         (vcreate): Ditto.
1644         (vlseg): Ditto.
1645         (vsseg): Ditto.
1646         (vlsseg): Ditto.
1647         (vssseg): Ditto.
1648         (vluxseg): Ditto.
1649         (vloxseg): Ditto.
1650         (vsuxseg): Ditto.
1651         (vsoxseg): Ditto.
1652         (vlsegff): Ditto.
1653         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_FUNCTION): Using variadic macro.
1654         * config/riscv/riscv-vector-builtins.h (struct function_group_info):
1655                                         Add avail function interface into struct.
1656         * config/riscv/t-riscv: Add dependency
1657         * config/riscv/riscv-vector-builtins-avail.h: New file.The definition of AVAIL marco.
1659 2023-12-12  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1661         * config/riscv/riscv-protos.h (estimated_poly_value): New function.
1662         * config/riscv/riscv-v.cc (estimated_poly_value): Ditto.
1663         * config/riscv/riscv.cc (riscv_estimated_poly_value): Move RVV POLY
1664         VALUE estimation to riscv-v.cc
1666 2023-12-12  Yang Yujie  <yangyujie@loongson.cn>
1668         * config/loongarch/loongarch.cc: Do not restore the saved eh_return
1669         data registers ($r4-$r7) for a normal return of a function that calls
1670         __builtin_eh_return elsewhere.
1671         * config/loongarch/loongarch-protos.h: Same.
1672         * config/loongarch/loongarch.md: Same.
1674 2023-12-11  Richard Sandiford  <richard.sandiford@arm.com>
1676         * recog.cc (constrain_operands): Pass VOIDmode to
1677         strict_memory_address_p for 'p' constraints in asms.
1678         * rtl-ssa/changes.cc (recog_level2): Skip redundant constrain_operands
1679         for asms.
1681 2023-12-11  Jason Merrill  <jason@redhat.com>
1683         * common.opt: Add comment.
1685 2023-12-11  Alexandre Oliva  <oliva@adacore.com>
1687         PR middle-end/112784
1688         * expr.cc (emit_block_move_via_loop): Call int_mode_for_size
1689         for maybe-too-wide sizes.
1690         (emit_block_cmp_via_loop): Likewise.
1692 2023-12-11  Alexandre Oliva  <oliva@adacore.com>
1694         PR target/112778
1695         * builtins.cc (can_store_by_multiple_pieces): New.
1696         (try_store_by_multiple_pieces): Call it.
1698 2023-12-11  Alexandre Oliva  <oliva@adacore.com>
1700         PR target/112804
1701         * builtins.cc (try_store_by_multiple_pieces): Use ptr's mode
1702         for the increment.
1704 2023-12-11  Alexandre Oliva  <oliva@adacore.com>
1706         * doc/invoke.texi (multiflags): Add period after @xref to
1707         silence warning.
1709 2023-12-11  Alexandre Oliva  <oliva@adacore.com>
1711         * config/rl78/rl78.cc (TARGET_HAVE_STRUB_SUPPORT_FOR): Disable.
1713 2023-12-11  Alexandre Oliva  <oliva@adacore.com>
1715         * ipa-strub.cc (pass_ipa_strub::execute): Check that we don't
1716         add indirection to pointer parameters, and document attribute
1717         access non-interactions.
1719 2023-12-11  Roger Sayle  <roger@nextmovesoftware.com>
1721         PR rtl-optimization/112380
1722         * combine.cc (expand_field_assignment): Check if gen_lowpart
1723         returned a CLOBBER, and avoid calling gen_simplify_binary with
1724         it if so.
1726 2023-12-11  Andrew Pinski  <quic_apinski@quicinc.com>
1728         PR target/111867
1729         * config/aarch64/aarch64.cc (aarch64_float_const_representable_p): For BFmode,
1730         only accept +0.0.
1732 2023-12-11  Andrew Pinski  <quic_apinski@quicinc.com>
1734         PR tree-optimization/111972
1735         PR tree-optimization/110637
1736         * match.pd (`(convert)(zeroone !=/== CST)`): Match
1737         and simplify to ((convert)zeroone){,^1}.
1738         * fold-const.cc (fold_binary_loc): Remove
1739         transformation of `(~a) & 1` and `(a ^ 1) & 1`
1740         into `(convert)(a == 0)`.
1742 2023-12-11  Andrew Pinski  <quic_apinski@quicinc.com>
1744         PR middle-end/112935
1745         * expr.cc (expand_expr_real_2): Use
1746         gimple_zero_one_valued_p instead of tree_nonzero_bits
1747         to find boolean defined expressions.
1749 2023-12-11  Mikael Pettersson  <mikpelinux@gmail.com>
1751         PR target/112413
1752         * config/m68k/linux.h (ASM_RETURN_CASE_JUMP): For
1753         TARGET_LONG_JUMP_TABLE_OFFSETS, reference the jump table
1754         via its label.
1755         * config/m68k/m68kelf.h (ASM_RETURN_CASE_JUMP): Likewise.
1756         * config/m68k/netbsd-elf.h (ASM_RETURN_CASE_JUMP): Likewise.
1758 2023-12-11  Andre Vieira  <andre.simoesdiasvieira@arm.com>
1760         * config/aarch64/aarch64.cc (lane_size): New function.
1761         (aarch64_simd_clone_compute_vecsize_and_simdlen): Determine simdlen according to NDS rule
1762         and reject combination of simdlen and types that lead to vectors larger than 128bits.
1764 2023-12-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1766         * rtl-ssa/insns.cc (function_info::record_use): Add !ordered_p case.
1768 2023-12-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1770         * config/riscv/riscv-v.cc (get_gather_index_mode): New function.
1771         (shuffle_series_patterns): Robostify shuffle index.
1772         (shuffle_generic_patterns): Ditto.
1774 2023-12-11  Victor Do Nascimento  <victor.donascimento@arm.com>
1776         * config/aarch64/arm_neon.h (vldap1_lane_u64): Add
1777         `const' to `__builtin_aarch64_simd_di *' cast.
1778         (vldap1q_lane_u64): Likewise.
1779         (vldap1_lane_s64): Cast __src to `const __builtin_aarch64_simd_di *'.
1780         (vldap1q_lane_s64): Likewise.
1781         (vldap1_lane_f64): Cast __src to `const __builtin_aarch64_simd_df *'.
1782         (vldap1q_lane_f64): Cast __src to `const __builtin_aarch64_simd_df *'.
1783         (vldap1_lane_p64): Add `const' to `__builtin_aarch64_simd_di *' cast.
1784         (vldap1q_lane_p64): Add `const' to `__builtin_aarch64_simd_di *' cast.
1785         (vstl1_lane_u64): remove stray `const'.
1786         (vstl1_lane_s64): Cast __src to `__builtin_aarch64_simd_di *'.
1787         (vstl1q_lane_s64): Likewise.
1788         (vstl1_lane_f64): Cast __src to `const __builtin_aarch64_simd_df *'.
1789         (vstl1q_lane_f64): Likewise.
1791 2023-12-11  Robin Dapp  <rdapp@ventanamicro.com>
1793         PR target/112853
1794         * config/riscv/riscv-v.cc (expand_const_vector):  Fix step
1795         calculation.
1796         (modulo_sel_indices): Also perform modulo for variable-length
1797         constants.
1798         (shuffle_series): Recognize series permutations.
1799         (expand_vec_perm_const_1): Add shuffle_series.
1801 2023-12-11  liuhongt  <hongtao.liu@intel.com>
1803         * match.pd (VCE (a cmp b ? -1 : 0) < 0) ? c : d ---> (VCE ((a
1804         cmp b) ? (VCE:c) : (VCE:d))): New gimple simplication.
1806 2023-12-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1808         PR target/112431
1809         * config/riscv/vector.md: Support highest overlap for wv instructions.
1811 2023-12-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1813         * config/riscv/riscv-vsetvl.cc (extract_single_source): Fix ICE.
1815 2023-12-11  Jakub Jelinek  <jakub@redhat.com>
1817         * doc/extend.texi (__sync_fetch_and_add, __sync_fetch_and_sub,
1818         __sync_fetch_and_or, __sync_fetch_and_and, __sync_fetch_and_xor,
1819         __sync_fetch_and_nand, __sync_add_and_fetch, __sync_sub_and_fetch,
1820         __sync_or_and_fetch, __sync_and_and_fetch, __sync_xor_and_fetch,
1821         __sync_nand_and_fetch, __sync_bool_compare_and_swap,
1822         __sync_val_compare_and_swap, __sync_lock_test_and_set,
1823         __sync_lock_release, __atomic_load_n, __atomic_load, __atomic_store_n,
1824         __atomic_store, __atomic_exchange_n, __atomic_exchange,
1825         __atomic_compare_exchange_n, __atomic_compare_exchange,
1826         __atomic_add_fetch, __atomic_sub_fetch, __atomic_and_fetch,
1827         __atomic_xor_fetch, __atomic_or_fetch, __atomic_nand_fetch,
1828         __atomic_fetch_add, __atomic_fetch_sub, __atomic_fetch_and,
1829         __atomic_fetch_xor, __atomic_fetch_or, __atomic_fetch_nand,
1830         __atomic_test_and_set, __atomic_clear, __atomic_thread_fence,
1831         __atomic_signal_fence, __atomic_always_lock_free,
1832         __atomic_is_lock_free, __builtin_add_overflow,
1833         __builtin_sadd_overflow, __builtin_saddl_overflow,
1834         __builtin_saddll_overflow, __builtin_uadd_overflow,
1835         __builtin_uaddl_overflow, __builtin_uaddll_overflow,
1836         __builtin_sub_overflow, __builtin_ssub_overflow,
1837         __builtin_ssubl_overflow, __builtin_ssubll_overflow,
1838         __builtin_usub_overflow, __builtin_usubl_overflow,
1839         __builtin_usubll_overflow, __builtin_mul_overflow,
1840         __builtin_smul_overflow, __builtin_smull_overflow,
1841         __builtin_smulll_overflow, __builtin_umul_overflow,
1842         __builtin_umull_overflow, __builtin_umulll_overflow,
1843         __builtin_add_overflow_p, __builtin_sub_overflow_p,
1844         __builtin_mul_overflow_p, __builtin_addc, __builtin_addcl,
1845         __builtin_addcll, __builtin_subc, __builtin_subcl, __builtin_subcll,
1846         __builtin_alloca, __builtin_alloca_with_align,
1847         __builtin_alloca_with_align_and_max, __builtin_speculation_safe_value,
1848         __builtin_nan, __builtin_nand32, __builtin_nand64, __builtin_nand128,
1849         __builtin_nanf, __builtin_nanl, __builtin_nanf@var{n},
1850         __builtin_nanf@var{n}x, __builtin_nans, __builtin_nansd32,
1851         __builtin_nansd64, __builtin_nansd128, __builtin_nansf,
1852         __builtin_nansl, __builtin_nansf@var{n}, __builtin_nansf@var{n}x,
1853         __builtin_ffs, __builtin_clz, __builtin_ctz, __builtin_clrsb,
1854         __builtin_popcount, __builtin_parity, __builtin_bswap16,
1855         __builtin_bswap32, __builtin_bswap64, __builtin_bswap128,
1856         __builtin_extend_pointer, __builtin_goacc_parlevel_id,
1857         __builtin_goacc_parlevel_size, vec_clrl, vec_clrr, vec_mulh, vec_mul,
1858         vec_div, vec_dive, vec_mod, __builtin_rx_mvtc): Use @var{...} around
1859         parameter names.
1860         (vec_rl, vec_sl, vec_sr, vec_sra): Likewise.  Use @var{...} also
1861         around A, B and R in description.
1863 2023-12-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1865         * config/riscv/riscv-selftests.cc (riscv_run_selftests):
1866         Remove poly self test when FIXED-VLMAX.
1868 2023-12-11  Fei Gao  <gaofei@eswincomputing.com>
1869             Xiao Zeng <zengxiao@eswincomputing.com>
1871         * ifcvt.cc (noce_cond_zero_binary_op_supported): Add support for AND.
1872         (noce_bbs_ok_for_cond_zero_arith): Likewise.
1873         (noce_try_cond_zero_arith): Likewise.
1875 2023-12-11  liuhongt  <hongtao.liu@intel.com>
1877         PR target/112904
1878         * config/i386/mmx.md (*xop_pcmov_<mode>): New define_insn.
1880 2023-12-11  Haochen Gui  <guihaoc@gcc.gnu.org>
1882         PR target/112707
1883         * config/rs6000/rs6000.h (TARGET_FCTID): Define.
1884         * config/rs6000/rs6000.md (lrint<mode>di2): Add guard TARGET_FCTID.
1885         * (lround<mode>di2): Replace TARGET_FPRND with TARGET_FCTID.
1887 2023-12-11  Haochen Gui  <guihaoc@gcc.gnu.org>
1889         PR target/112707
1890         * config/rs6000/rs6000.md (expand lrint<mode>si2): New.
1891         (insn lrint<mode>si2): Rename to...
1892         (*lrint<mode>si): ...this.
1893         (lrint<mode>si_di): New.
1895 2023-12-10  Fei Gao  <gaofei@eswincomputing.com>
1896             Xiao Zeng <zengxiao@eswincomputing.com>
1898         * ifcvt.cc (noce_cond_zero_binary_op_supported): Add support for shift
1899         like op.
1901 2023-12-10  Richard Sandiford  <richard.sandiford@arm.com>
1903         PR target/112931
1904         PR target/112933
1905         * config/aarch64/aarch64-protos.h (aarch64_sve_reinterpret): Declare.
1906         * config/aarch64/aarch64.cc (aarch64_sve_reinterpret): New function.
1907         * config/aarch64/aarch64-sve-builtins-sme.cc (svread_za_impl::expand)
1908         (svwrite_za_impl::expand): Use it to cast the SVE register to the
1909         right mode.
1911 2023-12-10  Richard Sandiford  <richard.sandiford@arm.com>
1913         PR target/112930
1914         * config/aarch64/aarch64.cc (aarch64_sme_mode_switch_regs::add_reg):
1915         Force specific SVE modes for single registers as well as structures.
1917 2023-12-10  Jason Merrill  <jason@redhat.com>
1919         * doc/invoke.texi (-fpermissive): Mention ObjC++ for -Wnarrowing.
1921 2023-12-10  Jeff Law  <jlaw@ventanamicro.com>
1923         * config/h8300/addsub.md (uaddv<mode>4, usubv<mode>4): New expanders.
1924         (uaddv): New define_insn_and_split plus post-reload pattern.
1926 2023-12-10  Jeff Law  <jlaw@ventanamicro.com>
1928         * config/h8300/h8300-protos.h (use_extvsi): Prototype.
1929         * config/h8300/combiner.md: Two new define_insn_and_split patterns
1930         to implement signed bitfield extractions.
1931         * config/h8300/h8300.cc (use_extvsi): New function.
1933 2023-12-10  Jeff Law  <jlaw@ventanamicro.com>
1935         * config/h8300/combiner.md (single bit signed bitfield extraction): Fix
1936         length computation when the bit we want is in the low half word.
1938 2023-12-10  Jeff Law  <jlaw@ventanamicro.com>
1940         * config/h8300/h8300.cc (compute_a_shift_length): Fix computation
1941         of logical shifts on the H8/SX.
1943 2023-12-09  Jakub Jelinek  <jakub@redhat.com>
1945         PR tree-optimization/112887
1946         * tree-ssa-phiopt.cc (hoist_adjacent_loads): Change type of
1947         param_align, param_align_bits, offset1, offset2, size2 and align1
1948         variables from int or unsigned int to unsigned HOST_WIDE_INT.
1950 2023-12-09  Costas Argyris  <costas.argyris@gmail.com>
1951             Jakub Jelinek  <jakub@redhat.com>
1953         PR driver/93019
1954         * gcc.cc (driver::finalize): Call XDELETEVEC on mdswitches before
1955         clearing it.
1957 2023-12-09  Jakub Jelinek  <jakub@redhat.com>
1959         * attribs.h (any_nonignored_attribute_p): Declare.
1960         * attribs.cc (any_nonignored_attribute_p): New function.
1962 2023-12-09  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
1964         PR target/112932
1965         * config/riscv/vector.md (movmisalign<mode>): Fix VLSmode bugs.
1967 2023-12-09  Alexandre Oliva  <oliva@adacore.com>
1969         * tree-emutls.cc: Include diagnostic-core.h.
1970         (pass_ipa_lower_emutls::gate): Skip if errors were seen.
1972 2023-12-08  Vladimir N. Makarov  <vmakarov@redhat.com>
1974         PR rtl-optimization/112875
1975         * lra-eliminations.cc (lra_eliminate_regs_1): Change an assert.
1976         Add ASM_OPERANDS case.
1978 2023-12-08  Robin Dapp  <rdapp@ventanamicro.com>
1980         PR target/112109
1981         * config/riscv/riscv-protos.h (expand_strcmp): Declare.
1982         * config/riscv/riscv-string.cc (riscv_expand_strcmp): Add
1983         strategy handling and delegation to scalar and vector expanders.
1984         (expand_strcmp): Vectorized implementation.
1985         * config/riscv/riscv.md: Add TARGET_VECTOR to strcmp and strncmp
1986         expander.
1988 2023-12-08  Robin Dapp  <rdapp@ventanamicro.com>
1990         PR target/112109
1991         * config/riscv/riscv-protos.h (expand_rawmemchr): Add strlen
1992         parameter.
1993         * config/riscv/riscv-string.cc (riscv_expand_strlen): Call
1994         rawmemchr.
1995         (expand_rawmemchr): Add strlen handling.
1996         * config/riscv/riscv.md: Add TARGET_VECTOR to strlen expander.
1998 2023-12-08  Richard Sandiford  <richard.sandiford@arm.com>
2000         * config/aarch64/aarch64-early-ra.cc (allocno_info::chain_next):
2001         Put into an enum with...
2002         (allocno_info::last_def_point): ...new member variable.
2003         (allocno_info::m_current_bb_point): New member variable.
2004         (likely_operand_match_p): Switch based on get_constraint_type,
2005         rather than based on rtx code.  Handle relaxed and special memory
2006         constraints.
2007         (early_ra::record_copy): Allow the source of an equivalence to be
2008         assigned to more than once.
2009         (early_ra::record_allocno_use): Invalidate any previous equivalence.
2010         Initialize last_def_point.
2011         (early_ra::record_allocno_def): Set last_def_point.
2012         (early_ra::valid_equivalence_p): New function, split out from...
2013         (early_ra::record_copy): ...here.  Use last_def_point to handle
2014         source registers that have a later definition.
2015         (make_pass_aarch64_early_ra): Fix comment.
2017 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2019         Revert:
2020         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2022         * config/arm/arm_neon.h
2023         (vld1q_u8_x2, vld1q_u16_x2, vld1q_u32_x2, vld1q_u64_x2): New.
2024         (vld1q_s8_x2, vld1q_s16_x2, vld1q_s32_x2, vld1q_s64_x2): New.
2025         (vld1q_f16_x2, vld1q_f32_x2): New.
2026         (vld1q_p8_x2, vld1q_p16_x2, vld1q_p64_x2): New.
2027         (vld1q_bf16_x2): New.
2028         * config/arm/arm_neon_builtins.def (vld1_x2): New entries.
2029         * config/arm/neon.md (vld1_x2<mode>): New.
2031 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2033         Revert:
2034         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2036         * config/arm/arm_neon.h
2037         (vld1q_u8_x3, vld1q_u16_x3, vld1q_u32_x3, vld1q_u64_x3): New.
2038         (vld1q_s8_x3, vld1q_s16_x3, vld1q_s32_x3, vld1q_s64_x3): New.
2039         (vld1q_f16_x3, vld1q_f32_x3): New.
2040         (vld1q_p8_x3, vld1q_p16_x3, vld1q_p64_x3): New.
2041         (vld1q_bf16_x3): New.
2042         * config/arm/arm_neon_builtins.def (vld1_x3): New entries.
2043         * config/arm/neon.md (vld1_x3<mode>): New.
2045 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2047         Revert:
2048         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2050         * config/arm/arm_neon.h
2051         (vld1q_u8_x4, vld1q_u16_x4, vld1q_u32_x4, vld1q_u64_x4): New.
2052         (vld1q_s8_x4, vld1q_s16_x4, vld1q_s32_x4, vld1q_s64_x4): New.
2053         (vld1q_f16_x4, vld1q_f32_x4): New.
2054         (vld1q_p8_x4, vld1q_p16_x4, vld1q_p64_x4): New.
2055         (vld1q_bf16_x4): New.
2056         * config/arm/arm_neon_builtins.def (vld1_x4): New entries.
2057         * config/arm/neon.md (vld1_x4<mode>): New.
2059 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2061         Revert:
2062         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2064         * config/arm/arm_neon.h
2065         (vst1_u8_x2, vst1_u16_x2, vst1_u32_x2, vst1_u64_x2): New.
2066         (vst1_s8_x2, vst1_s16_x2, vst1_s32_x2, vst1_s64_x2): New.
2067         (vst1_f16_x2, vst1_f32_x2): New.
2068         (vst1_p8_x2, vst1_p16_x2, vst1_p64_x2): New.
2069         (vst1_bf16_x2): New.
2070         * config/arm/arm_neon_builtins.def (vst1_x2): New entries.
2071         * config/arm/neon.md (vst1_x2<mode>): New.
2073 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2075         Revert:
2076         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2078         * config/arm/arm_neon.h
2079         (vst1_u8_x3, vst1_u16_x3, vst1_u32_x3, vst1_u64_x3): New.
2080         (vst1_s8_x3, vst1_s16_x3, vst1_s32_x3, vst1_s64_x3): New.
2081         (vst1_f16_x3, vst1_f32_x3): New.
2082         (vst1_p8_x3, vst1_p16_x3, vst1_p64_x3): New.
2083         (vst1_bf16_x3): New.
2084         * config/arm/arm_neon_builtins.def (vst1_x3): New entries.
2085         * config/arm/neon.md (vst1_x3<mode>): New.
2087 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2089         Revert:
2090         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2092         * config/arm/arm_neon.h
2093         (vst1_u8_x4, vst1_u16_x4, vst1_u32_x4, vst1_u64_x4): New.
2094         (vst1_s8_x4, vst1_s16_x4, vst1_s32_x4, vst1_s64_x4): New.
2095         (vst1_f16_x4, vst1_f32_x4): New.
2096         (vst1_p8_x4, vst1_p16_x4, vst1_p64_x4): New.
2097         (vst1_bf16_x4): New.
2098         * config/arm/arm_neon_builtins.def (vst1_x4): New entries.
2099         * config/arm/neon.md (vst1_x4<mode>): New.
2101 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2103         Revert:
2104         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2106         * config/arm/arm_neon.h
2107         (vst1q_u8_x2, vst1q_u16_x2, vst1q_u32_x2, vst1q_u64_x2): New.
2108         (vst1q_s8_x2, vst1q_s16_x2, vst1q_s32_x2, vst1q_s64_x2): New.
2109         (vst1q_f16_x2, vst1q_f32_x2): New.
2110         (vst1q_p8_x2, vst1q_p16_x2, vst1q_p64_x2): New.
2111         (vst1q_bf16_x2): New.
2112         * config/arm/arm_neon_builtins.def (vst1q_x2): New entries.
2113         * config/arm/neon.md
2114         (neon_vst1<VMEMX2_q>_x2<VDQX:mode>): Updated from
2115         neon_vst1_x2<mode>.
2116         * config/arm/iterators.md (VMEMX2): New mode iterator.
2117         (VMEMX2_q): New mode attribute.
2119 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2121         Revert:
2122         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2124         * config/arm/arm_neon.h
2125         (vst1q_u8_x3, vst1q_u16_x3, vst1q_u32_x3, vst1q_u64_x3): New.
2126         (vst1q_s8_x3, vst1q_s16_x3, vst1q_s32_x3, vst1q_s64_x3): New.
2127         (vst1q_f16_x3, vst1q_f32_x3): New.
2128         (vst1q_p8_x3, vst1q_p16_x3, vst1q_p64_x3): New.
2129         (vst1q_bf16_x3): New.
2130         * config/arm/arm_neon_builtins.def (vst1q_x3): New entries.
2131         * config/arm/neon.md (neon_vst1q_x3<mode>): New.
2133 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2135         Revert:
2136         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2138         * config/arm/arm_neon.h
2139         (vst1q_u8_x4, vst1q_u16_x4, vst1q_u32_x4, vst1q_u64_x4): New.
2140         (vst1q_s8_x4, vst1q_s16_x4, vst1q_s32_x4, vst1q_s64_x4): New.
2141         (vst1q_f16_x4, vst1q_f32_x4): New.
2142         (vst1q_p8_x4, vst1q_p16_x4, vst1q_p64_x4): New.
2143         (vst1q_bf16_x4): New.
2144         * config/arm/arm_neon_builtins.def (vst1q_x4): New entries.
2145         * config/arm/neon.md (neon_vst1q_x4<mode>): New.
2147 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2149         Revert:
2150         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2152         * config/arm/arm_neon.h
2153         (vld1_u8_x2, vld1_u16_x2, vld1_u32_x2, vld1_u64_x2): New
2154         (vld1_s8_x2, vld1_s16_x2, vld1_s32_x2, vld1_s64_x2): New.
2155         (vld1_f16_x2, vld1_f32_x2): New.
2156         (vld1_p8_x2, vld1_p16_x2, vld1_p64_x2): New.
2157         (vld1_bf16_x2): New.
2158         (vld1q_types_x2): Updated to use vld1q_x2 from
2159         arm_neon_builtins.def
2160         * config/arm/arm_neon_builtins.def
2161         (vld1_x2): Updated entries.
2162         (vld1q_x2): New entries, but comes from the old vld1_x2
2163         * config/arm/neon.md
2164         (neon_vld1<VMEMX2_q>_x2<VDQX:mode>): Updated
2165         from neon_vld1_x2<mode>.
2167 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2169         Revert:
2170         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2172         * config/arm/arm_neon.h
2173         (vld1_u8_x3, vld1_u16_x3, vld1_u32_x3, vld1_u64_x3): New
2174         (vld1_s8_x3, vld1_s16_x3, vld1_s32_x3, vld1_s64_x3): New.
2175         (vld1_f16_x3, vld1_f32_x3): New.
2176         (vld1_p8_x3, vld1_p16_x3, vld1_p64_x3): New.
2177         (vld1_bf16_x3): New.
2178         (vld1q_types_x3): Updated to use vld1q_x3 from
2179         arm_neon_builtins.def
2180         * config/arm/arm_neon_builtins.def
2181         (vld1_x3): Updated entries.
2182         (vld1q_x3): New entries, but comes from the old vld1_x2
2183         * config/arm/neon.md (neon_vld1q_x3<mode>): Updated from
2184         neon_vld1_x3<mode>.
2186 2023-12-08  Richard Earnshaw  <rearnsha@arm.com>
2188         Revert:
2189         2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2191         * config/arm/arm_neon.h
2192         (vld1_u8_x4, vld1_u16_x4, vld1_u32_x4, vld1_u64_x4): New
2193         (vld1_s8_x4, vld1_s16_x4, vld1_s32_x4, vld1_s64_x4): New.
2194         (vld1_f16_x4, vld1_f32_x4): New.
2195         (vld1_p8_x4, vld1_p16_x4, vld1_p64_x4): New.
2196         (vld1_bf16_x4): New.
2197         (vld1q_types_x4): Updated to use vld1q_x4
2198         from arm_neon_builtins.def
2199         * config/arm/arm_neon_builtins.def
2200         (vld1_x4): Updated entries.
2201         (vld1q_x4): New entries, but comes from the old vld1_x2
2202         * config/arm/neon.md (neon_vld1q_x4<mode>):
2203         Updated from neon_vld1_x4<mode>.
2205 2023-12-08  Tobias Burnus  <tobias@codesourcery.com>
2207         * builtin-types.def (BT_FN_PTR_PTR_SIZE_PTRMODE_PTRMODE): New.
2208         * omp-builtins.def (BUILT_IN_GOMP_REALLOC): New.
2209         * builtins.cc (builtin_fnspec): Handle it.
2210         * gimple-ssa-warn-access.cc (fndecl_alloc_p,
2211         matching_alloc_calls_p): Likewise.
2212         * gimple.cc (nonfreeing_call_p): Likewise.
2213         * predict.cc (expr_expected_value_1): Likewise.
2214         * tree-ssa-ccp.cc (evaluate_stmt): Likewise.
2215         * tree.cc (fndecl_dealloc_argno): Likewise.
2217 2023-12-08  Richard Biener  <rguenther@suse.de>
2219         PR tree-optimization/112909
2220         * tree-ssa-uninit.cc (find_uninit_use): Look through a
2221         single level of SSA name copies with single use.
2223 2023-12-08  Jiahao Xu  <xujiahao@loongson.cn>
2225         * config/loongarch/loongarch.cc (loongarch_try_expand_lsx_vshuf_const): Use
2226         simplify_gen_subreg instead of gen_rtx_SUBREG.
2227         (loongarch_expand_vec_perm_const_2): Ditto.
2228         (loongarch_expand_vec_cond_expr): Ditto.
2230 2023-12-08  Jiahao Xu  <xujiahao@loongson.cn>
2232         * config/loongarch/loongarch.cc (loongarch_vector_costs::determine_suggested_unroll_factor):
2233         If m_has_recip is true, uf return 1.
2234         (loongarch_vector_costs::add_stmt_cost): Detect the use of approximate instruction sequence.
2236 2023-12-08  Jiahao Xu  <xujiahao@loongson.cn>
2238         * config/loongarch/genopts/loongarch.opt.in (recip_mask): New variable.
2239         (-mrecip, -mrecip): New options.
2240         * config/loongarch/lasx.md (div<mode>3): New expander.
2241         (*div<mode>3): Rename.
2242         (sqrt<mode>2): New expander.
2243         (*sqrt<mode>2): Rename.
2244         (rsqrt<mode>2): New expander.
2245         * config/loongarch/loongarch-protos.h (loongarch_emit_swrsqrtsf): New prototype.
2246         (loongarch_emit_swdivsf): Ditto.
2247         * config/loongarch/loongarch.cc (loongarch_option_override_internal): Set
2248         recip_mask for -mrecip and -mrecip= options.
2249         (loongarch_emit_swrsqrtsf): New function.
2250         (loongarch_emit_swdivsf): Ditto.
2251         * config/loongarch/loongarch.h (RECIP_MASK_NONE, RECIP_MASK_DIV, RECIP_MASK_SQRT
2252         RECIP_MASK_RSQRT, RECIP_MASK_VEC_DIV, RECIP_MASK_VEC_SQRT, RECIP_MASK_VEC_RSQRT
2253         RECIP_MASK_ALL): New bitmasks.
2254         (TARGET_RECIP_DIV, TARGET_RECIP_SQRT, TARGET_RECIP_RSQRT, TARGET_RECIP_VEC_DIV
2255         TARGET_RECIP_VEC_SQRT, TARGET_RECIP_VEC_RSQRT): New tests.
2256         * config/loongarch/loongarch.md (sqrt<mode>2): New expander.
2257         (*sqrt<mode>2): Rename.
2258         (rsqrt<mode>2): New expander.
2259         * config/loongarch/loongarch.opt (recip_mask): New variable.
2260         (-mrecip, -mrecip): New options.
2261         * config/loongarch/lsx.md (div<mode>3): New expander.
2262         (*div<mode>3): Rename.
2263         (sqrt<mode>2): New expander.
2264         (*sqrt<mode>2): Rename.
2265         (rsqrt<mode>2): New expander.
2266         * config/loongarch/predicates.md (reg_or_vecotr_1_operand): New predicate.
2267         * doc/invoke.texi (LoongArch Options): Document new options.
2269 2023-12-08  Jiahao Xu  <xujiahao@loongson.cn>
2271         * config/loongarch/lasx.md (lasx_xvfrecip_<flasxfmt>): Renamed to ..
2272         (recip<mode>3): .. this.
2273         * config/loongarch/loongarch-builtins.cc (CODE_FOR_lsx_vfrecip_d): Redefine
2274         to new pattern name.
2275         (CODE_FOR_lsx_vfrecip_s): Ditto.
2276         (CODE_FOR_lasx_xvfrecip_d): Ditto.
2277         (CODE_FOR_lasx_xvfrecip_s): Ditto.
2278         (loongarch_expand_builtin_direct): For the vector recip instructions, construct a
2279         temporary parameter const1_vector.
2280         * config/loongarch/lsx.md (lsx_vfrecip_<flsxfmt>): Renamed to ..
2281         (recip<mode>3): .. this.
2282         * config/loongarch/predicates.md (const_vector_1_operand): New predicate.
2284 2023-12-08  Jiahao Xu  <xujiahao@loongson.cn>
2286         * config/loongarch/lasx.md (lasx_xvfrsqrt_<flasxfmt>): Renamed to ..
2287         (rsqrt<mode>2): .. this.
2288         * config/loongarch/loongarch-builtins.cc
2289         (CODE_FOR_lsx_vfrsqrt_d): Redefine to standard pattern name.
2290         (CODE_FOR_lsx_vfrsqrt_s): Ditto.
2291         (CODE_FOR_lasx_xvfrsqrt_d): Ditto.
2292         (CODE_FOR_lasx_xvfrsqrt_s): Ditto.
2293         * config/loongarch/loongarch.cc (use_rsqrt_p): New function.
2294         (loongarch_optab_supported_p): Ditto.
2295         (TARGET_OPTAB_SUPPORTED_P): New hook.
2296         * config/loongarch/loongarch.md (*rsqrt<mode>a): Remove.
2297         (*rsqrt<mode>2): New insn pattern.
2298         (*rsqrt<mode>b): Remove.
2299         * config/loongarch/lsx.md (lsx_vfrsqrt_<flsxfmt>): Renamed to ..
2300         (rsqrt<mode>2): .. this.
2302 2023-12-08  Jiahao Xu  <xujiahao@loongson.cn>
2304         * config/loongarch/genopts/isa-evolution.in (fecipe): Add.
2305         * config/loongarch/larchintrin.h (__frecipe_s): New intrinsic.
2306         (__frecipe_d): Ditto.
2307         (__frsqrte_s): Ditto.
2308         (__frsqrte_d): Ditto.
2309         * config/loongarch/lasx.md (lasx_xvfrecipe_<flasxfmt>): New insn pattern.
2310         (lasx_xvfrsqrte_<flasxfmt>): Ditto.
2311         * config/loongarch/lasxintrin.h (__lasx_xvfrecipe_s): New intrinsic.
2312         (__lasx_xvfrecipe_d): Ditto.
2313         (__lasx_xvfrsqrte_s): Ditto.
2314         (__lasx_xvfrsqrte_d): Ditto.
2315         * config/loongarch/loongarch-builtins.cc (AVAIL_ALL): Add predicates.
2316         (LSX_EXT_BUILTIN): New macro.
2317         (LASX_EXT_BUILTIN): Ditto.
2318         * config/loongarch/loongarch-cpucfg-map.h: Regenerate.
2319         * config/loongarch/loongarch-c.cc: Add builtin macro "__loongarch_frecipe".
2320         * config/loongarch/loongarch-def.cc: Regenerate.
2321         * config/loongarch/loongarch-str.h (OPTSTR_FRECIPE): Regenerate.
2322         * config/loongarch/loongarch.cc (loongarch_asm_code_end): Dump status for TARGET_FRECIPE.
2323         * config/loongarch/loongarch.md (loongarch_frecipe_<fmt>): New insn pattern.
2324         (loongarch_frsqrte_<fmt>): Ditto.
2325         * config/loongarch/loongarch.opt: Regenerate.
2326         * config/loongarch/lsx.md (lsx_vfrecipe_<flsxfmt>): New insn pattern.
2327         (lsx_vfrsqrte_<flsxfmt>): Ditto.
2328         * config/loongarch/lsxintrin.h (__lsx_vfrecipe_s): New intrinsic.
2329         (__lsx_vfrecipe_d): Ditto.
2330         (__lsx_vfrsqrte_s): Ditto.
2331         (__lsx_vfrsqrte_d): Ditto.
2332         * doc/extend.texi: Add documentation for LoongArch new builtins and intrinsics.
2334 2023-12-08  Richard Biener  <rguenther@suse.de>
2336         * tree-outof-ssa.cc (rewrite_out_of_ssa): Dump GIMPLE once only,
2337         after final IL adjustments.
2339 2023-12-08  Pan Li  <pan2.li@intel.com>
2341         * config/riscv/vector-iterators.md: Replace RVVM2SI to RVVM2SF
2342         for mode attr V_F2DI_CONVERT_BRIDGE.
2344 2023-12-08  Jiahao Xu  <xujiahao@loongson.cn>
2346         * config/loongarch/lasx.md (xorsign<mode>3): New expander.
2347         * config/loongarch/loongarch.cc (loongarch_can_change_mode_class): Allow
2348         conversion between LSX vector mode and scalar fp mode.
2349         * config/loongarch/loongarch.md (@xorsign<mode>3): New expander.
2350         * config/loongarch/lsx.md (@xorsign<mode>3): Ditto.
2352 2023-12-08  Jakub Jelinek  <jakub@redhat.com>
2354         PR tree-optimization/112902
2355         * gimple-lower-bitint.cc (gimple_lower_bitint): For a narrowing
2356         or same precision cast don't set SSA_NAME_VERSION in m_names only
2357         if use_stmt is mergeable_op or fall through into the check that
2358         use is a store or rhs1 is not mergeable or other reasons prevent
2359         merging.
2361 2023-12-08  Jakub Jelinek  <jakub@redhat.com>
2363         PR tree-optimization/112901
2364         * vr-values.cc
2365         (simplify_using_ranges::simplify_float_conversion_using_ranges):
2366         Return false if rhs1 has BITINT_TYPE type with BLKmode TYPE_MODE.
2368 2023-12-08  Jakub Jelinek  <jakub@redhat.com>
2370         PR middle-end/112411
2371         * haifa-sched.cc (extend_h_i_d): Use 3U instead of 3 in
2372         3 * get_max_uid () / 2 calculation.
2374 2023-12-08  Lulu Cheng  <chenglulu@loongson.cn>
2376         * config/loongarch/genopts/loongarch-strings: Delete STR_ISA_BASE_LA64V110.
2377         * config/loongarch/genopts/loongarch.opt.in: Likewise.
2378         * config/loongarch/loongarch-cpu.cc (ISA_BASE_LA64V110_FEATURES): Delete macro.
2379         (fill_native_cpu_config): Define a new variable hw_isa_evolution record the
2380         extended instruction set support read from cpucfg.
2381         * config/loongarch/loongarch-def.cc: Set evolution at initialization.
2382         * config/loongarch/loongarch-def.h (ISA_BASE_LA64V100): Delete.
2383         (ISA_BASE_LA64V110): Likewise.
2384         (N_ISA_BASE_TYPES): Likewise.
2385         (defined): Likewise.
2386         * config/loongarch/loongarch-opts.cc: Likewise.
2387         * config/loongarch/loongarch-opts.h (TARGET_64BIT): Likewise.
2388         (ISA_BASE_IS_LA64V110): Likewise.
2389         * config/loongarch/loongarch-str.h (STR_ISA_BASE_LA64V110): Likewise.
2390         * config/loongarch/loongarch.opt: Regenerate.
2392 2023-12-08  Xi Ruoyao  <xry111@xry111.site>
2394         * config/loongarch/loongarch-def.h: Remove extern "C".
2395         (loongarch_isa_base_strings): Declare as loongarch_def_array
2396         instead of plain array.
2397         (loongarch_isa_ext_strings): Likewise.
2398         (loongarch_abi_base_strings): Likewise.
2399         (loongarch_abi_ext_strings): Likewise.
2400         (loongarch_cmodel_strings): Likewise.
2401         (loongarch_cpu_strings): Likewise.
2402         (loongarch_cpu_default_isa): Likewise.
2403         (loongarch_cpu_issue_rate): Likewise.
2404         (loongarch_cpu_multipass_dfa_lookahead): Likewise.
2405         (loongarch_cpu_cache): Likewise.
2406         (loongarch_cpu_align): Likewise.
2407         (loongarch_cpu_rtx_cost_data): Likewise.
2408         (loongarch_isa): Add a constructor and field setter functions.
2409         * config/loongarch/loongarch-opts.h (loongarch-defs.h): Do not
2410         include for target libraries.
2411         * config/loongarch/loongarch-opts.cc: Comment code that doesn't
2412         run and causes compilation errors.
2413         * config/loongarch/loongarch-tune.h (LOONGARCH_TUNE_H): Likewise.
2414         (struct loongarch_rtx_cost_data): Likewise.
2415         (struct loongarch_cache): Likewise.
2416         (struct loongarch_align): Likewise.
2417         * config/loongarch/t-loongarch: Compile loongarch-def.cc with the
2418         C++ compiler.
2419         * config/loongarch/loongarch-def-array.h: New file for a
2420         std:array like data structure with position setter function.
2421         * config/loongarch/loongarch-def.c: Rename to ...
2422         * config/loongarch/loongarch-def.cc: ... here.
2423         (loongarch_cpu_strings): Define as loongarch_def_array instead
2424         of plain array.
2425         (loongarch_cpu_default_isa): Likewise.
2426         (loongarch_cpu_cache): Likewise.
2427         (loongarch_cpu_align): Likewise.
2428         (loongarch_cpu_rtx_cost_data): Likewise.
2429         (loongarch_cpu_issue_rate): Likewise.
2430         (loongarch_cpu_multipass_dfa_lookahead): Likewise.
2431         (loongarch_isa_base_strings): Likewise.
2432         (loongarch_isa_ext_strings): Likewise.
2433         (loongarch_abi_base_strings): Likewise.
2434         (loongarch_abi_ext_strings): Likewise.
2435         (loongarch_cmodel_strings): Likewise.
2436         (abi_minimal_isa): Likewise.
2437         (loongarch_rtx_cost_optimize_size): Use field setter functions
2438         instead of designated initializers.
2439         (loongarch_rtx_cost_data): Implement default constructor.
2441 2023-12-08  Jakub Jelinek  <jakub@redhat.com>
2443         PR middle-end/112411
2444         * params.opt (-param=min-nondebug-insn-uid=): Add
2445         IntegerRange(0, 1073741824).
2446         * lra.cc (check_and_expand_insn_recog_data): Use 3U rather than 3
2447         in * 3 / 2 computation and if the result is smaller or equal to
2448         index, use index + 1.
2450 2023-12-08  Haochen Jiang  <haochen.jiang@intel.com>
2452         * config/i386/driver-i386.cc (host_detect_local_cpu):
2453         Do not append "-mno-" for Xeon Phi ISAs.
2454         * config/i386/i386-options.cc (ix86_option_override_internal):
2455         Emit a warning for KNL/KNM targets.
2456         * config/i386/i386.opt: Emit a warning for Xeon Phi ISAs.
2458 2023-12-08  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
2460         * config/riscv/riscv-vector-costs.cc (costs::better_main_loop_than_p):
2461         Remove redundant check.
2463 2023-12-08  Hao Liu  <hliu@os.amperecomputing.com>
2465         PR tree-optimization/112774
2466         * tree-pretty-print.cc: if nonwrapping flag is set, chrec will be
2467         printed with additional <nw> info.
2468         * tree-scalar-evolution.cc: add record_nonwrapping_chrec and
2469         nonwrapping_chrec_p to set and check the new flag respectively.
2470         * tree-scalar-evolution.h: Likewise.
2471         * tree-ssa-loop-niter.cc (idx_infer_loop_bounds,
2472         infer_loop_bounds_from_pointer_arith, infer_loop_bounds_from_signedness,
2473         scev_probably_wraps_p): call record_nonwrapping_chrec before
2474         record_nonwrapping_iv, call nonwrapping_chrec_p to check the flag is
2475         set and return false from scev_probably_wraps_p.
2476         * tree-vect-loop.cc (vect_analyze_loop): call
2477         free_numbers_of_iterations_estimates explicitly.
2478         * tree-core.h: document the nothrow_flag usage in CHREC_NOWRAP
2479         * tree.h: add CHREC_NOWRAP(NODE), base.nothrow_flag is used to
2480         represent the nonwrapping info.
2482 2023-12-08  Fei Gao  <gaofei@eswincomputing.com>
2484         * ifcvt.cc (noce_try_cond_zero_arith): New function.
2485         (noce_emit_czero, get_base_reg): Likewise.
2486         (noce_cond_zero_binary_op_supported): Likewise.
2487         (noce_bbs_ok_for_cond_zero_arith): Likewise.
2488         (noce_process_if_block): Use noce_try_cond_zero_arith.
2489         Co-authored-by: Xiao Zeng<zengxiao@eswincomputing.com>
2491 2023-12-07  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
2493         * config/riscv/riscv-protos.h (expand_vec_series): Adapt function.
2494         * config/riscv/riscv-v.cc (rvv_builder::double_steps_npatterns_p): New function.
2495         (expand_vec_series): Adapt function.
2496         (expand_const_vector): Support new interleave vector with different step.
2498 2023-12-07  Richard Sandiford  <richard.sandiford@arm.com>
2500         PR rtl-optimization/106694
2501         PR rtl-optimization/109078
2502         PR rtl-optimization/109391
2503         * config.gcc: Add aarch64-early-ra.o for AArch64 targets.
2504         * config/aarch64/t-aarch64 (aarch64-early-ra.o): New rule.
2505         * config/aarch64/aarch64-opts.h (aarch64_early_ra_scope): New enum.
2506         * config/aarch64/aarch64.opt (mearly_ra): New option.
2507         * doc/invoke.texi: Document it.
2508         * common/config/aarch64/aarch64-common.cc
2509         (aarch_option_optimization_table): Use -mearly-ra=strided by
2510         default for -O2 and above.
2511         * config/aarch64/aarch64-passes.def (pass_aarch64_early_ra): New pass.
2512         * config/aarch64/aarch64-protos.h (aarch64_strided_registers_p)
2513         (make_pass_aarch64_early_ra): Declare.
2514         * config/aarch64/aarch64-sme.md (@aarch64_sme_lut<LUTI_BITS><mode>):
2515         Add a stride_type attribute.
2516         (@aarch64_sme_lut<LUTI_BITS><mode>_strided2): New pattern.
2517         (@aarch64_sme_lut<LUTI_BITS><mode>_strided4): Likewise.
2518         * config/aarch64/aarch64-sve-builtins-base.cc (svld1_impl::expand)
2519         (svldnt1_impl::expand, svst1_impl::expand, svstn1_impl::expand): Handle
2520         new way of defining multi-register loads and stores.
2521         * config/aarch64/aarch64-sve.md (@aarch64_ld1<SVE_FULLx24:mode>)
2522         (@aarch64_ldnt1<SVE_FULLx24:mode>, @aarch64_st1<SVE_FULLx24:mode>)
2523         (@aarch64_stnt1<SVE_FULLx24:mode>): Delete.
2524         * config/aarch64/aarch64-sve2.md (@aarch64_<LD1_COUNT:optab><mode>)
2525         (@aarch64_<LD1_COUNT:optab><mode>_strided2): New patterns.
2526         (@aarch64_<LD1_COUNT:optab><mode>_strided4): Likewise.
2527         (@aarch64_<ST1_COUNT:optab><mode>): Likewise.
2528         (@aarch64_<ST1_COUNT:optab><mode>_strided2): Likewise.
2529         (@aarch64_<ST1_COUNT:optab><mode>_strided4): Likewise.
2530         * config/aarch64/aarch64.cc (aarch64_strided_registers_p): New
2531         function.
2532         * config/aarch64/aarch64.md (UNSPEC_LD1_SVE_COUNT): Delete.
2533         (UNSPEC_ST1_SVE_COUNT, UNSPEC_LDNT1_SVE_COUNT): Likewise.
2534         (UNSPEC_STNT1_SVE_COUNT): Likewise.
2535         (stride_type): New attribute.
2536         * config/aarch64/constraints.md (Uwd, Uwt): New constraints.
2537         * config/aarch64/iterators.md (UNSPEC_LD1_COUNT, UNSPEC_LDNT1_COUNT)
2538         (UNSPEC_ST1_COUNT, UNSPEC_STNT1_COUNT): New unspecs.
2539         (optab): Handle them.
2540         (LD1_COUNT, ST1_COUNT): New iterators.
2541         * config/aarch64/aarch64-early-ra.cc: New file.
2543 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2545         * config/arm/arm_neon.h
2546         (vld1_u8_x4, vld1_u16_x4, vld1_u32_x4, vld1_u64_x4): New
2547         (vld1_s8_x4, vld1_s16_x4, vld1_s32_x4, vld1_s64_x4): New.
2548         (vld1_f16_x4, vld1_f32_x4): New.
2549         (vld1_p8_x4, vld1_p16_x4, vld1_p64_x4): New.
2550         (vld1_bf16_x4): New.
2551         (vld1q_types_x4): Updated to use vld1q_x4
2552         from arm_neon_builtins.def
2553         * config/arm/arm_neon_builtins.def
2554         (vld1_x4): Updated entries.
2555         (vld1q_x4): New entries, but comes from the old vld1_x2
2556         * config/arm/neon.md (neon_vld1q_x4<mode>):
2557         Updated from neon_vld1_x4<mode>.
2559 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2561         * config/arm/arm_neon.h
2562         (vld1_u8_x3, vld1_u16_x3, vld1_u32_x3, vld1_u64_x3): New
2563         (vld1_s8_x3, vld1_s16_x3, vld1_s32_x3, vld1_s64_x3): New.
2564         (vld1_f16_x3, vld1_f32_x3): New.
2565         (vld1_p8_x3, vld1_p16_x3, vld1_p64_x3): New.
2566         (vld1_bf16_x3): New.
2567         (vld1q_types_x3): Updated to use vld1q_x3 from
2568         arm_neon_builtins.def
2569         * config/arm/arm_neon_builtins.def
2570         (vld1_x3): Updated entries.
2571         (vld1q_x3): New entries, but comes from the old vld1_x2
2572         * config/arm/neon.md (neon_vld1q_x3<mode>): Updated from
2573         neon_vld1_x3<mode>.
2575 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2577         * config/arm/arm_neon.h
2578         (vld1_u8_x2, vld1_u16_x2, vld1_u32_x2, vld1_u64_x2): New
2579         (vld1_s8_x2, vld1_s16_x2, vld1_s32_x2, vld1_s64_x2): New.
2580         (vld1_f16_x2, vld1_f32_x2): New.
2581         (vld1_p8_x2, vld1_p16_x2, vld1_p64_x2): New.
2582         (vld1_bf16_x2): New.
2583         (vld1q_types_x2): Updated to use vld1q_x2 from
2584         arm_neon_builtins.def
2585         * config/arm/arm_neon_builtins.def
2586         (vld1_x2): Updated entries.
2587         (vld1q_x2): New entries, but comes from the old vld1_x2
2588         * config/arm/neon.md
2589         (neon_vld1<VMEMX2_q>_x2<VDQX:mode>): Updated
2590         from neon_vld1_x2<mode>.
2592 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2594         * config/arm/arm_neon.h
2595         (vst1q_u8_x4, vst1q_u16_x4, vst1q_u32_x4, vst1q_u64_x4): New.
2596         (vst1q_s8_x4, vst1q_s16_x4, vst1q_s32_x4, vst1q_s64_x4): New.
2597         (vst1q_f16_x4, vst1q_f32_x4): New.
2598         (vst1q_p8_x4, vst1q_p16_x4, vst1q_p64_x4): New.
2599         (vst1q_bf16_x4): New.
2600         * config/arm/arm_neon_builtins.def (vst1q_x4): New entries.
2601         * config/arm/neon.md (neon_vst1q_x4<mode>): New.
2603 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2605         * config/arm/arm_neon.h
2606         (vst1q_u8_x3, vst1q_u16_x3, vst1q_u32_x3, vst1q_u64_x3): New.
2607         (vst1q_s8_x3, vst1q_s16_x3, vst1q_s32_x3, vst1q_s64_x3): New.
2608         (vst1q_f16_x3, vst1q_f32_x3): New.
2609         (vst1q_p8_x3, vst1q_p16_x3, vst1q_p64_x3): New.
2610         (vst1q_bf16_x3): New.
2611         * config/arm/arm_neon_builtins.def (vst1q_x3): New entries.
2612         * config/arm/neon.md (neon_vst1q_x3<mode>): New.
2614 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2616         * config/arm/arm_neon.h
2617         (vst1q_u8_x2, vst1q_u16_x2, vst1q_u32_x2, vst1q_u64_x2): New.
2618         (vst1q_s8_x2, vst1q_s16_x2, vst1q_s32_x2, vst1q_s64_x2): New.
2619         (vst1q_f16_x2, vst1q_f32_x2): New.
2620         (vst1q_p8_x2, vst1q_p16_x2, vst1q_p64_x2): New.
2621         (vst1q_bf16_x2): New.
2622         * config/arm/arm_neon_builtins.def (vst1q_x2): New entries.
2623         * config/arm/neon.md
2624         (neon_vst1<VMEMX2_q>_x2<VDQX:mode>): Updated from
2625         neon_vst1_x2<mode>.
2626         * config/arm/iterators.md (VMEMX2): New mode iterator.
2627         (VMEMX2_q): New mode attribute.
2629 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2631         * config/arm/arm_neon.h
2632         (vst1_u8_x4, vst1_u16_x4, vst1_u32_x4, vst1_u64_x4): New.
2633         (vst1_s8_x4, vst1_s16_x4, vst1_s32_x4, vst1_s64_x4): New.
2634         (vst1_f16_x4, vst1_f32_x4): New.
2635         (vst1_p8_x4, vst1_p16_x4, vst1_p64_x4): New.
2636         (vst1_bf16_x4): New.
2637         * config/arm/arm_neon_builtins.def (vst1_x4): New entries.
2638         * config/arm/neon.md (vst1_x4<mode>): New.
2640 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2642         * config/arm/arm_neon.h
2643         (vst1_u8_x3, vst1_u16_x3, vst1_u32_x3, vst1_u64_x3): New.
2644         (vst1_s8_x3, vst1_s16_x3, vst1_s32_x3, vst1_s64_x3): New.
2645         (vst1_f16_x3, vst1_f32_x3): New.
2646         (vst1_p8_x3, vst1_p16_x3, vst1_p64_x3): New.
2647         (vst1_bf16_x3): New.
2648         * config/arm/arm_neon_builtins.def (vst1_x3): New entries.
2649         * config/arm/neon.md (vst1_x3<mode>): New.
2651 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2653         * config/arm/arm_neon.h
2654         (vst1_u8_x2, vst1_u16_x2, vst1_u32_x2, vst1_u64_x2): New.
2655         (vst1_s8_x2, vst1_s16_x2, vst1_s32_x2, vst1_s64_x2): New.
2656         (vst1_f16_x2, vst1_f32_x2): New.
2657         (vst1_p8_x2, vst1_p16_x2, vst1_p64_x2): New.
2658         (vst1_bf16_x2): New.
2659         * config/arm/arm_neon_builtins.def (vst1_x2): New entries.
2660         * config/arm/neon.md (vst1_x2<mode>): New.
2662 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2664         * config/arm/arm_neon.h
2665         (vld1q_u8_x4, vld1q_u16_x4, vld1q_u32_x4, vld1q_u64_x4): New.
2666         (vld1q_s8_x4, vld1q_s16_x4, vld1q_s32_x4, vld1q_s64_x4): New.
2667         (vld1q_f16_x4, vld1q_f32_x4): New.
2668         (vld1q_p8_x4, vld1q_p16_x4, vld1q_p64_x4): New.
2669         (vld1q_bf16_x4): New.
2670         * config/arm/arm_neon_builtins.def (vld1_x4): New entries.
2671         * config/arm/neon.md (vld1_x4<mode>): New.
2673 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2675         * config/arm/arm_neon.h
2676         (vld1q_u8_x3, vld1q_u16_x3, vld1q_u32_x3, vld1q_u64_x3): New.
2677         (vld1q_s8_x3, vld1q_s16_x3, vld1q_s32_x3, vld1q_s64_x3): New.
2678         (vld1q_f16_x3, vld1q_f32_x3): New.
2679         (vld1q_p8_x3, vld1q_p16_x3, vld1q_p64_x3): New.
2680         (vld1q_bf16_x3): New.
2681         * config/arm/arm_neon_builtins.def (vld1_x3): New entries.
2682         * config/arm/neon.md (vld1_x3<mode>): New.
2684 2023-12-07  Ezra Sitorus  <ezra.sitorus@arm.com>
2686         * config/arm/arm_neon.h
2687         (vld1q_u8_x2, vld1q_u16_x2, vld1q_u32_x2, vld1q_u64_x2): New.
2688         (vld1q_s8_x2, vld1q_s16_x2, vld1q_s32_x2, vld1q_s64_x2): New.
2689         (vld1q_f16_x2, vld1q_f32_x2): New.
2690         (vld1q_p8_x2, vld1q_p16_x2, vld1q_p64_x2): New.
2691         (vld1q_bf16_x2): New.
2692         * config/arm/arm_neon_builtins.def (vld1_x2): New entries.
2693         * config/arm/neon.md (vld1_x2<mode>): New.
2695 2023-12-07  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
2697         * config/s390/vecintrin.h (vec_step): Expand vec_step to
2698         __builtin_s390_vec_step.
2700 2023-12-07  Alexandre Oliva  <oliva@adacore.com>
2702         * target.def (have_strub_support_for): New hook.
2703         * doc/tm.texi.in: Document it.
2704         * doc/tm.texi: Rebuild.
2705         * ipa-strub.cc: Include target.h.
2706         (strub_target_support_p): New.
2707         (can_strub_p): Call it.  Test for no flag_split_stack.
2708         (pass_ipa_strub::adjust_at_calls_call): Check for target
2709         support.
2710         * config/nvptx/nvptx.cc (TARGET_HAVE_STRUB_SUPPORT_FOR):
2711         Disable.
2712         * doc/sourcebuild.texi (strub): Document new effective
2713         target.
2715 2023-12-07  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
2717         * config/riscv/riscv-avlprop.cc (simplify_replace_avl): New function.
2718         (simplify_replace_vlmax_avl): Fix bug.
2719         * config/riscv/t-riscv: Add a new include file.
2721 2023-12-07  Christoph Müllner  <christoph.muellner@vrull.eu>
2723         * config/riscv/thead.cc (th_memidx_classify_address_index):
2724         Require TARGET_XTHEADMEMIDX for FP modes.
2725         * config/riscv/thead.md: Require TARGET_XTHEADMEMIDX for all
2726         XTheadFMemIdx pattern.
2728 2023-12-07  Jakub Jelinek  <jakub@redhat.com>
2730         PR middle-end/112881
2731         * expr.cc (count_type_elements): Handle BITINT_TYPE like INTEGER_TYPE.
2733 2023-12-07  Jakub Jelinek  <jakub@redhat.com>
2735         PR tree-optimization/112880
2736         * tree-ssa-dce.cc (maybe_optimize_arith_overflow): Use
2737         unsigned_type_for instead of conditionally calling
2738         build_nonstandard_integer_type.
2740 2023-12-07  Victor Do Nascimento  <victor.donascimento@arm.com>
2742         * config/aarch64/arm_neon.h (vldap1_lane_u64): New.
2743         (vldap1q_lane_u64): Likewise.
2744         (vldap1_lane_s64): Likewise.
2745         (vldap1q_lane_s64): Likewise.
2746         (vldap1_lane_f64): Likewise.
2747         (vldap1q_lane_f64): Likewise.
2748         (vldap1_lane_p64): Likewise.
2749         (vldap1q_lane_p64): Likewise.
2750         (vstl1_lane_u64): Likewise.
2751         (vstl1q_lane_u64): Likewise.
2752         (vstl1_lane_s64): Likewise.
2753         (vstl1q_lane_s64): Likewise.
2754         (vstl1_lane_f64): Likewise.
2755         (vstl1q_lane_f64): Likewise.
2756         (vstl1_lane_p64): Likewise.
2757         (vstl1q_lane_p64): Likewise.
2759 2023-12-07  Victor Do Nascimento  <victor.donascimento@arm.com>
2761         * config/aarch64/aarch64-simd-builtins.def
2762         (vec_ldap1_lane): New.
2763         (vec_stl1_lane): Likewise.
2764         * config/aarch64/aarch64-simd.md
2765         (aarch64_vec_stl1_lanes<mode>_lane<Vel>): New.
2766         (aarch64_vec_stl1_lane<mode>): Likewise.
2767         (aarch64_vec_ldap1_lanes<mode>_lane<Vel>): Likewise.
2768         (aarch64_vec_ldap1_lane<mode>): Likewise.
2769         * config/aarch64/aarch64.md (UNSPEC_LDAP1_LANE): New.
2770         (UNSPEC_STL1_LANE): Likewise.
2772 2023-12-07  Victor Do Nascimento  <victor.donascimento@arm.com>
2774         * config/aarch64/iterators.md (V12DIF): New.
2775         (V12DUP): Likewise.
2776         (VEL): Add support for all V12DIF-associated modes.
2777         (Vetype): Add support for V1DI and V1DF.
2778         (Vel): Likewise.
2780 2023-12-07  Victor Do Nascimento  <victor.donascimento@arm.com>
2782         * config/aarch64/aarch64-option-extensions.def (rcpc3): New.
2783         * config/aarch64/aarch64.h (AARCH64_ISA_RCPC3): Likewise.
2784         (TARGET_RCPC3): Likewise.
2785         * doc/invoke.texi (rcpc3): Document feature in AArch64 Options.
2787 2023-12-07  Hongyu Wang  <hongyu.wang@intel.com>
2789         * config/i386/i386-expand.cc (ix86_split_ashl_ndd): New
2790         function to split NDD form lshift.
2791         (ix86_split_rshift_ndd): Likewise for l/ashiftrt.
2792         * config/i386/i386-protos.h (ix86_split_ashl_ndd): New
2793         prototype.
2794         (ix86_split_rshift_ndd): Likewise.
2795         * config/i386/i386.md (ashl<mode>3_doubleword): Add NDD
2796         alternative, call ndd split function when operands[0]
2797         not equal to operands[1].
2798         (define_split for doubleword lshift): Likewise.
2799         (define_peephole for doubleword lshift): Likewise.
2800         (<insn><mode>3_doubleword): Likewise for l/ashiftrt.
2801         (define_split for doubleword l/ashiftrt): Likewise.
2802         (define_peephole for doubleword l/ashiftrt): Likewise.
2804 2023-12-07  Hongyu Wang  <hongyu.wang@intel.com>
2806         * config/i386/i386.md (*mov<mode>cc_noc): Extend with new constraints
2807         to support NDD.
2808         (*movsicc_noc_zext): Likewise.
2809         (*movsicc_noc_zext_1): Likewise.
2810         (*movqicc_noc): Likewise.
2812 2023-12-07  Hongyu Wang  <hongyu.wang@intel.com>
2814         * config/i386/i386.md (x86_64_shld_ndd): New define_insn.
2815         (x86_64_shld_ndd_1): Likewise.
2816         (*x86_64_shld_ndd_2): Likewise.
2817         (x86_shld_ndd): Likewise.
2818         (x86_shld_ndd_1): Likewise.
2819         (*x86_shld_ndd_2): Likewise.
2820         (x86_64_shrd_ndd): Likewise.
2821         (x86_64_shrd_ndd_1): Likewise.
2822         (*x86_64_shrd_ndd_2): Likewise.
2823         (x86_shrd_ndd): Likewise.
2824         (x86_shrd_ndd_1): Likewise.
2825         (*x86_shrd_ndd_2): Likewise.
2826         (*x86_64_shld_shrd_1_nozext): Adjust codegen under TARGET_APX_NDD.
2827         (*x86_shld_shrd_1_nozext): Likewise.
2828         (*x86_64_shrd_shld_1_nozext): Likewise.
2829         (*x86_shrd_shld_1_nozext): Likewise.
2831 2023-12-07  Hongyu Wang  <hongyu.wang@intel.com>
2833         * config/i386/i386.md (*<insn><mode>3_1): Extend with a new
2834         alternative to support NDD for SI/DI rotate, and adjust output
2835         template.
2836         (*<insn>si3_1_zext): Likewise.
2837         (*<insn><mode>3_1): Likewise for QI/HI modes.
2838         (rcrsi2): Likewise, and use nonimmediate_operand for operands[1]
2839         to accept memory input for NDD alternative.
2840         (rcrdi2): Likewise.
2842 2023-12-07  Hongyu Wang  <hongyu.wang@intel.com>
2844         * config/i386/i386.md (ashr<mode>3_cvt): Extend with new
2845         alternatives to support NDD, and adjust output templates.
2846         (*ashr<mode>3_1): Likewise for SI/DI mode.
2847         (*lshr<mode>3_1): Likewise.
2848         (*<insn>si3_1_zext): Likewise.
2849         (*ashr<mode>3_1): Likewise for QI/HI mode.
2850         (*lshrqi3_1): Likewise.
2851         (*lshrhi3_1): Likewise.
2852         (<insn><mode>3_cmp): Likewise.
2853         (*<insn><mode>3_cconly): Likewise.
2854         (*ashrsi3_cvt_zext): Likewise, and use nonimmediate_operand for
2855         operands[1] to accept memory input for NDD alternative.
2856         (*highpartdisi2): Likewise.
2857         (*<insn>si3_cmp_zext): Likewise.
2858         (<insn><mode>3_carry): Likewise.
2860 2023-12-07  Hongyu Wang  <hongyu.wang@intel.com>
2862         * config/i386/i386.md (*ashl<mode>3_1): Extend with new
2863         alternatives to support NDD, limit the new alternative to
2864         generate sal only, and adjust output template for NDD.
2865         (*ashlsi3_1_zext): Likewise.
2866         (*ashlhi3_1): Likewise.
2867         (*ashlqi3_1): Likewise.
2868         (*ashl<mode>3_cmp): Likewise.
2869         (*ashlsi3_cmp_zext): Likewise, and use nonimmediate_operand for
2870         operands[1] to accept memory input for NDD alternative.
2871         (*ashl<mode>3_cconly): Likewise.
2872         (*ashl<dwi>3_doubleword_highpart): Adjust codegen for NDD.
2874 2023-12-07  Kong Lingling  <lingling.kong@intel.com>
2876         * config/i386/i386.md (<code><mode>3): Add new alternative for NDD
2877         and adjust output templates.
2878         (*<code><mode>_1): Likewise.
2879         (*<code>qi_1): Likewise.
2880         (*notxor<mode>_1): Likewise.
2881         (*<code>si_1_zext): Likewise.
2882         (*notxorqi_1): Likewise.
2883         (*<code><mode>_2): Likewise.
2884         (*<code>si_2_zext): Likewise.
2885         (*<code>si_2_zext_imm): Likewise.
2886         (*<code>si_1_zext_imm): Likewise, and use nonimmediate_operand for
2887         operands[1] to accept memory input for NDD alternative.
2888         (*one_cmplsi2_2_zext): Likewise.
2889         (define_split for *one_cmplsi2_2_zext): Use nonimmediate_operand for
2890         operands[3].
2891         (*<code><dwi>3_doubleword): Add NDD constraints, adopt '&' to NDD dest
2892         and emit move for optimized case if operands[0] != operands[1] or
2893         operands[4] != operands[5].
2894         (define_split for QI highpart OR/XOR): Prohibit splitter to split NDD
2895         form OR/XOR insn to <any_logic:code>qi_ext<mode>_3.
2896         (define_split for QI strict_lowpart optimization): Prohibit splitter to
2897         split NDD form AND insn to *<code><mode>3_1_slp.
2899 2023-12-07  Kong Lingling  <lingling.kong@intel.com>
2901         * config/i386/i386.md (and<mode>3): Add NDD alternatives and adjust
2902         output template.
2903         (*anddi_1): Likewise.
2904         (*and<mode>_1): Likewise.
2905         (*andqi_1): Likewise.
2906         (*andsi_1_zext): Likewise.
2907         (*anddi_2): Likewise.
2908         (*andsi_2_zext): Likewise.
2909         (*andqi_2_maybe_si): Likewise.
2910         (*and<mode>_2): Likewise.
2911         (*and<dwi>3_doubleword): Add NDD alternative, adopt '&' to NDD dest and
2912         emit move for optimized case if operands[0] not equal to operands[1].
2913         (define_split for QI highpart AND): Prohibit splitter to split NDD
2914         form AND insn to <any_logic:code>qi_ext<mode>_3.
2915         (define_split for QI strict_lowpart optimization): Prohibit splitter to
2916         split NDD form AND insn to *<code><mode>3_1_slp.
2917         (define_split for zero_extend and optimization): Prohibit splitter to
2918         split NDD form AND insn to zero_extend insn.
2920 2023-12-07  Kong Lingling  <lingling.kong@intel.com>
2922         * config/i386/i386.md (one_cmpl<mode>2): Add new constraints for NDD
2923         and adjust output template.
2924         (*one_cmpl<mode>2_1): Likewise.
2925         (*one_cmplqi2_1): Likewise.
2926         (*one_cmpl<dwi>2_doubleword): Likewise, and adopt '&' to NDD dest.
2927         (*one_cmpl<mode>2_2): Likewise.
2928         (*one_cmplsi2_1_zext): Likewise, and use nonimmediate_operand for
2929         operands[1] to accept memory input for NDD alternative.
2931 2023-12-07  Kong Lingling  <lingling.kong@intel.com>
2933         * config/i386/i386-expand.cc (ix86_expand_unary_operator): Add use_ndd
2934         parameter and adjust for NDD.
2935         * config/i386/i386-protos.h: Add use_ndd parameter for
2936         ix86_unary_operator_ok and ix86_expand_unary_operator.
2937         * config/i386/i386.cc (ix86_unary_operator_ok): Add use_ndd parameter
2938         and adjust for NDD.
2939         * config/i386/i386.md (neg<mode>2): Add new constraint for NDD and
2940         adjust output template.
2941         (*neg<mode>_1): Likewise.
2942         (*neg<dwi>2_doubleword): Likewise and adopt '&' to NDD dest.
2943         (*neg<mode>_2): Likewise.
2944         (*neg<mode>_ccc_1): Likewise.
2945         (*neg<mode>_ccc_2): Likewise.
2946         (*negsi_1_zext): Likewise, and use nonimmediate_operand for operands[1]
2947         to accept memory input for NDD alternatives.
2948         (*negsi_2_zext): Likewise.
2950 2023-12-07  Kong Lingling  <lingling.kong@intel.com>
2952         * config/i386/i386.md (*sub<dwi>3_doubleword): Add new alternative for
2953         NDD, adopt '&' modifier to NDD dest and emit move when operands[0] not
2954         equal to operands[1].
2955         (*sub<dwi>3_doubleword_zext): Likewise.
2956         (*subv<dwi>4_doubleword): Likewise.
2957         (*subv<dwi>4_doubleword_1): Likewise.
2958         (*subv<mode>4_overflow_1): Add NDD alternatives and adjust output
2959         templates.
2960         (*subv<mode>4_overflow_2): Likewise.
2961         (@sub<mode>3_carry): Likewise.
2962         (*addsi3_carry_zext_0r): Likewise, and use nonimmediate_operand for
2963         operands[1] to accept memory input for NDD alternative.
2964         (*subsi3_carry_zext): Likewise.
2965         (subborrow<mode>): Parse TARGET_APX_NDD to ix86_binary_operator_ok.
2966         (subborrow<mode>_0): Likewise.
2967         (*sub<mode>3_eq): Likewise.
2968         (*sub<mode>3_ne): Likewise.
2969         (*sub<mode>3_eq_1): Likewise.
2971 2023-12-07  Kong Lingling  <lingling.kong@intel.com>
2973         * config/i386/i386-expand.cc (ix86_fixup_binary_operands_no_copy):
2974         Add use_ndd parameter and parse it.
2975         * config/i386/i386-protos.h (ix86_fixup_binary_operands_no_copy):
2976         Change define.
2977         * config/i386/i386.md (sub<mode>3): Add new alternatives for NDD
2978         and adjust output templates.
2979         (*sub<mode>_1): Likewise.
2980         (*sub<mode>_2): Likewise.
2981         (subv<mode>4): Likewise.
2982         (*subv<mode>4): Likewise.
2983         (subv<mode>4_1): Likewise.
2984         (usubv<mode>4): Likewise.
2985         (*sub<mode>_3): Likewise.
2986         (*subsi_1_zext): Likewise, and use nonimmediate_operand for operands[1]
2987         to accept memory input for NDD alternatives.
2988         (*subsi_2_zext): Likewise.
2989         (*subsi_3_zext): Likewise.
2991 2023-12-07  Kong Lingling  <lingling.kong@intel.com>
2993         * config/i386/i386.md (*add<dwi>3_doubleword): Add ndd alternatives,
2994         adopt '&' to ndd dest and move operands[1] to operands[0] when they are
2995         not equal.
2996         (*add<dwi>3_doubleword_cc_overflow_1): Likewise.
2997         (*addv<dwi>4_doubleword): Likewise.
2998         (*addv<dwi>4_doubleword_1): Likewise.
2999         (*add<dwi>3_doubleword_zext): Likewise.
3000         (addv<mode>4_overflow_1): Add ndd alternatives.
3001         (*addv<mode>4_overflow_2): Likewise.
3002         (@add<mode>3_carry): Likewise.
3003         (*add<mode>3_carry_0): Likewise.
3004         (*addsi3_carry_zext): Likewise.
3005         (addcarry<mode>): Likewise.
3006         (addcarry<mode>_0): Likewise.
3007         (*addcarry<mode>_1): Likewise.
3008         (*add<mode>3_eq): Likewise.
3009         (*add<mode>3_ne): Likewise.
3010         (*addsi3_carry_zext_0): Likewise, and use nonimmediate_operand for
3011         operands[1] to accept memory input for NDD alternative.
3013 2023-12-07  Hongyu Wang  <hongyu.wang@intel.com>
3015         * config/i386/constraints.md (je): New constraint.
3016         * config/i386/i386-protos.h (x86_poff_operand_p): New function to
3017         check any *POFF constant in operand.
3018         * config/i386/i386.cc (x86_poff_operand_p): New prototype.
3019         * config/i386/i386.md (*add<mode>_1): Split out je alternative for add.
3021 2023-12-07  Kong Lingling  <lingling.kong@intel.com>
3023         * config/i386/i386.md: (addsi_1_zext): Add new alternatives for
3024         NDD and adjust output templates.
3025         (*add<mode>_2): Likewise.
3026         (*addsi_2_zext): Likewise.
3027         (*add<mode>_3): Likewise.
3028         (*addsi_3_zext): Likewise.
3029         (*adddi_4): Likewise.
3030         (*add<mode>_4): Likewise.
3031         (*add<mode>_5): Likewise.
3032         (*addv<mode>4): Likewise.
3033         (*addv<mode>4_1): Likewise.
3034         (*add<mode>3_cconly_overflow_1): Likewise.
3035         (*add<mode>3_cc_overflow_1): Likewise.
3036         (*addsi3_zext_cc_overflow_1): Likewise.
3037         (*add<mode>3_cconly_overflow_2): Likewise.
3038         (*add<mode>3_cc_overflow_2): Likewise.
3039         (*addsi3_zext_cc_overflow_2): Likewise.
3041 2023-12-07  Kong Lingling  <lingling.kong@intel.com>
3043         * config/i386/i386-expand.cc (ix86_fixup_binary_operands): Add
3044         new use_ndd flag to check whether ndd can be used for this binop
3045         and adjust operand emit.
3046         (ix86_binary_operator_ok): Likewise.
3047         (ix86_expand_binary_operator): Likewise, and void postreload
3048         expand generate lea pattern when use_ndd is explicit parsed.
3049         * config/i386/i386-options.cc (ix86_option_override_internal):
3050         Prohibit apx subfeatures when not in 64bit mode.
3051         * config/i386/i386-protos.h (ix86_binary_operator_ok):
3052         Add use_ndd flag.
3053         (ix86_fixup_binary_operand): Likewise.
3054         (ix86_expand_binary_operand): Likewise.
3055         * config/i386/i386.md (*add<mode>_1): Extend with new alternatives
3056         to support NDD, and adjust output template.
3057         (*addhi_1): Likewise.
3058         (*addqi_1): Likewise.
3060 2023-12-07  David Malcolm  <dmalcolm@redhat.com>
3062         PR analyzer/103546
3063         PR analyzer/112850
3064         * doc/invoke.texi: Add -Wanalyzer-symbol-too-complex.
3066 2023-12-06  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
3068         * config/riscv/riscv-vsetvl.cc (extract_single_source): new function.
3069         (pre_vsetvl::compute_lcm_local_properties): Fix ICE.
3071 2023-12-06  Victor Do Nascimento  <victor.donascimento@arm.com>
3073         * config/aarch64/aarch64-builtins.cc (AARCH64_RSR128): New
3074         `enum aarch64_builtins' value.
3075         (AARCH64_WSR128): Likewise.
3076         (aarch64_init_rwsr_builtins): Init `__builtin_aarch64_rsr128'
3077         and `__builtin_aarch64_wsr128' builtins.
3078         (aarch64_expand_rwsr_builtin): Extend function to handle
3079         `__builtin_aarch64_{rsr|wsr}128'.
3080         * config/aarch64/aarch64-protos.h (aarch64_retrieve_sysreg):
3081         Update function signature.
3082         * config/aarch64/aarch64.cc (F_REG_128): New.
3083         (aarch64_retrieve_sysreg): Add 128-bit register mode check.
3084         * config/aarch64/aarch64.md (UNSPEC_SYSREG_RTI): New.
3085         (UNSPEC_SYSREG_WTI): Likewise.
3086         (aarch64_read_sysregti): Likewise.
3087         (aarch64_write_sysregti): Likewise.
3088         * config/aarch64/arm_acle.h (__arm_rsr128): New.
3089         (__arm_wsr128): Likewise.
3091 2023-12-06  Victor Do Nascimento  <victor.donascimento@arm.com>
3093         * config/aarch64/aarch64-sys-regs.def: Copy from Binutils.
3095 2023-12-06  Victor Do Nascimento  <victor.donascimento@arm.com>
3097         * config/aarch64/aarch64-option-extensions.def (gcs): New.
3098         * config/aarch64/aarch64.h (AARCH64_ISA_GCS): New.
3099         (TARGET_THE):  Likewise.
3100         * doc/invoke.texi (AArch64 Options): Describe GCS.
3102 2023-12-06  Victor Do Nascimento  <victor.donascimento@arm.com>
3104         * config/aarch64/aarch64-c.cc (__ARM_FEATURE_SYSREG128): New.
3105         * config/aarch64/aarch64-arches.def (armv8.9-a): New.
3106         (armv9.4-a): Likewise.
3107         * config/aarch64/aarch64-option-extensions.def (d128): Likewise.
3108         (the): Likewise.
3109         * config/aarch64/aarch64.h (AARCH64_ISA_V9_4A): Likewise.
3110         (AARCH64_ISA_V8_9A): Likewise.
3111         (TARGET_ARMV9_4): Likewise.
3112         (AARCH64_ISA_D128): Likewise.
3113         (AARCH64_ISA_THE): Likewise.
3114         (TARGET_D128): Likewise.
3115         * doc/invoke.texi (AArch64 Options): Document new -march flags
3116         and extensions.
3118 2023-12-06  Eric Gallager  <egallager@gcc.gnu.org>
3120         * Makefile.in: Remove qmtest-related targets.
3122 2023-12-06  David Malcolm  <dmalcolm@redhat.com>
3124         * common.opt (fdiagnostics-json-formatting): New.
3125         * diagnostic-format-json.cc: Add "formatted" boolean
3126         to json_output_format and subclasses, and to the
3127         diagnostic_output_format_init_json_* functions.  Use it when
3128         printing JSON.
3129         * diagnostic-format-sarif.cc: Likewise for sarif_builder,
3130         sarif_output_format, and the various
3131         diagnostic_output_format_init_sarif_* functions.
3132         * diagnostic.cc (diagnostic_output_format_init): Add
3133         "json_formatting" boolean and pass on to the various cases.
3134         * diagnostic.h (diagnostic_output_format_init): Add
3135         "json_formatted" param.
3136         (diagnostic_output_format_init_json_stderr): Add "formatted" param
3137         (diagnostic_output_format_init_json_file): Likewise.
3138         (diagnostic_output_format_init_sarif_stderr): Likewise.
3139         (diagnostic_output_format_init_sarif_file): Likewise.
3140         (diagnostic_output_format_init_sarif_stream): Likewise.
3141         * doc/invoke.texi (-fdiagnostics-format=json): Remove discussion
3142         about JSON output needing formatting.
3143         (-fno-diagnostics-json-formatting): Add.
3144         * gcc.cc (driver_handle_option): Use
3145         opts->x_flag_diagnostics_json_formatting.
3146         * gcov.cc (generate_results): Pass "false" for new formatting
3147         option when printing json.
3148         * json.cc (value::dump): Add new "formatted" param.
3149         (object::print): Likewise, using it to add whitespace to format
3150         the JSON output.
3151         (array::print): Likewise.
3152         (float_number::print): Add new "formatted" param.
3153         (integer_number::print): Likewise.
3154         (string::print): Likewise.
3155         (literal::print): Likewise.
3156         (selftest::assert_print_eq): Add "formatted" param.
3157         (ASSERT_PRINT_EQ): Add "FORMATTED" param.
3158         (selftest::test_writing_objects): Test both formatted and
3159         unformatted printing.
3160         (selftest::test_writing_arrays): Likewise.
3161         (selftest::test_writing_float_numbers): Update for new param of
3162         ASSERT_PRINT_EQ.
3163         (selftest::test_writing_integer_numbers): Likewise.
3164         (selftest::test_writing_strings): Likewise.
3165         (selftest::test_writing_literals): Likewise.
3166         (selftest::test_formatting): New.
3167         (selftest::json_cc_tests): Call it.
3168         * json.h (value::print): Add "formatted" param.
3169         (value::dump): Likewise.
3170         (object::print): Likewise.
3171         (array::print): Likewise.
3172         (float_number::print): Likewise.
3173         (integer_number::print): Likewise.
3174         (string::print): Likewise.
3175         (literal::print): Likewise.
3176         * optinfo-emit-json.cc (optrecord_json_writer::write): Pass
3177         "false" for new formatting option when printing json.
3178         (selftest::test_building_json_from_dump_calls): Likewise.
3179         * opts.cc (common_handle_option): Use
3180         opts->x_flag_diagnostics_json_formatting.
3182 2023-12-06  David Malcolm  <dmalcolm@redhat.com>
3184         * diagnostic-format-json.cc (on_begin_diagnostic): Convert param
3185         to const reference.
3186         (on_end_diagnostic): Likewise.
3187         (json_output_format::on_end_diagnostic): Likewise.
3188         * diagnostic-format-sarif.cc
3189         (sarif_invocation::add_notification_for_ice): Likewise.
3190         (sarif_result::on_nested_diagnostic): Likewise.
3191         (sarif_ice_notification::sarif_ice_notification): Likewise.
3192         (sarif_builder::end_diagnostic): Likewise.
3193         (sarif_builder::make_result_object): Likewise.
3194         (make_reporting_descriptor_object_for_warning): Likewise.
3195         (sarif_builder::make_locations_arr): Likewise.
3196         (sarif_output_format::on_begin_diagnostic): Likewise.
3197         (sarif_output_format::on_end_diagnostic): Likewise.
3198         * diagnostic.cc (default_diagnostic_starter): Make diagnostic_info
3199         param const.
3200         (default_diagnostic_finalizer): Likewise.
3201         (diagnostic_context::report_diagnostic): Pass diagnostic by
3202         reference to on_{begin,end}_diagnostic.
3203         (diagnostic_text_output_format::on_begin_diagnostic): Convert
3204         param to const reference.
3205         (diagnostic_text_output_format::on_end_diagnostic): Likewise.
3206         * diagnostic.h (diagnostic_starter_fn): Make diagnostic_info param
3207         const.
3208         (diagnostic_finalizer_fn): Likeewise.
3209         (diagnostic_output_format::on_begin_diagnostic): Convert param to
3210         const reference.
3211         (diagnostic_output_format::on_end_diagnostic): Likewise.
3212         (diagnostic_text_output_format::on_begin_diagnostic): Likewise.
3213         (diagnostic_text_output_format::on_end_diagnostic): Likewise.
3214         (default_diagnostic_starter): Make diagnostic_info param const.
3215         (default_diagnostic_finalizer): Likewise.
3216         * langhooks-def.h (lhd_print_error_function): Make diagnostic_info
3217         param const.
3218         * langhooks.cc (lhd_print_error_function): Likewise.
3219         * langhooks.h (lang_hooks::print_error_function): Likewise.
3220         * tree-diagnostic.cc (diagnostic_report_current_function):
3221         Likewise.
3222         (default_tree_diagnostic_starter): Likewise.
3223         (virt_loc_aware_diagnostic_finalizer): Likewise.
3224         * tree-diagnostic.h (diagnostic_report_current_function):
3225         Likewise.
3226         (virt_loc_aware_diagnostic_finalizer): Likewise.
3228 2023-12-06  Andrew Stubbs  <ams@codesourcery.com>
3230         * config/gcn/gcn-builtins.def (DISPATCH_PTR): New built-in.
3231         * config/gcn/gcn.cc (gcn_init_machine_status): Disable global
3232         addressing.
3233         (gcn_expand_builtin_1): Implement GCN_BUILTIN_DISPATCH_PTR.
3235 2023-12-06  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
3237         PR target/112855
3238         * config/riscv/riscv-vsetvl.cc
3239         (pre_vsetvl::compute_lcm_local_properties): Fix transparant LCM data.
3240         (pre_vsetvl::earliest_fuse_vsetvl_info): Disable earliest fusion for unrelated edge.
3242 2023-12-06  Marek Polacek  <polacek@redhat.com>
3244         PR target/112762
3245         * config/linux.h: Redefine TARGET_FORTIFY_SOURCE_DEFAULT_LEVEL for
3246         glibc only.
3248 2023-12-06  Victor Do Nascimento  <victor.donascimento@arm.com>
3250         * config/aarch64/aarch64.cc
3251         (aarch64_test_sysreg_encoding_clashes): New.
3252         (aarch64_run_selftests): add call to
3253         aarch64_test_sysreg_encoding_clashes selftest.
3255 2023-12-06  Victor Do Nascimento  <victor.donascimento@arm.com>
3257         * config/aarch64/aarch64-builtins.cc (aarch64_general_check_builtin_call):
3258         New.
3259         * config/aarch64/aarch64-c.cc (aarch64_check_builtin_call):
3260         Add `aarch64_general_check_builtin_call' call.
3261         * config/aarch64/aarch64-protos.h (aarch64_general_check_builtin_call):
3262         New.
3264 2023-12-06  Victor Do Nascimento  <victor.donascimento@arm.com>
3266         * config/aarch64/aarch64-builtins.cc (enum aarch64_builtins):
3267         Add enums for new builtins.
3268         (aarch64_init_rwsr_builtins): New.
3269         (aarch64_general_init_builtins): Call aarch64_init_rwsr_builtins.
3270         (aarch64_expand_rwsr_builtin):  New.
3271         (aarch64_general_expand_builtin): Call aarch64_general_expand_builtin.
3272         * config/aarch64/aarch64.md (read_sysregdi): New insn_and_split.
3273         (write_sysregdi): Likewise.
3274         * config/aarch64/arm_acle.h (__arm_rsr): New.
3275         (__arm_rsrp): Likewise.
3276         (__arm_rsr64): Likewise.
3277         (__arm_rsrf): Likewise.
3278         (__arm_rsrf64): Likewise.
3279         (__arm_wsr): Likewise.
3280         (__arm_wsrp): Likewise.
3281         (__arm_wsr64): Likewise.
3282         (__arm_wsrf): Likewise.
3283         (__arm_wsrf64): Likewise.
3285 2023-12-06  Victor Do Nascimento  <victor.donascimento@arm.com>
3287         * config/aarch64/aarch64-protos.h (aarch64_valid_sysreg_name_p): New.
3288         (aarch64_retrieve_sysreg): Likewise.
3289         * config/aarch64/aarch64.cc (is_implem_def_reg): Likewise.
3290         (aarch64_valid_sysreg_name_p): Likewise.
3291         (aarch64_retrieve_sysreg): Likewise.
3292         (aarch64_register_sysreg): Likewise.
3293         (aarch64_init_sysregs): Likewise.
3294         (aarch64_lookup_sysreg_map): Likewise.
3295         * config/aarch64/predicates.md (aarch64_sysreg_string): New.
3297 2023-12-06  Victor Do Nascimento  <victor.donascimento@arm.com>
3299         * config/aarch64/aarch64.cc (sysreg_t): New.
3300         (aarch64_sysregs): Likewise.
3301         (AARCH64_FEATURE): Likewise.
3302         (AARCH64_FEATURES): Likewise.
3303         (AARCH64_NO_FEATURES): Likewise.
3304         * config/aarch64/aarch64.h (AARCH64_ISA_V8A): Add missing
3305         ISA flag.
3306         (AARCH64_ISA_V8_1A): Likewise.
3307         (AARCH64_ISA_V8_7A): Likewise.
3308         (AARCH64_ISA_V8_8A): Likewise.
3309         (AARCH64_NO_FEATURES): Likewise.
3310         (AARCH64_FL_RAS): New ISA flag alias.
3311         (AARCH64_FL_LOR): Likewise.
3312         (AARCH64_FL_PAN): Likewise.
3313         (AARCH64_FL_AMU): Likewise.
3314         (AARCH64_FL_SCXTNUM): Likewise.
3315         (AARCH64_FL_ID_PFR2): Likewise.
3316         (F_DEPRECATED): New.
3317         (F_REG_READ): Likewise.
3318         (F_REG_WRITE): Likewise.
3319         (F_ARCHEXT): Likewise.
3320         (F_REG_ALIAS): Likewise.
3322 2023-12-06  Victor Do Nascimento  <victor.donascimento@arm.com>
3324         * config/aarch64/aarch64-sys-regs.def: New.
3326 2023-12-06  Robin Dapp  <rdapp@ventanamicro.com>
3328         PR target/112854
3329         PR target/112872
3330         * config/riscv/autovec.md (vec_init<mode>qi): New expander.
3332 2023-12-06  Jakub Jelinek  <jakub@redhat.com>
3334         PR rtl-optimization/112760
3335         * config/i386/i386-passes.def (pass_insert_vzeroupper): Insert
3336         after pass_postreload_cse rather than pass_reload.
3337         * config/i386/i386-features.cc (rest_of_handle_insert_vzeroupper):
3338         Adjust comment for it.
3340 2023-12-06  Jakub Jelinek  <jakub@redhat.com>
3342         PR tree-optimization/112809
3343         * gimple-lower-bitint.cc (bitint_large_huge::lower_mergeable_stmt): For
3344         separate_ext in kind == bitint_prec_huge mode if rem == 0, create for
3345         i == cnt - 1 the loop rather than using size_int (end).
3347 2023-12-06  Jakub Jelinek  <jakub@redhat.com>
3349         * gcc.cc (driver_handle_option): Add /* FALLTHROUGH */ comment
3350         between OPT_pie and OPT_r cases.
3352 2023-12-06  Tobias Burnus  <tobias@codesourcery.com>
3354         * tsystem.h (calloc, realloc): Declare when inhibit_libc.
3356 2023-12-06  Richard Biener  <rguenther@suse.de>
3358         PR tree-optimization/112843
3359         * tree-ssa-operands.cc (update_stmt_operands): Do not call
3360         update_stmt from ranger.
3361         * value-query.h (range_query::update_stmt): Remove.
3362         * gimple-range.h (gimple_ranger::update_stmt): Likewise.
3363         * gimple-range.cc (gimple_ranger::update_stmt): Likewise.
3365 2023-12-06  xuli  <xuli1@eswincomputing.com>
3367         * config/riscv/riscv.md: Remove.
3369 2023-12-06  Alexandre Oliva  <oliva@adacore.com>
3371         * Makefile.in (OBJS): Add ipa-strub.o.
3372         (GTFILES): Add ipa-strub.cc.
3373         * builtins.def (BUILT_IN_STACK_ADDRESS): New.
3374         (BUILT_IN___STRUB_ENTER): New.
3375         (BUILT_IN___STRUB_UPDATE): New.
3376         (BUILT_IN___STRUB_LEAVE): New.
3377         * builtins.cc: Include ipa-strub.h.
3378         (STACK_STOPS, STACK_UNSIGNED): Define.
3379         (expand_builtin_stack_address): New.
3380         (expand_builtin_strub_enter): New.
3381         (expand_builtin_strub_update): New.
3382         (expand_builtin_strub_leave): New.
3383         (expand_builtin): Call them.
3384         * common.opt (fstrub=*): New options.
3385         * doc/extend.texi (strub): New type attribute.
3386         (__builtin_stack_address): New function.
3387         (Stack Scrubbing): New section.
3388         * doc/invoke.texi (-fstrub=*): New options.
3389         (-fdump-ipa-*): New passes.
3390         * gengtype-lex.l: Ignore multi-line pp-directives.
3391         * ipa-inline.cc: Include ipa-strub.h.
3392         (can_inline_edge_p): Test strub_inlinable_to_p.
3393         * ipa-split.cc: Include ipa-strub.h.
3394         (execute_split_functions): Test strub_splittable_p.
3395         * ipa-strub.cc, ipa-strub.h: New.
3396         * passes.def: Add strub_mode and strub passes.
3397         * tree-cfg.cc (gimple_verify_flow_info): Note on debug stmts.
3398         * tree-pass.h (make_pass_ipa_strub_mode): Declare.
3399         (make_pass_ipa_strub): Declare.
3400         (make_pass_ipa_function_and_variable_visibility): Fix
3401         formatting.
3402         * tree-ssa-ccp.cc (optimize_stack_restore): Keep restores
3403         before strub leave.
3404         * attribs.cc: Include ipa-strub.h.
3405         (decl_attributes): Support applying attributes to function
3406         type, rather than pointer type, at handler's request.
3407         (comp_type_attributes): Combine strub_comptypes and target
3408         comp_type results.
3409         * doc/tm.texi.in (TARGET_STRUB_USE_DYNAMIC_ARRAY): New.
3410         (TARGET_STRUB_MAY_USE_MEMSET): New.
3411         * doc/tm.texi: Rebuilt.
3412         * cgraph.h (symtab_node::reset): Add preserve_comdat_group
3413         param, with a default.
3414         * cgraphunit.cc (symtab_node::reset): Use it.
3416 2023-12-05  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
3418         PR target/112851
3419         PR target/112852
3420         * config/riscv/riscv-v.cc (vls_mode_valid_p): Block VLSmodes according
3421         TARGET_MAX_LMUL and BITS_PER_RISCV_VECTOR.
3423 2023-12-05  David Faust  <david.faust@oracle.com>
3425         PR debug/112849
3426         * btfout.cc (btf_collect_datasec): Avoid incorrectly creating an
3427         entry in a BTF_KIND_DATASEC record for extern variable decls without
3428         a known section.
3430 2023-12-05  Jakub Jelinek  <jakub@redhat.com>
3432         PR target/112606
3433         * config/rs6000/rs6000.md (copysign<mode>3): Change predicate
3434         of the last argument from gpc_reg_operand to any_operand.  If
3435         operands[2] is CONST_DOUBLE, emit abs or neg abs depending on
3436         its sign, otherwise if it doesn't satisfy gpc_reg_operand,
3437         force it to REG using copy_to_mode_reg.
3439 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
3441         * attribs.cc (handle_ignored_attributes_option): Add extra
3442         braces to work around PR 16333 in older compilers.
3443         * config/aarch64/aarch64.cc (aarch64_gnu_attribute_table): Likewise.
3444         (aarch64_arm_attribute_table): Likewise.
3445         * config/arm/arm.cc (arm_gnu_attribute_table): Likewise.
3446         * config/i386/i386-options.cc (ix86_gnu_attribute_table): Likewise.
3447         * config/ia64/ia64.cc (ia64_gnu_attribute_table): Likewise.
3448         * config/rs6000/rs6000.cc (rs6000_gnu_attribute_table): Likewise.
3449         * target-def.h (TARGET_GNU_ATTRIBUTES): Likewise.
3450         * genhooks.cc (emit_init_macros): Likewise, when emitting the
3451         instantiation of TARGET_ATTRIBUTE_TABLE.
3452         * langhooks-def.h (LANG_HOOKS_INITIALIZER): Likewise, when
3453         instantiating LANG_HOOKS_ATTRIBUTE_TABLE.
3454         (LANG_HOOKS_ATTRIBUTE_TABLE): Define to be empty by default.
3455         * target.def (attribute_table): Likewise.
3457 2023-12-05  Richard Biener  <rguenther@suse.de>
3459         PR middle-end/112860
3460         * passes.cc (should_skip_pass_p): Do not skip ISEL.
3462 2023-12-05  Richard Biener  <rguenther@suse.de>
3464         PR sanitizer/111736
3465         * asan.cc (asan_protect_global): Do not protect globals
3466         in non-generic address-space.
3468 2023-12-05  Richard Biener  <rguenther@suse.de>
3470         PR ipa/92606
3471         * ipa-icf.cc (sem_variable::equals_wpa): Compare address-spaces.
3473 2023-12-05  Richard Biener  <rguenther@suse.de>
3475         PR middle-end/112830
3476         * gimplify.cc (gimplify_modify_expr): Avoid turning aggregate
3477         copy of non-generic address-spaces to memcpy.
3478         (gimplify_modify_expr_to_memcpy): Assert we are dealing with
3479         a copy inside the generic address-space.
3480         (gimplify_modify_expr_to_memset): Likewise.
3481         * tree-cfg.cc (verify_gimple_assign_single): Allow
3482         WITH_SIZE_EXPR as part of the RHS of an assignment.
3483         * builtins.cc (get_memory_address): Assert we are dealing
3484         with the generic address-space.
3485         * tree-ssa-dce.cc (ref_may_be_aliased): Handle WITH_SIZE_EXPR.
3487 2023-12-05  Richard Biener  <rguenther@suse.de>
3489         PR tree-optimization/109689
3490         PR tree-optimization/112856
3491         * cfgloopmanip.h (unloop_loops): Adjust API.
3492         * tree-ssa-loop-ivcanon.cc (unloop_loops): Take edges_to_remove
3493         as parameter.
3494         (canonicalize_induction_variables): Adjust.
3495         (tree_unroll_loops_completely): Likewise.
3496         * tree-ssa-loop-ch.cc (ch_base::copy_headers): Rewrite into
3497         LC SSA if we unlooped some loops and we are in LC SSA.
3499 2023-12-05  Jakub Jelinek  <jakub@redhat.com>
3501         PR target/112845
3502         * config/i386/i386.md (movabsq $(i32 << shift), r64 peephole2): FAIL
3503         if the new immediate is ix86_endbr_immediate_operand.
3505 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
3507         * config/aarch64/aarch64.h (TARGET_STREAMING_SME2): New macro.
3508         (P_ALIASES): Likewise.
3509         (REGISTER_NAMES): Add pn aliases of the predicate registers.
3510         (W8_W11_REGNUM_P): New macro.
3511         (W8_W11_REGS): New register class.
3512         (REG_CLASS_NAMES, REG_CLASS_CONTENTS): Update accordingly.
3513         * config/aarch64/aarch64.cc (aarch64_print_operand): Add support
3514         for %K, which prints a predicate as a counter.  Handle tuples of
3515         predicates.
3516         (aarch64_regno_regclass): Handle W8_W11_REGS.
3517         (aarch64_class_max_nregs): Likewise.
3518         * config/aarch64/constraints.md (Uci, Uw2, Uw4): New constraints.
3519         (x, y): Move further up file.
3520         (Uph): Redefine as the high predicate registers, renaming the old
3521         constraint to...
3522         (Uih): ...this.
3523         * config/aarch64/predicates.md (const_0_to_7_operand): New predicate.
3524         (const_0_to_4_step_4_operand, const_0_to_6_step_2_operand): Likewise.
3525         (const_0_to_12_step_4_operand, const_0_to_14_step_2_operand): Likewise.
3526         (aarch64_simd_shift_imm_qi): Use const_0_to_7_operand.
3527         * config/aarch64/iterators.md (VNx16SI_ONLY, VNx8SI_ONLY)
3528         (VNx8DI_ONLY, SVE_FULL_BHSIx2, SVE_FULL_HF, SVE_FULL_SIx2_SDIx4)
3529         (SVE_FULL_BHS, SVE_FULLx24, SVE_DIx24, SVE_BHSx24, SVE_Ix24)
3530         (SVE_Fx24, SVE_SFx24, SME_ZA_BIx24, SME_ZA_BHIx124, SME_ZA_BHIx24)
3531         (SME_ZA_HFx124, SME_ZA_HFx24, SME_ZA_HIx124, SME_ZA_HIx24)
3532         (SME_ZA_SDIx24, SME_ZA_SDFx24): New mode iterators.
3533         (UNSPEC_REVD, UNSPEC_CNTP_C, UNSPEC_PEXT, UNSPEC_PEXTx2): New unspecs.
3534         (UNSPEC_PSEL, UNSPEC_PTRUE_C, UNSPEC_SQRSHR, UNSPEC_SQRSHRN)
3535         (UNSPEC_SQRSHRU, UNSPEC_SQRSHRUN, UNSPEC_UQRSHR, UNSPEC_UQRSHRN)
3536         (UNSPEC_UZP, UNSPEC_UZPQ, UNSPEC_ZIP, UNSPEC_ZIPQ, UNSPEC_BFMLSLB)
3537         (UNSPEC_BFMLSLT, UNSPEC_FCVTN, UNSPEC_FDOT, UNSPEC_SQCVT): Likewise.
3538         (UNSPEC_SQCVTN, UNSPEC_SQCVTU, UNSPEC_SQCVTUN, UNSPEC_UQCVT): Likewise.
3539         (UNSPEC_SME_ADD, UNSPEC_SME_ADD_WRITE, UNSPEC_SME_BMOPA): Likewise.
3540         (UNSPEC_SME_BMOPS, UNSPEC_SME_FADD, UNSPEC_SME_FDOT, UNSPEC_SME_FVDOT)
3541         (UNSPEC_SME_FMLA, UNSPEC_SME_FMLS, UNSPEC_SME_FSUB, UNSPEC_SME_READ)
3542         (UNSPEC_SME_SDOT, UNSPEC_SME_SVDOT, UNSPEC_SME_SMLA, UNSPEC_SME_SMLS)
3543         (UNSPEC_SME_SUB, UNSPEC_SME_SUB_WRITE, UNSPEC_SME_SUDOT): Likewise.
3544         (UNSPEC_SME_SUVDOT, UNSPEC_SME_UDOT, UNSPEC_SME_UVDOT): Likewise.
3545         (UNSPEC_SME_UMLA, UNSPEC_SME_UMLS, UNSPEC_SME_USDOT): Likewise.
3546         (UNSPEC_SME_USVDOT, UNSPEC_SME_WRITE): Likewise.
3547         (Vetype, VNARROW, V2XWIDE, Ventype, V_INT_EQUIV, v_int_equiv)
3548         (VSINGLE, vsingle, b): Add tuple modes.
3549         (v2xwide, za32_offset_range, za64_offset_range, za32_long)
3550         (za32_last_offset, vg_modifier, z_suffix, aligned_operand)
3551         (aligned_fpr): New mode attributes.
3552         (SVE_INT_BINARY_MULTI, SVE_INT_BINARY_SINGLE, SVE_INT_BINARY_MULTI)
3553         (SVE_FP_BINARY_MULTI): New int iterators.
3554         (SVE_BFLOAT_TERNARY_LONG): Add UNSPEC_BFMLSLB and UNSPEC_BFMLSLT.
3555         (SVE_BFLOAT_TERNARY_LONG_LANE): Likewise.
3556         (SVE_WHILE_ORDER, SVE2_INT_SHIFT_IMM_NARROWxN, SVE_QCVTxN)
3557         (SVE2_SFx24_UNARY, SVE2_x24_PERMUTE, SVE2_x24_PERMUTEQ)
3558         (UNSPEC_REVD_ONLY, SME2_INT_MOP, SME2_BMOP, SME_BINARY_SLICE_SDI)
3559         (SME_BINARY_SLICE_SDF, SME_BINARY_WRITE_SLICE_SDI, SME_INT_DOTPROD)
3560         (SME_INT_DOTPROD_LANE, SME_FP_DOTPROD, SME_FP_DOTPROD_LANE)
3561         (SME_INT_TERNARY_SLICE, SME_FP_TERNARY_SLICE, BHSD_BITS)
3562         (LUTI_BITS): New int iterators.
3563         (optab, sve_int_op): Handle the new unspecs.
3564         (sme_int_op, has_16bit_form): New int attributes.
3565         (bits_etype): Handle 64.
3566         * config/aarch64/aarch64.md (UNSPEC_LD1_SVE_COUNT): New unspec.
3567         (UNSPEC_ST1_SVE_COUNT, UNSPEC_LDNT1_SVE_COUNT): Likewise.
3568         (UNSPEC_STNT1_SVE_COUNT): Likewise.
3569         * config/aarch64/atomics.md (cas_short_expected_imm): Use Uhi
3570         rather than Uph for HImode immediates.
3571         * config/aarch64/aarch64-sve.md (@aarch64_ld1<SVE_FULLx24:mode>)
3572         (@aarch64_ldnt1<SVE_FULLx24:mode>, @aarch64_st1<SVE_FULLx24:mode>)
3573         (@aarch64_stnt1<SVE_FULLx24:mode>): New patterns.
3574         (@aarch64_<sur>dot_prod_lane<vsi2qi>): Extend to...
3575         (@aarch64_<sur>dot_prod_lane<SVE_FULL_SDI:mode><SVE_FULL_BHI:mode>)
3576         (@aarch64_<sur>dot_prod_lane<VNx4SI_ONLY:mode><VNx16QI_ONLY:mode>):
3577         ...these new patterns.
3578         (SVE_WHILE_B, SVE_WHILE_B_X2, SVE_WHILE_C): New constants.  Add
3579         SVE_WHILE_B to existing while patterns.
3580         * config/aarch64/aarch64-sve2.md (@aarch64_sve_ptrue_c<BHSD_BITS>)
3581         (@aarch64_sve_pext<BHSD_BITS>, @aarch64_sve_pext<BHSD_BITS>x2)
3582         (@aarch64_sve_psel<BHSD_BITS>, *aarch64_sve_psel<BHSD_BITS>_plus)
3583         (@aarch64_sve_cntp_c<BHSD_BITS>, <frint_pattern><mode>2)
3584         (<optab><mode>3, *<optab><mode>3, @aarch64_sve_single_<optab><mode>)
3585         (@aarch64_sve_<sve_int_op><mode>): New patterns.
3586         (@aarch64_sve_single_<sve_int_op><mode>, @aarch64_sve_<su>clamp<mode>)
3587         (*aarch64_sve_<su>clamp<mode>_x, @aarch64_sve_<su>clamp_single<mode>)
3588         (@aarch64_sve_fclamp<mode>, *aarch64_sve_fclamp<mode>_x)
3589         (@aarch64_sve_fclamp_single<mode>, <optab><mode><v2xwide>2)
3590         (@aarch64_sve_<sur>dotvnx4sivnx8hi): New patterns.
3591         (@aarch64_sve_<maxmin_uns_op><mode>): Likewise.
3592         (*aarch64_sve_<maxmin_uns_op><mode>): Likewise.
3593         (@aarch64_sve_single_<maxmin_uns_op><mode>): Likewise.
3594         (aarch64_sve_fdotvnx4sfvnx8hf): Likewise.
3595         (aarch64_fdot_prod_lanevnx4sfvnx8hf): Likewise.
3596         (@aarch64_sve_<optab><VNx16QI_ONLY:mode><VNx16SI_ONLY:mode>): Likewise.
3597         (@aarch64_sve_<optab><VNx8HI_ONLY:mode><VNx8SI_ONLY:mode>): Likewise.
3598         (@aarch64_sve_<optab><VNx8HI_ONLY:mode><VNx8DI_ONLY:mode>): Likewise.
3599         (truncvnx8sf<mode>2, @aarch64_sve_cvtn<mode>): Likewise.
3600         (<optab><v_int_equiv><mode>2, <optab><mode><v_int_equiv>2): Likewise.
3601         (@aarch64_sve_sel<mode>): Likewise.
3602         (@aarch64_sve_while<while_optab_cmp>_b<BHSD_BITS>_x2): Likewise.
3603         (@aarch64_sve_while<while_optab_cmp>_c<BHSD_BITS>): Likewise.
3604         (@aarch64_pred_<optab><mode>, @cond_<optab><mode>): Likewise.
3605         (@aarch64_sve_<optab><mode>): Likewise.
3606         * config/aarch64/aarch64-sme.md (@aarch64_sme_<optab><mode><mode>)
3607         (*aarch64_sme_<optab><mode><mode>_plus, @aarch64_sme_read<mode>)
3608         (*aarch64_sme_read<mode>_plus, @aarch64_sme_write<mode>): New patterns.
3609         (*aarch64_sme_write<mode>_plus aarch64_sme_zero_zt0): Likewise.
3610         (@aarch64_sme_<optab><mode>, *aarch64_sme_<optab><mode>_plus)
3611         (@aarch64_sme_single_<optab><mode>): Likewise.
3612         (*aarch64_sme_single_<optab><mode>_plus): Likewise.
3613         (@aarch64_sme_<optab><SME_ZA_SDI:mode><SME_ZA_BHIx24:mode>)
3614         (*aarch64_sme_<optab><SME_ZA_SDI:mode><SME_ZA_BHIx24:mode>_plus)
3615         (@aarch64_sme_single_<optab><SME_ZA_SDI:mode><SME_ZA_BHIx24:mode>)
3616         (*aarch64_sme_single_<optab><SME_ZA_SDI:mode><SME_ZA_BHIx24:mode>_plus)
3617         (@aarch64_sme_single_sudot<VNx4SI_ONLY:mode><SME_ZA_BIx24:mode>)
3618         (*aarch64_sme_single_sudot<VNx4SI_ONLY:mode><SME_ZA_BIx24:mode>_plus)
3619         (@aarch64_sme_lane_<optab><SME_ZA_SDI:mode><SME_ZA_BHIx24:mode>)
3620         (*aarch64_sme_lane_<optab><SME_ZA_SDI:mode><SME_ZA_BHIx24:mode>_plus)
3621         (@aarch64_sme_<optab><VNx4SI_ONLY:mode><SVE_FULL_BHI:mode>)
3622         (*aarch64_sme_<optab><VNx4SI_ONLY:mode><SVE_FULL_BHI:mode>_plus)
3623         (@aarch64_sme_<optab><VNx4SI_ONLY:mode><SME_ZA_BHIx24:mode>)
3624         (*aarch64_sme_<optab><VNx4SI_ONLY:mode><SME_ZA_BHIx24:mode>_plus)
3625         (@aarch64_sme_single_<optab><VNx4SI_ONLY:mode><SME_ZA_BHIx24:mode>)
3626         (*aarch64_sme_single_<optab><VNx4SI_ONLY:mode><SME_ZA_BHIx24:mode>_plus)
3627         (@aarch64_sme_lane_<optab><VNx4SI_ONLY:mode><SME_ZA_BHIx124:mode>)
3628         (*aarch64_sme_lane_<optab><VNx4SI_ONLY:mode><SME_ZA_BHIx124:mode>)
3629         (@aarch64_sme_<optab><VNx2DI_ONLY:mode><VNx8HI_ONLY:mode>)
3630         (*aarch64_sme_<optab><VNx2DI_ONLY:mode><VNx8HI_ONLY:mode>_plus)
3631         (@aarch64_sme_<optab><VNx2DI_ONLY:mode><SME_ZA_HIx24:mode>)
3632         (*aarch64_sme_<optab><VNx2DI_ONLY:mode><SME_ZA_HIx24:mode>_plus)
3633         (@aarch64_sme_single_<optab><VNx2DI_ONLY:mode><SME_ZA_HIx24:mode>)
3634         (*aarch64_sme_single_<optab><VNx2DI_ONLY:mode><SME_ZA_HIx24:mode>_plus)
3635         (@aarch64_sme_lane_<optab><VNx2DI_ONLY:mode><SME_ZA_HIx124:mode>)
3636         (*aarch64_sme_lane_<optab><VNx2DI_ONLY:mode><SME_ZA_HIx124:mode>)
3637         (@aarch64_sme_<optab><VNx4SI_ONLY:mode><VNx8HI_ONLY:mode>)
3638         (@aarch64_sme_<optab><VNx4SI_ONLY:mode><VNx4SI_ONLY:mode>)
3639         (@aarch64_sme_<optab><VNx4SI_ONLY:mode><SME_ZA_HFx24:mode>)
3640         (*aarch64_sme_<optab><VNx4SI_ONLY:mode><SME_ZA_HFx24:mode>_plus)
3641         (@aarch64_sme_single_<optab><VNx4SI_ONLY:mode><SME_ZA_HFx24:mode>)
3642         (*aarch64_sme_single_<optab><VNx4SI_ONLY:mode><SME_ZA_HFx24:mode>_plus)
3643         (@aarch64_sme_lane_<optab><VNx4SI_ONLY:mode><SME_ZA_HFx24:mode>)
3644         (*aarch64_sme_lane_<optab><VNx4SI_ONLY:mode><SME_ZA_HFx24:mode>_plus)
3645         (@aarch64_sme_<optab><SME_ZA_SDF_I:mode><SME_ZA_SDFx24:mode>)
3646         (*aarch64_sme_<optab><SME_ZA_SDF_I:mode><SME_ZA_SDFx24:mode>_plus)
3647         (@aarch64_sme_single_<optab><SME_ZA_SDF_I:mode><SME_ZA_SDFx24:mode>)
3648         (*aarch64_sme_single_<optab><SME_ZA_SDF_I:mode><SME_ZA_SDFx24:mode>_plus)
3649         (@aarch64_sme_lane_<optab><SME_ZA_SDF_I:mode><SME_ZA_SDFx24:mode>)
3650         (*aarch64_sme_lane_<optab><SME_ZA_SDF_I:mode><SME_ZA_SDFx24:mode>)
3651         (@aarch64_sme_<optab><VNx4SI_ONLY:mode><SVE_FULL_HF:mode>)
3652         (*aarch64_sme_<optab><VNx4SI_ONLY:mode><SVE_FULL_HF:mode>_plus)
3653         (@aarch64_sme_lane_<optab><VNx4SI_ONLY:mode><SME_ZA_HFx124:mode>)
3654         (*aarch64_sme_lane_<optab><VNx4SI_ONLY:mode><SME_ZA_HFx124:mode>)
3655         (@aarch64_sme_lut<LUTI_BITS><mode>): Likewise.
3656         (UNSPEC_SME_LUTI): New unspec.
3657         * config/aarch64/aarch64-sve-builtins.def (single): New mode suffix.
3658         (c8, c16, c32, c64): New type suffixes.
3659         (vg1x2, vg1x4, vg2, vg2x1, vg2x2, vg2x4, vg4, vg4x1, vg4x2)
3660         (vg4x4): New group suffixes.
3661         * config/aarch64/aarch64-sve-builtins.h (CP_READ_ZT0)
3662         (CP_WRITE_ZT0): New constants.
3663         (get_svbool_t): Delete.
3664         (function_resolver::report_mismatched_num_vectors): New member
3665         function.
3666         (function_resolver::resolve_conversion): Likewise.
3667         (function_resolver::infer_predicate_type): Likewise.
3668         (function_resolver::infer_64bit_scalar_integer_pair): Likewise.
3669         (function_resolver::require_matching_predicate_type): Likewise.
3670         (function_resolver::require_nonscalar_type): Likewise.
3671         (function_resolver::finish_opt_single_resolution): Likewise.
3672         (function_resolver::require_derived_vector_type): Add an
3673         expected_num_vectors parameter.
3674         (function_expander::map_to_rtx_codes): Add an extra parameter
3675         for unconditional FP unspecs.
3676         (function_instance::gp_type_index): New member function.
3677         (function_instance::gp_type): Likewise.
3678         (function_instance::gp_mode): Handle multi-vector operations.
3679         * config/aarch64/aarch64-sve-builtins.cc (TYPES_all_count)
3680         (TYPES_all_pred_count, TYPES_c, TYPES_bhs_data, TYPES_bhs_widen)
3681         (TYPES_hs_data, TYPES_cvt_h_s_float, TYPES_cvt_s_s, TYPES_qcvt_x2)
3682         (TYPES_qcvt_x4, TYPES_qrshr_x2, TYPES_qrshru_x2, TYPES_qrshr_x4)
3683         (TYPES_qrshru_x4, TYPES_while_x, TYPES_while_x_c, TYPES_s_narrow_fsu)
3684         (TYPES_za_s_b_signed, TYPES_za_s_b_unsigned, TYPES_za_s_b_integer)
3685         (TYPES_za_s_h_integer, TYPES_za_s_h_data, TYPES_za_s_unsigned)
3686         (TYPES_za_s_float, TYPES_za_s_data, TYPES_za_d_h_integer): New type
3687         macros.
3688         (groups_x2, groups_x12, groups_x4, groups_x24, groups_x124)
3689         (groups_vg1x2, groups_vg1x4, groups_vg1x24, groups_vg2, groups_vg4)
3690         (groups_vg24): New group arrays.
3691         (function_instance::reads_global_state_p): Handle CP_READ_ZT0.
3692         (function_instance::modifies_global_state_p): Handle CP_WRITE_ZT0.
3693         (add_shared_state_attribute): Handle zt0 state.
3694         (function_builder::add_overloaded_functions): Skip MODE_single
3695         for non-tuple groups.
3696         (function_resolver::report_mismatched_num_vectors): New function.
3697         (function_resolver::resolve_to): Add a fallback error message for
3698         the general two-type case.
3699         (function_resolver::resolve_conversion): New function.
3700         (function_resolver::infer_predicate_type): Likewise.
3701         (function_resolver::infer_64bit_scalar_integer_pair): Likewise.
3702         (function_resolver::require_matching_predicate_type): Likewise.
3703         (function_resolver::require_matching_vector_type): Specifically
3704         diagnose mismatched vector counts.
3705         (function_resolver::require_derived_vector_type): Add an
3706         expected_num_vectors parameter.  Extend to handle cases where
3707         tuples are expected.
3708         (function_resolver::require_nonscalar_type): New function.
3709         (function_resolver::check_gp_argument): Use gp_type_index rather
3710         than hard-coding VECTOR_TYPE_svbool_t.
3711         (function_resolver::finish_opt_single_resolution): New function.
3712         (function_checker::require_immediate_either_or): Remove hard-coded
3713         constants.
3714         (function_expander::direct_optab_handler): New function.
3715         (function_expander::use_pred_x_insn): Only add a strictness flag
3716         is the insn has an operand for it.
3717         (function_expander::map_to_rtx_codes): Take an unconditional
3718         FP unspec as an extra parameter.  Handle tuples and MODE_single.
3719         (function_expander::map_to_unspecs): Handle tuples and MODE_single.
3720         * config/aarch64/aarch64-sve-builtins-functions.h (read_zt0)
3721         (write_zt0): New typedefs.
3722         (full_width_access::memory_vector): Use the function's
3723         vectors_per_tuple.
3724         (rtx_code_function_base): Add an optional unconditional FP unspec.
3725         (rtx_code_function::expand): Update accordingly.
3726         (rtx_code_function_rotated::expand): Likewise.
3727         (unspec_based_function_exact_insn::expand): Use tuple_mode instead
3728         of vector_mode.
3729         (unspec_based_uncond_function): New typedef.
3730         (cond_or_uncond_unspec_function): New class.
3731         (sme_1mode_function::expand): Handle single forms.
3732         (sme_2mode_function_t): Likewise, adding a template parameter for them.
3733         (sme_2mode_function): Update accordingly.
3734         (sme_2mode_lane_function): New typedef.
3735         (multireg_permute): New class.
3736         (class integer_conversion): Likewise.
3737         (while_comparison::expand): Handle svcount_t and svboolx2_t results.
3738         * config/aarch64/aarch64-sve-builtins-shapes.h
3739         (binary_int_opt_single_n, binary_opt_single_n, binary_single)
3740         (binary_za_slice_lane, binary_za_slice_int_opt_single)
3741         (binary_za_slice_opt_single, binary_za_slice_uint_opt_single)
3742         (binaryx, clamp, compare_scalar_count, count_pred_c)
3743         (dot_za_slice_int_lane, dot_za_slice_lane, dot_za_slice_uint_lane)
3744         (extract_pred, inherent_zt, ldr_zt, read_za, read_za_slice)
3745         (select_pred, shift_right_imm_narrowxn, storexn, str_zt)
3746         (unary_convertxn, unary_za_slice, unaryxn, write_za)
3747         (write_za_slice): Declare.
3748         * config/aarch64/aarch64-sve-builtins-shapes.cc
3749         (za_group_is_pure_overload): New function.
3750         (apply_predication): Use the function's gp_type for the predicate,
3751         instead of hard-coding the use of svbool_t.
3752         (parse_element_type): Add support for "c" (svcount_t).
3753         (parse_type): Add support for "c0" and "c1" (conversion destination
3754         and source types).
3755         (binary_za_slice_lane_base): New class.
3756         (binary_za_slice_opt_single_base): Likewise.
3757         (load_contiguous_base::resolve): Pass the group suffix to r.resolve.
3758         (luti_lane_zt_base): New class.
3759         (binary_int_opt_single_n, binary_opt_single_n, binary_single)
3760         (binary_za_slice_lane, binary_za_slice_int_opt_single)
3761         (binary_za_slice_opt_single, binary_za_slice_uint_opt_single)
3762         (binaryx, clamp): New shapes.
3763         (compare_scalar_def::build): Allow the return type to be a tuple.
3764         (compare_scalar_def::expand): Pass the group suffix to r.resolve.
3765         (compare_scalar_count, count_pred_c, dot_za_slice_int_lane)
3766         (dot_za_slice_lane, dot_za_slice_uint_lane, extract_pred, inherent_zt)
3767         (ldr_zt, read_za, read_za_slice, select_pred, shift_right_imm_narrowxn)
3768         (storexn, str_zt): New shapes.
3769         (ternary_qq_lane_def, ternary_qq_opt_n_def): Replace with...
3770         (ternary_qq_or_011_lane_def, ternary_qq_opt_n_or_011_def): ...these
3771         new classes.  Allow a second suffix that specifies the type of the
3772         second vector argument, and that is used to derive the third.
3773         (unary_def::build): Extend to handle tuple types.
3774         (unary_convert_def::build): Use the new c0 and c1 format specifiers.
3775         (unary_convertxn, unary_za_slice, unaryxn, write_za): New shapes.
3776         (write_za_slice): Likewise.
3777         * config/aarch64/aarch64-sve-builtins-base.cc (svbic_impl::expand)
3778         (svext_bhw_impl::expand): Update call to map_to_rtx_costs.
3779         (svcntp_impl::expand): Handle svcount_t variants.
3780         (svcvt_impl::expand): Handle unpredicated conversions separately,
3781         dealing with tuples.
3782         (svdot_impl::expand): Handle 2-way dot products.
3783         (svdotprod_lane_impl::expand): Likewise.
3784         (svld1_impl::fold): Punt on tuple loads.
3785         (svld1_impl::expand): Handle tuple loads.
3786         (svldnt1_impl::expand): Likewise.
3787         (svpfalse_impl::fold): Punt on svcount_t forms.
3788         (svptrue_impl::fold): Likewise.
3789         (svptrue_impl::expand): Handle svcount_t forms.
3790         (svrint_impl): New class.
3791         (svsel_impl::fold): Punt on tuple forms.
3792         (svsel_impl::expand): Handle tuple forms.
3793         (svst1_impl::fold): Punt on tuple loads.
3794         (svst1_impl::expand): Handle tuple loads.
3795         (svstnt1_impl::expand): Likewise.
3796         (svwhilelx_impl::fold): Punt on tuple forms.
3797         (svdot_lane): Use UNSPEC_FDOT.
3798         (svmax, svmaxnm, svmin, svminmm): Add unconditional FP unspecs.
3799         (rinta, rinti, rintm, rintn, rintp, rintx, rintz): Use svrint_impl.
3800         * config/aarch64/aarch64-sve-builtins-base.def (svcreate2, svget2)
3801         (svset2, svundef2): Add _b variants.
3802         (svcvt): Use unary_convertxn.
3803         (svdot): Use ternary_qq_opt_n_or_011.
3804         (svdot_lane): Use ternary_qq_or_011_lane.
3805         (svmax, svmaxnm, svmin, svminnm): Use binary_opt_single_n.
3806         (svpfalse): Add a form that returns svcount_t results.
3807         (svrinta, svrintm, svrintn, svrintp): Use unaryxn.
3808         (svsel): Use binaryxn.
3809         (svst1, svstnt1): Use storexn.
3810         * config/aarch64/aarch64-sve-builtins-sme.h
3811         (svadd_za, svadd_write_za, svbmopa_za, svbmops_za, svdot_za)
3812         (svdot_lane_za, svldr_zt, svluti2_lane_zt, svluti4_lane_zt)
3813         (svmla_za, svmla_lane_za, svmls_za, svmls_lane_za, svread_za)
3814         (svstr_zt, svsub_za, svsub_write_za, svsudot_za, svsudot_lane_za)
3815         (svsuvdot_lane_za, svusdot_za, svusdot_lane_za, svusvdot_lane_za)
3816         (svvdot_lane_za, svwrite_za, svzero_zt): Declare.
3817         * config/aarch64/aarch64-sve-builtins-sme.cc (load_store_za_base):
3818         Rename to...
3819         (load_store_za_zt0_base): ...this and extend to tuples.
3820         (load_za_base, store_za_base): Update accordingly.
3821         (expand_ldr_str_zt0): New function.
3822         (svldr_zt_impl, svluti_lane_zt_impl, svread_za_impl, svstr_zt_impl)
3823         (svsudot_za_impl, svwrite_za_impl, svzero_zt_impl): New classes.
3824         (svadd_za, svadd_write_za, svbmopa_za, svbmops_za, svdot_za)
3825         (svdot_lane_za, svldr_zt, svluti2_lane_zt, svluti4_lane_zt)
3826         (svmla_za, svmla_lane_za, svmls_za, svmls_lane_za, svread_za)
3827         (svstr_zt, svsub_za, svsub_write_za, svsudot_za, svsudot_lane_za)
3828         (svsuvdot_lane_za, svusdot_za, svusdot_lane_za, svusvdot_lane_za)
3829         (svvdot_lane_za, svwrite_za, svzero_zt): New functions.
3830         * config/aarch64/aarch64-sve-builtins-sme.def: Add SME2 intrinsics.
3831         * config/aarch64/aarch64-sve-builtins-sve2.h
3832         (svbfmlslb, svbfmlslb_lane, svbfmlslt, svbfmlslt_lane, svclamp)
3833         (svcvtn, svpext, svpsel, svqcvt, svqcvtn, svqrshr, svqrshrn)
3834         (svqrshru, svqrshrun, svrevd, svunpk, svuzp, svuzpq, svzip)
3835         (svzipq): Declare.
3836         * config/aarch64/aarch64-sve-builtins-sve2.cc (svclamp_impl)
3837         (svcvtn_impl, svpext_impl, svpsel_impl): New classes.
3838         (svqrshl_impl::fold): Update for change to svrshl shape.
3839         (svrshl_impl::fold): Punt on tuple forms.
3840         (svsqadd_impl::expand): Update call to map_to_rtx_codes.
3841         (svunpk_impl): New class.
3842         (svbfmlslb, svbfmlslb_lane, svbfmlslt, svbfmlslt_lane, svclamp)
3843         (svcvtn, svpext, svpsel, svqcvt, svqcvtn, svqrshr, svqrshrn)
3844         (svqrshru, svqrshrun, svrevd, svunpk, svuzp, svuzpq, svzip)
3845         (svzipq): New functions.
3846         * config/aarch64/aarch64-sve-builtins-sve2.def: Add SME2 intrinsics.
3847         * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins): Define
3848         or undefine __ARM_FEATURE_SME2.
3850 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
3852         * config/aarch64/aarch64.md (ZT0_REGNUM): New constant.
3853         (LAST_FAKE_REGNUM): Bump to include it.
3854         * config/aarch64/aarch64.h (FIXED_REGISTERS): Add an entry for ZT0.
3855         (CALL_REALLY_USED_REGISTERS, REGISTER_NAMES): Likewise.
3856         (REG_CLASS_CONTENTS): Likewise.
3857         (machine_function): Add zt0_save_buffer.
3858         (CUMULATIVE_ARGS): Add shared_zt0_flags;
3859         * config/aarch64/aarch64.cc (aarch64_check_state_string): Handle zt0.
3860         (aarch64_fntype_pstate_za, aarch64_fndecl_pstate_za): Likewise.
3861         (aarch64_function_arg): Add the shared ZT0 flags as an extra
3862         limb of the parallel.
3863         (aarch64_init_cumulative_args): Initialize shared_zt0_flags.
3864         (aarch64_extra_live_on_entry): Handle ZT0_REGNUM.
3865         (aarch64_epilogue_uses): Likewise.
3866         (aarch64_get_zt0_save_buffer, aarch64_save_zt0): New functions.
3867         (aarch64_restore_zt0): Likewise.
3868         (aarch64_start_call_args): Reject calls to functions that share
3869         ZT0 from functions that have no ZT0 state.  Save ZT0 around shared-ZA
3870         calls that do not share ZT0.
3871         (aarch64_expand_call): Handle ZT0.  Reject calls to functions that
3872         share ZT0 but not ZA from functions with ZA state.
3873         (aarch64_end_call_args): Restore ZT0 after calls to shared-ZA functions
3874         that do not share ZT0.
3875         (aarch64_set_current_function): Require +sme2 for functions that
3876         have ZT0 state.
3877         (aarch64_function_attribute_inlinable_p): Don't allow functions to
3878         be inlined if they have local zt0 state.
3879         (AARCH64_IPA_CLOBBERS_ZT0): New constant.
3880         (aarch64_update_ipa_fn_target_info): Record asms that clobber ZT0.
3881         (aarch64_can_inline_p): Don't inline callees that clobber ZT0
3882         into functions that have ZT0 state.
3883         (aarch64_comp_type_attributes): Check for compatible ZT0 sharing.
3884         (aarch64_optimize_mode_switching): Use mode switching if the
3885         function has ZT0 state.
3886         (aarch64_mode_emit_local_sme_state): Save and restore ZT0 around
3887         calls to private-ZA functions.
3888         (aarch64_mode_needed_local_sme_state): Require ZA to be active
3889         for instructions that access ZT0.
3890         (aarch64_mode_entry): Mark ZA as dead on entry if the function
3891         only shares state other than "za" itself.
3892         (aarch64_mode_exit): Likewise mark ZA as dead on return.
3893         (aarch64_md_asm_adjust): Extend handling of ZA clobbers to ZT0.
3894         * config/aarch64/aarch64-c.cc (aarch64_define_unconditional_macros):
3895         Define __ARM_STATE_ZT0.
3896         * config/aarch64/aarch64-sme.md (UNSPECV_ASM_UPDATE_ZT0): New unspecv.
3897         (aarch64_asm_update_zt0): New insn.
3898         (UNSPEC_RESTORE_ZT0): New unspec.
3899         (aarch64_sme_ldr_zt0, aarch64_restore_zt0): New insns.
3900         (aarch64_sme_str_zt0): Likewise.
3902 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
3904         * config/aarch64/aarch64-modes.def (VNx32BI): New mode.
3905         * config/aarch64/aarch64-protos.h (aarch64_split_double_move): Declare.
3906         * config/aarch64/aarch64-sve-builtins.cc
3907         (register_tuple_type): Handle tuples of predicates.
3908         (handle_arm_sve_h): Define svboolx2_t as a pair of two svbool_ts.
3909         * config/aarch64/aarch64-sve.md (movvnx32bi): New insn.
3910         * config/aarch64/aarch64.cc
3911         (pure_scalable_type_info::piece::get_rtx): Use VNx32BI for pairs
3912         of predicates.
3913         (pure_scalable_type_info::add_piece): Don't try to form pairs of
3914         predicates.
3915         (VEC_STRUCT): Generalize comment.
3916         (aarch64_classify_vector_mode): Handle VNx32BI.
3917         (aarch64_array_mode): Likewise.  Return BLKmode for arrays of
3918         predicates that have no associated mode, rather than allowing
3919         an integer mode to be chosen.
3920         (aarch64_hard_regno_nregs): Handle VNx32BI.
3921         (aarch64_hard_regno_mode_ok): Likewise.
3922         (aarch64_split_double_move): New function, split out from...
3923         (aarch64_split_128bit_move): ...here.
3924         (aarch64_ptrue_reg): Tighten assert to aarch64_sve_pred_mode_p.
3925         (aarch64_pfalse_reg): Likewise.
3926         (aarch64_sve_same_pred_for_ptest_p): Likewise.
3927         (aarch64_sme_mode_switch_regs::add_reg): Handle VNx32BI.
3928         (aarch64_expand_mov_immediate): Restrict handling of boolean vector
3929         constants to single-predicate modes.
3930         (aarch64_classify_address): Handle VNx32BI, ensuring that both halves
3931         can be addressed.
3932         (aarch64_class_max_nregs): Handle VNx32BI.
3933         (aarch64_member_type_forces_blk): Don't for BLKmode for svboolx2_t.
3934         (aarch64_simd_valid_immediate): Allow all-zeros and all-ones for
3935         VNx32BI.
3936         (aarch64_mov_operand_p): Restrict predicate constant canonicalization
3937         to single-predicate modes.
3938         (aarch64_evpc_ext): Generalize exclusion to all predicate modes.
3939         (aarch64_evpc_rev_local, aarch64_evpc_dup): Likewise.
3940         * config/aarch64/constraints.md (PR_REGS): New predicate.
3942 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
3944         * config/aarch64/aarch64-sve-builtins-base.cc
3945         (svreinterpret_impl::fold): Handle reinterprets between svbool_t
3946         and svcount_t.
3947         (svreinterpret_impl::expand): Likewise.
3948         * config/aarch64/aarch64-sve-builtins-base.def (svreinterpret): Add
3949         b<->c forms.
3950         * config/aarch64/aarch64-sve-builtins.cc (TYPES_reinterpret_b): New
3951         type suffix list.
3952         (wrap_type_in_struct, register_type_decl): New functions, split out
3953         from...
3954         (register_tuple_type): ...here.
3955         (register_builtin_types): Handle svcount_t.
3956         (handle_arm_sve_h): Don't create tuples of svcount_t.
3957         * config/aarch64/aarch64-sve-builtins.def (svcount_t): New type.
3958         (c): New type suffix.
3959         * config/aarch64/aarch64-sve-builtins.h (TYPE_count): New type class.
3961 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
3963         * doc/invoke.texi: Document +sme2.
3964         * doc/sourcebuild.texi: Document aarch64_sme2.
3965         * config/aarch64/aarch64-option-extensions.def (AARCH64_OPT_EXTENSION):
3966         Add sme2.
3967         * config/aarch64/aarch64.h (AARCH64_ISA_SME2, TARGET_SME2): New macros.
3969 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
3971         * config/aarch64/aarch64.cc (aarch64_function_ok_for_sibcall):
3972         Enforce PSTATE.SM and PSTATE.ZA restrictions.
3973         (aarch64_expand_epilogue): Save and restore the arguments
3974         to a sibcall around any change to PSTATE.SM.
3976 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
3978         * config/aarch64/aarch64.cc: Include symbol-summary.h, ipa-prop.h,
3979         and ipa-fnsummary.h
3980         (aarch64_function_attribute_inlinable_p): New function.
3981         (AARCH64_IPA_SM_FIXED, AARCH64_IPA_CLOBBERS_ZA): New constants.
3982         (aarch64_need_ipa_fn_target_info): New function.
3983         (aarch64_update_ipa_fn_target_info): Likewise.
3984         (aarch64_can_inline_p): Restrict the previous ISA flag checks
3985         to non-modal features.  Prevent callees that require a particular
3986         PSTATE.SM state from being inlined into callers that can't guarantee
3987         that state.  Also prevent callees that have ZA state from being
3988         inlined into callers that don't.  Finally, prevent callees that
3989         clobber ZA from being inlined into callers that have ZA state.
3990         (TARGET_FUNCTION_ATTRIBUTE_INLINABLE_P): Define.
3991         (TARGET_NEED_IPA_FN_TARGET_INFO): Likewise.
3992         (TARGET_UPDATE_IPA_FN_TARGET_INFO): Likewise.
3994 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
3996         * config/aarch64/aarch64.cc: Include except.h
3997         (aarch64_sme_mode_switch_regs::add_call_preserved_reg): New function.
3998         (aarch64_sme_mode_switch_regs::add_call_preserved_regs): Likewise.
3999         (aarch64_need_old_pstate_sm): Return true if the function has
4000         a nonlocal-goto or exception receiver.
4001         (aarch64_switch_pstate_sm_for_landing_pad): New function.
4002         (aarch64_switch_pstate_sm_for_jump): Likewise.
4003         (pass_switch_pstate_sm::gate): Enable the pass for all
4004         streaming and streaming-compatible functions.
4005         (pass_switch_pstate_sm::execute): Handle non-local gotos and their
4006         receivers.  Handle exception handler entry points.
4008 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4010         * config/aarch64/aarch64.cc (aarch64_arm_attribute_table): Add
4011         arm::locally_streaming.
4012         (aarch64_fndecl_is_locally_streaming): New function.
4013         (aarch64_fndecl_sm_state): Handle locally-streaming functions.
4014         (aarch64_cfun_enables_pstate_sm): New function.
4015         (aarch64_add_offset): Add an argument that specifies whether
4016         the streaming vector length should be used instead of the
4017         prevailing one.
4018         (aarch64_split_add_offset, aarch64_add_sp, aarch64_sub_sp): Likewise.
4019         (aarch64_allocate_and_probe_stack_space): Likewise.
4020         (aarch64_expand_mov_immediate): Update calls accordingly.
4021         (aarch64_need_old_pstate_sm): Return true for locally-streaming
4022         streaming-compatible functions.
4023         (aarch64_layout_frame): Force all call-preserved Z and P registers
4024         to be saved and restored if the function switches PSTATE.SM in the
4025         prologue.
4026         (aarch64_get_separate_components): Disable shrink-wrapping of
4027         such Z and P saves and restores.
4028         (aarch64_use_late_prologue_epilogue): New function.
4029         (aarch64_expand_prologue): Measure SVE lengths in the streaming
4030         vector length for locally-streaming functions, then emit code
4031         to enable streaming mode.
4032         (aarch64_expand_epilogue): Likewise in reverse.
4033         (TARGET_USE_LATE_PROLOGUE_EPILOGUE): Define.
4034         * config/aarch64/aarch64-c.cc (aarch64_define_unconditional_macros):
4035         Define __arm_locally_streaming.
4037 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4039         * doc/invoke.texi: Document +sme-i16i64 and +sme-f64f64.
4040         * config.gcc (aarch64*-*-*): Add arm_sme.h to the list of headers
4041         to install and aarch64-sve-builtins-sme.o to the list of objects
4042         to build.
4043         * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins): Define
4044         or undefine TARGET_SME, TARGET_SME_I16I64 and TARGET_SME_F64F64.
4045         (aarch64_pragma_aarch64): Handle arm_sme.h.
4046         * config/aarch64/aarch64-option-extensions.def (sme-i16i64)
4047         (sme-f64f64): New extensions.
4048         * config/aarch64/aarch64-protos.h (aarch64_sme_vq_immediate)
4049         (aarch64_addsvl_addspl_immediate_p, aarch64_output_addsvl_addspl)
4050         (aarch64_output_sme_zero_za): Declare.
4051         (aarch64_output_move_struct): Delete.
4052         (aarch64_sme_ldr_vnum_offset): Declare.
4053         (aarch64_sve::handle_arm_sme_h): Likewise.
4054         * config/aarch64/aarch64.h (AARCH64_ISA_SM_ON): New macro.
4055         (AARCH64_ISA_SME_I16I64, AARCH64_ISA_SME_F64F64): Likewise.
4056         (TARGET_STREAMING, TARGET_STREAMING_SME): Likewise.
4057         (TARGET_SME_I16I64, TARGET_SME_F64F64): Likewise.
4058         * config/aarch64/aarch64.cc (aarch64_sve_rdvl_factor_p): Rename to...
4059         (aarch64_sve_rdvl_addvl_factor_p): ...this.
4060         (aarch64_sve_rdvl_immediate_p): Update accordingly.
4061         (aarch64_rdsvl_immediate_p, aarch64_add_offset): Likewise.
4062         (aarch64_sme_vq_immediate): Likewise.  Make public.
4063         (aarch64_sve_addpl_factor_p): New function.
4064         (aarch64_sve_addvl_addpl_immediate_p): Use
4065         aarch64_sve_rdvl_addvl_factor_p and aarch64_sve_addpl_factor_p.
4066         (aarch64_addsvl_addspl_immediate_p): New function.
4067         (aarch64_output_addsvl_addspl): Likewise.
4068         (aarch64_cannot_force_const_mem): Return true for RDSVL immediates.
4069         (aarch64_classify_index): Handle .Q scaling for VNx1TImode.
4070         (aarch64_classify_address): Likewise for vnum offsets.
4071         (aarch64_output_sme_zero_za): New function.
4072         (aarch64_sme_ldr_vnum_offset_p): Likewise.
4073         * config/aarch64/predicates.md (aarch64_addsvl_addspl_immediate):
4074         New predicate.
4075         (aarch64_pluslong_operand): Include it for SME.
4076         * config/aarch64/constraints.md (Ucj, Uav): New constraints.
4077         * config/aarch64/iterators.md (VNx1TI_ONLY): New mode iterator.
4078         (SME_ZA_I, SME_ZA_SDI, SME_ZA_SDF_I, SME_MOP_BHI): Likewise.
4079         (SME_MOP_HSDF): Likewise.
4080         (UNSPEC_SME_ADDHA, UNSPEC_SME_ADDVA, UNSPEC_SME_FMOPA)
4081         (UNSPEC_SME_FMOPS, UNSPEC_SME_LD1_HOR, UNSPEC_SME_LD1_VER)
4082         (UNSPEC_SME_READ_HOR, UNSPEC_SME_READ_VER, UNSPEC_SME_SMOPA)
4083         (UNSPEC_SME_SMOPS, UNSPEC_SME_ST1_HOR, UNSPEC_SME_ST1_VER)
4084         (UNSPEC_SME_SUMOPA, UNSPEC_SME_SUMOPS, UNSPEC_SME_UMOPA)
4085         (UNSPEC_SME_UMOPS, UNSPEC_SME_USMOPA, UNSPEC_SME_USMOPS)
4086         (UNSPEC_SME_WRITE_HOR, UNSPEC_SME_WRITE_VER): New unspecs.
4087         (elem_bits): Handle x2 and x4 structure modes, plus VNx1TI.
4088         (Vetype, Vesize, VPRED): Handle VNx1TI.
4089         (b): New mode attribute.
4090         (SME_LD1, SME_READ, SME_ST1, SME_WRITE, SME_BINARY_SDI, SME_INT_MOP)
4091         (SME_FP_MOP): New int iterators.
4092         (optab): Handle SME unspecs.
4093         (hv): New int attribute.
4094         * config/aarch64/aarch64.md (*add<mode>3_aarch64): Handle ADDSVL
4095         and ADDSPL.
4096         * config/aarch64/aarch64-sme.md (UNSPEC_SME_LDR): New unspec.
4097         (@aarch64_sme_<optab><mode>, @aarch64_sme_<optab><mode>_plus)
4098         (aarch64_sme_ldr0, @aarch64_sme_ldrn<mode>): New patterns.
4099         (UNSPEC_SME_STR): New unspec.
4100         (@aarch64_sme_<optab><mode>, @aarch64_sme_<optab><mode>_plus)
4101         (aarch64_sme_str0, @aarch64_sme_strn<mode>): New patterns.
4102         (@aarch64_sme_<optab><v_int_container><mode>): Likewise.
4103         (*aarch64_sme_<optab><v_int_container><mode>_plus): Likewise.
4104         (@aarch64_sme_<optab><VNx1TI_ONLY:mode><SVE_FULL:mode>): Likewise.
4105         (@aarch64_sme_<optab><v_int_container><mode>): Likewise.
4106         (*aarch64_sme_<optab><v_int_container><mode>_plus): Likewise.
4107         (@aarch64_sme_<optab><VNx1TI_ONLY:mode><SVE_FULL:mode>): Likewise.
4108         (UNSPEC_SME_ZERO): New unspec.
4109         (aarch64_sme_zero): New pattern.
4110         (@aarch64_sme_<SME_BINARY_SDI:optab><mode>): Likewise.
4111         (@aarch64_sme_<SME_INT_MOP:optab><mode>): Likewise.
4112         (@aarch64_sme_<SME_FP_MOP:optab><mode>): Likewise.
4113         * config/aarch64/aarch64-sve-builtins.def: Add ZA type suffixes.
4114         Include aarch64-sve-builtins-sme.def.
4115         (DEF_SME_ZA_FUNCTION): New macro.
4116         * config/aarch64/aarch64-sve-builtins.h (CP_READ_ZA): New call
4117         property.
4118         (CP_WRITE_ZA): Likewise.
4119         (PRED_za_m): New predication type.
4120         (type_suffix_index): Handle DEF_SME_ZA_SUFFIX.
4121         (type_suffix_info): Add vector_p and za_p fields.
4122         (function_instance::num_za_tiles): New member function.
4123         (function_builder::get_attributes): Add an aarch64_feature_flags
4124         argument.
4125         (function_expander::get_contiguous_base): Take a base argument
4126         number, a vnum argument number, and an argument that indicates
4127         whether the vnum parameter is a factor of the SME vector length
4128         or the prevailing vector length.
4129         (function_expander::add_integer_operand): Take a poly_int64.
4130         (sve_switcher::sve_switcher): Take a base set of flags.
4131         (sme_switcher): New class.
4132         (scalar_types): Add a null entry for NUM_VECTOR_TYPES.
4133         * config/aarch64/aarch64-sve-builtins.cc: Include
4134         aarch64-sve-builtins-sme.h.
4135         (pred_suffixes): Add an entry for PRED_za_m.
4136         (type_suffixes): Initialize vector_p and za_p.  Handle ZA suffixes.
4137         (TYPES_all_za, TYPES_d_za, TYPES_za_bhsd_data, TYPES_za_all_data)
4138         (TYPES_za_s_integer, TYPES_za_d_integer, TYPES_mop_base)
4139         (TYPES_mop_base_signed, TYPES_mop_base_unsigned, TYPES_mop_i16i64)
4140         (TYPES_mop_i16i64_signed, TYPES_mop_i16i64_unsigned, TYPES_za): New
4141         type suffix macros.
4142         (preds_m, preds_za_m): New predication lists.
4143         (function_groups): Handle DEF_SME_ZA_FUNCTION.
4144         (scalar_types): Add an entry for NUM_VECTOR_TYPES.
4145         (find_type_suffix_for_scalar_type): Check positively for vectors
4146         rather than negatively for predicates.
4147         (check_required_extensions): Handle PSTATE.SM and PSTATE.ZA
4148         requirements.
4149         (report_out_of_range): Handle the case where the minimum and
4150         maximum are the same.
4151         (function_instance::reads_global_state_p): Return true for functions
4152         that read ZA.
4153         (function_instance::modifies_global_state_p): Return true for functions
4154         that write to ZA.
4155         (sve_switcher::sve_switcher): Add a base flags argument.
4156         (function_builder::get_name): Handle "__arm_" prefixes.
4157         (add_attribute): Add an overload that takes a namespaces.
4158         (add_shared_state_attribute): New function.
4159         (function_builder::get_attributes): Take the required feature flags
4160         as argument.  Add streaming and ZA attributes where appropriate.
4161         (function_builder::add_unique_function): Update calls accordingly.
4162         (function_resolver::check_gp_argument): Assert that the predication
4163         isn't ZA _m predication.
4164         (function_checker::function_checker): Don't bias the argument
4165         number for ZA _m predication.
4166         (function_expander::get_contiguous_base): Add arguments that
4167         specify the base argument number, the vnum argument number,
4168         and an argument that indicates whether the vnum parameter is
4169         a factor of the SME vector length or the prevailing vector length.
4170         Handle the SME case.
4171         (function_expander::add_input_operand): Handle pmode_register_operand.
4172         (function_expander::add_integer_operand): Take a poly_int64.
4173         (init_builtins): Call handle_arm_sme_h for LTO.
4174         (handle_arm_sve_h): Skip SME intrinsics.
4175         (handle_arm_sme_h): New function.
4176         * config/aarch64/aarch64-sve-builtins-functions.h
4177         (read_write_za, write_za): New classes.
4178         (unspec_based_sme_function, za_arith_function): New using aliases.
4179         (quiet_za_arith_function): Likewise.
4180         * config/aarch64/aarch64-sve-builtins-shapes.h
4181         (binary_za_int_m, binary_za_m, binary_za_uint_m, bool_inherent)
4182         (inherent_za, inherent_mask_za, ldr_za, load_za, read_za_m, store_za)
4183         (str_za, unary_za_m, write_za_m): Declare.
4184         * config/aarch64/aarch64-sve-builtins-shapes.cc (apply_predication):
4185         Expect za_m functions to have an existing governing predicate.
4186         (binary_za_m_base, binary_za_int_m_def, binary_za_m_def): New classes.
4187         (binary_za_uint_m_def, bool_inherent_def, inherent_za_def): Likewise.
4188         (inherent_mask_za_def, ldr_za_def, load_za_def, read_za_m_def)
4189         (store_za_def, str_za_def, unary_za_m_def, write_za_m_def): Likewise.
4190         * config/aarch64/arm_sme.h: New file.
4191         * config/aarch64/aarch64-sve-builtins-sme.h: Likewise.
4192         * config/aarch64/aarch64-sve-builtins-sme.cc: Likewise.
4193         * config/aarch64/aarch64-sve-builtins-sme.def: Likewise.
4194         * config/aarch64/t-aarch64 (aarch64-sve-builtins.o): Depend on
4195         aarch64-sve-builtins-sme.def and aarch64-sve-builtins-sme.h.
4196         (aarch64-sve-builtins-sme.o): New rule.
4198 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4200         * config/aarch64/aarch64-sve-builtins.h
4201         (function_shape::has_merge_argument_p): New member function.
4202         * config/aarch64/aarch64-sve-builtins.cc:
4203         (function_resolver::check_gp_argument): Use it.
4204         (function_expander::get_fallback_value): Likewise.
4205         * config/aarch64/aarch64-sve-builtins-shapes.cc
4206         (apply_predication): Likewise.
4207         (unary_convert_narrowt_def::has_merge_argument_p): New function.
4209 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4211         * config/aarch64/aarch64-sve-builtins-functions.h
4212         (unspec_based_function_base): Allow type suffix 1 to determine
4213         the mode of the operation.
4214         (unspec_based_function): Update accordingly.
4215         (unspec_based_fused_function): Likewise.
4216         (unspec_based_fused_lane_function): Likewise.
4218 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4220         * config/aarch64/aarch64-modes.def: Add VNx1TI.
4222 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4224         * config/aarch64/aarch64.h (W12_W15_REGNUM_P): New macro.
4225         (W12_W15_REGS): New register class.
4226         (REG_CLASS_NAMES, REG_CLASS_CONTENTS): Add entries for it.
4227         * config/aarch64/aarch64.cc (aarch64_regno_regclass)
4228         (aarch64_class_max_nregs, aarch64_register_move_cost): Handle
4229         W12_W15_REGS.
4231 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4233         * config/aarch64/aarch64-isa-modes.def (ZA_ON): New ISA mode.
4234         * config/aarch64/aarch64-protos.h (aarch64_rdsvl_immediate_p)
4235         (aarch64_output_rdsvl, aarch64_optimize_mode_switching)
4236         (aarch64_restore_za): Declare.
4237         * config/aarch64/constraints.md (UsR): New constraint.
4238         * config/aarch64/aarch64.md (LOWERING_REGNUM, TPIDR_BLOCK_REGNUM)
4239         (SME_STATE_REGNUM, TPIDR2_SETUP_REGNUM, ZA_FREE_REGNUM)
4240         (ZA_SAVED_REGNUM, ZA_REGNUM, FIRST_FAKE_REGNUM): New constants.
4241         (LAST_FAKE_REGNUM): Likewise.
4242         (UNSPEC_SAVE_NZCV, UNSPEC_RESTORE_NZCV, UNSPEC_SME_VQ): New unspecs.
4243         (arches): Add sme.
4244         (arch_enabled): Handle it.
4245         (*cb<optab><mode>1): Rename to...
4246         (aarch64_cb<optab><mode>1): ...this.
4247         (*movsi_aarch64): Add an alternative for RDSVL.
4248         (*movdi_aarch64): Likewise.
4249         (aarch64_save_nzcv, aarch64_restore_nzcv): New insns.
4250         * config/aarch64/aarch64-sme.md (UNSPEC_SMSTOP_ZA)
4251         (UNSPEC_INITIAL_ZERO_ZA, UNSPEC_TPIDR2_SAVE, UNSPEC_TPIDR2_RESTORE)
4252         (UNSPEC_READ_TPIDR2, UNSPEC_WRITE_TPIDR2, UNSPEC_SETUP_LOCAL_TPIDR2)
4253         (UNSPEC_RESTORE_ZA, UNSPEC_START_PRIVATE_ZA_CALL): New unspecs.
4254         (UNSPEC_END_PRIVATE_ZA_CALL, UNSPEC_COMMIT_LAZY_SAVE): Likewise.
4255         (UNSPECV_ASM_UPDATE_ZA): New unspecv.
4256         (aarch64_tpidr2_save, aarch64_smstart_za, aarch64_smstop_za)
4257         (aarch64_initial_zero_za, aarch64_setup_local_tpidr2)
4258         (aarch64_clear_tpidr2, aarch64_write_tpidr2, aarch64_read_tpidr2)
4259         (aarch64_tpidr2_restore, aarch64_restore_za, aarch64_asm_update_za)
4260         (aarch64_start_private_za_call, aarch64_end_private_za_call)
4261         (aarch64_commit_lazy_save): New patterns.
4262         * config/aarch64/aarch64.h (AARCH64_ISA_ZA_ON, TARGET_ZA): New macros.
4263         (FIXED_REGISTERS, REGISTER_NAMES): Add the new fake ZA registers.
4264         (CALL_USED_REGISTERS): Replace with...
4265         (CALL_REALLY_USED_REGISTERS): ...this and add the fake ZA registers.
4266         (FIRST_PSEUDO_REGISTER): Bump to include the fake ZA registers.
4267         (FAKE_REGS): New register class.
4268         (REG_CLASS_NAMES): Update accordingly.
4269         (REG_CLASS_CONTENTS): Likewise.
4270         (machine_function::tpidr2_block): New member variable.
4271         (machine_function::tpidr2_block_ptr): Likewise.
4272         (machine_function::za_save_buffer): Likewise.
4273         (machine_function::next_asm_update_za_id): Likewise.
4274         (CUMULATIVE_ARGS::shared_za_flags): Likewise.
4275         (aarch64_mode_entity, aarch64_local_sme_state): New enums.
4276         (aarch64_tristate_mode): Likewise.
4277         (OPTIMIZE_MODE_SWITCHING, NUM_MODES_FOR_MODE_SWITCHING): Define.
4278         * config/aarch64/aarch64.cc (AARCH64_STATE_SHARED, AARCH64_STATE_IN)
4279         (AARCH64_STATE_OUT): New constants.
4280         (aarch64_attribute_shared_state_flags): New function.
4281         (aarch64_lookup_shared_state_flags, aarch64_fndecl_has_new_state)
4282         (aarch64_check_state_string, cmp_string_csts): Likewise.
4283         (aarch64_merge_string_arguments, aarch64_check_arm_new_against_type)
4284         (handle_arm_new, handle_arm_shared): Likewise.
4285         (handle_arm_new_za_attribute): New
4286         (aarch64_arm_attribute_table): Add new, preserves, in, out, and inout.
4287         (aarch64_hard_regno_nregs): Handle FAKE_REGS.
4288         (aarch64_hard_regno_mode_ok): Likewise.
4289         (aarch64_fntype_shared_flags, aarch64_fntype_pstate_za): New functions.
4290         (aarch64_fntype_isa_mode): Include aarch64_fntype_pstate_za.
4291         (aarch64_fndecl_has_state, aarch64_fndecl_pstate_za): New functions.
4292         (aarch64_fndecl_isa_mode): Include aarch64_fndecl_pstate_za.
4293         (aarch64_cfun_incoming_pstate_za, aarch64_cfun_shared_flags)
4294         (aarch64_cfun_has_new_state, aarch64_cfun_has_state): New functions.
4295         (aarch64_sme_vq_immediate, aarch64_sme_vq_unspec_p): Likewise.
4296         (aarch64_rdsvl_immediate_p, aarch64_output_rdsvl): Likewise.
4297         (aarch64_expand_mov_immediate): Handle RDSVL immediates.
4298         (aarch64_function_arg): Add the ZA sharing flags as a third limb
4299         of the PARALLEL.
4300         (aarch64_init_cumulative_args): Record the ZA sharing flags.
4301         (aarch64_extra_live_on_entry): New function.  Handle the new
4302         ZA-related fake registers.
4303         (aarch64_epilogue_uses): Handle the new ZA-related fake registers.
4304         (aarch64_cannot_force_const_mem): Handle UNSPEC_SME_VQ constants.
4305         (aarch64_get_tpidr2_block, aarch64_get_tpidr2_ptr): New functions.
4306         (aarch64_init_tpidr2_block, aarch64_restore_za): Likewise.
4307         (aarch64_layout_frame): Check whether the current function creates
4308         new ZA state.  Record that it clobbers LR if so.
4309         (aarch64_expand_prologue): Handle functions that create new ZA state.
4310         (aarch64_expand_epilogue): Likewise.
4311         (aarch64_create_tpidr2_block): New function.
4312         (aarch64_restore_za): Likewise.
4313         (aarch64_start_call_args): Disallow calls to shared-ZA functions
4314         from functions that have no ZA state.  Emit a marker instruction
4315         before calls to private-ZA functions from functions that have
4316         SME state.
4317         (aarch64_expand_call): Add return registers for state that is
4318         managed via attributes.  Record the use and clobber information
4319         for the ZA registers.
4320         (aarch64_end_call_args): New function.
4321         (aarch64_regno_regclass): Handle FAKE_REGS.
4322         (aarch64_class_max_nregs): Likewise.
4323         (aarch64_override_options_internal): Require TARGET_SME for
4324         functions that have ZA state.
4325         (aarch64_conditional_register_usage): Handle FAKE_REGS.
4326         (aarch64_mov_operand_p): Handle RDSVL immediates.
4327         (aarch64_comp_type_attributes): Check that the ZA sharing flags
4328         are equal.
4329         (aarch64_merge_decl_attributes): New function.
4330         (aarch64_optimize_mode_switching, aarch64_mode_emit_za_save_buffer)
4331         (aarch64_mode_emit_local_sme_state, aarch64_mode_emit):  Likewise.
4332         (aarch64_insn_references_sme_state_p): Likewise.
4333         (aarch64_mode_needed_local_sme_state): Likewise.
4334         (aarch64_mode_needed_za_save_buffer, aarch64_mode_needed): Likewise.
4335         (aarch64_mode_after_local_sme_state, aarch64_mode_after): Likewise.
4336         (aarch64_local_sme_confluence, aarch64_mode_confluence): Likewise.
4337         (aarch64_one_shot_backprop, aarch64_local_sme_backprop): Likewise.
4338         (aarch64_mode_backprop, aarch64_mode_entry): Likewise.
4339         (aarch64_mode_exit, aarch64_mode_eh_handler): Likewise.
4340         (aarch64_mode_priority, aarch64_md_asm_adjust): Likewise.
4341         (TARGET_END_CALL_ARGS, TARGET_MERGE_DECL_ATTRIBUTES): Define.
4342         (TARGET_MODE_EMIT, TARGET_MODE_NEEDED, TARGET_MODE_AFTER): Likewise.
4343         (TARGET_MODE_CONFLUENCE, TARGET_MODE_BACKPROP): Likewise.
4344         (TARGET_MODE_ENTRY, TARGET_MODE_EXIT): Likewise.
4345         (TARGET_MODE_EH_HANDLER, TARGET_MODE_PRIORITY): Likewise.
4346         (TARGET_EXTRA_LIVE_ON_ENTRY): Likewise.
4347         (TARGET_MD_ASM_ADJUST): Use aarch64_md_asm_adjust.
4348         * config/aarch64/aarch64-c.cc (aarch64_define_unconditional_macros):
4349         Define __arm_new, __arm_preserves,__arm_in, __arm_out, and __arm_inout.
4351 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4353         * config/aarch64/aarch64-passes.def
4354         (pass_late_thread_prologue_and_epilogue): New pass.
4355         * config/aarch64/aarch64-sme.md: New file.
4356         * config/aarch64/aarch64.md: Include it.
4357         (*tb<optab><mode>1): Rename to...
4358         (@aarch64_tb<optab><mode>): ...this.
4359         (call, call_value, sibcall, sibcall_value): Don't require operand 2
4360         to be a CONST_INT.
4361         * config/aarch64/aarch64-protos.h (aarch64_emit_call_insn): Return
4362         the insn.
4363         (make_pass_switch_sm_state): Declare.
4364         * config/aarch64/aarch64.h (TARGET_STREAMING_COMPATIBLE): New macro.
4365         (CALL_USED_REGISTER): Mark VG as call-preserved.
4366         (aarch64_frame::old_svcr_offset): New member variable.
4367         (machine_function::call_switches_sm_state): Likewise.
4368         (CUMULATIVE_ARGS::num_sme_mode_switch_args): Likewise.
4369         (CUMULATIVE_ARGS::sme_mode_switch_args): Likewise.
4370         * config/aarch64/aarch64.cc: Include tree-pass.h and cfgbuild.h.
4371         (aarch64_cfun_incoming_pstate_sm): New function.
4372         (aarch64_call_switches_pstate_sm): Likewise.
4373         (aarch64_reg_save_mode): Return DImode for VG_REGNUM.
4374         (aarch64_callee_isa_mode): New function.
4375         (aarch64_insn_callee_isa_mode): Likewise.
4376         (aarch64_guard_switch_pstate_sm): Likewise.
4377         (aarch64_switch_pstate_sm): Likewise.
4378         (aarch64_sme_mode_switch_regs): New class.
4379         (aarch64_record_sme_mode_switch_args): New function.
4380         (aarch64_finish_sme_mode_switch_args): Likewise.
4381         (aarch64_function_arg): Handle the end marker by returning a
4382         PARALLEL that contains the ABI cookie that we used previously
4383         alongside the result of aarch64_finish_sme_mode_switch_args.
4384         (aarch64_init_cumulative_args): Initialize num_sme_mode_switch_args.
4385         (aarch64_function_arg_advance): If a call would switch SM state,
4386         record all argument registers that would need to be saved around
4387         the mode switch.
4388         (aarch64_need_old_pstate_sm): New function.
4389         (aarch64_layout_frame): Decide whether the frame needs to store the
4390         incoming value of PSTATE.SM and allocate a save slot for it if so.
4391         If a function switches SME state, arrange to save the old value
4392         of the DWARF VG register.  Handle the case where this is the only
4393         register save slot above the FP.
4394         (aarch64_save_callee_saves): Handles saves of the DWARF VG register.
4395         (aarch64_get_separate_components): Prevent such saves from being
4396         shrink-wrapped.
4397         (aarch64_old_svcr_mem): New function.
4398         (aarch64_read_old_svcr): Likewise.
4399         (aarch64_guard_switch_pstate_sm): Likewise.
4400         (aarch64_expand_prologue): Handle saves of the DWARF VG register.
4401         Initialize any SVCR save slot.
4402         (aarch64_expand_call): Allow the cookie to be PARALLEL that contains
4403         both the UNSPEC_CALLEE_ABI value and a list of registers that need
4404         to be preserved across a change to PSTATE.SM.  If the call does
4405         involve such a change to PSTATE.SM, record the registers that
4406         would be clobbered by this process.  Also emit an instruction
4407         to mark the temporary change in VG.  Update call_switches_pstate_sm.
4408         (aarch64_emit_call_insn): Return the emitted instruction.
4409         (aarch64_frame_pointer_required): New function.
4410         (aarch64_conditional_register_usage): Prevent VG_REGNUM from being
4411         treated as a register operand.
4412         (aarch64_switch_pstate_sm_for_call): New function.
4413         (pass_data_switch_pstate_sm): New pass variable.
4414         (pass_switch_pstate_sm): New pass class.
4415         (make_pass_switch_pstate_sm): New function.
4416         (TARGET_FRAME_POINTER_REQUIRED): Define.
4417         * config/aarch64/t-aarch64 (s-check-sve-md): Add aarch64-sme.md.
4419 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4421         * config/aarch64/aarch64.h (TARGET_NON_STREAMING): New macro.
4422         (TARGET_SVE2_AES, TARGET_SVE2_BITPERM): Use it.
4423         (TARGET_SVE2_SHA3, TARGET_SVE2_SM4): Likewise.
4424         * config/aarch64/aarch64-sve-builtins-base.def: Separate out
4425         the functions that require PSTATE.SM to be 0 and guard them
4426         with AARCH64_FL_SM_OFF.
4427         * config/aarch64/aarch64-sve-builtins-sve2.def: Likewise.
4428         * config/aarch64/aarch64-sve-builtins.cc (check_required_extensions):
4429         Enforce AARCH64_FL_SM_OFF requirements.
4430         * config/aarch64/aarch64-sve.md (aarch64_wrffr): Require
4431         TARGET_NON_STREAMING
4432         (aarch64_rdffr, aarch64_rdffr_z, *aarch64_rdffr_z_ptest): Likewise.
4433         (*aarch64_rdffr_ptest, *aarch64_rdffr_z_cc, *aarch64_rdffr_cc)
4434         (@aarch64_ld<fn>f1<mode>): Likewise.
4435         (@aarch64_ld<fn>f1_<ANY_EXTEND:optab><SVE_HSDI:mode><SVE_PARTIAL_I:mode>)
4436         (gather_load<mode><v_int_container>): Likewise
4437         (mask_gather_load<mode><v_int_container>): Likewise.
4438         (mask_gather_load<mode><v_int_container>): Likewise.
4439         (*mask_gather_load<mode><v_int_container>_<su>xtw_unpacked): Likewise.
4440         (*mask_gather_load<mode><v_int_container>_sxtw): Likewise.
4441         (*mask_gather_load<mode><v_int_container>_uxtw): Likewise.
4442         (@aarch64_gather_load_<ANY_EXTEND:optab><SVE_4HSI:mode><SVE_4BHI:mode>)
4443         (@aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
4444         <SVE_2BHSI:mode>): Likewise.
4445         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
4446         <SVE_2BHSI:mode>_<ANY_EXTEND2:su>xtw_unpacked)
4447         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
4448         <SVE_2BHSI:mode>_sxtw): Likewise.
4449         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
4450         <SVE_2BHSI:mode>_uxtw): Likewise.
4451         (@aarch64_ldff1_gather<mode>, @aarch64_ldff1_gather<mode>): Likewise.
4452         (*aarch64_ldff1_gather<mode>_sxtw): Likewise.
4453         (*aarch64_ldff1_gather<mode>_uxtw): Likewise.
4454         (@aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx4_WIDE:mode>
4455         <VNx4_NARROW:mode>): Likewise.
4456         (@aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
4457         <VNx2_NARROW:mode>): Likewise.
4458         (*aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
4459         <VNx2_NARROW:mode>_sxtw): Likewise.
4460         (*aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
4461         <VNx2_NARROW:mode>_uxtw): Likewise.
4462         (@aarch64_sve_gather_prefetch<SVE_FULL_I:mode><VNx4SI_ONLY:mode>)
4463         (@aarch64_sve_gather_prefetch<SVE_FULL_I:mode><VNx2DI_ONLY:mode>)
4464         (*aarch64_sve_gather_prefetch<SVE_FULL_I:mode><VNx2DI_ONLY:mode>_sxtw)
4465         (*aarch64_sve_gather_prefetch<SVE_FULL_I:mode><VNx2DI_ONLY:mode>_uxtw)
4466         (scatter_store<mode><v_int_container>): Likewise.
4467         (mask_scatter_store<mode><v_int_container>): Likewise.
4468         (*mask_scatter_store<mode><v_int_container>_<su>xtw_unpacked)
4469         (*mask_scatter_store<mode><v_int_container>_sxtw): Likewise.
4470         (*mask_scatter_store<mode><v_int_container>_uxtw): Likewise.
4471         (@aarch64_scatter_store_trunc<VNx4_NARROW:mode><VNx4_WIDE:mode>)
4472         (@aarch64_scatter_store_trunc<VNx2_NARROW:mode><VNx2_WIDE:mode>)
4473         (*aarch64_scatter_store_trunc<VNx2_NARROW:mode><VNx2_WIDE:mode>_sxtw)
4474         (*aarch64_scatter_store_trunc<VNx2_NARROW:mode><VNx2_WIDE:mode>_uxtw)
4475         (@aarch64_sve_ld1ro<mode>, @aarch64_adr<mode>): Likewise.
4476         (*aarch64_adr_sxtw, *aarch64_adr_uxtw_unspec): Likewise.
4477         (*aarch64_adr_uxtw_and, @aarch64_adr<mode>_shift): Likewise.
4478         (*aarch64_adr<mode>_shift, *aarch64_adr_shift_sxtw): Likewise.
4479         (*aarch64_adr_shift_uxtw, @aarch64_sve_add_<optab><vsi2qi>): Likewise.
4480         (@aarch64_sve_<sve_fp_op><mode>, fold_left_plus_<mode>): Likewise.
4481         (mask_fold_left_plus_<mode>, @aarch64_sve_compact<mode>): Likewise.
4482         * config/aarch64/aarch64-sve2.md (@aarch64_gather_ldnt<mode>)
4483         (@aarch64_gather_ldnt_<ANY_EXTEND:optab><SVE_FULL_SDI:mode>
4484         <SVE_PARTIAL_I:mode>): Likewise.
4485         (@aarch64_sve2_histcnt<mode>, @aarch64_sve2_histseg<mode>): Likewise.
4486         (@aarch64_pred_<SVE2_MATCH:sve_int_op><mode>): Likewise.
4487         (*aarch64_pred_<SVE2_MATCH:sve_int_op><mode>_cc): Likewise.
4488         (*aarch64_pred_<SVE2_MATCH:sve_int_op><mode>_ptest): Likewise.
4489         * config/aarch64/iterators.md (SVE_FP_UNARY_INT): Make FEXPA
4490         depend on TARGET_NON_STREAMING.
4491         (SVE_BFLOAT_TERNARY_LONG): Likewise BFMMLA.
4493 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4495         * config/aarch64/aarch64.h (TARGET_BASE_SIMD): New macro.
4496         (TARGET_SIMD): Require PSTATE.SM to be 0.
4497         (AARCH64_ISA_SM_OFF): New macro.
4498         * config/aarch64/aarch64.cc (aarch64_array_mode_supported_p):
4499         Allow Advanced SIMD structure modes for TARGET_BASE_SIMD.
4500         (aarch64_print_operand): Support '%Z'.
4501         (aarch64_secondary_reload): Expect SVE moves to be used for
4502         Advanced SIMD modes if SVE is enabled and non-streaming
4503         Advanced SIMD isn't.
4504         (aarch64_register_move_cost): Likewise.
4505         (aarch64_simd_container_mode): Extend Advanced SIMD mode
4506         handling to TARGET_BASE_SIMD.
4507         (aarch64_expand_cpymem): Expand commentary.
4508         * config/aarch64/aarch64.md (arches): Add base_simd and nobase_simd.
4509         (arch_enabled): Handle it.
4510         (*mov<mode>_aarch64): Extend UMOV alternative to TARGET_BASE_SIMD.
4511         (*movti_aarch64): Use an SVE move instruction if non-streaming
4512         SIMD isn't available.
4513         (*mov<TFD:mode>_aarch64): Likewise.
4514         (load_pair_dw_tftf): Extend to TARGET_BASE_SIMD.
4515         (store_pair_dw_tftf): Likewise.
4516         (loadwb_pair<TX:mode>_<P:mode>): Likewise.
4517         (storewb_pair<TX:mode>_<P:mode>): Likewise.
4518         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<VDMOV:mode>):
4519         Allow UMOV in streaming mode.
4520         (*aarch64_simd_mov<VQMOV:mode>): Use an SVE move instruction
4521         if non-streaming SIMD isn't available.
4522         (aarch64_store_lane0<mode>): Depend on TARGET_FLOAT rather than
4523         TARGET_SIMD.
4524         (aarch64_simd_mov_from_<mode>low): Likewise.  Use fmov if
4525         Advanced SIMD is completely disabled.
4526         (aarch64_simd_mov_from_<mode>high): Use SVE EXT instructions if
4527         non-streaming SIMD isn't available.
4529 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4531         * doc/invoke.texi: Document SME.
4532         * doc/sourcebuild.texi: Document aarch64_sve.
4533         * config/aarch64/aarch64-option-extensions.def (sme): Define.
4534         * config/aarch64/aarch64.h (AARCH64_ISA_SME): New macro.
4535         (TARGET_SME): Likewise.
4536         * config/aarch64/aarch64.cc (aarch64_override_options_internal):
4537         Ensure that SME is present when compiling streaming code.
4539 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4541         * config/aarch64/aarch64-isa-modes.def: New file.
4542         * config/aarch64/aarch64.h: Include it in the feature enumerations.
4543         (AARCH64_FL_SM_STATE, AARCH64_FL_ISA_MODES): New constants.
4544         (AARCH64_FL_DEFAULT_ISA_MODE): Likewise.
4545         (AARCH64_ISA_MODE): New macro.
4546         (CUMULATIVE_ARGS): Add an isa_mode field.
4547         * config/aarch64/aarch64-protos.h (aarch64_gen_callee_cookie): Declare.
4548         (aarch64_tlsdesc_abi_id): Return an arm_pcs.
4549         * config/aarch64/aarch64.cc (attr_streaming_exclusions)
4550         (aarch64_gnu_attributes, aarch64_gnu_attribute_table)
4551         (aarch64_arm_attributes, aarch64_arm_attribute_table): New tables.
4552         (aarch64_attribute_table): Redefine to include the gnu and arm
4553         attributes.
4554         (aarch64_fntype_pstate_sm, aarch64_fntype_isa_mode): New functions.
4555         (aarch64_fndecl_pstate_sm, aarch64_fndecl_isa_mode): Likewise.
4556         (aarch64_gen_callee_cookie, aarch64_callee_abi): Likewise.
4557         (aarch64_insn_callee_cookie, aarch64_insn_callee_abi): Use them.
4558         (aarch64_function_arg, aarch64_output_mi_thunk): Likewise.
4559         (aarch64_init_cumulative_args): Initialize the isa_mode field.
4560         (aarch64_output_mi_thunk): Use aarch64_gen_callee_cookie to get
4561         the ABI cookie.
4562         (aarch64_override_options): Add the ISA mode to the feature set.
4563         (aarch64_temporary_target::copy_from_fndecl): Likewise.
4564         (aarch64_fndecl_options, aarch64_handle_attr_arch): Likewise.
4565         (aarch64_set_current_function): Maintain the correct ISA mode.
4566         (aarch64_tlsdesc_abi_id): Return an arm_pcs.
4567         (aarch64_comp_type_attributes): Handle arm::streaming and
4568         arm::streaming_compatible.
4569         * config/aarch64/aarch64-c.cc (aarch64_define_unconditional_macros):
4570         Define __arm_streaming and __arm_streaming_compatible.
4571         * config/aarch64/aarch64.md (tlsdesc_small_<mode>): Use
4572         aarch64_gen_callee_cookie to get the ABI cookie.
4573         * config/aarch64/t-aarch64 (TM_H): Add all feature-related .def files.
4575 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4577         * config/aarch64/aarch64-sve-builtins-base.cc
4578         (svreinterpret_impl::fold): Punt on tuple forms.
4579         (svreinterpret_impl::expand): Use tuple_mode instead of vector_mode.
4580         * config/aarch64/aarch64-sve-builtins-base.def (svreinterpret):
4581         Extend to x1234 groups.
4582         * config/aarch64/aarch64-sve-builtins-functions.h
4583         (multi_vector_function::vectors_per_tuple): If the function has
4584         a group suffix, get the number of vectors from there.
4585         * config/aarch64/aarch64-sve-builtins-shapes.h (reinterpret): Declare.
4586         * config/aarch64/aarch64-sve-builtins-shapes.cc (reinterpret_def)
4587         (reinterpret): New function shape.
4588         * config/aarch64/aarch64-sve-builtins.cc (function_groups): Handle
4589         DEF_SVE_FUNCTION_GS.
4590         * config/aarch64/aarch64-sve-builtins.def (DEF_SVE_FUNCTION_GS): New
4591         macro.
4592         (DEF_SVE_FUNCTION): Forward to DEF_SVE_FUNCTION_GS by default.
4593         * config/aarch64/aarch64-sve-builtins.h
4594         (function_instance::tuple_mode): New member function.
4595         (function_base::vectors_per_tuple): Take the function instance
4596         as argument and get the number from the group suffix.
4597         (function_instance::vectors_per_tuple): Update accordingly.
4598         * config/aarch64/iterators.md (SVE_FULLx2, SVE_FULLx3, SVE_FULLx4)
4599         (SVE_ALL_STRUCT): New mode iterators.
4600         (SVE_STRUCT): Redefine in terms of SVE_FULL*.
4601         * config/aarch64/aarch64-sve.md (@aarch64_sve_reinterpret<mode>)
4602         (*aarch64_sve_reinterpret<mode>): Extend to SVE structure modes.
4604 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4606         * config/aarch64/aarch64-sve-builtins.cc
4607         (function_resolver::require_derived_vector_type): Add a specific
4608         error message for the case in which the caller wants a single
4609         vector whose element type matches a previous tuyple argument.
4611 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4613         * config/aarch64/aarch64-sve-builtins.h
4614         (function_resolver::lookup_form): Add an overload that takes
4615         an sve_type rather than type and group suffixes.
4616         (function_resolver::resolve_to): Likewise.
4617         (function_resolver::infer_vector_or_tuple_type): Return an sve_type.
4618         (function_resolver::infer_tuple_type): Likewise.
4619         (function_resolver::require_matching_vector_type): Take an sve_type
4620         rather than a type_suffix_index.
4621         (function_resolver::require_derived_vector_type): Likewise.
4622         * config/aarch64/aarch64-sve-builtins.cc (num_vectors_to_group):
4623         New function.
4624         (function_resolver::lookup_form): Add an overload that takes
4625         an sve_type rather than type and group suffixes.
4626         (function_resolver::resolve_to): Likewise.
4627         (function_resolver::infer_vector_or_tuple_type): Return an sve_type.
4628         (function_resolver::infer_tuple_type): Likewise.
4629         (function_resolver::infer_vector_type): Update accordingly.
4630         (function_resolver::require_matching_vector_type): Take an sve_type
4631         rather than a type_suffix_index.
4632         (function_resolver::require_derived_vector_type): Likewise.
4633         * config/aarch64/aarch64-sve-builtins-shapes.cc (get_def::resolve)
4634         (set_def::resolve, store_def::resolve, tbl_tuple_def::resolve): Update
4635         calls accordingly.
4637 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4639         * config/aarch64/aarch64-sve-builtins.h
4640         (function_resolver::require_matching_vector_type): Add a parameter
4641         that specifies the number of the earlier argument that is being
4642         matched against.
4643         * config/aarch64/aarch64-sve-builtins.cc
4644         (function_resolver::require_matching_vector_type): Likewise.
4645         (require_derived_vector_type): Update calls accordingly.
4646         (function_resolver::resolve_unary): Likewise.
4647         (function_resolver::resolve_uniform): Likewise.
4648         (function_resolver::resolve_uniform_opt_n): Likewise.
4649         * config/aarch64/aarch64-sve-builtins-shapes.cc
4650         (binary_long_lane_def::resolve): Likewise.
4651         (clast_def::resolve, ternary_uint_def::resolve): Likewise.
4653 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4655         * config/aarch64/aarch64-sve-builtins.h
4656         (function_resolver::infer_sve_type): New member function.
4657         (function_resolver::report_incorrect_num_vectors): Likewise.
4658         * config/aarch64/aarch64-sve-builtins.cc
4659         (function_resolver::infer_sve_type): New function,.
4660         (function_resolver::report_incorrect_num_vectors): New function,
4661         split out from...
4662         (function_resolver::infer_vector_or_tuple_type): ...here.  Use
4663         infer_sve_type.
4665 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4667         * config/aarch64/aarch64-sve-builtins.h (sve_type): New struct.
4668         (sve_type::operator==): New function.
4669         (function_resolver::get_vector_type): Delete.
4670         (function_resolver::report_no_such_form): Take an sve_type rather
4671         than a type_suffix_index.
4672         * config/aarch64/aarch64-sve-builtins.cc (get_vector_type): New
4673         function.
4674         (function_resolver::get_vector_type): Delete.
4675         (function_resolver::report_no_such_form): Take an sve_type rather
4676         than a type_suffix_index.
4677         (find_sve_type): New function, split out from...
4678         (function_resolver::infer_vector_or_tuple_type): ...here.
4680 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4682         * config/aarch64/aarch64-sve-builtins-shapes.cc (build_one): Take
4683         a group suffix index parameter.
4684         (build_32_64, build_all): Update accordingly.  Iterate over all
4685         group suffixes.
4686         * config/aarch64/aarch64-sve-builtins-sve2.cc (svqrshl_impl::fold)
4687         (svqshl_impl::fold, svrshl_impl::fold): Update function_instance
4688         constructors.
4689         * config/aarch64/aarch64-sve-builtins.cc (group_suffixes): New array.
4690         (groups_none): New constant.
4691         (function_groups): Initialize the groups field.
4692         (function_instance::hash): Hash the group index.
4693         (function_builder::get_name): Add the group suffix.
4694         (function_builder::add_overloaded_functions): Iterate over all
4695         group suffixes.
4696         (function_resolver::lookup_form): Take a group suffix parameter.
4697         (function_resolver::resolve_to): Likewise.
4698         * config/aarch64/aarch64-sve-builtins.def (DEF_SVE_GROUP_SUFFIX): New
4699         macro.
4700         (x2, x3, x4): New group suffixes.
4701         * config/aarch64/aarch64-sve-builtins.h (group_suffix_index): New enum.
4702         (group_suffix_info): New structure.
4703         (function_group_info::groups): New member variable.
4704         (function_instance::group_suffix_id): Likewise.
4705         (group_suffixes): New array.
4706         (function_instance::operator==): Compare the group suffixes.
4707         (function_instance::group_suffix): New function.
4709 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4711         * config/aarch64/aarch64-sve-builtins.cc (function_groups): Remove
4712         implied requirement on SVE.
4713         * config/aarch64/aarch64-sve-builtins-base.def: Explicitly require SVE.
4714         * config/aarch64/aarch64-sve-builtins-sve2.def: Likewise.
4716 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4718         * config/aarch64/aarch64-protos.h (aarch64_sve_rdvl_immediate_p)
4719         (aarch64_output_sve_rdvl): Declare.
4720         * config/aarch64/aarch64.cc (aarch64_sve_cnt_factor_p): New
4721         function, split out from...
4722         (aarch64_sve_cnt_immediate_p): ...here.
4723         (aarch64_sve_rdvl_factor_p): New function.
4724         (aarch64_sve_rdvl_immediate_p): Likewise.
4725         (aarch64_output_sve_rdvl): Likewise.
4726         (aarch64_offset_temporaries): Rewrite the SVE handling to use RDVL
4727         for some cases.
4728         (aarch64_expand_mov_immediate): Handle RDVL immediates.
4729         (aarch64_mov_operand_p): Likewise.
4730         * config/aarch64/constraints.md (Usr): New constraint.
4731         * config/aarch64/aarch64.md (*mov<SHORT:mode>_aarch64): Add an RDVL
4732         alternative.
4733         (*movsi_aarch64, *movdi_aarch64): Likewise.
4735 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4737         * config/aarch64/aarch64-sve-builtins.h:
4738         (function_checker::require_immediate_lane_index): Add an argument
4739         for the index of the indexed vector argument.
4740         * config/aarch64/aarch64-sve-builtins.cc
4741         (function_checker::require_immediate_lane_index): Likewise.
4742         * config/aarch64/aarch64-sve-builtins-shapes.cc
4743         (ternary_bfloat_lane_base::check): Update accordingly.
4744         (ternary_qq_lane_base::check): Likewise.
4745         (binary_lane_def::check): Likewise.
4746         (binary_long_lane_def::check): Likewise.
4747         (ternary_lane_def::check): Likewise.
4748         (ternary_lane_rotate_def::check): Likewise.
4749         (ternary_long_lane_def::check): Likewise.
4750         (ternary_qq_lane_rotate_def::check): Likewise.
4752 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4754         * target.def (md_asm_adjust): Add a uses parameter.
4755         * doc/tm.texi: Regenerate.
4756         * cfgexpand.cc (expand_asm_loc): Update call to md_asm_adjust.
4757         Handle any USEs created by the target.
4758         (expand_asm_stmt): Likewise.
4759         * recog.cc (asm_noperands): Handle asms with USEs.
4760         (decode_asm_operands): Likewise.
4761         * config/arm/aarch-common-protos.h (arm_md_asm_adjust): Add uses
4762         parameter.
4763         * config/arm/aarch-common.cc (arm_md_asm_adjust): Likewise.
4764         * config/arm/arm.cc (thumb1_md_asm_adjust): Likewise.
4765         * config/avr/avr.cc (avr_md_asm_adjust): Likewise.
4766         * config/cris/cris.cc (cris_md_asm_adjust): Likewise.
4767         * config/i386/i386.cc (ix86_md_asm_adjust): Likewise.
4768         * config/mn10300/mn10300.cc (mn10300_md_asm_adjust): Likewise.
4769         * config/nds32/nds32.cc (nds32_md_asm_adjust): Likewise.
4770         * config/pdp11/pdp11.cc (pdp11_md_asm_adjust): Likewise.
4771         * config/rs6000/rs6000.cc (rs6000_md_asm_adjust): Likewise.
4772         * config/s390/s390.cc (s390_md_asm_adjust): Likewise.
4773         * config/vax/vax.cc (vax_md_asm_adjust): Likewise.
4774         * config/visium/visium.cc (visium_md_asm_adjust): Likewise.
4776 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4778         * doc/tm.texi.in: Add TARGET_START_CALL_ARGS.
4779         * doc/tm.texi: Regenerate.
4780         * target.def (start_call_args): New hook.
4781         (call_args, end_call_args): Add a parameter for the cumulative
4782         argument information.
4783         * hooks.h (hook_void_rtx_tree): Delete.
4784         * hooks.cc (hook_void_rtx_tree): Likewise.
4785         * targhooks.h (hook_void_CUMULATIVE_ARGS): Declare.
4786         (hook_void_CUMULATIVE_ARGS_rtx_tree): Likewise.
4787         * targhooks.cc (hook_void_CUMULATIVE_ARGS): New function.
4788         (hook_void_CUMULATIVE_ARGS_rtx_tree): Likewise.
4789         * calls.cc (expand_call): Call start_call_args before computing
4790         and storing stack parameters.  Pass the cumulative argument
4791         information to call_args and end_call_args.
4792         (emit_library_call_value_1): Likewise.
4793         * config/nvptx/nvptx.cc (nvptx_call_args): Add a cumulative
4794         argument parameter.
4795         (nvptx_end_call_args): Likewise.
4797 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4799         * doc/tm.texi.in: Add TARGET_EMIT_EPILOGUE_FOR_SIBCALL.
4800         * doc/tm.texi: Regenerate.
4801         * target.def (emit_epilogue_for_sibcall): New hook.
4802         * calls.cc (can_implement_as_sibling_call_p): Use it.
4803         * function.cc (thread_prologue_and_epilogue_insns): Likewise.
4804         (reposition_prologue_and_epilogue_notes): Likewise.
4805         * config/aarch64/aarch64-protos.h (aarch64_expand_epilogue): Take
4806         an rtx_call_insn * rather than a bool.
4807         * config/aarch64/aarch64.cc (aarch64_expand_epilogue): Likewise.
4808         (TARGET_EMIT_EPILOGUE_FOR_SIBCALL): Define.
4809         * config/aarch64/aarch64.md (epilogue): Update call.
4810         (sibcall_epilogue): Delete.
4812 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4814         * target.def (use_late_prologue_epilogue): New hook.
4815         * doc/tm.texi.in: Add TARGET_USE_LATE_PROLOGUE_EPILOGUE.
4816         * doc/tm.texi: Regenerate.
4817         * passes.def (pass_late_thread_prologue_and_epilogue): New pass.
4818         * tree-pass.h (make_pass_late_thread_prologue_and_epilogue): Declare.
4819         * function.cc (pass_thread_prologue_and_epilogue::gate): New function.
4820         (pass_data_late_thread_prologue_and_epilogue): New pass variable.
4821         (pass_late_thread_prologue_and_epilogue): New pass class.
4822         (make_pass_late_thread_prologue_and_epilogue): New function.
4824 2023-12-05  Kito Cheng  <kito.cheng@sifive.com>
4826         * common/config/riscv/riscv-common.cc
4827         (riscv_subset_list::check_conflict_ext): Check zcd conflicts
4828         with zcmt and zcmp.
4830 2023-12-05  Richard Sandiford  <richard.sandiford@arm.com>
4832         PR rtl-optimization/112278
4833         * lra-int.h (lra_update_biggest_mode): New function.
4834         * lra-coalesce.cc (merge_pseudos): Use it.
4835         * lra-lives.cc (process_bb_lives): Likewise.
4836         * lra.cc (new_insn_reg): Likewise.
4838 2023-12-05  Jakub Jelinek  <jakub@redhat.com>
4840         PR tree-optimization/112843
4841         * gimple-lower-bitint.cc (gimple_lower_bitint): Change lhs of stmt
4842         to lhs2 before building and inserting lhs = (cast) lhs2; assignment.
4843         Adjust stmt operands before adjusting lhs.
4845 2023-12-05  xuli  <xuli1@eswincomputing.com>
4847         * config/riscv/riscv-v.cc (sew64_scalar_helper): Bugfix.
4849 2023-12-05  Jakub Jelinek  <jakub@redhat.com>
4851         PR target/112816
4852         * config/i386/sse.md ((eq (eq (lshiftrt x elt_bits-1) 0) 0)): New
4853         splitter to turn psrld $31; pcmpeq; pcmpeq into psrad $31.
4855 2023-12-05  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
4857         * config/riscv/autovec.md: Add blocker.
4858         * config/riscv/riscv-protos.h (gather_scatter_valid_offset_p): New function.
4859         * config/riscv/riscv-v.cc (gather_scatter_valid_offset_p): Ditto.
4861 2023-12-05  Richard Biener  <rguenther@suse.de>
4863         PR tree-optimization/112827
4864         PR tree-optimization/112848
4865         * tree-scalar-evolution.cc (final_value_replacement_loop):
4866         Compute the insert location for each insert.
4868 2023-12-05  liuhongt  <hongtao.liu@intel.com>
4870         * config/i386/i386.cc (ix86_vector_costs::add_stmt_cost):
4871         Count sse_reg/gpr_regs for components not loaded from memory.
4872         (ix86_vector_costs:ix86_vector_costs): New constructor.
4873         (ix86_vector_costs::m_num_gpr_needed[3]): New private memeber.
4874         (ix86_vector_costs::m_num_sse_needed[3]): Ditto.
4875         (ix86_vector_costs::finish_cost): Estimate overall register
4876         pressure cost.
4877         (ix86_vector_costs::ix86_vect_estimate_reg_pressure): New
4878         function.
4880 2023-12-05  liuhongt  <hongtao.liu@intel.com>
4882         * config/i386/sse.md (udot_prodv64qi): New expander.
4883         (udot_prod<mode>): Emulates with VEC_UNPACKU_EXPR +
4884         DOT_PROD (short, int).
4886 2023-12-05  Marek Polacek  <polacek@redhat.com>
4888         PR c++/107687
4889         PR c++/110997
4890         * doc/invoke.texi: Document -fno-immediate-escalation.
4892 2023-12-04  Andrew Pinski  <quic_apinski@quicinc.com>
4894         * match.pd (zero_one_valued_p): For convert
4895         make sure type is not a signed 1-bit integer.
4897 2023-12-04  Jeff Law  <jlaw@ventanamicro.com>
4899         * config/microblaze/microblaze.md (movhi): Use %i for half-word
4900         loads to properly select between lhu/lhui.
4902 2023-12-04  Robin Dapp  <rdapp@ventanamicro.com>
4904         * config/riscv/riscv-string.cc (expand_rawmemchr): Increment
4905         source address by vl * element_size.
4907 2023-12-04  Robin Dapp  <rdapp@ventanamicro.com>
4909         * config/riscv/riscv-opts.h (enum riscv_stringop_strategy_enum):
4910         Rename...
4911         (enum stringop_strategy_enum): ... to this.
4912         * config/riscv/riscv-string.cc (riscv_expand_block_move): New
4913         wrapper expander handling the strategies and delegation.
4914         (riscv_expand_block_move_scalar): Rename function and make
4915         static.
4916         (expand_block_move): Remove strategy handling.
4917         * config/riscv/riscv.md: Call expander wrapper.
4918         * config/riscv/riscv.opt: Rename.
4920 2023-12-04  Richard Biener  <rguenther@suse.de>
4922         PR middle-end/112785
4923         * function.h (get_new_clique): New inline function handling
4924         last_clique overflow.
4925         * cfgrtl.cc (duplicate_insn_chain): Use it.
4926         * tree-cfg.cc (gimple_duplicate_bb): Likewise.
4927         * tree-inline.cc (remap_dependence_clique): Likewise.
4929 2023-12-04  Christoph Müllner  <christoph.muellner@vrull.eu>
4931         PR target/112650
4932         * doc/invoke.texi: Document riscv-strcmp-inline-limit.
4934 2023-12-04  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
4936         PR target/112431
4937         * config/riscv/vector.md: Fix incorrect overlap in v0.
4939 2023-12-04  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
4941         PR target/112431
4942         * config/riscv/vector.md: Add highest-number overlap support.
4944 2023-12-04  Richard Biener  <rguenther@suse.de>
4946         PR tree-optimization/112818
4947         * tree-vect-stmts.cc (vectorizable_bswap): Check input and
4948         output vector types have the same size.
4950 2023-12-04  Richard Biener  <rguenther@suse.de>
4952         PR tree-optimization/112827
4953         * tree-scalar-evolution.cc (final_value_replacement_loop):
4954         Do not release SSA name but keep a dead initialization around.
4956 2023-12-04  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
4958         PR target/112431
4959         * config/riscv/vector.md: Remove earlyclobber from widen reduction.
4961 2023-12-04  Indu Bhagat  <indu.bhagat@oracle.com>
4963         PR debug/112656
4964         * btfout.cc (btf_asm_type): Fixup ctti_name for all
4965         BTF types of kind BTF_KIND_FUNC_PROTO.
4967 2023-12-04  Indu Bhagat  <indu.bhagat@oracle.com>
4969         PR debug/112768
4970         * btfout.cc (get_btf_type_name): New definition.
4971         (btf_collect_datasec): Update dtd_name to the original type name
4972         string.
4973         (btf_asm_type_ref): Use the new get_btf_type_name function
4974         instead.
4975         (btf_asm_type): Likewise.
4976         (btf_asm_func_type): Likewise.
4978 2023-12-04  Jakub Jelinek  <jakub@redhat.com>
4980         PR target/112837
4981         * config/i386/i386.cc (ix86_elim_entry_set_got): Before checking
4982         for UNSPEC_SET_GOT check that SET_SRC is UNSPEC.  Use SET_SRC and
4983         SET_DEST macros instead of XEXP, rename vec variable to set.
4985 2023-12-04  Jakub Jelinek  <jakub@redhat.com>
4987         PR target/112816
4988         * config/i386/sse.md (signbit<mode>2): Force operands[1] into a REG.
4990 2023-12-04  Feng Wang  <wangfeng@eswincomputing.com>
4992         * common/config/riscv/riscv-common.cc: Add zvkb ISA info.
4993         * config/riscv/riscv.opt: Add Mask(ZVKB)
4995 2023-12-04  Fei Gao  <gaofei@eswincomputing.com>
4996             Xiao Zeng <zengxiao@eswincomputing.com>
4998         * config/riscv/riscv.md (*mov<GPR:mode><X:mode>cc):move to sfb.md
4999         * config/riscv/sfb.md: New file.
5001 2023-12-04  Kito Cheng  <kito.cheng@sifive.com>
5003         * config/riscv/riscv-cores.def: Add sifive-x280.
5004         * doc/invoke.texi (RISC-V Options): Add sifive-x280
5006 2023-12-04  Kito Cheng  <kito.cheng@sifive.com>
5008         * common/config/riscv/riscv-common.cc (riscv_implied_predicator_t): New.
5009         (riscv_implied_info_t::riscv_implied_info_t): New.
5010         (riscv_implied_info_t::match): New.
5011         (riscv_implied_info): New entry for zcf.
5012         (riscv_subset_list::handle_implied_ext): Use
5013         riscv_implied_info_t::match.
5014         (riscv_subset_list::check_implied_ext): Ditto.
5015         (riscv_subset_list::handle_combine_ext): Ditto.
5016         (riscv_subset_list::parse): Move zcf implication handling to
5017         riscv_implied_infos.
5019 2023-12-04  Kito Cheng  <kito.cheng@sifive.com>
5021         * common/config/riscv/riscv-common.cc
5022         (riscv_subset_list::check_conflict_ext): New.
5023         (riscv_subset_list::parse): Move checking conflict ext. to
5024         check_conflict_ext.
5025         * config/riscv/riscv-subset.h:
5026         Add riscv_subset_list::check_conflict_ext.
5028 2023-12-04  Hu, Lin1  <lin1.hu@intel.com>
5030         * common/config/i386/cpuinfo.h (get_available_features): Move USER_MSR
5031         to the correct location.
5033 2023-12-04  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5035         * config/riscv/riscv.md: Rostify the constraints.
5037 2023-12-04  chenxiaolong  <chenxiaolong@loongson.cn>
5039         * doc/extend.texi: Add information about the intrinsic function of the vector
5040         instruction.
5042 2023-12-03  Jakub Jelinek  <jakub@redhat.com>
5044         PR middle-end/112807
5045         * gimple-lower-bitint.cc (bitint_large_huge::lower_addsub_overflow):
5046         When choosing type0 and type1 types, if prec3 has small/middle bitint
5047         kind, use maximum of type0 and type1's precision instead of prec3.
5049 2023-12-03  Jeff Law  <jlaw@ventanamicro.com>
5051         * config/frv/frv.h (TRANSFER_FROM_TRAMPOLINE): Add prototype for exit.
5053 2023-12-02  Richard Sandiford  <richard.sandiford@arm.com>
5055         * attribs.cc (comp_type_attributes): Pass the full TREE_PURPOSE
5056         to lookup_attribute_spec, rather than just the name.
5057         (remove_attributes_matching): Likewise.
5059 2023-12-02  Richard Sandiford  <richard.sandiford@arm.com>
5061         * attribs.cc (find_same_attribute): New function.
5062         (decl_attributes, comp_type_attributes): Use it when looking
5063         up one list's attributes in another list.
5065 2023-12-02  Richard Sandiford  <richard.sandiford@arm.com>
5067         * Makefile.in (GTFILES): Add attribs.cc.
5068         * attribs.cc (gnu_namespace_cache): New variable.
5069         (get_gnu_namespace): New function.
5070         (lookup_attribute_spec): Use it instead of get_identifier ("gnu").
5071         (get_attribute_namespace, attribs_cc_tests): Likewise.
5073 2023-12-02  Richard Sandiford  <richard.sandiford@arm.com>
5075         * attribs.h (scoped_attribute_specs): New structure.
5076         (register_scoped_attributes): Take a reference to a
5077         scoped_attribute_specs instead of separate namespace and array
5078         parameters.
5079         * plugin.h (register_scoped_attributes): Likewise.
5080         * attribs.cc (register_scoped_attributes): Likewise.
5081         (attribute_tables): Change into an array of scoped_attribute_specs
5082         pointers.  Reduce to 1 element for frontends and 1 element for targets.
5083         (empty_attribute_table): Delete.
5084         (check_attribute_tables): Update for changes to attribute_tables.
5085         Use a hash_set to identify duplicates.
5086         (handle_ignored_attributes_option): Update for above changes.
5087         (init_attributes): Likewise.
5088         (excl_pair): Delete.
5089         (test_attribute_exclusions): Update for above changes.  Don't
5090         enforce symmetry for standard attributes in the top-level namespace.
5091         * langhooks-def.h (LANG_HOOKS_COMMON_ATTRIBUTE_TABLE): Delete.
5092         (LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE): Likewise.
5093         (LANG_HOOKS_INITIALIZER): Update accordingly.
5094         (LANG_HOOKS_ATTRIBUTE_TABLE): Define to an empty constructor.
5095         * langhooks.h (lang_hooks::common_attribute_table): Delete.
5096         (lang_hooks::format_attribute_table): Likewise.
5097         (lang_hooks::attribute_table): Redefine to an array of
5098         scoped_attribute_specs pointers.
5099         * target-def.h (TARGET_GNU_ATTRIBUTES): New macro.
5100         * target.def (attribute_spec): Redefine to return an array of
5101         scoped_attribute_specs pointers.
5102         * tree-inline.cc (function_attribute_inlinable_p): Update accordingly.
5103         * doc/tm.texi: Regenerate.
5104         * config/aarch64/aarch64.cc (aarch64_attribute_table): Define using
5105         TARGET_GNU_ATTRIBUTES.
5106         * config/alpha/alpha.cc (vms_attribute_table): Likewise.
5107         * config/avr/avr.cc (avr_attribute_table): Likewise.
5108         * config/bfin/bfin.cc (bfin_attribute_table): Likewise.
5109         * config/bpf/bpf.cc (bpf_attribute_table): Likewise.
5110         * config/csky/csky.cc (csky_attribute_table): Likewise.
5111         * config/epiphany/epiphany.cc (epiphany_attribute_table): Likewise.
5112         * config/gcn/gcn.cc (gcn_attribute_table): Likewise.
5113         * config/h8300/h8300.cc (h8300_attribute_table): Likewise.
5114         * config/loongarch/loongarch.cc (loongarch_attribute_table): Likewise.
5115         * config/m32c/m32c.cc (m32c_attribute_table): Likewise.
5116         * config/m32r/m32r.cc (m32r_attribute_table): Likewise.
5117         * config/m68k/m68k.cc (m68k_attribute_table): Likewise.
5118         * config/mcore/mcore.cc (mcore_attribute_table): Likewise.
5119         * config/microblaze/microblaze.cc (microblaze_attribute_table):
5120         Likewise.
5121         * config/mips/mips.cc (mips_attribute_table): Likewise.
5122         * config/msp430/msp430.cc (msp430_attribute_table): Likewise.
5123         * config/nds32/nds32.cc (nds32_attribute_table): Likewise.
5124         * config/nvptx/nvptx.cc (nvptx_attribute_table): Likewise.
5125         * config/riscv/riscv.cc (riscv_attribute_table): Likewise.
5126         * config/rl78/rl78.cc (rl78_attribute_table): Likewise.
5127         * config/rx/rx.cc (rx_attribute_table): Likewise.
5128         * config/s390/s390.cc (s390_attribute_table): Likewise.
5129         * config/sh/sh.cc (sh_attribute_table): Likewise.
5130         * config/sparc/sparc.cc (sparc_attribute_table): Likewise.
5131         * config/stormy16/stormy16.cc (xstormy16_attribute_table): Likewise.
5132         * config/v850/v850.cc (v850_attribute_table): Likewise.
5133         * config/visium/visium.cc (visium_attribute_table): Likewise.
5134         * config/arc/arc.cc (arc_attribute_table): Likewise.  Move further
5135         down file.
5136         * config/arm/arm.cc (arm_attribute_table): Update for above changes,
5137         using...
5138         (arm_gnu_attributes, arm_gnu_attribute_table): ...these new globals.
5139         * config/i386/i386-options.h (ix86_attribute_table): Delete.
5140         (ix86_gnu_attribute_table): Declare.
5141         * config/i386/i386-options.cc (ix86_attribute_table): Replace with...
5142         (ix86_gnu_attributes, ix86_gnu_attribute_table): ...these two globals.
5143         * config/i386/i386.cc (ix86_attribute_table): Define as an array of
5144         scoped_attribute_specs pointers.
5145         * config/ia64/ia64.cc (ia64_attribute_table): Update for above changes,
5146         using...
5147         (ia64_gnu_attributes, ia64_gnu_attribute_table): ...these new globals.
5148         * config/rs6000/rs6000.cc (rs6000_attribute_table): Update for above
5149         changes, using...
5150         (rs6000_gnu_attributes, rs6000_gnu_attribute_table): ...these new
5151         globals.
5153 2023-12-02  Roger Sayle  <roger@nextmovesoftware.com>
5155         * config/riscv/riscv-vsetvl.cc (csetvl_info::parse_insn): Rename
5156         local variable from demand_flags to dflags, to avoid conflicting
5157         with (enumeration) type of the same name.
5159 2023-12-02  Li Wei  <liwei@loongson.cn>
5161         * config/loongarch/loongarch.cc (loongarch_is_odd_extraction):
5162         Supplementary function prototype.
5163         (loongarch_is_even_extraction): Adjust.
5164         (loongarch_try_expand_lsx_vshuf_const): Adjust.
5165         (loongarch_is_extraction_permutation): Adjust.
5166         (loongarch_expand_vec_perm_const_2): Adjust.
5168 2023-12-02  Li Wei  <liwei@loongson.cn>
5170         * config/loongarch/loongarch.md (v2di): Used to simplify the
5171         following templates.
5172         (popcount<mode>2): New.
5174 2023-12-02  Li Wei  <liwei@loongson.cn>
5176         * config/loongarch/loongarch.h (CTZ_DEFINED_VALUE_AT_ZERO): Add
5177         description.
5178         (CLZ_DEFINED_VALUE_AT_ZERO): Remove duplicate definition.
5180 2023-12-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5182         PR target/112801
5183         * config/riscv/vector.md: Add !TARGET_64BIT.
5185 2023-12-02  Pan Li  <pan2.li@intel.com>
5187         PR target/112743
5188         * config/riscv/riscv.cc (riscv_legitimize_move): Take the
5189         exist (U *mode) and handle DFmode like DImode when EEW is
5190         32bits for ZVE32F.
5192 2023-12-01  Andrew MacLeod  <amacleod@redhat.com>
5194         * gimple-range-fold.h (range_compatible_p): Relocate.
5195         * value-range.h (range_compatible_p): Here.
5196         * range-op-mixed.h (operand_equal::operand_check_p): Call
5197         range_compatible_p rather than comparing precision.
5198         (operand_not_equal::operand_check_p): Ditto.
5199         (operand_not_lt::operand_check_p): Ditto.
5200         (operand_not_le::operand_check_p): Ditto.
5201         (operand_not_gt::operand_check_p): Ditto.
5202         (operand_not_ge::operand_check_p): Ditto.
5203         (operand_plus::operand_check_p): Ditto.
5204         (operand_abs::operand_check_p): Ditto.
5205         (operand_minus::operand_check_p): Ditto.
5206         (operand_negate::operand_check_p): Ditto.
5207         (operand_mult::operand_check_p): Ditto.
5208         (operand_bitwise_not::operand_check_p): Ditto.
5209         (operand_bitwise_xor::operand_check_p): Ditto.
5210         (operand_bitwise_and::operand_check_p): Ditto.
5211         (operand_bitwise_or::operand_check_p): Ditto.
5212         (operand_min::operand_check_p): Ditto.
5213         (operand_max::operand_check_p): Ditto.
5214         * range-op.cc (operand_lshift::operand_check_p): Ditto.
5215         (operand_rshift::operand_check_p): Ditto.
5216         (operand_logical_and::operand_check_p): Ditto.
5217         (operand_logical_or::operand_check_p): Ditto.
5218         (operand_logical_not::operand_check_p): Ditto.
5220 2023-12-01  Vladimir N. Makarov  <vmakarov@redhat.com>
5222         PR target/112445
5223         * lra.h (lra): Add one more arg.
5224         * lra-int.h (lra_verbose, lra_dump_insns): New externals.
5225         (lra_dump_insns_if_possible): Ditto.
5226         * lra.cc (lra_dump_insns): Dump all insns.
5227         (lra_dump_insns_if_possible):  Dump all insns for lra_verbose >= 7.
5228         (lra_verbose): New global.
5229         (lra): Add new arg.  Setup lra_verbose from its value.
5230         * lra-assigns.cc (lra_split_hard_reg_for): Dump insns if rtl
5231         was changed.
5232         * lra-remat.cc (lra_remat): Dump insns if rtl was changed.
5233         * lra-constraints.cc (lra_inheritance): Dump insns.
5234         (lra_constraints, lra_undo_inheritance): Dump insns if rtl
5235         was changed.
5236         (remove_inheritance_pseudos): Use restore reg if it is set up.
5237         * ira.cc: (lra): Pass internal_flag_ira_verbose.
5239 2023-12-01  Jakub Jelinek  <jakub@redhat.com>
5241         * doc/extend.texi (__builtin_addc, __builtin_addcl, __builtin_addcll,
5242         __builtin_subc, __builtin_subcl, __builtin_subcll,
5243         __builtin_stdc_bit_width, __builtin_stdc_count_ones,
5244         __builtin_stdc_count_zeros, __builtin_stdc_first_leading_one,
5245         __builtin_stdc_first_leading_zero, __builtin_stdc_first_trailing_one,
5246         __builtin_stdc_first_trailing_zero, __builtin_stdc_has_single_bit,
5247         __builtin_stdc_leading_ones, __builtin_stdc_leading_zeros,
5248         __builtin_stdc_trailing_ones, __builtin_stdc_trailing_zeros,
5249         __builtin_nvptx_brev, __builtin_nvptx_brevll, __builtin_darn,
5250         __builtin_darn_raw, __builtin_ia32_vec_ext_v2di,
5251         __builtin_ia32_crc32qi, __builtin_ia32_crc32hi,
5252         __builtin_ia32_crc32si, __builtin_ia32_crc32di): Put {}s around
5253         return type with spaces in it.
5254         (__builtin_rx_mvfachi, __builtin_rx_mvfacmi): Remove superfluous
5255         whitespace.
5257 2023-12-01  David Malcolm  <dmalcolm@redhat.com>
5259         * diagnostic-core.h (emit_diagnostic_valist): New overload decl.
5260         * diagnostic-format-sarif.cc (sarif_builder::make_result_object):
5261         When we have metadata, call its maybe_add_sarif_properties vfunc.
5262         * diagnostic-metadata.h (class sarif_object): Forward decl.
5263         (diagnostic_metadata::~diagnostic_metadata): New.
5264         (diagnostic_metadata::maybe_add_sarif_properties): New vfunc.
5265         * diagnostic.cc (emit_diagnostic_valist): New overload.
5267 2023-12-01  David Malcolm  <dmalcolm@redhat.com>
5269         PR analyzer/103533
5270         * doc/extend.texi: Remove stray reference to
5271         -fanalyzer-checker=taint.
5273 2023-12-01  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5275         PR target/112431
5276         * config/riscv/vector.md: Support highpart overlap for vx/vf.
5278 2023-12-01  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5280         PR target/112431
5281         * config/riscv/vector.md: Support highpart overlap for indexed load.
5283 2023-12-01  Richard Biener  <rguenther@suse.de>
5285         * tree-vectorizer.h (vect_get_vec_defs): Re-order arguments.
5286         * tree-vect-stmts.cc (vect_get_vec_defs): Likewise.
5287         (vectorizable_condition): Update caller.
5288         (vectorizable_comparison_1): Likewise.
5289         (vectorizable_conversion): Specify the vector type to be
5290         used for invariant/external defs.
5291         * tree-vect-loop.cc (vect_transform_reduction): Update caller.
5293 2023-12-01  Jakub Jelinek  <jakub@redhat.com>
5295         PR middle-end/112770
5296         * gimple-lower-bitint.cc (gimple_lower_bitint): When adjusting
5297         lhs of middle _BitInt setter which ends bb, insert cast on
5298         the fallthru edge rather than after stmt.
5300 2023-12-01  Jakub Jelinek  <jakub@redhat.com>
5302         PR middle-end/112771
5303         * gimple-lower-bitint.cc (bitint_large_huge::handle_operand_addr):
5304         Use mp = 1 if it is zero.
5306 2023-12-01  Jose E. Marchesi  <jose.marchesi@oracle.com>
5308         * config/bpf/bpf.cc (bpf_asm_named_section): New function.
5309         (TARGET_ASM_NAMED_SECTION): Set to bpf_asm_named_section.
5311 2023-12-01  Di Zhao  <dizhao@os.amperecomputing.com>
5313         * config/aarch64/aarch64-tuning-flags.def
5314         (AARCH64_EXTRA_TUNING_OPTION): New tuning option to avoid
5315         cross-loop FMA.
5316         * config/aarch64/aarch64.cc
5317         (aarch64_override_options_internal): Set
5318         param_avoid_fma_max_bits according to tuning option.
5319         * config/aarch64/tuning_models/ampere1.h (ampere1_tunings):
5320         Modify tunings related with FMA.
5321         * config/aarch64/tuning_models/ampere1a.h (ampere1a_tunings):
5322         Likewise.
5323         * config/aarch64/tuning_models/ampere1b.h (ampere1b_tunings):
5324         Likewise.
5326 2023-12-01  Richard Sandiford  <richard.sandiford@arm.com>
5328         * config/aarch64/aarch64-sve-builtins.h
5329         (function_expander::result_mode): New member function.
5330         * config/aarch64/aarch64-sve-builtins-base.cc
5331         (svld234_impl::expand): Use it.
5332         * config/aarch64/aarch64-sve-builtins.cc
5333         (function_expander::get_reg_target): Likewise.
5335 2023-12-01  Jakub Jelinek  <jakub@redhat.com>
5337         * gimple-lower-bitint.cc (range_to_prec): Don't return -1 for
5338         signed types.
5339         (bitint_large_huge::lower_addsub_overflow): Fix up computation of
5340         prec2.
5341         (bitint_large_huge::lower_mul_overflow): Likewise.
5343 2023-12-01  Jakub Jelinek  <jakub@redhat.com>
5345         * gimple-lower-bitint.cc (bitint_large_huge::finish_arith_overflow):
5346         When replacing use_stmt which is gsi_stmt (m_gsi), update m_gsi to
5347         the new statement.
5349 2023-12-01  Jakub Jelinek  <jakub@redhat.com>
5351         PR middle-end/112750
5352         * gimple-lower-bitint.cc (bitint_large_huge::lower_addsub_overflow):
5353         Use NE_EXPR rather than EQ_EXPR for g2 if !single_comparison and
5354         adjust probabilities.
5356 2023-12-01  Xi Ruoyao  <xry111@xry111.site>
5358         * doc/install.texi: Deem srcdir == objdir broken, but objdir
5359         as a subdirectory of srcdir fine.
5361 2023-12-01  Juergen Christ  <jchrist@linux.ibm.com>
5363         PR target/112753
5364         * config/s390/s390.cc (s390_md_asm_adjust): Return after dealing
5365         with the outputs, if no further processing of long doubles is
5366         required.
5368 2023-12-01  Jakub Jelinek  <jakub@redhat.com>
5370         PR target/112725
5371         * config/s390/s390.cc (s390_invalid_arg_for_unprototyped_fn): Return
5372         NULL for __builtin_classify_type calls with vector arguments.
5374 2023-12-01  Florian Weimer  <fweimer@redhat.com>
5376         * doc/invoke.texi (Warning Options): Document
5377         -Wdeclaration-missing-parameter-type.
5379 2023-12-01  Florian Weimer  <fweimer@redhat.com>
5381         * doc/invoke.texi (Warning Options): Document changes.
5383 2023-12-01  Florian Weimer  <fweimer@redhat.com>
5385         * doc/invoke.texi (Warning Options): Document that
5386         -Wreturn-mismatch is a permerror in C99 and later.
5388 2023-12-01  Florian Weimer  <fweimer@redhat.com>
5390         PR c/91093
5391         PR c/96284
5392         * doc/invoke.texi (Warning Options): Document changes.
5394 2023-12-01  Florian Weimer  <fweimer@redhat.com>
5396         * doc/invoke.texi (Warning Options): Document changes.
5398 2023-12-01  Florian Weimer  <fweimer@redhat.com>
5400         * doc/invoke.texi (Warning Options): Document changes.
5402 2023-12-01  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5404         PR target/112776
5405         * config/riscv/riscv-vsetvl.cc (pre_vsetvl::pre_global_vsetvl_info): Fix ratio.
5407 2023-11-30  Wilco Dijkstra  <wilco.dijkstra@arm.com>
5409         PR target/111404
5410         * config/aarch64/aarch64.cc (aarch64_split_compare_and_swap):
5411         For 128-bit store the loaded value and loop if needed.
5413 2023-11-30  Wilco Dijkstra  <wilco.dijkstra@arm.com>
5415         PR target/103100
5416         * config/aarch64/aarch64.md (cpymemdi): Remove pattern condition.
5417         (setmemdi): Likewise.
5418         * config/aarch64/aarch64.cc (aarch64_expand_cpymem): Support
5419         strict-align.  Cleanup condition for using MOPS.
5420         (aarch64_expand_setmem): Likewise.
5422 2023-11-30  Richard Biener  <rguenther@suse.de>
5424         PR tree-optimization/112767
5425         * tree-scalar-evolution.cc (final_value_replacement_loop):
5426         Propagate constants to immediate uses immediately.
5428 2023-11-30  Richard Biener  <rguenther@suse.de>
5430         PR tree-optimization/112766
5431         * gimple-predicate-analysis.cc (find_var_cmp_const):
5432         Support continuing the iteration and report every candidate.
5433         (uninit_analysis::overlap): Iterate over all flag var
5434         candidates.
5436 2023-11-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5438         PR target/112431
5439         * config/riscv/vector.md: Add widening overlap of vf2/vf4.
5441 2023-11-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5443         PR target/112431
5444         * config/riscv/vector.md: Remove earlyclobber for wx/wf instructions.
5446 2023-11-30  Jakub Jelinek  <jakub@redhat.com>
5448         PR middle-end/112733
5449         * wide-int.cc (wi::mul_internal): Don't allocate twice as much
5450         space for u, v and r as needed.
5451         (divmod_internal_2): Change return type from void to int, for n == 1
5452         return 1, otherwise before writing b_dividend into b_remainder set
5453         n to MIN (n, m) and at the end return it.
5454         (wi::divmod_internal): Don't allocate 4 times as much space for
5455         b_quotient, b_remainder, b_dividend and b_divisor.  Set n to
5456         result of divmod_internal_2.
5457         (wide_int_cc_tests): Add test for unsigned widest_int
5458         wi::multiple_of_p of 1 and -128.
5460 2023-11-30  liuhongt  <hongtao.liu@intel.com>
5462         * config/i386/sse.md (sdot_prodv64qi): New expander.
5463         (sseunpackmodelower): New mode attr.
5464         (sdot_prod<mode>): Emulate sdot_prodv*qi with sodt_prov*hi
5465         when TARGET_VNNIINT8 is not available.
5467 2023-11-30  liuhongt  <hongtao.liu@intel.com>
5469         * config/i386/sse.md: (reduc_plus_scal_<mode>): Use
5470         vec_extract_lo instead of subreg.
5471         (reduc_<code>_scal_<mode>): Ditto.
5472         (reduc_<code>_scal_<mode>): Ditto.
5473         (reduc_<code>_scal_<mode>): Ditto.
5474         (reduc_<code>_scal_<mode>): Ditto.
5476 2023-11-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5478         PR target/112431
5479         * config/riscv/vector.md: Add widenning overlap.
5481 2023-11-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5483         * config/riscv/constraints.md (TARGET_VECTOR ? V_REGS : NO_REGS): Fix constraint.
5484         * config/riscv/riscv.md (no,W21,W42,W84,W41,W81,W82): Rename vconstraint into group_overlap.
5485         (no,yes): Ditto.
5486         (none,W21,W42,W84,W43,W86,W87): Ditto.
5487         * config/riscv/vector.md: Ditto.
5489 2023-11-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5491         * config/riscv/vector.md: Support highpart overlap for vext.vf2
5493 2023-11-29  Philipp Tomsich  <philipp.tomsich@vrull.eu>
5495         * config/aarch64/aarch64-cores.def (AARCH64_CORE): Add ampere-1b
5496         * config/aarch64/aarch64-cost-tables.h: Add ampere1b_extra_costs
5497         * config/aarch64/aarch64-tune.md: Regenerate
5498         * config/aarch64/aarch64.cc: Include ampere1b tuning model
5499         * doc/invoke.texi: Document -mcpu=ampere1b
5500         * config/aarch64/tuning_models/ampere1b.h: New file.
5502 2023-11-29  David Faust  <david.faust@oracle.com>
5504         * config/bpf/bpf.h (ASM_COMMENT_START): Change from ';' to '#'.
5506 2023-11-29  Jakub Jelinek  <jakub@redhat.com>
5508         PR target/112725
5509         * config/rs6000/rs6000.cc (invalid_arg_for_unprototyped_fn): Return
5510         NULL for __builtin_classify_type calls with vector arguments.
5512 2023-11-29  Andrew MacLeod  <amacleod@redhat.com>
5514         PR tree-optimization/111922
5515         * ipa-cp.cc (ipa_vr_operation_and_type_effects): Check the
5516         operands are valid before calling fold_range.
5518 2023-11-29  Andrew MacLeod  <amacleod@redhat.com>
5520         * range-op-mixed.h (operator_equal::operand_check_p): New.
5521         (operator_not_equal::operand_check_p): New.
5522         (operator_lt::operand_check_p): New.
5523         (operator_le::operand_check_p): New.
5524         (operator_gt::operand_check_p): New.
5525         (operator_ge::operand_check_p): New.
5526         (operator_plus::operand_check_p): New.
5527         (operator_abs::operand_check_p): New.
5528         (operator_minus::operand_check_p): New.
5529         (operator_negate::operand_check_p): New.
5530         (operator_mult::operand_check_p): New.
5531         (operator_bitwise_not::operand_check_p): New.
5532         (operator_bitwise_xor::operand_check_p): New.
5533         (operator_bitwise_and::operand_check_p): New.
5534         (operator_bitwise_or::operand_check_p): New.
5535         (operator_min::operand_check_p): New.
5536         (operator_max::operand_check_p): New.
5537         * range-op.cc (range_op_handler::fold_range): Check operand
5538         parameter types.
5539         (range_op_handler::op1_range): Ditto.
5540         (range_op_handler::op2_range): Ditto.
5541         (range_op_handler::operand_check_p): New.
5542         (range_operator::operand_check_p): New.
5543         (operator_lshift::operand_check_p): New.
5544         (operator_rshift::operand_check_p): New.
5545         (operator_logical_and::operand_check_p): New.
5546         (operator_logical_or::operand_check_p): New.
5547         (operator_logical_not::operand_check_p): New.
5548         * range-op.h (range_operator::operand_check_p): New.
5549         (range_op_handler::operand_check_p): New.
5551 2023-11-29  Martin Jambor  <mjambor@suse.cz>
5553         PR tree-optimization/112711
5554         PR tree-optimization/112721
5555         * tree-sra.cc (build_access_from_call_arg): New parameter
5556         CAN_BE_RETURNED, disqualify any candidate passed by reference if it is
5557         true.  Adjust leading comment.
5558         (scan_function): Pass appropriate value to CAN_BE_RETURNED of
5559         build_access_from_call_arg.
5561 2023-11-29  Thomas Schwinge  <thomas@codesourcery.com>
5563         * doc/sourcebuild.texi (Final Actions): Document
5564         'only_for_offload_target' wrapper.
5566 2023-11-29  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
5568         PR testsuite/112729
5569         * doc/sourcebuild.texi (Effective-Target Keywords, Environment
5570         attributes): Document cfi.
5572 2023-11-29  Richard Biener  <rguenther@suse.de>
5574         PR middle-end/110237
5575         * internal-fn.cc (expand_partial_load_optab_fn): Clear
5576         MEM_EXPR and MEM_OFFSET.
5577         (expand_partial_store_optab_fn): Likewise.
5579 2023-11-29  Jakub Jelinek  <jakub@redhat.com>
5581         PR middle-end/112733
5582         * fold-const.cc (multiple_of_p): Pass SIGNED rather than
5583         UNSIGNED for wi::multiple_of_p on widest_int arguments.
5585 2023-11-29  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5586             kito-cheng  <kito.cheng@sifive.com>
5587             kito-cheng  <kito.cheng@gmail.com>
5589         PR target/112431
5590         * config/riscv/constraints.md (TARGET_VECTOR ? V_REGS : NO_REGS): New register filters.
5591         * config/riscv/riscv.md (no,W21,W42,W84,W41,W81,W82): Ditto.
5592         (no,yes): Ditto.
5593         * config/riscv/vector.md: Support highpart register overlap for vwcvt.
5595 2023-11-29  xuli  <xuli1@eswincomputing.com>
5597         * config/riscv/riscv.cc (riscv_option_override): Eliminate warning.
5599 2023-11-29  Jakub Jelinek  <jakub@redhat.com>
5601         PR bootstrap/111601
5602         * fold-mem-offsets.cc (get_uses): Ignore DEBUG_INSN uses.  Otherwise,
5603         punt if use is in a different basic block from INSN or appears before
5604         INSN in the same basic block.  Formatting fixes.
5605         (get_single_def_in_bb): Formatting fixes.
5606         (fold_offsets_1, pass_fold_mem_offsets::execute): Comment formatting
5607         fixes.
5609 2023-11-29  Xi Ruoyao  <xry111@xry111.site>
5611         * config/loongarch/simd.md (LSX_SCALAR_FRINT): New int iterator.
5612         (VLSX_FOR_FMODE): New mode attribute.
5613         (<simd_for_scalar_frint_pattern><mode>2): New expander,
5614         expanding to vreplvei.{w/d} + frint{rp/rz/rm/rne}.{s.d}.
5616 2023-11-29  Xi Ruoyao  <xry111@xry111.site>
5618         * config/loongarch/loongarch.md (lrint_allow_inexact): Remove.
5619         (<lrint_pattern><ANYF:mode><ANYFI:mode>2): Check if <LRINT>
5620         == UNSPEC_FTINT instead of <lrint_allow_inexact>.
5622 2023-11-29  Xi Ruoyao  <xry111@xry111.site>
5624         * config/loongarch/lsx.md (bitimm): Move to ...
5625         (UNSPEC_LSX_VROTR): Remove.
5626         (lsx_vrotr_<lsxfmt>): Remove.
5627         (lsx_vrotri_<lsxfmt>): Remove.
5628         * config/loongarch/lasx.md (UNSPEC_LASX_XVROTR): Remove.
5629         (lsx_vrotr_<lsxfmt>): Remove.
5630         (lsx_vrotri_<lsxfmt>): Remove.
5631         * config/loongarch/simd.md (bitimm): ... here.  Expand it to
5632         cover LASX modes.
5633         (vrotr<mode>3): New define_insn.
5634         (vrotri<mode>3): New define_insn.
5635         * config/loongarch/loongarch-builtins.cc:
5636         (CODE_FOR_lsx_vrotr_b): Use standard pattern name.
5637         (CODE_FOR_lsx_vrotr_h): Likewise.
5638         (CODE_FOR_lsx_vrotr_w): Likewise.
5639         (CODE_FOR_lsx_vrotr_d): Likewise.
5640         (CODE_FOR_lasx_xvrotr_b): Likewise.
5641         (CODE_FOR_lasx_xvrotr_h): Likewise.
5642         (CODE_FOR_lasx_xvrotr_w): Likewise.
5643         (CODE_FOR_lasx_xvrotr_d): Likewise.
5644         (CODE_FOR_lsx_vrotri_b): Define to standard pattern name.
5645         (CODE_FOR_lsx_vrotri_h): Likewise.
5646         (CODE_FOR_lsx_vrotri_w): Likewise.
5647         (CODE_FOR_lsx_vrotri_d): Likewise.
5648         (CODE_FOR_lasx_xvrotri_b): Likewise.
5649         (CODE_FOR_lasx_xvrotri_h): Likewise.
5650         (CODE_FOR_lasx_xvrotri_w): Likewise.
5651         (CODE_FOR_lasx_xvrotri_d): Likewise.
5653 2023-11-29  Xi Ruoyao  <xry111@xry111.site>
5655         * config/loongarch/simd.md (muh): New code attribute mapping
5656         any_extend to smul_highpart or umul_highpart.
5657         (<su>mul<mode>3_highpart): New define_insn.
5658         * config/loongarch/lsx.md (UNSPEC_LSX_VMUH_S): Remove.
5659         (UNSPEC_LSX_VMUH_U): Remove.
5660         (lsx_vmuh_s_<lsxfmt>): Remove.
5661         (lsx_vmuh_u_<lsxfmt>): Remove.
5662         * config/loongarch/lasx.md (UNSPEC_LASX_XVMUH_S): Remove.
5663         (UNSPEC_LASX_XVMUH_U): Remove.
5664         (lasx_xvmuh_s_<lasxfmt>): Remove.
5665         (lasx_xvmuh_u_<lasxfmt>): Remove.
5666         * config/loongarch/loongarch-builtins.cc (CODE_FOR_lsx_vmuh_b):
5667         Redefine to standard pattern name.
5668         (CODE_FOR_lsx_vmuh_h): Likewise.
5669         (CODE_FOR_lsx_vmuh_w): Likewise.
5670         (CODE_FOR_lsx_vmuh_d): Likewise.
5671         (CODE_FOR_lsx_vmuh_bu): Likewise.
5672         (CODE_FOR_lsx_vmuh_hu): Likewise.
5673         (CODE_FOR_lsx_vmuh_wu): Likewise.
5674         (CODE_FOR_lsx_vmuh_du): Likewise.
5675         (CODE_FOR_lasx_xvmuh_b): Likewise.
5676         (CODE_FOR_lasx_xvmuh_h): Likewise.
5677         (CODE_FOR_lasx_xvmuh_w): Likewise.
5678         (CODE_FOR_lasx_xvmuh_d): Likewise.
5679         (CODE_FOR_lasx_xvmuh_bu): Likewise.
5680         (CODE_FOR_lasx_xvmuh_hu): Likewise.
5681         (CODE_FOR_lasx_xvmuh_wu): Likewise.
5682         (CODE_FOR_lasx_xvmuh_du): Likewise.
5684 2023-11-29  Xi Ruoyao  <xry111@xry111.site>
5686         PR target/112578
5687         * config/loongarch/lsx.md (UNSPEC_LSX_VFTINT_S,
5688         UNSPEC_LSX_VFTINTRNE, UNSPEC_LSX_VFTINTRP,
5689         UNSPEC_LSX_VFTINTRM, UNSPEC_LSX_VFRINTRNE_S,
5690         UNSPEC_LSX_VFRINTRNE_D, UNSPEC_LSX_VFRINTRZ_S,
5691         UNSPEC_LSX_VFRINTRZ_D, UNSPEC_LSX_VFRINTRP_S,
5692         UNSPEC_LSX_VFRINTRP_D, UNSPEC_LSX_VFRINTRM_S,
5693         UNSPEC_LSX_VFRINTRM_D): Remove.
5694         (ILSX, FLSX): Move into ...
5695         (VIMODE): Move into ...
5696         (FRINT_S, FRINT_D): Remove.
5697         (frint_pattern_s, frint_pattern_d, frint_suffix): Remove.
5698         (lsx_vfrint_<flsxfmt>, lsx_vftint_s_<ilsxfmt>_<flsxfmt>,
5699         lsx_vftintrne_w_s, lsx_vftintrne_l_d, lsx_vftintrp_w_s,
5700         lsx_vftintrp_l_d, lsx_vftintrm_w_s, lsx_vftintrm_l_d,
5701         lsx_vfrintrne_s, lsx_vfrintrne_d, lsx_vfrintrz_s,
5702         lsx_vfrintrz_d, lsx_vfrintrp_s, lsx_vfrintrp_d,
5703         lsx_vfrintrm_s, lsx_vfrintrm_d,
5704         <FRINT_S:frint_pattern_s>v4sf2,
5705         <FRINT_D:frint_pattern_d>v2df2, round<mode>2,
5706         fix_trunc<mode>2): Remove.
5707         * config/loongarch/lasx.md: Likewise.
5708         * config/loongarch/simd.md: New file.
5709         (ILSX, ILASX, FLSX, FLASX, VIMODE): ... here.
5710         (IVEC, FVEC): New mode iterators.
5711         (VIMODE): ... here.  Extend it to work for all LSX/LASX vector
5712         modes.
5713         (x, wu, simd_isa, WVEC, vimode, simdfmt, simdifmt_for_f,
5714         elebits): New mode attributes.
5715         (UNSPEC_SIMD_FRINTRP, UNSPEC_SIMD_FRINTRZ, UNSPEC_SIMD_FRINT,
5716         UNSPEC_SIMD_FRINTRM, UNSPEC_SIMD_FRINTRNE): New unspecs.
5717         (SIMD_FRINT): New int iterator.
5718         (simd_frint_rounding, simd_frint_pattern): New int attributes.
5719         (<simd_isa>_<x>vfrint<simd_frint_rounding>_<simdfmt>): New
5720         define_insn template for frint instructions.
5721         (<simd_isa>_<x>vftint<simd_frint_rounding>_<simdifmt_for_f>_<simdfmt>):
5722         Likewise, but for ftint instructions.
5723         (<simd_frint_pattern><mode>2): New define_expand with
5724         flag_fp_int_builtin_inexact checked.
5725         (l<simd_frint_pattern><mode><vimode>2): Likewise.
5726         (ftrunc<mode>2): New define_expand.  It does not require
5727         flag_fp_int_builtin_inexact.
5728         (fix_trunc<mode><vimode>2): New define_insn_and_split.  It does
5729         not require flag_fp_int_builtin_inexact.
5730         (include): Add lsx.md and lasx.md.
5731         * config/loongarch/loongarch.md (include): Include simd.md,
5732         instead of including lsx.md and lasx.md directly.
5733         * config/loongarch/loongarch-builtins.cc
5734         (CODE_FOR_lsx_vftint_w_s, CODE_FOR_lsx_vftint_l_d,
5735         CODE_FOR_lasx_xvftint_w_s, CODE_FOR_lasx_xvftint_l_d):
5736         Remove.
5738 2023-11-29  Alexandre Oliva  <oliva@adacore.com>
5740         * doc/extend.texi (hardbool): New type attribute.
5741         * doc/invoke.texi (-ftrivial-auto-var-init): Document
5742         representation vs values.
5744 2023-11-29  Alexandre Oliva  <oliva@adacore.com>
5746         * expr.cc (emit_block_move_hints): Take ctz of len.  Obey
5747         -finline-stringops.  Use oriented or sized loop.
5748         (emit_block_move): Take ctz of len, and pass it on.
5749         (emit_block_move_via_sized_loop): New.
5750         (emit_block_move_via_oriented_loop): New.
5751         (emit_block_move_via_loop): Take incr.  Move an incr-sized
5752         block per iteration.
5753         (emit_block_cmp_via_cmpmem): Take ctz of len.  Obey
5754         -finline-stringops.
5755         (emit_block_cmp_via_loop): New.
5756         * expr.h (emit_block_move): Add ctz of len defaulting to zero.
5757         (emit_block_move_hints): Likewise.
5758         (emit_block_cmp_hints): Likewise.
5759         * builtins.cc (expand_builtin_memory_copy_args): Pass ctz of
5760         len to emit_block_move_hints.
5761         (try_store_by_multiple_pieces): Support starting with a loop.
5762         (expand_builtin_memcmp): Pass ctz of len to
5763         emit_block_cmp_hints.
5764         (expand_builtin): Allow inline expansion of memset, memcpy,
5765         memmove and memcmp if requested.
5766         * common.opt (finline-stringops): New.
5767         (ilsop_fn): New enum.
5768         * flag-types.h (enum ilsop_fn): New.
5769         * doc/invoke.texi (-finline-stringops): Add.
5771 2023-11-29  Pan Li  <pan2.li@intel.com>
5773         PR target/112743
5774         * config/riscv/riscv-string.cc (expand_block_move): Add
5775         precondition check for exact_div.
5777 2023-11-28  Roger Sayle  <roger@nextmovesoftware.com>
5779         * config/arc/arc.md: Make output template whitespace consistent.
5781 2023-11-28  Jose E. Marchesi  <jose.marchesi@oracle.com>
5783         * varasm.cc (assemble_external_libcall): Refer in assert only ifdef
5784         ASM_OUTPUT_EXTERNAL.
5786 2023-11-28  Andrew Pinski  <quic_apinski@quicinc.com>
5788         PR tree-optimization/112738
5789         * match.pd (`(nop_convert)-(convert)a`): Reject
5790         when the outer type is boolean.
5792 2023-11-28  Richard Biener  <rguenther@suse.de>
5794         PR middle-end/112732
5795         * tree.cc (build_opaque_vector_type): Reset TYPE_ALIAS_SET
5796         of the newly built type.
5798 2023-11-28  Uros Bizjak  <ubizjak@gmail.com>
5800         PR target/112494
5801         * config/i386/i386.md (cmpstrnqi_1): Set FLAGS_REG to its previous
5802         value when operand 2 equals zero.
5803         (*cmpstrnqi_1): Ditto.
5804         (*cmpstrnqi_1 peephole2): Ditto.
5806 2023-11-28  Cupertino Miranda  <cupertino.miranda@oracle.com>
5808         Revert:
5809         2023-11-28  Cupertino Miranda  <cupertino.miranda@oracle.com>
5811         * config/bpf/bpf.cc (bpf_output_call): Report error in case the
5812         function call is for a builtin.
5813         (bpf_external_libcall): Added target hook to detect and report
5814         error when other external calls that are not builtins.
5816 2023-11-28  Jose E. Marchesi  <jose.marchesi@oracle.com>
5818         PR target/109253
5819         * varasm.cc (pending_libcall_symbols): New variable.
5820         (process_pending_assemble_externals): Process
5821         pending_libcall_symbols.
5822         (assemble_external_libcall): Defer emitting external libcall
5823         symbols to process_pending_assemble_externals.
5825 2023-11-28  Cupertino Miranda  <cupertino.miranda@oracle.com>
5827         * btfout.cc (btf_calc_num_vbytes): Fixed logic for enum64.
5828         (btf_asm_enum_const): Corrected logic for enum64 and smaller
5829         than 4 bytes values.
5831 2023-11-28  Cupertino Miranda  <cupertino.miranda@oracle.com>
5833         * config/bpf/bpf.cc (bpf_output_call): Report error in case the
5834         function call is for a builtin.
5835         (bpf_external_libcall): Added target hook to detect and report
5836         error when other external calls that are not builtins.
5838 2023-11-28  Cupertino Miranda  <cupertino.miranda@oracle.com>
5840         * config/bpf/bpf.cc (bpf_use_by_pieces_infrastructure_p): Added
5841         function to bypass default behaviour.
5842         * config/bpf/bpf.h (COMPARE_MAX_PIECES): Defined to 1024 bytes.
5844 2023-11-28  Cupertino Miranda  <cupertino.miranda@oracle.com>
5846         * config/bpf/core-builtins.cc (core_mark_as_access_index):
5847         Corrected check.
5849 2023-11-28  Cupertino Miranda  <cupertino.miranda@oracle.com>
5851         * config/bpf/core-builtins.cc
5852         (bpf_resolve_overloaded_core_builtin): Removed call.
5853         (execute_lower_bpf_core): Added all to remove_parser_plugin.
5855 2023-11-28  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5857         PR target/112694
5858         * config/riscv/riscv-v.cc (expand_vec_perm_const): Disallow poly size (1, 1) VLA SLP.
5860 2023-11-28  Jakub Jelinek  <jakub@redhat.com>
5862         PR tree-optimization/112719
5863         * match.pd (parity(X)^parity(Y) -> parity(X^Y)): Handle case of
5864         mismatched types.
5865         * gimple-match-exports.cc (build_call_internal): Add special-case for
5866         bit query ifns on large/huge BITINT_TYPE before bitint lowering.
5868 2023-11-28  Jakub Jelinek  <jakub@redhat.com>
5870         PR tree-optimization/112719
5871         * match.pd (popcount (X) + popcount (Y) -> POPCOUNT (X | Y)): Deal
5872         with argument types with different precisions.
5874 2023-11-28  David Malcolm  <dmalcolm@redhat.com>
5876         PR analyzer/109077
5877         * Makefile.in (PLUGIN_HEADERS): Add analyzer headers.
5878         (install-plugin): Keep the directory structure for files in
5879         "analyzer".
5881 2023-11-28  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
5883         PR target/112713
5884         * config/riscv/riscv-vsetvl.cc (pre_vsetvl::compute_lcm_local_properties): Fix regression.
5886 2023-11-28  David Malcolm  <dmalcolm@redhat.com>
5888         * diagnostic-show-locus.cc (layout::maybe_add_location_range):
5889         Don't print annotation lines for ranges when there's no column
5890         info.
5891         (selftest::test_one_liner_no_column): New.
5892         (selftest::test_diagnostic_show_locus_one_liner): Call it.
5894 2023-11-28  David Malcolm  <dmalcolm@redhat.com>
5896         * diagnostic.cc (diagnostic_get_location_text): Convert to...
5897         (diagnostic_context::get_location_text): ...this, and convert
5898         return type from char * to label_text.
5899         (diagnostic_build_prefix): Update for above change.
5900         (default_diagnostic_start_span_fn): Likewise.
5901         (selftest::assert_location_text): Likewise.
5902         * diagnostic.h (diagnostic_context::get_location_text): New decl.
5904 2023-11-27  Andrew Pinski  <quic_apinski@quicinc.com>
5906         * config/aarch64/aarch64.cc (aarch64_if_then_else_costs):
5907         Handle csinv/csinc case of 1/-1.
5909 2023-11-27  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
5910             Richard Sandiford  <richard.sandiford@arm.com>
5912         PR middle-end/111754
5913         * fold-const.cc (fold_vec_perm_cst): Set result's encoding to sel's
5914         encoding, and set res_nelts_per_pattern to 2 if sel contains stepped
5915         sequence but input vectors do not.
5916         (test_nunits_min_2): New test Case 8.
5917         (test_nunits_min_4): New tests Case 8 and Case 9.
5919 2023-11-27  Szabolcs Nagy  <szabolcs.nagy@arm.com>
5921         * config/aarch64/aarch64.cc (aarch64_needs_frame_chain): Do not
5922         force frame chain for eh_return.
5924 2023-11-27  Szabolcs Nagy  <szabolcs.nagy@arm.com>
5926         * config/aarch64/aarch64-protos.h (aarch64_eh_return_handler_rtx):
5927         Remove.
5928         * config/aarch64/aarch64.cc (aarch64_return_address_signing_enabled):
5929         Sign return address even in functions with eh_return.
5930         (aarch64_expand_epilogue): Conditionally return with br or ret.
5931         (aarch64_eh_return_handler_rtx): Remove.
5932         * config/aarch64/aarch64.h (EH_RETURN_TAKEN_RTX): Define.
5933         (EH_RETURN_STACKADJ_RTX): Change to R5.
5934         (EH_RETURN_HANDLER_RTX): Change to R6.
5935         * df-scan.cc: Handle EH_RETURN_TAKEN_RTX.
5936         * doc/tm.texi: Regenerate.
5937         * doc/tm.texi.in: Document EH_RETURN_TAKEN_RTX.
5938         * except.cc (expand_eh_return): Handle EH_RETURN_TAKEN_RTX.
5940 2023-11-27  Thomas Schwinge  <thomas@codesourcery.com>
5942         * config.gcc <amdgcn-*-amdhsa> (extra_gcc_objs): Don't set.
5943         * config/gcn/driver-gcn.cc: Remove.
5944         * config/gcn/gcn-hsa.h (ASM_SPEC, EXTRA_SPEC_FUNCTIONS): Remove
5945         'last_arg' spec function.
5946         * config/gcn/t-gcn-hsa (driver-gcn.o): Remove.
5948 2023-11-27  Thomas Schwinge  <thomas@codesourcery.com>
5950         PR target/112669
5951         * config/gcn/gcn.opt (march=, mtune=): Tag as 'Negative' of
5952         themselves.
5954 2023-11-27  Samuel Thibault  <samuel.thibault@gnu.org>
5956         * config/i386/gnu.h: Use PIE_SPEC, add static-pie case.
5957         * config/i386/gnu64.h: Use PIE_SPEC, add static-pie case.
5959 2023-11-27  Samuel Thibault  <samuel.thibault@gnu.org>
5961         * config/i386/t-gnu64: New file.
5962         * config.gcc [x86_64-*-gnu*]: Add i386/t-gnu64 to
5963         tmake_file.
5965 2023-11-27  Richard Sandiford  <richard.sandiford@arm.com>
5967         PR target/106326
5968         * config/aarch64/aarch64-sve-builtins.h (is_ptrue): Declare.
5969         * config/aarch64/aarch64-sve-builtins.cc (is_ptrue): New function.
5970         (gimple_folder::redirect_pred_x): Likewise.
5971         (gimple_folder::fold): Use it.
5973 2023-11-27  Richard Sandiford  <richard.sandiford@arm.com>
5975         * config/aarch64/aarch64-sve-builtins.h (vector_cst_all_same): Declare.
5976         * config/aarch64/aarch64-sve-builtins.cc (vector_cst_all_same): New
5977         function, a generalized replacement of...
5978         * config/aarch64/aarch64-sve-builtins-base.cc
5979         (svlast_impl::vect_all_same): ...this.
5980         (svlast_impl::fold): Update accordingly.
5982 2023-11-27  Richard Biener  <rguenther@suse.de>
5984         PR tree-optimization/112653
5985         * gimple-ssa.h (gimple_df): Add escaped_return solution.
5986         * tree-ssa.cc (init_tree_ssa): Reset it.
5987         (delete_tree_ssa): Likewise.
5988         * tree-ssa-structalias.cc (escaped_return_id): New.
5989         (find_func_aliases): Handle non-IPA return stmts by
5990         adding to ESCAPED_RETURN.
5991         (set_uids_in_ptset): Adjust HEAP escaping to also cover
5992         escapes through return.
5993         (init_base_vars): Initialize ESCAPED_RETURN.
5994         (compute_points_to_sets): Replace ESCAPED post-processing
5995         with recording the ESCAPED_RETURN solution.
5996         * tree-ssa-alias.cc (ref_may_alias_global_p_1): Check
5997         the ESCAPED_RETUNR solution.
5998         (dump_alias_info): Dump it.
5999         * cfgexpand.cc (update_alias_info_with_stack_vars): Update it.
6000         * ipa-icf.cc (sem_item_optimizer::fixup_points_to_sets):
6001         Likewise.
6002         * tree-inline.cc (expand_call_inline): Reset it.
6003         * tree-parloops.cc (parallelize_loops): Likewise.
6004         * tree-sra.cc (maybe_add_sra_candidate): Check it.
6006 2023-11-27  Richard Biener  <rguenther@suse.de>
6007             Richard Sandiford  <richard.sandiford@arm.com>
6009         PR tree-optimization/112661
6010         * tree-vect-slp.cc (vect_get_and_check_slp_defs): Defer duplicate-and-
6011         interleave test to...
6012         (vect_build_slp_tree_2): ...here, once we have all the operands.
6013         Skip the test for uniform vectors.
6014         (vect_create_constant_vectors): Detect uniform vectors.  Avoid
6015         redundant conversions in that case.  Use gimple_build_vector_from_val
6016         to build the vector.
6018 2023-11-27  Richard Sandiford  <richard.sandiford@arm.com>
6020         * attribs.cc (excl_hash_traits): Delete.
6021         (test_attribute_exclusions): Use pair_hash and nofree_string_hash
6022         instead.
6024 2023-11-27  Andrew Stubbs  <ams@codesourcery.com>
6026         * config/gcn/gcn.cc (gcn_vectorize_vec_perm_const): Disallow TImode.
6028 2023-11-27  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
6030         * config/s390/s390-builtin-types.def (BT_FN_UV8HI_UV8HI_UINT):
6031         Add missing builtin type.
6033 2023-11-27  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
6035         * config/s390/s390-builtin-types.def: Remove types.
6036         * config/s390/s390-builtins.def (O_U64): Remove 64-bit literal support.
6037         Don't restrict s390_vec_rli and s390_verll[bhfg] to immediates.
6038         * config/s390/s390.cc (s390_const_operand_ok): Remove 64-bit
6039         literal support.
6041 2023-11-27  Alex Coplan  <alex.coplan@arm.com>
6042             Iain Sandoe  <iain@sandoe.co.uk>
6044         PR c++/60512
6045         * doc/cpp.texi: Document __has_{feature,extension}.
6047 2023-11-27  Richard Biener  <rguenther@suse.de>
6049         PR tree-optimization/112706
6050         * match.pd (ptr + o ==/!=/- ptr + o'): New patterns.
6052 2023-11-27  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
6054         * config/s390/s390-builtin-types.def: Add/remove types.
6055         * config/s390/s390-builtins.def
6056         (s390_vclfnhs,s390_vclfnls,s390_vcrnfs,s390_vcfn,s390_vcnf):
6057         Replace type V8HI with UV8HI.
6059 2023-11-27  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
6061         * config/s390/s390-builtins.def
6062         (s390_vcefb,s390_vcdgb,s390_vcelfb,s390_vcdlgb,s390_vcfeb,s390_vcgdb,
6063         s390_vclfeb,s390_vclgdb): Remove flags for non-existing operands
6064         2 and 3.
6066 2023-11-27  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
6068         * config/s390/s390.md (*cmphi_ccu): For immediate operand 1 make
6069         use of constraint n instead of D and chop of high bits in the
6070         output template.
6072 2023-11-27  Jakub Jelinek  <jakub@redhat.com>
6074         PR target/112300
6075         * config.gcc (mips*-sde-elf*): Append to tm_defines rather than
6076         overwriting them.
6078 2023-11-27  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6080         * config/riscv/autovec.md
6081         (mask_len_gather_load<RATIO1:mode><RATIO1:mode>):
6082         Remove gather_scatter_valid_offset_mode_p.
6083         (mask_len_gather_load<mode><mode>): Ditto.
6084         (mask_len_scatter_store<RATIO1:mode><RATIO1:mode>): Ditto.
6085         (mask_len_scatter_store<mode><mode>): Ditto.
6086         * config/riscv/predicates.md (const_1_or_8_operand): New predicate.
6087         (vector_gs_scale_operand_64): Remove.
6088         * config/riscv/riscv-protos.h (gather_scatter_valid_offset_mode_p): Remove.
6089         * config/riscv/riscv-v.cc (expand_gather_scatter): Refine code.
6090         (gather_scatter_valid_offset_mode_p): Remove.
6091         * config/riscv/vector-iterators.md: Fix iterator bugs.
6093 2023-11-27  Tsukasa OI  <research_trasio@irq.a4lg.com>
6095         * common/config/riscv/riscv-common.cc
6096         (riscv_ext_version_table): Set version to ratified 2.0.
6097         (riscv_subset_list::parse_std_ext): Allow RV64E.
6098         * config.gcc: Parse base ISA 'rv64e' and ABI 'lp64e'.
6099         * config/riscv/arch-canonicalize: Parse base ISA 'rv64e'.
6100         * config/riscv/riscv-c.cc (riscv_cpu_cpp_builtins):
6101         Define different macro per XLEN.  Add handling for ABI_LP64E.
6102         * config/riscv/riscv-d.cc (riscv_d_handle_target_float_abi):
6103         Add handling for ABI_LP64E.
6104         * config/riscv/riscv-opts.h (enum riscv_abi_type): Add ABI_LP64E.
6105         * config/riscv/riscv.cc (riscv_option_override): Enhance error
6106         handling to support RV64E and LP64E.
6107         (riscv_conditional_register_usage): Change "RV32E" in a comment
6108         to "RV32E/RV64E".
6109         * config/riscv/riscv.h
6110         (UNITS_PER_FP_ARG): Add handling for ABI_LP64E.
6111         (STACK_BOUNDARY): Ditto.
6112         (ABI_STACK_BOUNDARY): Ditto.
6113         (MAX_ARGS_IN_REGISTERS): Ditto.
6114         (ABI_SPEC): Add support for "lp64e".
6115         * config/riscv/riscv.opt: Parse -mabi=lp64e as ABI_LP64E.
6116         * doc/invoke.texi: Add documentation of the LP64E ABI.
6118 2023-11-27  Jose E. Marchesi  <jose.marchesi@oracle.com>
6120         * config/bpf/bpf-helpers.h: Remove.
6121         * config.gcc: Adapt accordingly.
6123 2023-11-27  Guo Jie  <guojie@loongson.cn>
6125         * config/loongarch/loongarch.cc (loongarch_split_plus_constant):
6126         avoid left shift of negative value -0x8000.
6128 2023-11-27  Guo Jie  <guojie@loongson.cn>
6130         * config/loongarch/loongarch.cc
6131         (enum loongarch_load_imm_method): Add new method.
6132         (loongarch_build_integer): Add relevant implementations for
6133         new method.
6134         (loongarch_move_integer): Ditto.
6136 2023-11-26  Alexander Monakov  <amonakov@ispras.ru>
6138         * sort.cc: Use 'sorting networks' in comments.
6140 2023-11-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6142         PR target/112599
6143         * config/riscv/riscv-avlprop.cc (avl_can_be_propagated_p): Add slidedown.
6144         (vlmax_ta_p): Ditto.
6145         (pass_avlprop::get_vlmax_ta_preferred_avl): Ditto.
6147 2023-11-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6149         * config/riscv/riscv-avlprop.cc (alv_can_be_propagated_p): Fix typo.
6150         (avl_can_be_propagated_p): Ditto.
6151         (vlmax_ta_p): Ditto.
6153 2023-11-25  Gerald Pfeifer  <gerald@pfeifer.com>
6155         PR other/69374
6156         * doc/install.texi (Downloading the source): Sort the list of
6157         front ends and add D, Go, and Modula-2.
6159 2023-11-25  Gerald Pfeifer  <gerald@pfeifer.com>
6161         PR target/69374
6162         * doc/install.texi (Specific) <*-*-freebsd*>: Remove older
6163         contents referencing GCC 4.x.
6165 2023-11-25  Gerald Pfeifer  <gerald@pfeifer.com>
6167         * doc/standards.texi (Standards): Update ISO C++ reference.
6169 2023-11-25  Jakub Jelinek  <jakub@redhat.com>
6171         PR target/111408
6172         * config/i386/i386.md (*jcc_bt<mode>_mask,
6173         *jcc_bt<SWI48:mode>_mask_1): Add (const_int 0) as expected
6174         second operand of bt_comparison_operator.
6176 2023-11-25  Andrew Pinski  <pinskia@gmail.com>
6177             Jakub Jelinek  <jakub@redhat.com>
6179         PR target/109977
6180         * config/aarch64/aarch64-simd.md (aarch64_simd_stp<mode>): Use <vwcore>
6181         rather than %<vw> for alternative with r constraint on input operand.
6183 2023-11-24  Tobias Burnus  <tobias@codesourcery.com>
6185         * doc/install.texi (amdgcn-*-amdhsa): Fix URL to ROCm;
6186         change 'in the future' to 'in LLVM 18'.
6188 2023-11-24  John David Anglin  <danglin@gcc.gnu.org>
6190         * config/pa/pa.cc (pa_emit_move_sequence): Use INT14_OK_STRICT
6191         in a couple of places.
6193 2023-11-24  Martin Jambor  <mjambor@suse.cz>
6195         PR middle-end/109849
6196         * tree-sra.cc (passed_by_ref_in_call): New.
6197         (sra_initialize): Allocate passed_by_ref_in_call.
6198         (sra_deinitialize): Free passed_by_ref_in_call.
6199         (create_access): Add decl pool candidates only if they are not
6200         already candidates.
6201         (build_access_from_expr_1): Bail out on ADDR_EXPRs.
6202         (build_access_from_call_arg): New function.
6203         (asm_visit_addr): Rename to scan_visit_addr, change the
6204         disqualification dump message.
6205         (scan_function): Check taken addresses for all non-call statements,
6206         including phi nodes.  Process all call arguments, including the static
6207         chain, build_access_from_call_arg.
6208         (maybe_add_sra_candidate): Relax need_to_live_in_memory check to allow
6209         non-escaped local variables.
6210         (sort_and_splice_var_accesses): Disallow smaller-than-precision
6211         replacements for aggregates passed by reference to functions.
6212         (sra_modify_expr): Use a separate stmt iterator for adding satements
6213         before the processed statement and after it.
6214         (enum out_edge_check): New type.
6215         (abnormal_edge_after_stmt_p): New function.
6216         (sra_modify_call_arg): New function.
6217         (sra_modify_assign): Adjust calls to sra_modify_expr.
6218         (sra_modify_function_body): Likewise, use sra_modify_call_arg to
6219         process call arguments, including the static chain.
6221 2023-11-24  Uros Bizjak  <ubizjak@gmail.com>
6223         PR target/112686
6224         * config/i386/i386.cc (ix86_expand_split_stack_prologue): Load
6225         function address to a register for ix86_cmodel == CM_LARGE.
6227 2023-11-24  Tobias Burnus  <tobias@codesourcery.com>
6229         * doc/invoke.texi (-Wopenmp): Add.
6230         * gimplify.cc (gimplify_omp_for): Add OPT_Wopenmp to warning_at.
6231         * omp-expand.cc (expand_omp_ordered_sink): Likewise.
6232         * omp-general.cc (omp_check_context_selector): Likewise.
6233         * omp-low.cc (scan_omp_for, check_omp_nesting_restrictions,
6234         lower_omp_ordered_clauses): Likewise.
6235         * omp-simd-clone.cc (simd_clone_clauses_extract): Likewise.
6237 2023-11-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6239         PR target/112694
6240         * config/riscv/riscv-v.cc (preferred_simd_mode): Allow poly_int (1,1) vectors.
6242 2023-11-24  Alexander Monakov  <amonakov@ispras.ru>
6244         * config.in: Regenerate.
6245         * configure: Regenerate.
6246         * configure.ac: Delete manual checks for old Valgrind headers.
6247         * system.h (VALGRIND_MAKE_MEM_NOACCESS): Delete.
6248         (VALGRIND_MAKE_MEM_DEFINED): Delete.
6249         (VALGRIND_MAKE_MEM_UNDEFINED): Delete.
6250         (VALGRIND_MALLOCLIKE_BLOCK): Delete.
6251         (VALGRIND_FREELIKE_BLOCK): Delete.
6253 2023-11-24  Jakub Jelinek  <jakub@redhat.com>
6255         PR target/112681
6256         * config/i386/i386-expand.cc (ix86_expand_branch): Use
6257         ix86_expand_vector_logical_operator to expand vector XOR rather than
6258         gen_rtx_SET on gen_rtx_XOR.
6260 2023-11-24  Alex Coplan  <alex.coplan@arm.com>
6262         * rtl-ssa/access-utils.h (filter_accesses): New.
6263         (remove_regno_access): New.
6264         (check_remove_regno_access): New.
6265         * rtl-ssa/accesses.cc (rtl_ssa::remove_note_accesses_base): Use
6266         new filter_accesses helper.
6268 2023-11-24  Alex Coplan  <alex.coplan@arm.com>
6270         * rtl-ssa/accesses.cc (function_info::create_set): New.
6271         * rtl-ssa/accesses.h (access_info::is_temporary): New.
6272         * rtl-ssa/changes.cc (move_insn): Handle new (temporary) insns.
6273         (function_info::finalize_new_accesses): Handle new/temporary
6274         user-created accesses.
6275         (function_info::apply_changes_to_insn): Ensure m_is_temp flag
6276         on new insns gets cleared.
6277         (function_info::change_insns): Handle new/temporary insns.
6278         (function_info::create_insn): New.
6279         * rtl-ssa/changes.h (class insn_change): Make function_info a
6280         friend class.
6281         * rtl-ssa/functions.h (function_info): Declare new entry points:
6282         create_set, create_insn.  Declare new change_alloc helper.
6283         * rtl-ssa/insns.cc (insn_info::print_full): Identify temporary insns in
6284         dump.
6285         * rtl-ssa/insns.h (insn_info): Add new m_is_temp flag and accompanying
6286         is_temporary accessor.
6287         * rtl-ssa/internals.inl (insn_info::insn_info): Initialize m_is_temp to
6288         false.
6289         * rtl-ssa/member-fns.inl (function_info::change_alloc): New.
6290         * rtl-ssa/movement.h (restrict_movement_for_defs_ignoring): Add
6291         handling for temporary defs.
6293 2023-11-24  Jakub Jelinek  <jakub@redhat.com>
6295         PR tree-optimization/112673
6296         * match.pd (bit_field_ref (vce @0) -> bit_field_ref @0): Only simplify
6297         if either @0 doesn't have scalar integral type or if it has mode
6298         precision.
6300 2023-11-24  Jakub Jelinek  <jakub@redhat.com>
6302         PR middle-end/112679
6303         * gimple-lower-bitint.cc (gimple_lower_bitint): Also stop first loop on
6304         floating point SSA_NAME set in FLOAT_EXPR assignment from BITINT_TYPE
6305         INTEGER_CST.  Set has_large_huge for those if that BITINT_TYPE is large
6306         or huge.  Set kind to such FLOAT_EXPR assignment rhs1 BITINT_TYPE's kind.
6308 2023-11-24  Richard Biener  <rguenther@suse.de>
6310         PR tree-optimization/112677
6311         * tree-vect-loop.cc (vectorizable_reduction): Use alloca
6312         to allocate vectype_op.
6314 2023-11-24  Haochen Gui  <guihaoc@gcc.gnu.org>
6316         * expr.cc (by_pieces_ninsns): Include by pieces compare when
6317         do the adjustment for overlap operations.  Replace mov_optab
6318         checks with gcc assertion.
6320 2023-11-24  Jakub Jelinek  <jakub@redhat.com>
6322         PR middle-end/112668
6323         * gimple-iterator.h (gsi_end, gsi_end_bb): New inline functions.
6324         * gimple-lower-bitint.cc (bitint_large_huge::handle_cast): After
6325         temporarily adding statements after m_init_gsi, update m_init_gsi
6326         such that later additions after it will be after the added statements.
6327         (bitint_large_huge::handle_load): Likewise.  When splitting
6328         gsi_bb (m_init_gsi) basic block, update m_preheader_bb if needed
6329         and update saved m_gsi as well if needed.
6330         (bitint_large_huge::lower_mergeable_stmt,
6331         bitint_large_huge::lower_comparison_stmt,
6332         bitint_large_huge::lower_mul_overflow,
6333         bitint_large_huge::lower_bit_query): Use gsi_end_bb.
6335 2023-11-24  Jakub Jelinek  <jakub@redhat.com>
6337         PR c++/112619
6338         * tree.cc (try_catch_may_fallthru): If second operand of
6339         TRY_CATCH_EXPR is not a STATEMENT_LIST, handle it as if it was a
6340         STATEMENT_LIST containing a single statement.
6342 2023-11-24  Richard Biener  <rguenther@suse.de>
6344         PR tree-optimization/112344
6345         * tree-chrec.cc (chrec_apply): Only use an unsigned add
6346         when the overall increment doesn't fit the signed type.
6348 2023-11-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6350         PR target/112599
6351         * config/riscv/riscv-v.cc (shuffle_extract_and_slide1up_patterns): New function.
6352         (expand_vec_perm_const_1): Add new optimization.
6354 2023-11-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6356         * config/riscv/riscv-v.cc (shuffle_bswap_pattern): Disable for NUNIT < 4.
6358 2023-11-24  Haochen Jiang  <haochen.jiang@intel.com>
6360         PR target/112643
6361         * config/i386/driver-i386.cc (check_avx10_avx512_features):
6362         Renamed to ...
6363         (check_avx512_features): this and remove avx10 check.
6364         (host_detect_local_cpu): Never append -mno-avx10.1-{256,512} to
6365         avoid emitting warnings when building GCC with native arch.
6366         * config/i386/i386-builtin.def (BDESC): Add missing AVX512VL for
6367         128/256 bit builtin for AVX512VP2INTERSECT.
6368         * config/i386/i386-options.cc (ix86_option_override_internal):
6369         Also check whether the AVX512 flags is set when trying to reset.
6370         * config/i386/i386.h
6371         (PTA_SKYLAKE_AVX512): Add missing PTA_EVEX512.
6372         (PTA_ZNVER4): Ditto.
6374 2023-11-23  Georg-Johann Lay  <avr@gjlay.de>
6376         PR target/86776
6377         * config/avr/avr.cc (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define
6378         to speculation_safe_value_not_needed.
6380 2023-11-23  Marek Polacek  <polacek@redhat.com>
6382         * common.opt (Whardened, fhardened): New options.
6383         * config.in: Regenerate.
6384         * config/bpf/bpf.cc: Include "opts.h".
6385         (bpf_option_override): If flag_stack_protector_set_by_fhardened_p, do
6386         not inform that -fstack-protector does not work.
6387         * config/i386/i386-options.cc (ix86_option_override_internal): When
6388         -fhardened, maybe enable -fcf-protection=full.
6389         * config/linux-protos.h (linux_fortify_source_default_level): Declare.
6390         * config/linux.cc (linux_fortify_source_default_level): New.
6391         * config/linux.h (TARGET_FORTIFY_SOURCE_DEFAULT_LEVEL): Redefine.
6392         * configure: Regenerate.
6393         * configure.ac: Check if the linker supports '-z now' and '-z relro'.
6394         Check if -fhardened is supported on $target_os.
6395         * doc/invoke.texi: Document -fhardened and -Whardened.
6396         * doc/tm.texi: Regenerate.
6397         * doc/tm.texi.in (TARGET_FORTIFY_SOURCE_DEFAULT_LEVEL): Add.
6398         * gcc.cc (driver_handle_option): Remember if any link options or -static
6399         were specified on the command line.
6400         (process_command): When -fhardened, maybe enable -pie and
6401         -Wl,-z,relro,-z,now.
6402         * opts.cc (flag_stack_protector_set_by_fhardened_p): New global.
6403         (finish_options): When -fhardened, enable
6404         -ftrivial-auto-var-init=zero and -fstack-protector-strong.
6405         (print_help_hardened): New.
6406         (print_help): Call it.
6407         * opts.h (flag_stack_protector_set_by_fhardened_p): Declare.
6408         * target.def (fortify_source_default_level): New target hook.
6409         * targhooks.cc (default_fortify_source_default_level): New.
6410         * targhooks.h (default_fortify_source_default_level): Declare.
6411         * toplev.cc (process_options): When -fhardened, enable
6412         -fstack-clash-protection.  If flag_stack_protector_set_by_fhardened_p,
6413         do not warn that -fstack-protector not supported for this target.
6414         Don't enable -fhardened when !HAVE_FHARDENED_SUPPORT.
6416 2023-11-23  Christophe Lyon  <christophe.lyon@linaro.org>
6418         * config/arm/arm-mve-builtins-functions.h
6419         (full_width_access::memory_vector_mode): Add default clause.
6421 2023-11-23  Uros Bizjak  <ubizjak@gmail.com>
6423         PR target/112672
6424         * config/i386/i386.md (parityhi2):
6425         Use temporary register in the call to gen_parityhi2_cmp.
6427 2023-11-23  Uros Bizjak  <ubizjak@gmail.com>
6429         PR target/89316
6430         * config/i386/i386.cc (ix86_expand_split_stack_prologue): Obtain
6431         scratch regno when flag_force_indirect_call is set.  On 64-bit
6432         targets, call __morestack_large_model when  flag_force_indirect_call
6433         is set and on 32-bit targets with -fpic, manually expand PIC sequence
6434         to call __morestack.  Move the function address to an indirect
6435         call scratch register.
6437 2023-11-23  Sebastian Huber  <sebastian.huber@embedded-brains.de>
6439         PR tree-optimization/112678
6440         * tree-profile.cc (tree_profiling): Do not use atomic operations
6441         for -fprofile-update=single.
6443 2023-11-23  Juergen Christ  <jchrist@linux.ibm.com>
6445         * config/s390/s390-c.cc (s390_cpu_cpp_builtins): Define
6446         __GCC_ASM_FLAG_OUTPUTS__.
6447         * config/s390/s390.cc (s390_canonicalize_comparison): More
6448         UNSPEC_CC_TO_INT cases.
6449         (s390_md_asm_adjust): Implement flags output.
6450         * config/s390/s390.md (ccstore4): Allow mask operands.
6451         * doc/extend.texi: Document flags output.
6453 2023-11-23  Juergen Christ  <jchrist@linux.ibm.com>
6455         * config/s390/s390.md: Split TImode loads.
6457 2023-11-23  Juergen Christ  <jchrist@linux.ibm.com>
6459         * config/s390/vector.md: (*vec_extract) Fix.
6461 2023-11-23  Di Zhao  <dizhao@os.amperecomputing.com>
6463         * tree-ssa-reassoc.cc (get_reassociation_width): check
6464         for loop dependent FMAs.
6465         (reassociate_bb): For 3 ops, refine the condition to call
6466         swap_ops_for_binary_stmt.
6468 2023-11-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6470         * config/riscv/riscv-protos.h (emit_vec_extract): New function.
6471         * config/riscv/riscv-v.cc (emit_vec_extract): Ditto.
6472         * config/riscv/riscv.cc (riscv_legitimize_move): Refine codes.
6474 2023-11-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6476         PR target/112599
6477         PR target/112670
6478         * config/riscv/riscv-avlprop.cc (alv_can_be_propagated_p): New function.
6479         (vlmax_ta_p): Disable vrgather AVL propagation.
6481 2023-11-23  Jakub Jelinek  <jakub@redhat.com>
6483         PR middle-end/112336
6484         * expr.cc (EXTEND_BITINT): Don't call reduce_to_bit_field_precision
6485         if modifier is EXPAND_INITIALIZER.
6487 2023-11-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6489         * config/riscv/riscv-v.cc (emit_vlmax_gather_insn): Refine codes.
6490         (emit_vlmax_masked_gather_mu_insn): Ditto.
6491         (modulo_sel_indices): Ditto.
6492         (expand_vec_perm): Ditto.
6493         (shuffle_generic_patterns): Ditto.
6495 2023-11-23  Jakub Jelinek  <jakub@redhat.com>
6497         * doc/extend.texi (__builtin_stdc_bit_ceil, __builtin_stdc_bit_floor,
6498         __builtin_stdc_bit_width, __builtin_stdc_count_ones,
6499         __builtin_stdc_count_zeros, __builtin_stdc_first_leading_one,
6500         __builtin_stdc_first_leading_zero, __builtin_stdc_first_trailing_one,
6501         __builtin_stdc_first_trailing_zero, __builtin_stdc_has_single_bit,
6502         __builtin_stdc_leading_ones, __builtin_stdc_leading_zeros,
6503         __builtin_stdc_trailing_ones, __builtin_stdc_trailing_zeros): Document.
6505 2023-11-23  Richard Biener  <rguenther@suse.de>
6507         PR middle-end/32667
6508         * doc/md.texi (cpymem): Document that exact overlap of source
6509         and destination needs to work.
6510         * doc/standards.texi (ffreestanding): Mention memcpy is required
6511         to handle the exact overlap case.
6513 2023-11-23  Jakub Jelinek  <jakub@redhat.com>
6515         PR c++/110348
6516         * doc/invoke.texi (-Wno-c++26-extensions): Document.
6518 2023-11-23  Manolis Tsamis  <manolis.tsamis@vrull.eu>
6520         * ifcvt.cc (noce_convert_multiple_sets_1): Remove old code.
6522 2023-11-23  Pan Li  <pan2.li@intel.com>
6524         PR target/111720
6525         * dse.cc (get_stored_val): Allow vector mode if read size is
6526         less than or equal to stored size.
6528 2023-11-23  Costas Argyris  <costas.argyris@gmail.com>
6530         * configure.ac: Handle new --enable-win32-utf8-manifest
6531         option.
6532         * config.host: allow win32 utf8 manifest to be disabled
6533         by user.
6534         * configure: Regenerate.
6536 2023-11-22  John David Anglin  <danglin@gcc.gnu.org>
6538         PR target/112592
6539         * config/pa/pa.h (MAX_FIXED_MODE_SIZE): Define.
6541 2023-11-22  John David Anglin  <danglin@gcc.gnu.org>
6543         PR target/112617
6544         * config/pa/predicates.md (integer_store_memory_operand): Return
6545         true for REG+D addresses when reload_in_progress is true.
6547 2023-11-22  Richard Biener  <rguenther@suse.de>
6549         PR tree-optimization/112344
6550         * tree-chrec.cc (chrec_apply): Perform the overall increment
6551         calculation and increment in an unsigned type.
6553 2023-11-22  Andrew Stubbs  <ams@codesourcery.com>
6555         * config/gcn/gcn-valu.md (*mov<mode>_4reg): Disparage AVGPR use when a
6556         reload is required.
6558 2023-11-22  Vladimir N. Makarov  <vmakarov@redhat.com>
6560         PR rtl-optimization/112610
6561         * ira-costs.cc: (find_costs_and_classes): Remove arg.
6562         Use ira_dump_file for printing.
6563         (print_allocno_costs, print_pseudo_costs): Ditto.
6564         (ira_costs): Adjust call of find_costs_and_classes.
6565         (ira_set_pseudo_classes): Set up and restore ira_dump_file.
6567 2023-11-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6569         PR target/112598
6570         * config/riscv/riscv-v.cc (shuffle_compress_patterns): Fix vcompress bug.
6572 2023-11-22  Tamar Christina  <tamar.christina@arm.com>
6574         * config/aarch64/aarch64-simd.md
6575         (aarch64_uaddw<mode>_<PERM_EXTEND:perm_hilo>_zip,
6576         aarch64_usubw<mode>_<PERM_EXTEND:perm_hilo>_zip): Split into...
6577         (aarch64_uaddw<mode>_lo_zip, aarch64_uaddw<mode>_hi_zip,
6578         "aarch64_usubw<mode>_lo_zip, "aarch64_usubw<mode>_hi_zip): ... This.
6579         * config/aarch64/iterators.md (PERM_EXTEND, perm_index): Remove.
6580         (perm_hilo): Remove UNSPEC_ZIP1, UNSPEC_ZIP2.
6582 2023-11-22  Christophe Lyon  <christophe.lyon@linaro.org>
6584         * config/arm/arm-mve-builtins.cc
6585         (function_resolver::infer_pointer_type): Remove spurious line.
6587 2023-11-22  Xi Ruoyao  <xry111@xry111.site>
6589         * config/loongarch/lsx.md (vec_perm<mode:LSX>): Make the
6590         selector VIMODE.
6591         * config/loongarch/loongarch.cc (loongarch_expand_vec_perm):
6592         Use the mode of the selector (instead of the shuffled vector)
6593         for truncating it.  Operate on subregs in the selector mode if
6594         the shuffled vector has a different mode (i. e. it's a
6595         floating-point vector).
6597 2023-11-22  Hongyu Wang  <hongyu.wang@intel.com>
6599         * config/i386/i386.md (push2_di): Adjust operand order for AT&T
6600         syntax.
6601         (pop2_di): Likewise.
6602         (push2p_di): Likewise.
6603         (pop2p_di): Likewise.
6605 2023-11-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6607         PR target/112598
6608         * config/riscv/riscv-v.cc (emit_vlmax_gather_insn): Adapt the priority.
6609         (shuffle_generic_patterns): Fix permutation indice bug.
6610         * config/riscv/vector-iterators.md: Fix VEI16 bug.
6612 2023-11-22  liuhongt  <hongtao.liu@intel.com>
6614         * config/i386/sse.md (cbranch<mode>4): Extend to Vector
6615         HI/QImode.
6617 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6619         PR target/111815
6620         * config/vax/vax.cc (index_term_p): Only accept the index scaler
6621         as the RHS operand to ASHIFT.
6623 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6625         * config/riscv/predicates.md (order_operator): Remove predicate.
6626         * config/riscv/riscv.cc (riscv_rtx_costs): Update accordingly.
6627         * config/riscv/riscv.md (*branch<mode>, *mov<GPR:mode><X:mode>cc)
6628         (cstore<mode>4): Likewise.
6630 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6632         * config/riscv/riscv-protos.h (riscv_expand_float_scc): Add
6633         `invert_ptr' parameter.
6634         * config/riscv/riscv.cc (riscv_emit_float_compare): Add NE
6635         inversion handling.
6636         (riscv_expand_float_scc): Pass `invert_ptr' through to
6637         `riscv_emit_float_compare'.
6638         (riscv_expand_conditional_move): Pass `&invert' to
6639         `riscv_expand_float_scc'.
6640         * config/riscv/riscv.md (add<mode>cc): Likewise.
6642 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6644         * config/riscv/riscv.cc (riscv_emit_float_compare) <NE>: Handle
6645         separately.
6646         <EQ, LE, LT, GE, GT>: Return operands supplied as is.
6647         (riscv_emit_binary): Call `riscv_emit_binary' directly rather
6648         than going through a temporary register for word-mode targets.
6649         (riscv_expand_conditional_branch): Canonicalize the comparison
6650         if not against constant zero.
6652 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6654         * config/riscv/predicates.md (ne_operator): New predicate.
6655         * config/riscv/riscv.cc (riscv_insn_cost): Handle branches on a
6656         floating-point condition.
6657         * config/riscv/riscv.md (@cbranch<mode>4): Rename expander to...
6658         (@cbranch<ANYF:mode>4): ... this.  Only expand the RTX via
6659         `riscv_expand_conditional_branch' for `!signed_order_operator'
6660         operators, otherwise let it through.
6661         (*cbranch<ANYF:mode>4, *cbranch<ANYF:mode>4): New insns and
6662         splitters.
6664 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6666         * config/riscv/riscv.cc (riscv_expand_conditional_move): Don't
6667         bail out in floating-point conditions.
6669 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6671         * config/riscv/riscv.cc (riscv_expand_float_scc): Suppress the
6672         use of SUBREG if the conditional-set target is word-mode.
6674 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6676         * config/riscv/riscv.md (add<mode>cc): New expander.
6678 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6680         * config/riscv/predicates.md (movcc_operand): New predicate.
6681         * config/riscv/riscv.cc (riscv_expand_conditional_move): Handle
6682         generic targets.
6683         * config/riscv/riscv.md (mov<mode>cc): Likewise.
6684         * config/riscv/riscv.opt (mmovcc): New option.
6685         * doc/invoke.texi (Option Summary): Document it.
6687 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6689         * config/riscv/riscv-protos.h (riscv_emit_unary): New prototype.
6690         * config/riscv/riscv.cc (riscv_emit_unary): New function.
6692 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6694         * config/riscv/riscv.cc (riscv_expand_conditional_move): Unify
6695         conditional-move handling across all the relevant targets.
6697 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6699         * config/riscv/riscv.cc (riscv_expand_conditional_move): Also
6700         accept constants for T-Head data input operands.
6702 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6704         * config/riscv/riscv.cc (riscv_expand_conditional_move): Also
6705         accept constants for T-Head comparison operands.
6707 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6709         * config/riscv/riscv.cc (riscv_expand_conditional_move): Remove
6710         the check for operand 1 being constant 0 in the Ventana/Zicond
6711         case for equality comparisons.
6713 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6715         * config/riscv/riscv.cc (riscv_expand_conditional_move): Also
6716         invert the condition for GEU and LEU.
6718 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6720         * config/riscv/riscv.cc (riscv_insn_cost): New function.
6721         (riscv_max_noce_ifcvt_seq_cost): Likewise.
6722         (riscv_noce_conversion_profitable_p): Likewise.
6723         (TARGET_INSN_COST): New macro.
6724         (TARGET_MAX_NOCE_IFCVT_SEQ_COST): New macro.
6725         (TARGET_NOCE_CONVERSION_PROFITABLE_P): New macro.
6727 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6729         * config/riscv/riscv.cc (riscv_expand_conditional_move): Remove
6730         extraneous variable for EQ vs NE operation selection.
6732 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6734         * config/riscv/riscv.cc (riscv_expand_conditional_move): Use
6735         `nullptr' rather than 0 to initialize a pointer.
6737 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6739         * config/riscv/riscv.cc (riscv_expand_conditional_move): Use
6740         `mode0' and `mode1' for `GET_MODE (op0)' and `GET_MODE (op1)'.
6742 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6744         * config/riscv/riscv.cc (riscv_expand_conditional_move): Use
6745         `mode' for `GET_MODE (dest)' throughout.
6747 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6749         * config/riscv/riscv.cc (riscv_emit_int_compare): Bail out if
6750         NEED_EQ_NE_P but the comparison is neither EQ nor NE.
6752 2023-11-22  Maciej W. Rozycki  <macro@embecosm.com>
6754         * config/riscv/riscv.md (mov<mode>cc): Move comment on SFB
6755         patterns over to...
6756         (*mov<GPR:mode><X:mode>cc): ... here.
6758 2023-11-21  Robin Dapp  <rdapp@ventanamicro.com>
6760         PR middle-end/112406
6761         * tree-vect-loop.cc (vectorize_fold_left_reduction): Allow
6762         reduction index != 1.
6763         (vect_transform_reduction): Handle reduction index != 1.
6765 2023-11-21  Richard Sandiford  <richard.sandiford@arm.com>
6767         * common.md (aligned_register_operand): New predicate.
6769 2023-11-21  Richard Sandiford  <richard.sandiford@arm.com>
6771         * ira-int.h (ira_allocno): Add a register_filters field.
6772         (ALLOCNO_REGISTER_FILTERS): New macro.
6773         (ALLOCNO_SET_REGISTER_FILTERS): Likewise.
6774         * ira-build.cc (ira_create_allocno): Initialize register_filters.
6775         (create_cap_allocno): Propagate register_filters.
6776         (propagate_allocno_info): Likewise.
6777         (propagate_some_info_from_allocno): Likewise.
6778         * ira-lives.cc (process_register_constraint_filters): New function.
6779         (process_bb_node_lives): Use it to record register filter
6780         information.
6781         * ira-color.cc (assign_hard_reg): Check register filters.
6782         (improve_allocation, fast_allocation): Likewise.
6784 2023-11-21  Richard Sandiford  <richard.sandiford@arm.com>
6786         * lra-constraints.cc (process_alt_operands): Check register filters.
6788 2023-11-21  Richard Sandiford  <richard.sandiford@arm.com>
6790         * recog.h (operand_alternative): Add a register_filters field.
6791         (alternative_register_filters): New function.
6792         * recog.cc (preprocess_constraints): Calculate the filters field.
6793         (constrain_operands): Check register filters.
6795 2023-11-21  Richard Sandiford  <richard.sandiford@arm.com>
6797         * rtl.def (DEFINE_REGISTER_CONSTRAINT): Add an optional filter
6798         operand.
6799         * doc/md.texi (define_register_constraint): Document it.
6800         * doc/tm.texi.in: Reference it in discussion about aligned registers.
6801         * doc/tm.texi: Regenerate.
6802         * gensupport.h (register_filters, get_register_filter_id): Declare.
6803         * gensupport.cc (register_filter_map, register_filters): New variables.
6804         (get_register_filter_id): New function.
6805         (process_define_register_constraint): Likewise.
6806         (process_rtx): Pass define_register_constraints to
6807         process_define_register_constraint.
6808         * genconfig.cc (main): Emit a definition of NUM_REGISTER_FILTERS.
6809         * genpreds.cc (constraint_data): Add a filter field.
6810         (add_constraint): Update accordingly.
6811         (process_define_register_constraint): Pass the filter operand.
6812         (write_init_reg_class_start_regs): New function.
6813         (write_get_register_filter): Likewise.
6814         (write_get_register_filter_id): Likewise.
6815         (write_tm_preds_h): Write a definition of target_constraints,
6816         plus helpers to test its contents.  Write the get_register_filter*
6817         functions.
6818         (write_insn_preds_c): Write init_reg_class_start_regs.
6819         * reginfo.cc (init_reg_class_start_regs): Declare.
6820         (init_reg_sets): Call it.
6821         * target-globals.h (this_target_constraints): Declare.
6822         (target_globals): Add a constraints field.
6823         (restore_target_globals): Update accordingly.
6824         * target-globals.cc: Include tm_p.h.
6825         (default_target_globals): Initialize the constraints field.
6826         (save_target_globals): Handle the constraints field.
6827         (target_globals::~target_globals): Likewise.
6829 2023-11-21  Richard Biener  <rguenther@suse.de>
6831         PR tree-optimization/112623
6832         * tree-ssa-forwprop.cc (simplify_vector_constructor):
6833         Check the source mode of the insn for vector pack/unpacks.
6835 2023-11-21  Richard Biener  <rguenther@suse.de>
6837         * tree-vect-loop.cc (vect_analyze_loop_2): Move check
6838         of VF against max_vf until VF is final.
6840 2023-11-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
6842         PR target/112598
6843         * config/riscv/riscv.cc (riscv_const_insns): Disallow DI CONST_VECTOR on RV32.
6845 2023-11-21  Tamar Christina  <tamar.christina@arm.com>
6847         * config/aarch64/aarch64.cc (aarch64_override_options): Rework warnings.
6849 2023-11-21  Tamar Christina  <tamar.christina@arm.com>
6851         PR target/111370
6852         * config/aarch64/aarch64-arches.def (armv9-a, armv9.1-a, armv9.2-a,
6853         armv9.3-a): Update to generic-armv9-a.
6854         * config/aarch64/aarch64-cores.def (generic-armv9-a): New.
6855         * config/aarch64/aarch64-tune.md: Regenerate.
6856         * config/aarch64/aarch64.cc: Include generic_armv9_a.h.
6857         * config/aarch64/tuning_models/generic_armv9_a.h: New file.
6859 2023-11-21  Tamar Christina  <tamar.christina@arm.com>
6861         PR target/111370
6862         * config/aarch64/aarch64-arches.def (armv8-9, armv8-a, armv8.1-a,
6863         armv8.2-a, armv8.3-a, armv8.4-a, armv8.5-a, armv8.6-a, armv8.7-a,
6864         armv8.8-a): Update to generic_armv8_a.
6865         * config/aarch64/aarch64-cores.def (generic-armv8-a): New.
6866         * config/aarch64/aarch64-tune.md: Regenerate.
6867         * config/aarch64/aarch64.cc: Include generic_armv8_a.h
6868         * config/aarch64/aarch64.h (TARGET_CPU_DEFAULT): Change to
6869         TARGET_CPU_generic_armv8_a.
6870         * config/aarch64/tuning_models/generic_armv8_a.h: New file.
6872 2023-11-21  Tamar Christina  <tamar.christina@arm.com>
6874         PR target/111370
6875         * config/aarch64/aarch64-cores.def: Add generic.
6876         * config/aarch64/aarch64-opts.h (enum aarch64_proc): Remove generic.
6877         * config/aarch64/aarch64-tune.md: Regenerate
6878         * config/aarch64/aarch64.cc (all_cores): Remove generic
6879         * config/aarch64/aarch64.h (enum target_cpus): Remove
6880         TARGET_CPU_generic.
6882 2023-11-21  Tamar Christina  <tamar.christina@arm.com>
6884         PR target/111370
6885         * config/aarch64/aarch64.cc (generic_addrcost_table,
6886         exynosm1_addrcost_table,
6887         xgene1_addrcost_table,
6888         thunderx2t99_addrcost_table,
6889         thunderx3t110_addrcost_table,
6890         tsv110_addrcost_table,
6891         qdf24xx_addrcost_table,
6892         a64fx_addrcost_table,
6893         neoversev1_addrcost_table,
6894         neoversen2_addrcost_table,
6895         neoversev2_addrcost_table,
6896         generic_regmove_cost,
6897         cortexa57_regmove_cost,
6898         cortexa53_regmove_cost,
6899         exynosm1_regmove_cost,
6900         thunderx_regmove_cost,
6901         xgene1_regmove_cost,
6902         qdf24xx_regmove_cost,
6903         thunderx2t99_regmove_cost,
6904         thunderx3t110_regmove_cost,
6905         tsv110_regmove_cost,
6906         a64fx_regmove_cost,
6907         neoversen2_regmove_cost,
6908         neoversev1_regmove_cost,
6909         neoversev2_regmove_cost,
6910         generic_vector_cost,
6911         a64fx_vector_cost,
6912         qdf24xx_vector_cost,
6913         thunderx_vector_cost,
6914         tsv110_vector_cost,
6915         cortexa57_vector_cost,
6916         exynosm1_vector_cost,
6917         xgene1_vector_cost,
6918         thunderx2t99_vector_cost,
6919         thunderx3t110_vector_cost,
6920         ampere1_vector_cost,
6921         generic_branch_cost,
6922         generic_tunings,
6923         cortexa35_tunings,
6924         cortexa53_tunings,
6925         cortexa57_tunings,
6926         cortexa72_tunings,
6927         cortexa73_tunings,
6928         exynosm1_tunings,
6929         thunderxt88_tunings,
6930         thunderx_tunings,
6931         tsv110_tunings,
6932         xgene1_tunings,
6933         emag_tunings,
6934         qdf24xx_tunings,
6935         saphira_tunings,
6936         thunderx2t99_tunings,
6937         thunderx3t110_tunings,
6938         neoversen1_tunings,
6939         ampere1_tunings,
6940         ampere1a_tunings,
6941         neoversev1_vector_cost,
6942         neoversev1_tunings,
6943         neoverse512tvb_vector_cost,
6944         neoverse512tvb_tunings,
6945         neoversen2_vector_cost,
6946         neoversen2_tunings,
6947         neoversev2_vector_cost,
6948         neoversev2_tunings
6949         a64fx_tunings): Split into own files.
6950         * config/aarch64/tuning_models/a64fx.h: New file.
6951         * config/aarch64/tuning_models/ampere1.h: New file.
6952         * config/aarch64/tuning_models/ampere1a.h: New file.
6953         * config/aarch64/tuning_models/cortexa35.h: New file.
6954         * config/aarch64/tuning_models/cortexa53.h: New file.
6955         * config/aarch64/tuning_models/cortexa57.h: New file.
6956         * config/aarch64/tuning_models/cortexa72.h: New file.
6957         * config/aarch64/tuning_models/cortexa73.h: New file.
6958         * config/aarch64/tuning_models/emag.h: New file.
6959         * config/aarch64/tuning_models/exynosm1.h: New file.
6960         * config/aarch64/tuning_models/generic.h: New file.
6961         * config/aarch64/tuning_models/neoverse512tvb.h: New file.
6962         * config/aarch64/tuning_models/neoversen1.h: New file.
6963         * config/aarch64/tuning_models/neoversen2.h: New file.
6964         * config/aarch64/tuning_models/neoversev1.h: New file.
6965         * config/aarch64/tuning_models/neoversev2.h: New file.
6966         * config/aarch64/tuning_models/qdf24xx.h: New file.
6967         * config/aarch64/tuning_models/saphira.h: New file.
6968         * config/aarch64/tuning_models/thunderx.h: New file.
6969         * config/aarch64/tuning_models/thunderx2t99.h: New file.
6970         * config/aarch64/tuning_models/thunderx3t110.h: New file.
6971         * config/aarch64/tuning_models/thunderxt88.h: New file.
6972         * config/aarch64/tuning_models/tsv110.h: New file.
6973         * config/aarch64/tuning_models/xgene1.h: New file.
6975 2023-11-21  Tamar Christina  <tamar.christina@arm.com>
6977         * config/aarch64/aarch64-simd.md (vec_unpack<su>_lo_<mode,
6978         vec_unpack<su>_lo_<mode): Split into...
6979         (vec_unpacku_lo_<mode, vec_unpacks_lo_<mode,
6980         vec_unpacku_lo_<mode, vec_unpacks_lo_<mode): ...These.
6981         (aarch64_usubw<mode>_<PERM_EXTEND:perm_hilo>_zip): New.
6982         (aarch64_uaddw<mode>_<PERM_EXTEND:perm_hilo>_zip): New.
6983         * config/aarch64/iterators.md (PERM_EXTEND, perm_index): New.
6984         (perm_hilo): Add UNSPEC_ZIP1, UNSPEC_ZIP2.
6986 2023-11-21  Tamar Christina  <tamar.christina@arm.com>
6988         * config/aarch64/aarch64.cc (aarch64_adjust_stmt_cost): Guard mla.
6989         (aarch64_vector_costs::count_ops): Likewise.
6991 2023-11-21  Sebastian Huber  <sebastian.huber@embedded-brains.de>
6993         PR middle-end/112634
6994         * tree-profile.cc (gen_assign_counter_update): Cast the unsigned result type of
6995         __atomic_add_fetch() to the signed counter type.
6996         (gen_counter_update): Fix formatting.
6998 2023-11-21  Jakub Jelinek  <jakub@redhat.com>
7000         * tree-profile.cc (gen_counter_update, tree_profiling): Formatting
7001         fixes.
7003 2023-11-21  Jakub Jelinek  <jakub@redhat.com>
7005         PR middle-end/112639
7006         * builtins.cc (fold_builtin_bit_query): If arg0 has side-effects, arg1
7007         is specified but cleared, call save_expr on arg0.
7009 2023-11-21  Hongyu Wang  <hongyu.wang@intel.com>
7011         * config/i386/i386-expand.h (gen_push): Add default bool
7012         parameter.
7013         (gen_pop): Likewise.
7014         * config/i386/i386-opts.h (enum apx_features): Add apx_ppx, add
7015         it to apx_all.
7016         * config/i386/i386.cc (ix86_emit_restore_reg_using_pop): Add
7017         ppx_p parameter for function declaration.
7018         (gen_push2): Add ppx_p parameter, emit push2p if ppx_p is true.
7019         (gen_push): Likewise.
7020         (ix86_emit_restore_reg_using_pop2): Likewise for pop2p.
7021         (ix86_emit_save_regs): Emit pushp/push2p under TARGET_APX_PPX.
7022         (ix86_emit_restore_reg_using_pop): Add ppx_p, emit popp insn
7023         and adjust cfi when ppx_p is ture.
7024         (ix86_emit_restore_reg_using_pop2): Add ppx_p and parse to its
7025         callee.
7026         (ix86_emit_restore_regs_using_pop2): Likewise.
7027         (ix86_expand_epilogue): Parse TARGET_APX_PPX to
7028         ix86_emit_restore_reg_using_pop.
7029         * config/i386/i386.h (TARGET_APX_PPX): New.
7030         * config/i386/i386.md (UNSPEC_APX_PPX): New unspec.
7031         (pushp_di): New define_insn.
7032         (popp_di): Likewise.
7033         (push2p_di): Likewise.
7034         (pop2p_di): Likewise.
7035         * config/i386/i386.opt: Add apx_ppx enum.
7037 2023-11-21  Richard Biener  <rguenther@suse.de>
7039         PR tree-optimization/111970
7040         * tree-vect-stmts.cc (vectorizable_load): Fix offset calculation
7041         for SLP gather load.
7042         (vectorizable_store): Likewise for SLP scatter store.
7044 2023-11-21  Xi Ruoyao  <xry111@xry111.site>
7046         * config/loongarch/loongarch-def.h (stdint.h): Guard with #if to
7047         exclude it for target libraries.
7048         (loongarch_isa_base_features): Likewise.
7049         (loongarch_isa): Likewise.
7050         (loongarch_abi): Likewise.
7051         (loongarch_target): Likewise.
7052         (loongarch_cpu_default_isa): Likewise.
7054 2023-11-21  liuhongt  <hongtao.liu@intel.com>
7056         PR target/112325
7057         * config/i386/i386-expand.cc (emit_reduc_half): Hanlde
7058         V8QImode.
7059         * config/i386/mmx.md (reduc_<code>_scal_<mode>): New expander.
7060         (reduc_<code>_scal_v4qi): Ditto.
7062 2023-11-20  Marc Poulhiès  <dkm@kataplop.net>
7064         * config/nvptx/nvptx.h (struct machine_function): Fix typo in variadic.
7065         * config/nvptx/nvptx.cc (nvptx_function_arg_advance): Adjust to use fixed name.
7066         (nvptx_declare_function_name): Likewise.
7067         (nvptx_call_args): Likewise.
7068         (nvptx_expand_call): Likewise.
7070 2023-11-20  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7072         * tree-profile.cc (gen_counter_update): Use unshare_expr() for the
7073         counter expression in the second gimple_build_assign().
7075 2023-11-20  Jan Hubicka  <jh@suse.cz>
7077         * cgraph.cc (add_detected_attribute_1): New function.
7078         (cgraph_node::add_detected_attribute): Likewise.
7079         * cgraph.h (cgraph_node::add_detected_attribute): Declare.
7080         * common.opt: Add -Wsuggest-attribute=returns_nonnull.
7081         * doc/invoke.texi: Document new flag.
7082         * gimple-range-fold.cc (fold_using_range::range_of_call):
7083         Use known reutrn value ranges.
7084         * ipa-prop.cc (struct ipa_return_value_summary): New type.
7085         (class ipa_return_value_sum_t): New type.
7086         (ipa_return_value_sum): New summary.
7087         (ipa_record_return_value_range): New function.
7088         (ipa_return_value_range): New function.
7089         * ipa-prop.h (ipa_return_value_range): Declare.
7090         (ipa_record_return_value_range): Declare.
7091         * ipa-pure-const.cc (warn_function_returns_nonnull): New funcion.
7092         * ipa-utils.h (warn_function_returns_nonnull): Declare.
7093         * symbol-summary.h: Fix comment.
7094         * tree-vrp.cc (execute_ranger_vrp): Record return values.
7096 2023-11-20  Richard Biener  <rguenther@suse.de>
7098         PR tree-optimization/112618
7099         * tree-vect-loop.cc (vect_transform_loop_stmt): For not
7100         relevant and unused .MASK_CALL make sure we remove the
7101         scalar stmt.
7103 2023-11-20  Richard Biener  <rguenther@suse.de>
7105         PR tree-optimization/112281
7106         * tree-loop-distribution.cc
7107         (loop_distribution::pg_add_dependence_edges): For = in the
7108         innermost common loop record a partition conflict.
7110 2023-11-20  Richard Biener  <rguenther@suse.de>
7112         PR middle-end/112622
7113         * convert.cc (convert_to_real_1): Use element_precision
7114         where a vector type might appear.  Provide specific
7115         diagnostic for unexpected vector argument.
7117 2023-11-20  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
7119         PR target/112597
7120         * config/riscv/vector-iterators.md: Remove VDEMOTE and VMDEMOTE.
7121         * config/riscv/vector.md: Fix slide1 intermediate mode bug.
7123 2023-11-20  Robin Dapp  <rdapp@ventanamicro.com>
7125         * config/riscv/riscv-v.cc (gather_scatter_valid_offset_mode_p):
7126         Add check for XLEN == 32.
7127         * config/riscv/vector-iterators.md: Change VLS part of the
7128         demote iterator to 2x elements modes
7129         * config/riscv/vector.md: Adjust iterators and insn conditions.
7131 2023-11-20  Christophe Lyon  <christophe.lyon@linaro.org>
7133         * config/arm/arm-mve-builtins-base.cc (vld1_impl, vld1q)
7134         (vst1_impl, vst1q): New.
7135         * config/arm/arm-mve-builtins-base.def (vld1q, vst1q): New.
7136         * config/arm/arm-mve-builtins-base.h (vld1q, vst1q): New.
7137         * config/arm/arm_mve.h
7138         (vld1q): Delete.
7139         (vst1q): Delete.
7140         (vld1q_s8): Delete.
7141         (vld1q_s32): Delete.
7142         (vld1q_s16): Delete.
7143         (vld1q_u8): Delete.
7144         (vld1q_u32): Delete.
7145         (vld1q_u16): Delete.
7146         (vld1q_f32): Delete.
7147         (vld1q_f16): Delete.
7148         (vst1q_f32): Delete.
7149         (vst1q_f16): Delete.
7150         (vst1q_s8): Delete.
7151         (vst1q_s32): Delete.
7152         (vst1q_s16): Delete.
7153         (vst1q_u8): Delete.
7154         (vst1q_u32): Delete.
7155         (vst1q_u16): Delete.
7156         (__arm_vld1q_s8): Delete.
7157         (__arm_vld1q_s32): Delete.
7158         (__arm_vld1q_s16): Delete.
7159         (__arm_vld1q_u8): Delete.
7160         (__arm_vld1q_u32): Delete.
7161         (__arm_vld1q_u16): Delete.
7162         (__arm_vst1q_s8): Delete.
7163         (__arm_vst1q_s32): Delete.
7164         (__arm_vst1q_s16): Delete.
7165         (__arm_vst1q_u8): Delete.
7166         (__arm_vst1q_u32): Delete.
7167         (__arm_vst1q_u16): Delete.
7168         (__arm_vld1q_f32): Delete.
7169         (__arm_vld1q_f16): Delete.
7170         (__arm_vst1q_f32): Delete.
7171         (__arm_vst1q_f16): Delete.
7172         (__arm_vld1q): Delete.
7173         (__arm_vst1q): Delete.
7174         * config/arm/mve.md (mve_vld1q_f<mode>): Rename into ...
7175         (@mve_vld1q_f<mode>): ... this.
7176         (mve_vld1q_<supf><mode>): Rename into ...
7177         (@mve_vld1q_<supf><mode>) ... this.
7178         (mve_vst1q_f<mode>): Rename into ...
7179         (@mve_vst1q_f<mode>): ... this.
7180         (mve_vst1q_<supf><mode>): Rename into ...
7181         (@mve_vst1q_<supf><mode>) ... this.
7183 2023-11-20  Christophe Lyon  <christophe.lyon@linaro.org>
7185         * config/arm/arm-mve-builtins-shapes.cc (load, store): New.
7186         * config/arm/arm-mve-builtins-shapes.h (load, store): New.
7188 2023-11-20  Christophe Lyon  <christophe.lyon@linaro.org>
7190         * config/arm/arm-mve-builtins-functions.h (multi_vector_function)
7191         (full_width_access): New classes.
7192         * config/arm/arm-mve-builtins.cc
7193         (find_type_suffix_for_scalar_type, infer_pointer_type)
7194         (require_pointer_type, get_contiguous_base, add_mem_operand)
7195         (add_fixed_operand, use_contiguous_load_insn)
7196         (use_contiguous_store_insn): New.
7197         * config/arm/arm-mve-builtins.h (memory_vector_mode)
7198         (infer_pointer_type, require_pointer_type, get_contiguous_base)
7199         (add_mem_operand)
7200         (add_fixed_operand, use_contiguous_load_insn)
7201         (use_contiguous_store_insn): New.
7203 2023-11-20  Christophe Lyon  <christophe.lyon@linaro.org>
7205         * config/arm/arm-mve-builtins-shapes.cc (build_const_pointer):
7206         New.
7207         (parse_type): Add support for '_', 'al' and 'as'.
7208         * config/arm/arm-mve-builtins.h (function_instance): Add
7209         memory_scalar_type.
7210         (function_base): Likewise.
7212 2023-11-20  Christophe Lyon  <christophe.lyon@linaro.org>
7214         * config/arm/arm-builtins.cc (arm_init_simd_builtin_types): Fix
7215         initialization of arm_simd_types[].eltype.
7216         * config/arm/arm-mve-builtins.def (DEF_MVE_TYPE): Fix scalar
7217         types.
7219 2023-11-20  Jakub Jelinek  <jakub@redhat.com>
7221         * typeclass.h (enum type_class): Add vector_type_class.
7222         * builtins.cc (type_to_class): Return vector_type_class for
7223         VECTOR_TYPE.
7224         * doc/extend.texi (__builtin_classify_type): Mention bit-precise
7225         integer types and vector types.
7227 2023-11-20  Robin Dapp  <rdapp@ventanamicro.com>
7229         PR middle-end/112406
7230         * tree-vect-patterns.cc (vect_recog_mask_conversion_pattern):
7231         Convert masks for conditional operations as well.
7233 2023-11-20  Jakub Jelinek  <jakub@redhat.com>
7235         PR tree-optimization/90693
7236         * tree-ssa-math-opts.cc (match_single_bit_test): Mark POPCOUNT with
7237         result only used in equality comparison against 1 with direct optab
7238         support as .POPCOUNT call with 2 arguments.
7239         * internal-fn.h (expand_POPCOUNT): Declare.
7240         * internal-fn.def (DEF_INTERNAL_INT_EXT_FN): New macro, document it,
7241         undefine at the end.
7242         (POPCOUNT): Use it instead of DEF_INTERNAL_INT_FN.
7243         * internal-fn.cc (DEF_INTERNAL_INT_EXT_FN): Define to nothing before
7244         inclusion to define expanders.
7245         (expand_POPCOUNT): New function.
7247 2023-11-20  Jakub Jelinek  <jakub@redhat.com>
7249         PR tree-optimization/90693
7250         * tree-ssa-math-opts.cc (match_single_bit_test): New function.
7251         (math_opts_dom_walker::after_dom_children): Call it for EQ_EXPR
7252         and NE_EXPR assignments and GIMPLE_CONDs.
7254 2023-11-20  Jakub Jelinek  <jakub@redhat.com>
7256         * internal-fn.def: Document missing DEF_INTERNAL* macros and make sure
7257         they are all undefined at the end.
7258         * internal-fn.cc (lookup_hilo_internal_fn, lookup_evenodd_internal_fn,
7259         widening_fn_p, get_len_internal_fn): Don't undef DEF_INTERNAL_*FN
7260         macros after inclusion of internal-fn.def.
7262 2023-11-20  Haochen Jiang  <haochen.jiang@intel.com>
7264         * common/config/i386/cpuinfo.h (get_available_features):
7265         Add avx10_set and version and detect avx10.1.
7266         (cpu_indicator_init): Handle avx10.1-512.
7267         * common/config/i386/i386-common.cc
7268         (OPTION_MASK_ISA2_AVX10_1_256_SET): New.
7269         (OPTION_MASK_ISA2_AVX10_1_256_SET): Ditto.
7270         (OPTION_MASK_ISA2_AVX10_1_512_UNSET): Ditto.
7271         (OPTION_MASK_ISA2_AVX10_1_512_UNSET): Ditto.
7272         (OPTION_MASK_ISA2_AVX2_UNSET): Modify for AVX10.1.
7273         (ix86_handle_option): Handle -mavx10.1-256 and -mavx10.1-512.
7274         Add indicator for explicit no-avx512 and no-avx10.1 options.
7275         * common/config/i386/i386-cpuinfo.h (enum processor_features):
7276         Add FEATURE_AVX10_1_256 and FEATURE_AVX10_1_512.
7277         * common/config/i386/i386-isas.h: Add ISA_NAME_TABLE_ENTRY for
7278         AVX10_1_256 and AVX10_1_512.
7279         * config/i386/cpuid.h (bit_AVX10): New.
7280         (bit_AVX10_256): Ditto.
7281         (bit_AVX10_512): Ditto.
7282         * config/i386/driver-i386.cc (check_avx10_avx512_features): New.
7283         (host_detect_local_cpu): Do not append "-mno-" options under
7284         specific scenarios to avoid emitting a warning.
7285         * config/i386/i386-isa.def
7286         (EVEX512): Add DEF_PTA(EVEX512).
7287         (AVX10_1_256): Add DEF_PTA(AVX10_1_256).
7288         (AVX10_1_512): Add DEF_PTA(AVX10_1_512).
7289         * config/i386/i386-options.cc (isa2_opts): Add -mavx10.1-256 and
7290         -mavx10.1-512.
7291         (ix86_function_specific_save): Save explicit no indicator.
7292         (ix86_function_specific_restore): Restore explicit no indicator.
7293         (ix86_valid_target_attribute_inner_p): Handle avx10.1, avx10.1-256 and
7294         avx10.1-512.
7295         (ix86_valid_target_attribute_tree): Handle avx512 function
7296         attributes with avx10.1 command line option.
7297         (ix86_option_override_internal): Handle AVX10.1 options.
7298         * config/i386/i386.h: Add PTA_EVEX512 for AVX512 target
7299         machines.
7300         * config/i386/i386.opt: Add variable ix86_no_avx512_explicit and
7301         ix86_no_avx10_1_explicit, option -mavx10.1, -mavx10.1-256 and
7302         -mavx10.1-512.
7303         * doc/extend.texi: Document avx10.1, avx10.1-256 and avx10.1-512.
7304         * doc/invoke.texi: Document -mavx10.1, -mavx10.1-256 and -mavx10.1-512.
7305         * doc/sourcebuild.texi: Document target avx10.1, avx10.1-256
7306         and avx10.1-512.
7308 2023-11-20  liuhongt  <hongtao.liu@intel.com>
7310         PR target/112325
7311         * config/i386/sse.md (reduc_<code>_scal_<mode>): New expander.
7312         (REDUC_ANY_LOGIC_MODE): New iterator.
7313         (REDUC_PLUS_MODE): Extend to VxHI/SI/DImode.
7314         (REDUC_SSE_PLUS_MODE): Ditto.
7316 2023-11-20  xuli  <xuli1@eswincomputing.com>
7318         PR target/112537
7319         * config/riscv/riscv-opts.h (enum riscv_stringop_strategy_enum): Strategy enum.
7320         * config/riscv/riscv-string.cc (riscv_expand_block_move): Disabled based on options.
7321         (expand_block_move): Ditto.
7322         * config/riscv/riscv.opt: Add -mmemcpy-strategy=.
7324 2023-11-20  Lulu Cheng  <chenglulu@loongson.cn>
7326         * config/loongarch/gnu-user.h (MUSL_ABI_SPEC): Modify suffix.
7328 2023-11-19  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
7330         * config/riscv/riscv-v.cc (emit_vlmax_insn_lra): Optimize constant AVL.
7332 2023-11-19  Philipp Tomsich  <philipp.tomsich@vrull.eu>
7334         * config/riscv/riscv-protos.h (extract_base_offset_in_addr): Prototype.
7335         * config/riscv/riscv.cc (riscv_fusion_pairs): New enum.
7336         (riscv_tune_param): Add fusible_ops field.
7337         (riscv_tune_param_rocket_tune_info): Initialize new field.
7338         (riscv_tune_param_sifive_7_tune_info): Likewise.
7339         (thead_c906_tune_info): Likewise.
7340         (generic_oo_tune_info): Likewise.
7341         (optimize_size_tune_info): Likewise.
7342         (riscv_macro_fusion_p): New function.
7343         (riscv_fusion_enabled_p): Likewise.
7344         (riscv_macro_fusion_pair_p): Likewise.
7345         (TARGET_SCHED_MACRO_FUSION_P): Define.
7346         (TARGET_SCHED_MACRO_FUSION_PAIR_P): Likewise.
7347         (extract_base_offset_in_addr): Moved into riscv.cc from...
7348         * config/riscv/thead.cc: Here.
7349         Co-authored-by: Raphael Zinsly <rzinsly@ventanamicro.com>
7350         Co-authored-by: Jeff Law <jlaw@ventanamicro.com>
7352 2023-11-19  Jeff Law  <jlaw@ventanamicro.com>
7354         * config/c6x/c6x.md (mvilc): Add mode to UNSPEC source.
7355         * config/mips/mips.md (rdhwr_synci_step_<mode>): Likewise.
7356         * config/riscv/riscv.md (riscv_frcsr, riscv_frflags): Likewise.
7357         * config/s390/s390.md (@split_stack_call<mode>): Likewise.
7358         (@split_stack_cond_call<mode>): Likewise.
7359         * config/sh/sh.md (sp_switch_1): Likewise.
7361 2023-11-19  David Malcolm  <dmalcolm@redhat.com>
7363         * diagnostic.h: Include "rich-location.h".
7364         * edit-context.h (class fixit_hint): New forward decl.
7365         * gcc-rich-location.h: Include "rich-location.h".
7366         * genmatch.cc: Likewise.
7367         * pretty-print.h: Likewise.
7369 2023-11-19  David Malcolm  <dmalcolm@redhat.com>
7371         * Makefile.in (CPPLIB_H): Add libcpp/include/rich-location.h.
7372         * coretypes.h (class rich_location): New forward decl.
7374 2023-11-19  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
7376         * config/riscv/riscv-v.cc (expand_tuple_move): Fix bug.
7378 2023-11-19  David Malcolm  <dmalcolm@redhat.com>
7380         PR analyzer/107573
7381         * doc/invoke.texi: Add -Wanalyzer-undefined-behavior-strtok.
7383 2023-11-18  Xi Ruoyao  <xry111@xry111.site>
7385         * config/loongarch/predicates.md (const_call_insn_operand):
7386         Remove buggy "HAVE_AS_SUPPORT_CALL36" conditions.  Change "1" to
7387         "true" to make the coding style consistent.
7389 2023-11-18  Xi Ruoyao  <xry111@xry111.site>
7391         * config/loongarch/genopts/isa-evolution.in: (lam-bh, lamcas):
7392         Add.
7393         * config/loongarch/loongarch-str.h: Regenerate.
7394         * config/loongarch/loongarch.opt: Regenerate.
7395         * config/loongarch/loongarch-cpucfg-map.h: Regenerate.
7396         * config/loongarch/loongarch-cpu.cc
7397         (ISA_BASE_LA64V110_FEATURES): Include OPTION_MASK_ISA_LAM_BH
7398         and OPTION_MASK_ISA_LAMCAS.
7399         * config/loongarch/sync.md (atomic_add<mode:SHORT>): Use
7400         TARGET_LAM_BH instead of ISA_BASE_IS_LA64V110.  Remove empty
7401         lines from assembly output.
7402         (atomic_exchange<mode>_short): Likewise.
7403         (atomic_exchange<mode:SHORT>): Likewise.
7404         (atomic_fetch_add<mode>_short): Likewise.
7405         (atomic_fetch_add<mode:SHORT>): Likewise.
7406         (atomic_cas_value_strong<mode>_amcas): Use TARGET_LAMCAS instead
7407         of ISA_BASE_IS_LA64V110.
7408         (atomic_compare_and_swap<mode>): Likewise.
7409         (atomic_compare_and_swap<mode:GPR>): Likewise.
7410         (atomic_compare_and_swap<mode:SHORT>): Likewise.
7411         * config/loongarch/loongarch.cc (loongarch_asm_code_end): Dump
7412         status if -mlam-bh and -mlamcas if -fverbose-asm.
7414 2023-11-18  Xi Ruoyao  <xry111@xry111.site>
7416         * config/loongarch/loongarch.cc (loongarch_print_operand): Don't
7417         print dbar 0x700 if TARGET_LD_SEQ_SA.
7418         * config/loongarch/sync.md (atomic_load<mode>): Likewise.
7420 2023-11-18  Xi Ruoyao  <xry111@xry111.site>
7422         * config/loongarch/loongarch.md (DIV): New mode iterator.
7423         (<optab:ANY_DIV><mode:GPR>3): Don't expand if TARGET_DIV32.
7424         (<optab:ANY_DIV>di3_fake): Disable if TARGET_DIV32.
7425         (*<optab:ANY_DIV><mode:GPR>3): Allow SImode if TARGET_DIV32.
7426         (<optab:ANY_DIV>si3_extended): New insn if TARGET_DIV32.
7428 2023-11-18  Xi Ruoyao  <xry111@xry111.site>
7430         * config/loongarch/loongarch-def.h:
7431         (loongarch_isa_base_features): Declare.  Define it in ...
7432         * config/loongarch/loongarch-cpu.cc
7433         (loongarch_isa_base_features): ... here.
7434         (fill_native_cpu_config): If we know the base ISA of the CPU
7435         model from PRID, use it instead of la64 (v1.0).  Check if all
7436         expected features of this base ISA is available, emit a warning
7437         if not.
7438         * config/loongarch/loongarch-opts.cc (config_target_isa): Enable
7439         the features implied by the base ISA if not -march=native.
7441 2023-11-18  Xi Ruoyao  <xry111@xry111.site>
7443         * config/loongarch/genopts/isa-evolution.in: New data file.
7444         * config/loongarch/genopts/genstr.sh: Translate info in
7445         isa-evolution.in when generating loongarch-str.h, loongarch.opt,
7446         and loongarch-cpucfg-map.h.
7447         * config/loongarch/genopts/loongarch.opt.in (isa_evolution):
7448         New variable.
7449         * config/loongarch/t-loongarch: (loongarch-cpucfg-map.h): New
7450         rule.
7451         (loongarch-str.h): Depend on isa-evolution.in.
7452         (loongarch.opt): Depend on isa-evolution.in.
7453         (loongarch-cpu.o): Depend on loongarch-cpucfg-map.h.
7454         * config/loongarch/loongarch-str.h: Regenerate.
7455         * config/loongarch/loongarch-def.h (loongarch_isa):  Add field
7456         for evolution features.  Add helper function to enable features
7457         in this field.
7458         Probe native CPU capability and save the corresponding options
7459         into preset.
7460         * config/loongarch/loongarch-cpu.cc (fill_native_cpu_config):
7461         Probe native CPU capability and save the corresponding options
7462         into preset.
7463         (cache_cpucfg): Simplify with C++11-style for loop.
7464         (cpucfg_useful_idx, N_CPUCFG_WORDS): Move to ...
7465         * config/loongarch/loongarch.cc
7466         (loongarch_option_override_internal): Enable the ISA evolution
7467         feature options implied by -march and not explicitly disabled.
7468         (loongarch_asm_code_end): New function, print ISA information as
7469         comments in the assembly if -fverbose-asm.  It makes easier to
7470         debug things like -march=native.
7471         (TARGET_ASM_CODE_END): Define.
7472         * config/loongarch/loongarch.opt: Regenerate.
7473         * config/loongarch/loongarch-cpucfg-map.h: Generate.
7474         (cpucfg_useful_idx, N_CPUCFG_WORDS) ... here.
7476 2023-11-18  Xi Ruoyao  <xry111@xry111.site>
7478         * config/loongarch/genopts/loongarch-strings:
7479         (STR_ISA_BASE_LA64V110): Add.
7480         * config/loongarch/genopts/loongarch.opt.in:
7481         (ISA_BASE_LA64V110): Add.
7482         * config/loongarch/loongarch-def.c
7483         (loongarch_isa_base_strings): Initialize [ISA_BASE_LA64V110]
7484         to STR_ISA_BASE_LA64V110.
7485         * config/loongarch/loongarch.opt: Regenerate.
7486         * config/loongarch/loongarch-str.h: Regenerate.
7488 2023-11-18  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7490         * doc/invoke.texi (-fprofile-update): Clarify default method.  Document
7491         the atomic method behaviour.
7492         * tree-profile.cc (enum counter_update_method): New.
7493         (counter_update): Likewise.
7494         (gen_counter_update): Use counter_update_method.  Split the
7495         atomic counter update in two 32-bit atomic operations if
7496         necessary.
7497         (tree_profiling): Select counter_update_method.
7499 2023-11-18  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7501         * tree-profile.cc (gen_assign_counter_update): New.
7502         (gen_counter_update): Likewise.
7503         (gimple_gen_edge_profiler): Use gen_counter_update().
7504         (gimple_gen_time_profiler): Likewise.
7506 2023-11-18  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7508         * config/rtems.h (TARGET_HAVE_LIBATOMIC): Define.
7509         * doc/tm.texi: Regenerate.
7510         * doc/tm.texi.in (TARGET_HAVE_LIBATOMIC): Add.
7511         * target.def (have_libatomic): New.
7513 2023-11-18  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7515         Revert:
7516         2023-11-18  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7518         * config/sparc/rtemself.h (SPARC_GCOV_TYPE_SIZE): Define.
7519         * config/sparc/sparc.c (sparc_gcov_type_size): New.
7520         (TARGET_GCOV_TYPE_SIZE): Redefine if SPARC_GCOV_TYPE_SIZE is defined.
7521         * coverage.c (get_gcov_type): Use targetm.gcov_type_size().
7522         * doc/tm.texi (TARGET_GCOV_TYPE_SIZE): Add hook under "Misc".
7523         * doc/tm.texi.in: Regenerate.
7524         * target.def (gcov_type_size): New target hook.
7525         * targhooks.c (default_gcov_type_size): New.
7526         * targhooks.h (default_gcov_type_size): Declare.
7527         * tree-profile.c (gimple_gen_edge_profiler): Use precision of
7528         gcov_type_node.
7529         (gimple_gen_time_profiler): Likewise.
7531 2023-11-18  Kito Cheng  <kito.cheng@sifive.com>
7533         * config/riscv/riscv-target-attr.cc
7534         (riscv_target_attr_parser::parse_arch): Use char[] for
7535         std::unique_ptr to prevent mismatched new delete issue.
7536         (riscv_process_one_target_attr): Ditto.
7537         (riscv_process_target_attr): Ditto.
7539 2023-11-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
7541         * config/riscv/vector-iterators.md: Refactor iterators.
7543 2023-11-18  Lulu Cheng  <chenglulu@loongson.cn>
7545         * config/loongarch/sync.md (atomic_load<mode>): New template.
7547 2023-11-18  Lulu Cheng  <chenglulu@loongson.cn>
7549         * config/loongarch/loongarch-def.h: Add comments.
7550         * config/loongarch/loongarch-opts.h (ISA_BASE_IS_LA64V110): Define macro.
7551         * config/loongarch/loongarch.cc (loongarch_memmodel_needs_rel_acq_fence):
7552         Remove redundant code implementations.
7553         * config/loongarch/sync.md (d): Added QI, HI support.
7554         (atomic_add<mode>): New template.
7555         (atomic_exchange<mode>_short): Likewise.
7556         (atomic_cas_value_strong<mode>_amcas): Likewise..
7557         (atomic_fetch_add<mode>_short): Likewise.
7559 2023-11-18  Lulu Cheng  <chenglulu@loongson.cn>
7561         * config.gcc: Support LA664.
7562         * config/loongarch/genopts/loongarch-strings: Likewise.
7563         * config/loongarch/genopts/loongarch.opt.in: Likewise.
7564         * config/loongarch/loongarch-cpu.cc (fill_native_cpu_config): Likewise.
7565         * config/loongarch/loongarch-def.c: Likewise.
7566         * config/loongarch/loongarch-def.h (N_ISA_BASE_TYPES): Likewise.
7567         (ISA_BASE_LA64V110): Define macro.
7568         (N_ARCH_TYPES): Update value.
7569         (N_TUNE_TYPES): Update value.
7570         (CPU_LA664): New macro.
7571         * config/loongarch/loongarch-opts.cc (isa_default_abi): Likewise.
7572         (isa_base_compat_p): Likewise.
7573         * config/loongarch/loongarch-opts.h (TARGET_64BIT): This parameter is enabled
7574         when la_target.isa.base is equal to ISA_BASE_LA64V100 or ISA_BASE_LA64V110.
7575         (TARGET_uARCH_LA664): Define macro.
7576         * config/loongarch/loongarch-str.h (STR_CPU_LA664): Likewise.
7577         * config/loongarch/loongarch.cc (loongarch_cpu_sched_reassociation_width):
7578         Add LA664 support.
7579         * config/loongarch/loongarch.opt: Regenerate.
7581 2023-11-18  Lulu Cheng  <chenglulu@loongson.cn>
7582             Xi Ruoyao  <xry111@xry111.site>
7584         * config.in: Regenerate.
7585         * config/loongarch/loongarch-opts.h (HAVE_AS_SUPPORT_CALL36): Define macro.
7586         * config/loongarch/loongarch.cc (loongarch_legitimize_call_address):
7587         If binutils supports call36, the function call is not split over expand.
7588         * config/loongarch/loongarch.md: Add call36 generation code.
7589         * config/loongarch/predicates.md: Likewise.
7590         * configure: Regenerate.
7591         * configure.ac: Check whether binutils supports call36.
7593 2023-11-18  David Malcolm  <dmalcolm@redhat.com>
7595         PR analyzer/106147
7596         * Makefile.in (ANALYZER_OBJS): Add analyzer/infinite-loop.o.
7597         * doc/invoke.texi: Add -fdump-analyzer-infinite-loop and
7598         -Wanalyzer-infinite-loop.  Add missing CWE link for
7599         -Wanalyzer-infinite-recursion.
7600         * timevar.def (TV_ANALYZER_INFINITE_LOOPS): New.
7602 2023-11-17  Robin Dapp  <rdapp@ventanamicro.com>
7604         PR middle-end/112406
7605         PR middle-end/112552
7606         * tree-vect-loop.cc (vect_transform_reduction): Pass truth
7607         vectype for mask operand.
7609 2023-11-17  Jakub Jelinek  <jakub@redhat.com>
7611         PR c++/107571
7612         * gimplify.cc (expand_FALLTHROUGH_r): Use wi->removed_stmt after
7613         gsi_remove, change the way of passing fallthrough stmt at the end
7614         of sequence to expand_FALLTHROUGH.  Diagnose IFN_FALLTHROUGH
7615         with GF_CALL_NOTHROW flag.
7616         (expand_FALLTHROUGH): Change loc into array of 2 location_t elts,
7617         don't test wi.callback_result, instead check whether first
7618         elt is not UNKNOWN_LOCATION and in that case pedwarn with the
7619         second location.
7620         * gimple-walk.cc (walk_gimple_seq_mod): Clear wi->removed_stmt
7621         after the flag has been used.
7622         * internal-fn.def (FALLTHROUGH): Mention in comment the special
7623         meaning of the TREE_NOTHROW/GF_CALL_NOTHROW flag on the calls.
7625 2023-11-17  Jakub Jelinek  <jakub@redhat.com>
7627         PR tree-optimization/112566
7628         PR tree-optimization/83171
7629         * match.pd (ctz(ext(X)) -> ctz(X), popcount(zext(X)) -> popcount(X),
7630         parity(ext(X)) -> parity(X), ffs(ext(X)) -> ffs(X)): New
7631         simplifications.
7632         ( __builtin_ffs (X) == 0 -> X == 0): Use FFS rather than
7633         BUILT_IN_FFS BUILT_IN_FFSL BUILT_IN_FFSLL BUILT_IN_FFSIMAX.
7635 2023-11-17  Jakub Jelinek  <jakub@redhat.com>
7637         PR tree-optimization/112374
7638         * tree-vect-loop.cc (check_reduction_path): Perform the cond_fn_p
7639         special case only if op_use_stmt == use_stmt, use as_a rather than
7640         dyn_cast in that case.
7642 2023-11-17  Richard Biener  <rguenther@suse.de>
7644         Revert:
7645         2023-11-14  Richard Biener  <rguenther@suse.de>
7647         PR tree-optimization/112281
7648         * tree-loop-distribution.cc (pg_add_dependence_edges):
7649         Preserve stmt order when the innermost loop has exact
7650         overlap.
7652 2023-11-17  Georg-Johann Lay  <avr@gjlay.de>
7654         PR target/53372
7655         * config/avr/avr.cc (avr_asm_named_section) [AVR_SECTION_PROGMEM]:
7656         Only return some .progmem*.data section if the user did not
7657         specify a section attribute.
7658         (avr_section_type_flags) [avr_progmem_p]: Unset SECTION_NOTYPE
7659         in returned section flags.
7661 2023-11-17  Xi Ruoyao  <xry111@xry111.site>
7663         * config/loongarch/lsx.md (copysign<mode>3): Allow operand[2] to
7664         be an reg_or_vector_same_val_operand.  If it's a const vector
7665         with same negative elements, expand the copysign with a bitset
7666         instruction.  Otherwise, force it into an register.
7667         * config/loongarch/lasx.md (copysign<mode>3): Likewise.
7669 2023-11-17  Haochen Gui  <guihaoc@gcc.gnu.org>
7671         PR target/111449
7672         * config/rs6000/vsx.md (*vsx_le_mem_to_mem_mov_ti): New.
7674 2023-11-17  Haochen Gui  <guihaoc@gcc.gnu.org>
7676         PR target/111449
7677         * config/rs6000/altivec.md (cbranchv16qi4): New expand pattern.
7678         * config/rs6000/rs6000.cc (rs6000_generate_compare): Generate
7679         insn sequence for V16QImode equality compare.
7680         * config/rs6000/rs6000.h (MOVE_MAX_PIECES): Define.
7681         (STORE_MAX_PIECES): Define.
7683 2023-11-17  Li Wei  <liwei@loongson.cn>
7685         * config/loongarch/loongarch.h (CLZ_DEFINED_VALUE_AT_ZERO):
7686         Implement.
7687         (CTZ_DEFINED_VALUE_AT_ZERO): Same.
7689 2023-11-17  Richard Biener  <rguenther@suse.de>
7691         * dwarf2out.cc (add_AT_die_ref): Assert we do not add
7692         a self-ref DW_AT_abstract_origin or DW_AT_specification.
7694 2023-11-17  Jiahao Xu  <xujiahao@loongson.cn>
7696         * config/loongarch/loongarch.cc
7697         (loongarch_builtin_vectorization_cost): Adjust.
7699 2023-11-16  Andrew Pinski  <pinskia@gmail.com>
7701         PR rtl-optimization/112483
7702         * simplify-rtx.cc (simplify_binary_operation_1) <case COPYSIGN>:
7703         Call simplify_unary_operation for NEG instead of
7704         simplify_gen_unary.
7706 2023-11-16  Edwin Lu  <ewlu@rivosinc.com>
7708         PR target/111557
7709         * config/riscv/riscv-c.cc (riscv_cpu_cpp_builtins): update macro name
7711 2023-11-16  Uros Bizjak  <ubizjak@gmail.com>
7713         PR target/78904
7714         * config/i386/i386.md (*addqi_ext2<mode>_0):
7715         New define_insn_and_split pattern.
7716         (*subqi_ext2<mode>_0): Ditto.
7717         (*<code>qi_ext2<mode>_0): Ditto.
7719 2023-11-16  John David Anglin  <danglin@gcc.gnu.org>
7721         PR rtl-optimization/112415
7722         * config/pa/pa.cc (pa_legitimate_address_p): Allow 14-bit
7723         displacements before reload.  Simplify logic flow.  Revise
7724         comments.
7725         * config/pa/pa.h (TARGET_ELF64): New define.
7726         (INT14_OK_STRICT): Update define and comment.
7727         * config/pa/pa64-linux.h (TARGET_ELF64): Define.
7728         * config/pa/predicates.md (base14_operand): Don't check
7729         alignment of short displacements.
7730         (integer_store_memory_operand): Don't return true when
7731         reload_in_progress is true.  Remove INT_5_BITS check.
7732         (floating_point_store_memory_operand): Don't return true when
7733         reload_in_progress is true.  Use INT14_OK_STRICT to check
7734         whether long displacements are always okay.
7736 2023-11-16  Uros Bizjak  <ubizjak@gmail.com>
7738         PR target/112567
7739         * config/i386/i386.md (*<any_logic:code>qi_ext<mode>_1_slp):
7740         Fix generation of invalid RTX in split pattern.
7742 2023-11-16  David Malcolm  <dmalcolm@redhat.com>
7744         * diagnostic.cc (diagnostic_context::set_option_hooks): Add
7745         "lang_mask" param.
7746         * diagnostic.h (diagnostic_context::option_enabled_p): Update for
7747         move of m_lang_mask.
7748         (diagnostic_context::set_option_hooks): Add "lang_mask" param.
7749         (diagnostic_context::get_lang_mask): New.
7750         (diagnostic_context::m_lang_mask): Move into m_option_callbacks,
7751         thus making private.
7752         * lto-wrapper.cc (main): Update for new lang_mask param of
7753         set_option_hooks.
7754         * toplev.cc (init_asm_output): Use get_lang_mask.
7755         (general_init): Move initialization of global_dc's lang_mask to
7756         new lang_mask param of set_option_hooks.
7758 2023-11-16  Tamar Christina  <tamar.christina@arm.com>
7760         PR tree-optimization/111878
7761         * tree-vect-loop-manip.cc (find_loop_location): Skip edges check if
7762         latch incorrect.
7764 2023-11-16  Kito Cheng  <kito.cheng@sifive.com>
7766         * config.gcc (riscv): Add riscv-target-attr.o.
7767         * config/riscv/riscv-protos.h (riscv_declare_function_size) New.
7768         (riscv_option_valid_attribute_p): New.
7769         (riscv_override_options_internal): New.
7770         (struct riscv_tune_info): New.
7771         (riscv_parse_tune): New.
7772         * config/riscv/riscv-target-attr.cc
7773         (class riscv_target_attr_parser): New.
7774         (struct riscv_attribute_info): New.
7775         (riscv_attributes): New.
7776         (riscv_target_attr_parser::parse_arch): New.
7777         (riscv_target_attr_parser::handle_arch): New.
7778         (riscv_target_attr_parser::handle_cpu): New.
7779         (riscv_target_attr_parser::handle_tune): New.
7780         (riscv_target_attr_parser::update_settings): New.
7781         (riscv_process_one_target_attr): New.
7782         (num_occurences_in_str): New.
7783         (riscv_process_target_attr): New.
7784         (riscv_option_valid_attribute_p): New.
7785         * config/riscv/riscv.cc: Include target-globals.h and
7786         riscv-subset.h.
7787         (struct riscv_tune_info): Move to riscv-protos.h.
7788         (get_tune_str): New.
7789         (riscv_parse_tune): New parameter null_p.
7790         (riscv_declare_function_size): New.
7791         (riscv_option_override): Build target_option_default_node and
7792         target_option_current_node.
7793         (riscv_save_restore_target_globals): New.
7794         (riscv_option_restore): New.
7795         (riscv_previous_fndecl): New.
7796         (riscv_set_current_function): Apply the target attribute.
7797         (TARGET_OPTION_RESTORE): Define.
7798         (TARGET_OPTION_VALID_ATTRIBUTE_P): Ditto.
7799         * config/riscv/riscv.h (SWITCHABLE_TARGET): Define to 1.
7800         (ASM_DECLARE_FUNCTION_SIZE) Define.
7801         * config/riscv/riscv.opt (mtune=): Add Save attribute.
7802         (mcpu=): Ditto.
7803         (mcmodel=): Ditto.
7804         * config/riscv/t-riscv: Add build rule for riscv-target-attr.o
7805         * doc/extend.texi: Add doc for target attribute.
7807 2023-11-16  Kito Cheng  <kito.cheng@sifive.com>
7809         PR target/112478
7810         * config/riscv/riscv.cc (riscv_save_return_addr_reg_p): Check ra
7811         is ever lived.
7813 2023-11-16  liuhongt  <hongtao.liu@intel.com>
7815         PR target/112532
7816         * config/i386/mmx.md (*vec_dup<mode>): Extend for V4HI and
7817         V2HI.
7819 2023-11-16  Jakub Jelinek  <jakub@redhat.com>
7821         PR target/112526
7822         * config/i386/i386.md
7823         (mov imm,%rax; mov %rdi,%rdx; mulx %rax -> mov imm,%rdx; mulx %rdi):
7824         Verify in define_peephole2 that operands[2] dies or is overwritten
7825         at the end of multiplication.
7827 2023-11-16  Jakub Jelinek  <jakub@redhat.com>
7829         PR tree-optimization/112536
7830         * tree-vect-slp.cc (arg0_map): New variable.
7831         (vect_get_operand_map): For IFN_CLZ or IFN_CTZ, return arg0_map.
7833 2023-11-16  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
7835         PR middle-end/112554
7836         * tree-vect-loop.cc (vect_determine_partial_vectors_and_peeling):
7837         Clear SELECT_VL_P for non-partial vectorization.
7839 2023-11-16  Hongyu Wang  <hongyu.wang@intel.com>
7841         * config/i386/sse.md (vec_extract_hi_<mode>): Add noavx512vl
7842         alternative with attr addr gpr16 and "jm" constraint.
7843         (vec_extract_hi_<mode>): Likewise for SF vector modes.
7844         (@vec_extract_hi_<mode>): Likewise.
7845         (*vec_extractv2ti): Likewise.
7846         (vec_set_hi_<mode><mask_name>): Likewise.
7847         * config/i386/mmx.md (@sse4_1_insertps_<mode>): Correct gpr16 attr for
7848         each alternative.
7850 2023-11-15  Uros Bizjak  <ubizjak@gmail.com>
7852         PR target/78904
7853         * config/i386/i386.md (*movstrictqi_ext<mode>_1): New insn pattern.
7854         (*addqi_ext<mode>_2_slp): New define_insn_and_split pattern.
7855         (*subqi_ext<mode>_2_slp): Ditto.
7856         (*<any_logic:code>qi_ext<mode>_2_slp): Ditto.
7858 2023-11-15  Patrick O'Neill  <patrick@rivosinc.com>
7860         * common/config/riscv/riscv-common.cc
7861         (riscv_subset_list::parse_std_ext): Emit an error and skip to
7862         the next extension when a non-canonical ordering is detected.
7864 2023-11-15  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
7866         * gcc-rich-location.cc (maybe_range_label_for_tree_type_mismatch::get_text):
7867         Revert using the macro CAN_HAVE_LOCATION_P.
7869 2023-11-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
7871         PR target/112447
7872         * config/riscv/riscv-vsetvl.cc (pre_vsetvl::emit_vsetvl): Insert
7873         local vsetvl info before LCM suggested one.
7874         Tested-by: Patrick O'Neill <patrick@rivosinc.com> # pre-commit-CI #679
7875         Co-developed-by: Vineet Gupta <vineetg@rivosinc.com>
7877 2023-11-15  Vineet Gupta  <vineetg@rivosinc.com>
7879         * config/riscv/riscv.cc (riscv_sign_extend_if_not_subreg_prom): New.
7880         * (riscv_extend_comparands): Call New function on operands.
7882 2023-11-15  Uros Bizjak  <ubizjak@gmail.com>
7884         * config/i386/i386.md (*addqi_ext<mode>_1_slp):
7885         Add "&& " before "reload_completed" in split condition.
7886         (*subqi_ext<mode>_1_slp): Ditto.
7887         (*<any_logic:code>qi_ext<mode>_1_slp): Ditto.
7889 2023-11-15  Uros Bizjak  <ubizjak@gmail.com>
7891         PR target/112540
7892         * config/i386/i386.md (*addqi_ext<mode>_1_slp):
7893         Correct operand numbers in split pattern.  Replace !Q constraint
7894         of operand 1 with !qm.  Add insn constrain.
7895         (*subqi_ext<mode>_1_slp): Ditto.
7896         (*<any_logic:code>qi_ext<mode>_1_slp): Ditto.
7898 2023-11-15  Thomas Schwinge  <thomas@codesourcery.com>
7900         * doc/extend.texi (Nvidia PTX Built-in Functions): Fix
7901         copy'n'paste-o in '__builtin_nvptx_brev' description.
7903 2023-11-15  Roger Sayle  <roger@nextmovesoftware.com>
7904             Thomas Schwinge  <thomas@codesourcery.com>
7906         * config/nvptx/nvptx.md (UNSPEC_BITREV): Delete.
7907         (bitrev<mode>2): Represent using bitreverse.
7909 2023-11-15  Andrew Stubbs  <ams@codesourcery.com>
7910             Andrew Jenner   <andrew@codesourcery.com>
7912         * config/gcn/constraints.md: Add "a" AVGPR constraint.
7913         * config/gcn/gcn-valu.md (*mov<mode>): Add AVGPR alternatives.
7914         (*mov<mode>_4reg): Likewise.
7915         (@mov<mode>_sgprbase): Likewise.
7916         (gather<mode>_insn_1offset<exec>): Likewise.
7917         (gather<mode>_insn_1offset_ds<exec>): Likewise.
7918         (gather<mode>_insn_2offsets<exec>): Likewise.
7919         (scatter<mode>_expr<exec_scatter>): Likewise.
7920         (scatter<mode>_insn_1offset_ds<exec_scatter>): Likewise.
7921         (scatter<mode>_insn_2offsets<exec_scatter>): Likewise.
7922         * config/gcn/gcn.cc (MAX_NORMAL_AVGPR_COUNT): Define.
7923         (gcn_class_max_nregs): Handle AVGPR_REGS and ALL_VGPR_REGS.
7924         (gcn_hard_regno_mode_ok): Likewise.
7925         (gcn_regno_reg_class): Likewise.
7926         (gcn_spill_class): Allow spilling to AVGPRs on TARGET_CDNA1_PLUS.
7927         (gcn_sgpr_move_p): Handle AVGPRs.
7928         (gcn_secondary_reload): Reload AVGPRs via VGPRs.
7929         (gcn_conditional_register_usage): Handle AVGPRs.
7930         (gcn_vgpr_equivalent_register_operand): New function.
7931         (gcn_valid_move_p): Check for validity of AVGPR moves.
7932         (gcn_compute_frame_offsets): Handle AVGPRs.
7933         (gcn_memory_move_cost): Likewise.
7934         (gcn_register_move_cost): Likewise.
7935         (gcn_vmem_insn_p): Handle TYPE_VOP3P_MAI.
7936         (gcn_md_reorg): Handle AVGPRs.
7937         (gcn_hsa_declare_function_name): Likewise.
7938         (print_reg): Likewise.
7939         (gcn_dwarf_register_number): Likewise.
7940         * config/gcn/gcn.h (FIRST_AVGPR_REG): Define.
7941         (AVGPR_REGNO): Define.
7942         (LAST_AVGPR_REG): Define.
7943         (SOFT_ARG_REG): Update.
7944         (FRAME_POINTER_REGNUM): Update.
7945         (DWARF_LINK_REGISTER): Update.
7946         (FIRST_PSEUDO_REGISTER): Update.
7947         (AVGPR_REGNO_P): Define.
7948         (enum reg_class): Add AVGPR_REGS and ALL_VGPR_REGS.
7949         (REG_CLASS_CONTENTS): Add new register classes and add entries for
7950         AVGPRs to all classes.
7951         (REGISTER_NAMES): Add AVGPRs.
7952         * config/gcn/gcn.md (FIRST_AVGPR_REG, LAST_AVGPR_REG): Define.
7953         (AP_REGNUM, FP_REGNUM): Update.
7954         (define_attr "type"): Add vop3p_mai.
7955         (define_attr "unit"): Handle vop3p_mai.
7956         (define_attr "gcn_version"): Add "cdna2".
7957         (define_attr "enabled"): Handle cdna2.
7958         (*mov<mode>_insn): Add AVGPR alternatives.
7959         (*movti_insn): Likewise.
7960         * config/gcn/mkoffload.cc (isa_has_combined_avgprs): New.
7961         (process_asm): Process avgpr_count.
7962         * config/gcn/predicates.md (gcn_avgpr_register_operand): New.
7963         (gcn_avgpr_hard_register_operand): New.
7964         * doc/md.texi: Document the "a" constraint.
7966 2023-11-15  Andrew Stubbs  <ams@codesourcery.com>
7968         * config/gcn/gcn-valu.md (mov<mode>_sgprbase): Add @ modifier.
7969         (reload_in<mode>): Delete.
7970         (reload_out<mode>): Delete.
7971         * config/gcn/gcn.cc (CODE_FOR): Delete.
7972         (get_code_for_##PREFIX##vN##SUFFIX): Delete.
7973         (CODE_FOR_OP): Delete.
7974         (get_code_for_##PREFIX): Delete.
7975         (gcn_secondary_reload): Replace "get_code_for" with "code_for".
7977 2023-11-15  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
7979         * config/s390/t-s390: Generate s390-gen-builtins.h without
7980         linemarkers.
7982 2023-11-15  Richard Biener  <rguenther@suse.de>
7984         PR tree-optimization/112282
7985         * tree-if-conv.cc (ifcvt_hoist_invariants): Only hoist from
7986         the loop header.
7988 2023-11-15  Richard Biener  <rguenther@suse.de>
7990         * tree-vect-slp.cc (vect_slp_region): Also clear visited flag when
7991         we skipped an instance due to -fdbg-cnt.
7993 2023-11-15  Xi Ruoyao  <xry111@xry111.site>
7995         * config/loongarch/loongarch.cc
7996         (loongarch_memmodel_needs_release_fence): Remove.
7997         (loongarch_cas_failure_memorder_needs_acquire): New static
7998         function.
7999         (loongarch_print_operand): Redefine 'G' for the barrier on CAS
8000         failure.
8001         * config/loongarch/sync.md (atomic_cas_value_strong<mode>):
8002         Remove the redundant barrier before the LL instruction, and
8003         emit an acquire barrier on failure if needed by
8004         failure_memorder.
8005         (atomic_cas_value_cmp_and_7_<mode>): Likewise.
8006         (atomic_cas_value_add_7_<mode>): Remove the unnecessary barrier
8007         before the LL instruction.
8008         (atomic_cas_value_sub_7_<mode>): Likewise.
8009         (atomic_cas_value_and_7_<mode>): Likewise.
8010         (atomic_cas_value_xor_7_<mode>): Likewise.
8011         (atomic_cas_value_or_7_<mode>): Likewise.
8012         (atomic_cas_value_nand_7_<mode>): Likewise.
8013         (atomic_cas_value_exchange_7_<mode>): Likewise.
8015 2023-11-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
8017         * config/riscv/riscv-v.cc (expand_vector_init_trailing_same_elem): New function.
8018         (expand_vec_init): Add trailing optimization.
8020 2023-11-15  Pan Li  <pan2.li@intel.com>
8022         * config/riscv/riscv-v.cc (rvv_builder::get_merge_scalar_mask):
8023         Add inner_mode mask arg for mask int mode.
8024         (get_repeating_sequence_dup_machine_mode): Add mask_bit_mode arg
8025         to get the good enough vector int mode on precision.
8026         (expand_vector_init_merge_repeating_sequence): Pass required args
8027         to above func.
8029 2023-11-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
8031         PR target/112535
8032         * config/riscv/riscv.cc (riscv_legitimate_address_p): Disallow RVV modes base address.
8034 2023-11-15  David Malcolm  <dmalcolm@redhat.com>
8036         * json.cc (selftest::assert_print_eq): Add "loc" param and use
8037         ASSERT_STREQ_AT.
8038         (ASSERT_PRINT_EQ): New macro.
8039         (selftest::test_writing_objects): Use ASSERT_PRINT_EQ to capture
8040         source location of assertion.
8041         (selftest::test_writing_arrays): Likewise.
8042         (selftest::test_writing_float_numbers): Likewise.
8043         (selftest::test_writing_integer_numbers): Likewise.
8044         (selftest::test_writing_strings): Likewise.
8045         (selftest::test_writing_literals): Likewise.
8047 2023-11-14  David Malcolm  <dmalcolm@redhat.com>
8049         PR analyzer/103533
8050         * doc/invoke.texi (Static Analyzer Options): Add the six
8051         -Wanalyzer-tainted-* warnings.  Update documentation of each
8052         warning to reflect removed requirement to use
8053         -fanalyzer-checker=taint.  Remove discussion of
8054         -fanalyzer-checker=taint.
8056 2023-11-14  David Malcolm  <dmalcolm@redhat.com>
8058         * diagnostic-format-json.cc
8059         (json_output_format::on_end_diagnostic): Update calls to m_context
8060         callbacks to use member functions; tighten up scopes.
8061         * diagnostic-format-sarif.cc (sarif_builder::make_result_object):
8062         Likewise.
8063         (sarif_builder::make_reporting_descriptor_object_for_warning):
8064         Likewise.
8065         * diagnostic.cc (diagnostic_context::initialize): Update for
8066         callbacks being moved into m_option_callbacks and being renamed.
8067         (diagnostic_context::set_option_hooks): New.
8068         (diagnostic_option_classifier::classify_diagnostic): Update call
8069         to global_dc->m_option_enabled to use option_enabled_p.
8070         (diagnostic_context::print_option_information): Update calls to
8071         m_context callbacks to use member functions; tighten up scopes.
8072         (diagnostic_context::diagnostic_enabled): Likewise.
8073         * diagnostic.h (diagnostic_option_enabled_cb): New typedef.
8074         (diagnostic_make_option_name_cb): New typedef.
8075         (diagnostic_make_option_url_cb): New typedef.
8076         (diagnostic_context::option_enabled_p): New.
8077         (diagnostic_context::make_option_name): New.
8078         (diagnostic_context::make_option_url): New.
8079         (diagnostic_context::set_option_hooks): New decl.
8080         (diagnostic_context::m_option_enabled): Rename to
8081         m_option_enabled_cb and move within m_option_callbacks, using
8082         typedef.
8083         (diagnostic_context::m_option_state): Move within
8084         m_option_callbacks.
8085         (diagnostic_context::m_option_name): Rename to
8086         m_make_option_name_cb and move within m_option_callbacks, using
8087         typedef.
8088         (diagnostic_context::m_get_option_url): Likewise, renaming to
8089         m_make_option_url_cb.
8090         * lto-wrapper.cc (print_lto_docs_link): Update call to m_context
8091         callback to use member function.
8092         (main): Use diagnostic_context::set_option_hooks.
8093         * opts-diagnostic.h (option_name): Make context param const.
8094         (get_option_url): Likewise.
8095         * opts.cc (option_name): Likewise.
8096         (get_option_url): Likewise.
8097         * toplev.cc (general_init): Use
8098         diagnostic_context::set_option_hooks.
8100 2023-11-14  David Malcolm  <dmalcolm@redhat.com>
8102         * selftest-diagnostic.cc
8103         (test_diagnostic_context::test_diagnostic_context): Use
8104         diagnostic_start_span.
8105         * tree-diagnostic-path.cc (struct event_range): Likewise.
8107 2023-11-14  David Malcolm  <dmalcolm@redhat.com>
8109         * diagnostic-show-locus.cc (diagnostic_context::show_locus):
8110         Update for renaming of text callbacks fields.
8111         * diagnostic.cc (diagnostic_context::initialize): Likewise.
8112         * diagnostic.h (class diagnostic_context): Add "friend" for
8113         accessors to m_text_callbacks.
8114         (diagnostic_context::m_text_callbacks): Make private, and add an
8115         "m_" prefix to field names.
8116         (diagnostic_starter): Convert from macro to inline function.
8117         (diagnostic_start_span): New.
8118         (diagnostic_finalizer): Convert from macro to inline function.
8120 2023-11-14  David Malcolm  <dmalcolm@redhat.com>
8122         * diagnostic.h (diagnostic_ready_p): Convert from macro to inline
8123         function.
8125 2023-11-14  Uros Bizjak  <ubizjak@gmail.com>
8127         PR target/78904
8128         * config/i386/i386.md (*addqi_ext<mode>_1_slp):
8129         New define_insn_and_split pattern.
8130         (*subqi_ext<mode>_1_slp): Ditto.
8131         (*<any_logic:code>qi_ext<mode>_1_slp): Ditto.
8133 2023-11-14  Andrew Stubbs  <ams@codesourcery.com>
8135         PR target/112481
8136         * expr.cc (store_constructor): Use OPTAB_WIDEN for mask adjustment.
8138 2023-11-14  David Malcolm  <dmalcolm@redhat.com>
8140         * diagnostic-format-sarif.cc (sarif_builder::get_sarif_column):
8141         Use m_context's file_cache.
8142         (sarif_builder::maybe_make_artifact_content_object): Likewise.
8143         (sarif_builder::get_source_lines): Likewise.
8144         * diagnostic-show-locus.cc
8145         (exploc_with_display_col::exploc_with_display_col): Add file_cache
8146         param.
8147         (layout::m_file_cache): New field.
8148         (make_range): Add file_cache param.
8149         (selftest::test_layout_range_for_single_point): Create and use a
8150         temporary file_cache.
8151         (selftest::test_layout_range_for_single_line): Likewise.
8152         (selftest::test_layout_range_for_multiple_lines): Likewise.
8153         (layout::layout): Initialize m_file_cache from the context and use it.
8154         (layout::maybe_add_location_range): Use m_file_cache.
8155         (layout::calculate_x_offset_display): Likewise.
8156         (get_affected_range): Add file_cache param.
8157         (get_printed_columns): Likewise.
8158         (line_corrections::line_corrections): Likewwise.
8159         (line_corrections::m_file_cache): New field.
8160         (source_line::source_line): Add file_cache param.
8161         (line_corrections::add_hint): Use m_file_cache.
8162         (layout::print_trailing_fixits): Likewise.
8163         (layout::print_line): Likewise.
8164         (selftest::test_layout_x_offset_display_utf8): Create and use a
8165         temporary file_cache.
8166         (selftest::test_layout_x_offset_display_tab): Likewise.
8167         (selftest::test_diagnostic_show_locus_one_liner_utf8): Likewise.
8168         (selftest::test_add_location_if_nearby): Pass global_dc's
8169         file_cache to temp_source_file ctor.
8170         (selftest::test_overlapped_fixit_printing): Create and use a
8171         temporary file_cache.
8172         (selftest::test_overlapped_fixit_printing_utf8): Likewise.
8173         (selftest::test_overlapped_fixit_printing_2): Use dc's file_cache.
8174         * diagnostic.cc (diagnostic_context::initialize): Always create a
8175         file_cache.
8176         (diagnostic_context::initialize_input_context): Assume
8177         m_file_cache has already been created.
8178         (diagnostic_context::create_edit_context): Pass m_file_cache to
8179         edit_context.
8180         (convert_column_unit): Add file_cache param.
8181         (diagnostic_context::converted_column): Use context's file_cache.
8182         (print_parseable_fixits): Add file_cache param.
8183         (diagnostic_context::report_diagnostic): Use context's file_cache.
8184         (selftest::test_print_parseable_fixits_none): Create and use a
8185         temporary file_cache.
8186         (selftest::test_print_parseable_fixits_insert): Likewise.
8187         (selftest::test_print_parseable_fixits_remove): Likewise.
8188         (selftest::test_print_parseable_fixits_replace): Likewise.
8189         (selftest::test_print_parseable_fixits_bytes_vs_display_columns):
8190         Likewise.
8191         * diagnostic.h (diagnostic_context::file_cache_init): Delete.
8192         (diagnostic_context::get_file_cache): Convert return type from
8193         pointer to reference.
8194         * edit-context.cc (edited_file::get_file_cache): New.
8195         (edited_file::m_edit_context): New.
8196         (edit_context::edit_context): Add file_cache param.
8197         (edit_context::get_or_insert_file): Pass this to edited_file's
8198         ctor.
8199         (edited_file::edited_file): Add edit_context param.
8200         (edited_file::print_content): Use get_file_cache.
8201         (edited_file::print_diff_hunk): Likewise.
8202         (edited_file::print_run_of_changed_lines): Likewise.
8203         (edited_file::get_or_insert_line): Likewise.
8204         (edited_file::get_num_lines): Likewise.
8205         (edited_line::edited_line): Pass in file_cache and use it.
8206         (selftest::test_get_content): Create and use a
8207         temporary file_cache.
8208         (selftest::test_applying_fixits_insert_before): Likewise.
8209         (selftest::test_applying_fixits_insert_after): Likewise.
8210         (selftest::test_applying_fixits_insert_after_at_line_end):
8211         Likewise.
8212         (selftest::test_applying_fixits_insert_after_failure): Likewise.
8213         (selftest::test_applying_fixits_insert_containing_newline):
8214         Likewise.
8215         (selftest::test_applying_fixits_growing_replace): Likewise.
8216         (selftest::test_applying_fixits_shrinking_replace): Likewise.
8217         (selftest::test_applying_fixits_replace_containing_newline):
8218         Likewise.
8219         (selftest::test_applying_fixits_remove): Likewise.
8220         (selftest::test_applying_fixits_multiple): Likewise.
8221         (selftest::test_applying_fixits_multiple_lines): Likewise.
8222         (selftest::test_applying_fixits_modernize_named_init): Likewise.
8223         (selftest::test_applying_fixits_modernize_named_init): Likewise.
8224         (selftest::test_applying_fixits_unreadable_file): Likewise.
8225         (selftest::test_applying_fixits_line_out_of_range): Likewise.
8226         (selftest::test_applying_fixits_column_validation): Likewise.
8227         (selftest::test_applying_fixits_column_validation): Likewise.
8228         (selftest::test_applying_fixits_column_validation): Likewise.
8229         (selftest::test_applying_fixits_column_validation): Likewise.
8230         * edit-context.h (edit_context::edit_context): Add file_cache
8231         param.
8232         (edit_context::get_file_cache): New.
8233         (edit_context::m_file_cache): New.
8234         * final.cc: Include "diagnostic.h".
8235         (asm_show_source): Use global_dc's file_cache.
8236         * gcc-rich-location.cc (blank_line_before_p): Add file_cache
8237         param.
8238         (use_new_line): Likewise.
8239         (gcc_rich_location::add_fixit_insert_formatted): Use global dc's
8240         file_cache.
8241         * input.cc (diagnostic_file_cache_init): Delete.
8242         (diagnostic_context::file_cache_init): Delete.
8243         (diagnostics_file_cache_forcibly_evict_file): Delete.
8244         (file_cache::missing_trailing_newline_p): New.
8245         (file_cache::evicted_cache_tab_entry): Don't call
8246         diagnostic_file_cache_init.
8247         (location_get_source_line): Delete.
8248         (get_source_text_between): Add file_cache param.
8249         (get_source_file_content): Delete.
8250         (location_missing_trailing_newline): Delete.
8251         (location_compute_display_column): Add file_cache param.
8252         (dump_location_info): Create and use temporary file_cache.
8253         (get_substring_ranges_for_loc): Add file_cache param.
8254         (get_location_within_string): Likewise.
8255         (get_source_range_for_char): Likewise.
8256         (get_num_source_ranges_for_substring): Likewise.
8257         (selftest::test_reading_source_line): Create and use temporary
8258         file_cache.
8259         (selftest::lexer_test::m_file_cache): New field.
8260         (selftest::assert_char_at_range): Use test.m_file_cache.
8261         (selftest::assert_num_substring_ranges): Likewise.
8262         (selftest::assert_has_no_substring_ranges): Likewise.
8263         (selftest::test_lexer_string_locations_concatenation_2): Likewise.
8264         * input.h (class file_cache): New forward decl.
8265         (location_compute_display_column): Add file_cache param.
8266         (location_get_source_line): Delete.
8267         (get_source_text_between): Add file_cache param.
8268         (get_source_file_content): Delete.
8269         (location_missing_trailing_newline): Delete.
8270         (file_cache::missing_trailing_newline_p): New decl.
8271         (diagnostics_file_cache_forcibly_evict_file): Delete.
8272         * selftest.cc (named_temp_file::named_temp_file): Add file_cache
8273         param.
8274         (named_temp_file::~named_temp_file): Optionally evict the file
8275         from the given file_cache.
8276         (temp_source_file::temp_source_file): Add file_cache param.
8277         * selftest.h (class file_cache): New forward decl.
8278         (named_temp_file::named_temp_file): Add file_cache param.
8279         (named_temp_file::m_file_cache): New field.
8280         (temp_source_file::temp_source_file): Add file_cache param.
8281         * substring-locations.h (get_location_within_string): Add
8282         file_cache param.
8284 2023-11-14  David Malcolm  <dmalcolm@redhat.com>
8286         * diagnostic-format-json.cc: Use type-specific "set_*" functions
8287         of json::object to avoid naked new of json value subclasses.
8288         * diagnostic-format-sarif.cc: Likewise.
8289         * gcov.cc: Likewise.
8290         * json.cc (object::set_string): New.
8291         (object::set_integer): New.
8292         (object::set_float): New.
8293         (object::set_bool): New.
8294         (selftest::test_writing_objects): Use object::set_string.
8295         * json.h (object::set_string): New decl.
8296         (object::set_integer): New decl.
8297         (object::set_float): New decl.
8298         (object::set_bool): New decl.
8299         * optinfo-emit-json.cc: Use type-specific "set_*" functions of
8300         json::object to avoid naked new of json value subclasses.
8301         * timevar.cc: Likewise.
8302         * tree-diagnostic-path.cc: Likewise.
8304 2023-11-14  Andrew MacLeod  <amacleod@redhat.com>
8306         PR tree-optimization/112509
8307         * tree-vrp.cc (find_case_label_range): Create range from case labels.
8309 2023-11-14  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
8311         * config/s390/s390-builtin-types.def: Add/remove types.
8312         * config/s390/s390-builtins.def (s390_vec_scatter_element_flt):
8313         The type for the offset should be UV4SI instead of V4SF.
8315 2023-11-14  Saurabh Jha  <saurabh.jha@arm.com>
8317         PR target/112337
8318         * config/arm/arm.cc (mve_vector_mem_operand): Add a REG_P check for INC
8319         and DEC operations.
8321 2023-11-14  Richard Biener  <rguenther@suse.de>
8323         PR tree-optimization/111233
8324         PR tree-optimization/111652
8325         PR tree-optimization/111727
8326         PR tree-optimization/111838
8327         PR tree-optimization/112113
8328         * tree-ssa-loop-split.cc (patch_loop_exit): Get the new
8329         guard code instead of the old guard stmt.
8330         (split_loop): Adjust.
8332 2023-11-14  Richard Biener  <rguenther@suse.de>
8334         * tree-loop-distribution.cc (loop_distribution::data_dep_in_cycle_p):
8335         Consider all loops in the nest when looking for
8336         lambda_vector_zerop.
8338 2023-11-14  Richard Biener  <rguenther@suse.de>
8340         PR tree-optimization/112281
8341         * tree-loop-distribution.cc (pg_add_dependence_edges):
8342         Preserve stmt order when the innermost loop has exact
8343         overlap.
8345 2023-11-14  Jakub Jelinek  <jakub@redhat.com>
8347         PR target/112523
8348         PR ada/112514
8349         * config/i386/i386.md (<insn><dwi>3_doubleword_lowpart): Move
8350         operands[1] aka low part of input rather than operands[3] aka high
8351         part of input to output if not the same register.
8353 2023-11-14  Andreas Krebbel  <krebbel@linux.ibm.com>
8355         * config.gcc: Add s390-gen-builtins.h to target_gtfiles.
8356         * config/s390/s390-builtins.h (s390_builtin_types)
8357         (s390_builtin_fn_types, s390_builtin_decls): Add GTY marker.
8358         * config/s390/t-s390 (EXTRA_GTYPE_DEPS): Add s390-gen-builtins.h.
8359         Add build rule for s390-gen-builtins.h.
8361 2023-11-14  Andreas Krebbel  <krebbel@linux.ibm.com>
8363         * config/s390/s390-c.cc (s390_fn_types_compatible): Add a check
8364         for error_mark_node.
8366 2023-11-14  Jakub Jelinek  <jakub@redhat.com>
8368         PR c/111309
8369         * builtins.def (BUILT_IN_CLZG, BUILT_IN_CTZG, BUILT_IN_CLRSBG,
8370         BUILT_IN_FFSG, BUILT_IN_PARITYG, BUILT_IN_POPCOUNTG): New
8371         builtins.
8372         * builtins.cc (fold_builtin_bit_query): New function.
8373         (fold_builtin_1): Use it for
8374         BUILT_IN_{CLZ,CTZ,CLRSB,FFS,PARITY,POPCOUNT}G.
8375         (fold_builtin_2): Use it for BUILT_IN_{CLZ,CTZ}G.
8376         * fold-const-call.cc: Fix comment typo on tm.h inclusion.
8377         (fold_const_call_ss): Handle
8378         CFN_BUILT_IN_{CLZ,CTZ,CLRSB,FFS,PARITY,POPCOUNT}G.
8379         (fold_const_call_sss): New function.
8380         (fold_const_call_1): Call it for 2 argument functions returning
8381         scalar when passed 2 INTEGER_CSTs.
8382         * genmatch.cc (cmp_operand): For function calls also compare
8383         number of arguments.
8384         (fns_cmp): New function.
8385         (dt_node::gen_kids): Sort fns and generic_fns.
8386         (dt_node::gen_kids_1): Handle fns with the same id but different
8387         number of arguments.
8388         * match.pd (CLZ simplifications): Drop checks for defined behavior
8389         at zero.  Add variant of simplifications for IFN_CLZ with 2 arguments.
8390         (CTZ simplifications): Drop checks for defined behavior at zero,
8391         don't optimize precisions above MAX_FIXED_MODE_SIZE.  Add variant of
8392         simplifications for IFN_CTZ with 2 arguments.
8393         (a != 0 ? CLZ(a) : CST -> .CLZ(a)): Use TREE_TYPE (@3) instead of
8394         type, add BITINT_TYPE handling, create 2 argument IFN_CLZ rather than
8395         one argument.  Add variant for matching CLZ with 2 arguments.
8396         (a != 0 ? CTZ(a) : CST -> .CTZ(a)): Similarly.
8397         * gimple-lower-bitint.cc (bitint_large_huge::lower_bit_query): New
8398         method.
8399         (bitint_large_huge::lower_call): Use it for IFN_{CLZ,CTZ,CLRSB,FFS}
8400         and IFN_{PARITY,POPCOUNT} calls.
8401         * gimple-range-op.cc (cfn_clz::fold_range): Don't check
8402         CLZ_DEFINED_VALUE_AT_ZERO for m_gimple_call_internal_p, instead
8403         assume defined value at zero if the call has 2 arguments and use
8404         second argument value for that case.
8405         (cfn_ctz::fold_range): Similarly.
8406         (gimple_range_op_handler::maybe_builtin_call): Use op_cfn_clz_internal
8407         or op_cfn_ctz_internal only if internal fn call has 2 arguments and
8408         set m_op2 in that case.
8409         * tree-vect-patterns.cc (vect_recog_ctz_ffs_pattern,
8410         vect_recog_popcount_clz_ctz_ffs_pattern): For value defined at zero
8411         use second argument of calls if present, otherwise assume UB at zero,
8412         create 2 argument .CLZ/.CTZ calls if needed.
8413         * tree-vect-stmts.cc (vectorizable_call): Handle 2 argument .CLZ/.CTZ
8414         calls.
8415         * tree-ssa-loop-niter.cc (build_cltz_expr): Create 2 argument
8416         .CLZ/.CTZ calls if needed.
8417         * tree-ssa-forwprop.cc (simplify_count_trailing_zeroes): Create 2
8418         argument .CTZ calls if needed.
8419         * tree-ssa-phiopt.cc (cond_removal_in_builtin_zero_pattern): Handle
8420         2 argument .CLZ/.CTZ calls, handle BITINT_TYPE, create 2 argument
8421         .CLZ/.CTZ calls.
8422         * doc/extend.texi (__builtin_clzg, __builtin_ctzg, __builtin_clrsbg,
8423         __builtin_ffsg, __builtin_parityg, __builtin_popcountg): Document.
8425 2023-11-14  Xi Ruoyao  <xry111@xry111.site>
8427         PR target/112330
8428         * config/loongarch/genopts/loongarch.opt.in: Add
8429         -m[no]-pass-relax-to-as.  Change the default of -m[no]-relax to
8430         account conditional branch relaxation support status.
8431         * config/loongarch/loongarch.opt: Regenerate.
8432         * configure.ac (gcc_cv_as_loongarch_cond_branch_relax): Check if
8433         the assembler supports conditional branch relaxation.
8434         * configure: Regenerate.
8435         * config.in: Regenerate.  Note that there are some unrelated
8436         changes introduced by r14-5424 (which does not contain a
8437         config.in regeneration).
8438         * config/loongarch/loongarch-opts.h
8439         (HAVE_AS_COND_BRANCH_RELAXATION): Define to 0 if not defined.
8440         * config/loongarch/loongarch-driver.h (ASM_MRELAX_DEFAULT):
8441         Define.
8442         (ASM_MRELAX_SPEC): Define.
8443         (ASM_SPEC): Use ASM_MRELAX_SPEC instead of "%{mno-relax}".
8444         * config/loongarch/loongarch.cc: Take the setting of
8445         -m[no-]relax into account when determining the default of
8446         -mexplicit-relocs=.
8447         * doc/invoke.texi: Document -m[no-]relax and
8448         -m[no-]pass-mrelax-to-as for LoongArch.  Update the default
8449         value of -mexplicit-relocs=.
8451 2023-11-14  liuhongt  <hongtao.liu@intel.com>
8453         PR tree-optimization/112496
8454         * tree-vect-loop.cc (vectorizable_nonlinear_induction): Return
8455         false when !tree_nop_conversion_p (TREE_TYPE (vectype),
8456         TREE_TYPE (init_expr)).
8458 2023-11-14  Xi Ruoyao  <xry111@xry111.site>
8460         * config/loongarch/sync.md (mem_thread_fence): Remove redundant
8461         check.
8462         (mem_thread_fence_1): Emit finer-grained DBAR hints for
8463         different memory models, instead of 0.
8465 2023-11-14  Jakub Jelinek  <jakub@redhat.com>
8467         PR middle-end/112511
8468         * tree.cc (type_contains_placeholder_1): Handle BITINT_TYPE like
8469         INTEGER_TYPE.
8471 2023-11-14  Jakub Jelinek  <jakub@redhat.com>
8472             Hu, Lin1  <lin1.hu@intel.com>
8474         PR target/112435
8475         * config/i386/sse.md (avx512vl_shuf_<shuffletype>32x4_1<mask_name>,
8476         <mask_codefor>avx512dq_shuf_<shuffletype>64x2_1<mask_name>): Add
8477         alternative with just x instead of v constraints and xjm instead of
8478         vm and use vblendps as optimization only with that alternative.
8480 2023-11-14  liuhongt  <hongtao.liu@intel.com>
8482         PR tree-optimization/105735
8483         PR tree-optimization/111972
8484         * tree-scalar-evolution.cc
8485         (analyze_and_compute_bitop_with_inv_effect): Handle bitop with
8486         INTEGER_CST.
8488 2023-11-13  Arsen Arsenović  <arsen@aarsen.me>
8490         * configure: Regenerate.
8491         * aclocal.m4: Regenerate.
8492         * Makefile.in (LIBDEPS): Remove (potential) ./ prefix from
8493         LIBINTL_DEP.
8494         * doc/install.texi: Document new (notable) flags added by the
8495         optional gettext tree and by AM_GNU_GETTEXT.  Document libintl/libc
8496         with gettext dependency.
8498 2023-11-13  Uros Bizjak  <ubizjak@gmail.com>
8500         * config/i386/i386-expand.h (gen_pushfl): New prototype.
8501         (gen_popfl): Ditto.
8502         * config/i386/i386-expand.cc (ix86_expand_builtin)
8503         [case IX86_BUILTIN_READ_FLAGS]: Use gen_pushfl.
8504         [case IX86_BUILTIN_WRITE_FLAGS]: Use gen_popfl.
8505         * config/i386/i386.cc (gen_pushfl): New function.
8506         (gen_popfl): Ditto.
8507         * config/i386/i386.md (unspec): Add UNSPEC_PUSHFL and UNSPEC_POPFL.
8508         (@pushfl<mode>2): Rename from *pushfl<mode>2.
8509         Rewrite as unspec using UNSPEC_PUSHFL.
8510         (@popfl<mode>1): Rename from *popfl<mode>1.
8511         Rewrite as unspec using UNSPEC_POPFL.
8513 2023-11-13  Uros Bizjak  <ubizjak@gmail.com>
8515         PR target/112494
8516         * config/i386/i386.cc (ix86_cc_mode) [default]: Return CCmode.
8518 2023-11-13  Robin Dapp  <rdapp@ventanamicro.com>
8520         * config/riscv/riscv-vsetvl.cc (source_equal_p): Use pointer
8521         equality for REG_EQUAL.
8523 2023-11-13  Richard Biener  <rguenther@suse.de>
8525         PR tree-optimization/112495
8526         * tree-data-ref.cc (runtime_alias_check_p): Reject checks
8527         between different address spaces.
8529 2023-11-13  Richard Biener  <rguenther@suse.de>
8531         PR middle-end/112487
8532         * tree-inline.cc (setup_one_parameter): When the parameter
8533         is unused only insert a debug bind when there's not a gross
8534         mismatch in value and declared parameter type.  Do not assert
8535         there effectively isn't.
8537 2023-11-13  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
8539         * config/riscv/riscv-v.cc
8540         (rvv_builder::combine_sequence_use_merge_profitable_p): New function.
8541         (expand_vector_init_merge_combine_sequence): Ditto.
8542         (expand_vec_init): Adapt for new optimization.
8544 2023-11-13  liuhongt  <hongtao.liu@intel.com>
8546         * config/i386/i386-expand.cc
8547         (ix86_expand_vector_init_duplicate): Handle V4HF/V4BF and
8548         V2HF/V2BF.
8549         (ix86_expand_vector_init_one_nonzero): Ditto.
8550         (ix86_expand_vector_init_one_var): Ditto.
8551         (ix86_expand_vector_init_general): Ditto.
8552         (ix86_expand_vector_set_var): Ditto.
8553         (ix86_expand_vector_set): Ditto.
8554         (ix86_expand_vector_extract): Ditto.
8555         * config/i386/mmx.md
8556         (mmxdoublevecmode): Extend to V4HF/V4BF/V2HF/V2BF.
8557         (*mmx_pinsrw): Extend to V4FI_64, add a new alternative (&x,
8558         x, x), add a new define_split after the pattern.
8559         (*mmx_pextrw<mode>): New define_insn.
8560         (mmx_pshufw_1): Rename to ..
8561         (mmx_pshufw<mode>_1): .. this, extend to V4FI_64.
8562         (*mmx_pblendw64): Extend to V4FI_64.
8563         (*vec_dup<mode>): New define_insn.
8564         (vec_setv4hi): Rename to ..
8565         (vec_set<mode>): .. this, and extend to V4FI_64
8566         (vec_extractv4hihi): Rename to ..
8567         (vec_extract<mode><mmxscalarmodelower>): .. this, and extend
8568         to V4FI_64.
8569         (vec_init<mode><mmxscalarmodelower>): New define_insn.
8570         (*pinsrw): Extend to V2FI_32, add a new alternative (&x,
8571         x, x), and add a new define_split after it.
8572         (*pextrw<mode>): New define_insn.
8573         (vec_setv2hi): Rename to ..
8574         (vec_set<mode>): .. this, extend to V2FI_32.
8575         (vec_extractv2hihi): Rename to ..
8576         (vec_extract<mode><mmxscalarmodelower>): .. this, extend to
8577         V2FI_32.
8578         (*punpckwd): Extend to V2FI_32.
8579         (*pshufw_1): Rename to ..
8580         (*pshufw<mode>_1): .. this, extend to V2FI_32.
8581         (vec_initv2hihi): Rename to ..
8582         (vec_init<mode><mmxscalarmodelower>): .. this, and extend to
8583         V2FI_32.
8584         (*vec_dup<mode>): New define_insn.
8585         * config/i386/sse.md (*vec_extract<mode>): Refine constraint
8586         from v to Yw.
8588 2023-11-13  Roger Sayle  <roger@nextmovesoftware.com>
8590         * config/arc/arc.md (UNSPEC_ARC_CC_NEZ): New UNSPEC that
8591         represents the carry flag being set if the operand is non-zero.
8592         (adc_f): New define_insn representing adc with updated flags.
8593         (ashrdi3): New define_expand that only handles shifts by 1.
8594         (ashrdi3_cnt1): New pre-reload define_insn_and_split.
8595         (lshrdi3): New define_expand that only handles shifts by 1.
8596         (lshrdi3_cnt1): New pre-reload define_insn_and_split.
8597         (rrcsi2): New define_insn for rrc (SImode rotate right through carry).
8598         (rrcsi2_carry): Likewise for rrc.f, as above but updating flags.
8599         (rotldi3): New define_expand that only handles rotates by 1.
8600         (rotldi3_cnt1): New pre-reload define_insn_and_split.
8601         (rotrdi3): New define_expand that only handles rotates by 1.
8602         (rotrdi3_cnt1): New pre-reload define_insn_and_split.
8603         (lshrsi3_cnt1_carry): New define_insn for lsr.f.
8604         (ashrsi3_cnt1_carry): New define_insn for asr.f.
8605         (btst_0_carry): New define_insn for asr.f without result.
8607 2023-11-13  Roger Sayle  <roger@nextmovesoftware.com>
8609         * config/arc/arc.cc (TARGET_FOLD_BUILTIN): Define to
8610         arc_fold_builtin.
8611         (arc_fold_builtin): New function.  Convert ARC_BUILTIN_SWAP
8612         into a rotate.  Evaluate ARC_BUILTIN_NORM and
8613         ARC_BUILTIN_NORMW of constant arguments.
8614         * config/arc/arc.md (UNSPEC_ARC_SWAP): Delete.
8615         (normw): Make output template/assembler whitespace consistent.
8616         (swap): Remove define_insn, only use of SWAP UNSPEC.
8617         * config/arc/builtins.def: Tweak indentation.
8618         (SWAP): Expand using rotlsi2_cnt16 instead of using swap.
8620 2023-11-13  Roger Sayle  <roger@nextmovesoftware.com>
8622         * config/i386/i386.md (<insn><dwi>3_doubleword_lowpart): New
8623         define_insn_and_split to optimize register usage of doubleword
8624         right shifts followed by truncation.
8626 2023-11-13  Jakub Jelinek  <jakub@redhat.com>
8628         * config/i386/constraints.md: Remove j constraint letter from list of
8629         unused letters.
8631 2023-11-13  Xi Ruoyao  <xry111@xry111.site>
8633         PR rtl-optimization/112483
8634         * simplify-rtx.cc (simplify_binary_operation_1) <case COPYSIGN>:
8635         Fix the simplification of (fcopysign x, NEGATIVE_CONST).
8637 2023-11-13  Jakub Jelinek  <jakub@redhat.com>
8639         PR tree-optimization/111967
8640         * gimple-range-cache.cc (block_range_cache::set_bb_range): Grow
8641         m_ssa_ranges to num_ssa_names rather than num_ssa_names + 1.
8642         (block_range_cache::dump): Iterate from 1 rather than 0.  Don't use
8643         ssa_name (x) unless m_ssa_ranges[x] is non-NULL.  Iterate to
8644         m_ssa_ranges.length () rather than num_ssa_names.
8646 2023-11-13  Xi Ruoyao  <xry111@xry111.site>
8648         * config/loongarch/loongarch.md (LD_AT_LEAST_32_BIT): New mode
8649         iterator.
8650         (ST_ANY): New mode iterator.
8651         (define_peephole2): Use LD_AT_LEAST_32_BIT instead of GPR and
8652         ST_ANY instead of QHWD for applicable patterns.
8654 2023-11-13  Xi Ruoyao  <xry111@xry111.site>
8656         PR target/112476
8657         * config/loongarch/loongarch.cc
8658         (loongarch_expand_vec_cond_mask_expr): Call simplify_gen_subreg
8659         instead of gen_rtx_SUBREG.
8661 2023-11-13  Pan Li  <pan2.li@intel.com>
8663         * config/riscv/autovec.md: Add bridge mode to lrint and lround
8664         pattern.
8665         * config/riscv/riscv-protos.h (expand_vec_lrint): Add new arg
8666         bridge machine mode.
8667         (expand_vec_lround): Ditto.
8668         * config/riscv/riscv-v.cc (emit_vec_widden_cvt_f_f): New helper
8669         func impl to emit vfwcvt.f.f.
8670         (emit_vec_rounding_to_integer): Handle the HF to DI rounding
8671         with the bridge mode.
8672         (expand_vec_lrint): Reorder the args.
8673         (expand_vec_lround): Ditto.
8674         (expand_vec_lceil): Ditto.
8675         (expand_vec_lfloor): Ditto.
8676         * config/riscv/vector-iterators.md: Add vector HFmode and bridge
8677         mode for converting to DI.
8679 2023-11-12  Jeff Law  <jlaw@ventanamicro.com>
8681         Revert:
8682         2023-11-11  Jin Ma  <jinma@linux.alibaba.com>
8684         * haifa-sched.cc (use_or_clobber_starts_range_p): New.
8685         (prune_ready_list): USE or CLOBBER should delay execution
8686         if it starts a new live range.
8688 2023-11-12  Uros Bizjak  <ubizjak@gmail.com>
8690         * config/i386/i386.md (*stack_protect_set_4s_<mode>_di):
8691         Remove alternative 0.
8693 2023-11-11  Eric Botcazou  <ebotcazou@adacore.com>
8695         * ipa-cp.cc (print_ipcp_constant_value): Move to...
8696         (values_equal_for_ipcp_p): Deal with VAR_DECLs from the
8697         constant pool.
8698         * ipa-prop.cc (ipa_print_constant_value): ...here.  Likewise.
8699         (ipa_print_node_jump_functions_for_edge): Call the function
8700         ipa_print_constant_value to print IPA_JF_CONST elements.
8702 2023-11-11  Jin Ma  <jinma@linux.alibaba.com>
8704         * haifa-sched.cc (use_or_clobber_starts_range_p): New.
8705         (prune_ready_list): USE or CLOBBER should delay execution
8706         if it starts a new live range.
8708 2023-11-11  Jakub Jelinek  <jakub@redhat.com>
8710         PR middle-end/112430
8711         * tree-ssa-math-opts.cc (match_uaddc_usubc): Remove temp_stmts in the
8712         order they were pushed rather than in reverse order.  Call
8713         release_defs after gsi_remove.
8715 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8717         * target.def (mode_switching.backprop): New hook.
8718         * doc/tm.texi.in (TARGET_MODE_BACKPROP): New @hook.
8719         * doc/tm.texi: Regenerate.
8720         * mode-switching.cc (struct bb_info): Add single_succ.
8721         (confluence_info): Add transp field.
8722         (single_succ_confluence_n, single_succ_transfer): New functions.
8723         (backprop_confluence_n, backprop_transfer): Likewise.
8724         (optimize_mode_switching): Use them.  Push mode transitions onto
8725         a block's incoming edges, if the backprop hook requires it.
8727 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8729         * target.def (mode_switching.confluence): New hook.
8730         * doc/tm.texi (TARGET_MODE_CONFLUENCE): New @hook.
8731         * doc/tm.texi.in: Regenerate.
8732         * mode-switching.cc (confluence_info): New variable.
8733         (mode_confluence, forward_confluence_n, forward_transfer): New
8734         functions.
8735         (optimize_mode_switching): Use them to calculate mode_in when
8736         TARGET_MODE_CONFLUENCE is defined.
8738 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8740         * mode-switching.cc (commit_mode_sets): Use 1-based edge aux values.
8742 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8744         * target.def (mode_switching.after): Add a regs_live parameter.
8745         * doc/tm.texi: Regenerate.
8746         * config/epiphany/epiphany-protos.h (epiphany_mode_after): Update
8747         accordingly.
8748         * config/epiphany/epiphany.cc (epiphany_mode_needed): Likewise.
8749         (epiphany_mode_after): Likewise.
8750         * config/i386/i386.cc (ix86_mode_after): Likewise.
8751         * config/riscv/riscv.cc (riscv_mode_after): Likewise.
8752         * config/sh/sh.cc (sh_mode_after): Likewise.
8753         * mode-switching.cc (optimize_mode_switching): Likewise.
8755 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8757         * target.def (mode_switching.needed): Add a regs_live parameter.
8758         * doc/tm.texi: Regenerate.
8759         * config/epiphany/epiphany-protos.h (epiphany_mode_needed): Update
8760         accordingly.
8761         * config/epiphany/epiphany.cc (epiphany_mode_needed): Likewise.
8762         * config/epiphany/mode-switch-use.cc (insert_uses): Likewise.
8763         * config/i386/i386.cc (ix86_mode_needed): Likewise.
8764         * config/riscv/riscv.cc (riscv_mode_needed): Likewise.
8765         * config/sh/sh.cc (sh_mode_needed): Likewise.
8766         * mode-switching.cc (optimize_mode_switching): Likewise.
8767         (create_pre_exit): Likewise, using the DF simulate functions
8768         to calculate the required information.
8770 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8772         * target.def (mode_switching.eh_handler): New hook.
8773         * doc/tm.texi.in (TARGET_MODE_EH_HANDLER): New @hook.
8774         * doc/tm.texi: Regenerate.
8775         * mode-switching.cc (optimize_mode_switching): Use eh_handler
8776         to get the mode on entry to an exception handler.
8778 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8780         * mode-switching.cc (optimize_mode_switching): Mark the exit
8781         block as nontransparent if it requires a specific mode.
8782         Handle the entry and exit mode as sibling rather than nested
8783         concepts.  Remove outdated comment.
8785 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8787         * mode-switching.cc (optimize_mode_switching): Initially
8788         compute transparency in a bit-per-block bitmap.
8790 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8792         * mode-switching.cc (seginfo): Add a prev_mode field.
8793         (new_seginfo): Take and initialize the prev_mode.
8794         (optimize_mode_switching): Update calls accordingly.
8795         Use the recorded modes during the emit phase, rather than
8796         computing one on the fly.
8798 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8800         * mode-switching.cc (add_seginfo): Replace head pointer with
8801         a pointer to the tail pointer.
8802         (optimize_mode_switching): Update calls accordingly.
8804 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8806         * mode-switching.cc (optimize_mode_switching): Call
8807         df_note_add_problem.
8809 2023-11-11  Richard Sandiford  <richard.sandiford@arm.com>
8811         * target.def: Tweak documentation of mode-switching hooks.
8812         * doc/tm.texi.in (OPTIMIZE_MODE_SWITCHING): Tweak documentation.
8813         (NUM_MODES_FOR_MODE_SWITCHING): Likewise.
8814         * doc/tm.texi: Regenerate.
8816 2023-11-11  Martin Uecker  <uecker@tugraz.at>
8818         PR c/110815
8819         PR c/112428
8820         * gimple-ssa-warn-access.cc (pass_waccess::maybe_check_access_sizes):
8821         remove warning for parameters declared with `static`.
8823 2023-11-11  Joern Rennecke  <joern.rennecke@embecosm.com>
8825         * doc/sourcebuild.texi (Scan the assembly output): Document change.
8827 2023-11-10  Mao  <sray@live.com>
8829         PR middle-end/110983
8830         * doc/invoke.texi (Option Summary): Add -fpatchable-function-entry.
8832 2023-11-10  Maciej W. Rozycki  <macro@embecosm.com>
8834         * config/riscv/riscv.md (length): Fix indentation for branch and
8835         jump length calculation expressions.
8837 2023-11-10  Eric Botcazou  <ebotcazou@adacore.com>
8839         * fold-const.cc (operand_compare::operand_equal_p) <CONSTRUCTOR>:
8840         Deal with nonempty constant CONSTRUCTORs.
8841         (operand_compare::hash_operand) <CONSTRUCTOR>: Hash DECL_FIELD_OFFSET
8842         and DECL_FIELD_BIT_OFFSET for FIELD_DECLs.
8844 2023-11-10  Vladimir N. Makarov  <vmakarov@redhat.com>
8846         PR target/112337
8847         * ira-costs.cc: (validate_autoinc_and_mem_addr_p): New function.
8848         (equiv_can_be_consumed_p): Use it.
8850 2023-11-10  Richard Sandiford  <richard.sandiford@arm.com>
8852         * read-rtl.cc (md_reader::read_mapping): Allow iterators to
8853         include other iterators.
8854         * doc/md.texi: Document the change.
8855         * config/aarch64/iterators.md (DREG2, VQ2, TX2, DX2, SX2): Include
8856         the iterator that is being duplicated, rather than reproducing it.
8857         (VSTRUCT_D): Redefine using VSTRUCT_[234]D.
8858         (VSTRUCT_Q): Likewise VSTRUCT_[234]Q.
8859         (VSTRUCT_2QD, VSTRUCT_3QD, VSTRUCT_4QD, VSTRUCT_QD): Redefine using
8860         the individual D and Q iterators.
8862 2023-11-10  Uros Bizjak  <ubizjak@gmail.com>
8864         * config/i386/i386.md (stack_protect_set_1 peephole2):
8865         Explicitly check operand 2 for word_mode.
8866         (stack_protect_set_1 peephole2 #2): Ditto.
8867         (stack_protect_set_2 peephole2): Ditto.
8868         (stack_protect_set_3 peephole2): Ditto.
8869         (*stack_protect_set_4z_<mode>_di): New insn patter.
8870         (*stack_protect_set_4s_<mode>_di): Ditto.
8871         (stack_protect_set_4 peephole2): New peephole2 pattern to
8872         substitute stack protector scratch register clear with unrelated
8873         register initialization involving zero/sign-extend instruction.
8875 2023-11-10  Uros Bizjak  <ubizjak@gmail.com>
8877         * config/i386/i386.md (shift): Use SAL insted of SLL
8878         for ashift insn mnemonic.
8880 2023-11-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
8882         PR tree-optimization/112438
8883         * tree-vect-loop.cc (vectorizable_induction): Bugfix when
8884         LOOP_VINFO_USING_SELECT_VL_P.
8886 2023-11-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
8888         * config/riscv/riscv-protos.h (enum insn_type): New enum.
8889         * config/riscv/riscv-v.cc
8890         (rvv_builder::combine_sequence_use_slideup_profitable_p): New function.
8891         (expand_vector_init_slideup_combine_sequence): Ditto.
8892         (expand_vec_init): Add slideup combine optimization.
8894 2023-11-10  Robin Dapp  <rdapp@ventanamicro.com>
8896         PR tree-optimization/112464
8897         * tree-vect-loop.cc (vectorize_fold_left_reduction): Use
8898         vect_orig_stmt on scalar_dest_def_info.
8900 2023-11-10  Jin Ma  <jinma@linux.alibaba.com>
8902         * config/riscv/riscv.cc (riscv_for_each_saved_reg): Place the interrupt
8903         operation before the XTheadMemPair.
8905 2023-11-10  Richard Biener  <rguenther@suse.de>
8907         PR tree-optimization/110221
8908         * tree-vect-slp.cc (vect_schedule_slp_node): When loop
8909         masking / len is applied make sure to not schedule
8910         intenal defs outside of the loop.
8912 2023-11-10  Andrew Stubbs  <ams@codesourcery.com>
8914         * expr.cc (store_constructor): Add "and" operation to uniform mask
8915         generation.
8917 2023-11-10  Andrew Stubbs  <ams@codesourcery.com>
8919         PR target/112308
8920         * config/gcn/gcn-valu.md (add<mode>3<exec_clobber>): Fix B constraint
8921         and switch to the new format.
8922         (add<mode>3_dup<exec_clobber>): Likewise.
8923         (add<mode>3_vcc<exec_vcc>): Likewise.
8924         (add<mode>3_vcc_dup<exec_vcc>): Likewise.
8925         (add<mode>3_vcc_zext_dup): Likewise.
8926         (add<mode>3_vcc_zext_dup_exec): Likewise.
8927         (add<mode>3_vcc_zext_dup2): Likewise.
8928         (add<mode>3_vcc_zext_dup2_exec): Likewise.
8930 2023-11-10  Richard Biener  <rguenther@suse.de>
8932         PR middle-end/112469
8933         * match.pd (cond ? op a : b -> .COND_op (cond, a, b)): Add
8934         missing view_converts.
8936 2023-11-10  Andrew Stubbs  <ams@codesourcery.com>
8938         * config/gcn/gcn.cc (gcn_expand_reduc_scalar): Add clobber to DImode
8939         min/max instructions.
8941 2023-11-10  Chenghui Pan  <panchenghui@loongson.cn>
8943         * config/loongarch/lsx.md: Fix instruction name typo in
8944         lsx_vreplgr2vr_<lsxfmt_f> template.
8946 2023-11-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
8948         * config/riscv/autovec.md (vec_init<mode><vel>): Split patterns.
8950 2023-11-10  Pan Li  <pan2.li@intel.com>
8952         Revert:
8953         2023-11-10  Pan Li  <pan2.li@intel.com>
8954         * config/riscv/riscv-v.cc (expand_vector_init_trailing_same_elem):
8955         New fun impl to expand the insn when trailing same elements.
8956         (expand_vec_init): Try trailing same elements when vec_init.
8958 2023-11-10  Pan Li  <pan2.li@intel.com>
8960         * config/riscv/riscv-v.cc (expand_vector_init_trailing_same_elem):
8961         New fun impl to expand the insn when trailing same elements.
8962         (expand_vec_init): Try trailing same elements when vec_init.
8964 2023-11-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
8966         * config/riscv/autovec-opt.md (*cond_copysign<mode>): Remove.
8967         * config/riscv/autovec.md (cond_copysign<mode>): New pattern.
8969 2023-11-10  Pan Li  <pan2.li@intel.com>
8971         PR target/112432
8972         * internal-fn.def (LRINT): Add FLOATN support.
8973         (LROUND): Ditto.
8974         (LLRINT): Ditto.
8975         (LLROUND): Ditto.
8977 2023-11-10  Jeff Law  <jlaw@ventanamicro.com>
8979         * config/h8300/combiner.md (single bit sign_extract): Avoid recently
8980         added patterns for H8/SX.
8981         (single bit zero_extract): New patterns.
8983 2023-11-10  liuhongt  <hongtao.liu@intel.com>
8985         PR target/112443
8986         * config/i386/sse.md (*avx2_pcmp<mode>3_4): Fix swap condition
8987         from LT to GT since there's not in the pattern.
8988         (*avx2_pcmp<mode>3_5): Ditto.
8990 2023-11-10  Jose E. Marchesi  <jose.marchesi@oracle.com>
8992         * config/bpf/bpf.cc (bpf_print_register): Accept modifier code 'W'
8993         to force emitting register names using the wN form.
8994         * config/bpf/bpf.md (*mulsidi3_zeroextend): Force operands to
8995         always use wN written form in pseudo-C assembly syntax.
8997 2023-11-09  David Malcolm  <dmalcolm@redhat.com>
8999         * diagnostic-show-locus.cc (layout::m_line_table): New field.
9000         (compatible_locations_p): Convert to...
9001         (layout::compatible_locations_p): ...this, replacing uses of
9002         line_table global with m_line_table.
9003         (layout::layout): Convert "richloc" param from a pointer to a
9004         const reference.  Initialize m_line_table member.
9005         (layout::maybe_add_location_range):  Replace uses of line_table
9006         global with m_line_table.  Pass the latter to
9007         linemap_client_expand_location_to_spelling_point.
9008         (layout::print_leading_fixits): Pass m_line_table to
9009         affects_line_p.
9010         (layout::print_trailing_fixits): Likewise.
9011         (gcc_rich_location::add_location_if_nearby): Update for change
9012         to layout ctor params.
9013         (diagnostic_show_locus): Convert to...
9014         (diagnostic_context::maybe_show_locus): ...this, converting
9015         richloc param from a pointer to a const reference.  Make "loc"
9016         const.  Split out printing part of function to...
9017         (diagnostic_context::show_locus): ...this.
9018         (selftest::test_offset_impl): Update for change to layout ctor
9019         params.
9020         (selftest::test_layout_x_offset_display_utf8): Likewise.
9021         (selftest::test_layout_x_offset_display_tab): Likewise.
9022         (selftest::test_tab_expansion): Likewise.
9023         * diagnostic.h (diagnostic_context::maybe_show_locus): New decl.
9024         (diagnostic_context::show_locus): New decl.
9025         (diagnostic_show_locus): Convert from a decl to an inline function.
9026         * gdbinit.in (break-on-diagnostic): Update from a breakpoint
9027         on diagnostic_show_locus to one on
9028         diagnostic_context::maybe_show_locus.
9029         * genmatch.cc (linemap_client_expand_location_to_spelling_point):
9030         Add "set" param and use it in place of line_table global.
9031         * input.cc (expand_location_1): Likewise.
9032         (expand_location): Update for new param of expand_location_1.
9033         (expand_location_to_spelling_point): Likewise.
9034         (linemap_client_expand_location_to_spelling_point): Add "set"
9035         param and use it in place of line_table global.
9036         * tree-diagnostic-path.cc (event_range::print): Pass line_table
9037         for new param of linemap_client_expand_location_to_spelling_point.
9039 2023-11-09  Uros Bizjak  <ubizjak@gmail.com>
9041         * config/i386/i386.md (@stack_protect_set_1_<PTR:mode>_<W:mode>):
9042         Use W mode iterator instead of SWI48.  Output MOV instead of XOR
9043         for TARGET_USE_MOV0.
9044         (stack_protect_set_1 peephole2): Use integer modes with
9045         mode size <= word mode size for operand 3.
9046         (stack_protect_set_1 peephole2 #2): New peephole2 pattern to
9047         substitute stack protector scratch register clear with unrelated
9048         register initialization, originally in front of stack
9049         protector sequence.
9050         (*stack_protect_set_3_<PTR:mode>_<SWI48:mode>): New insn pattern.
9051         (stack_protect_set_1 peephole2): New peephole2 pattern to
9052         substitute stack protector scratch register clear with unrelated
9053         register initialization involving LEA instruction.
9055 2023-11-09  Vladimir N. Makarov  <vmakarov@redhat.com>
9057         PR rtl-optimization/110215
9058         * ira-lives.cc: (add_conflict_from_region_landing_pads): New
9059         function.
9060         (process_bb_node_lives): Use it.
9062 2023-11-09  Alexandre Oliva  <oliva@adacore.com>
9064         * config/i386/i386.cc (symbolic_base_address_p,
9065         base_address_p): New, factored out from...
9066         (extract_base_offset_in_addr): ... here and extended to
9067         recognize REG+GOTOFF, as in gcc.target/i386/sse2-load-multi.c
9068         and sse2-store-multi.c with PIE enabled by default.
9070 2023-11-09  Tamar Christina  <tamar.christina@arm.com>
9072         PR tree-optimization/109154
9073         * config/aarch64/aarch64-sve.md (cond_copysign<mode>): New.
9075 2023-11-09  Tamar Christina  <tamar.christina@arm.com>
9077         PR tree-optimization/109154
9078         * config/aarch64/aarch64.md (copysign<GPF:mode>3): Handle
9079         copysign (x, -1).
9080         * config/aarch64/aarch64-simd.md (copysign<mode>3): Likewise.
9081         * config/aarch64/aarch64-sve.md (copysign<mode>3): Likewise.
9083 2023-11-09  Tamar Christina  <tamar.christina@arm.com>
9085         PR tree-optimization/109154
9086         * config/aarch64/aarch64.md (<optab><mode>3): Add SVE split case.
9087         * config/aarch64/aarch64-simd.md (ior<mode>3<vczle><vczbe>): Likewise.
9088         * config/aarch64/predicates.md(aarch64_orr_imm_sve_advsimd): New.
9090 2023-11-09  Tamar Christina  <tamar.christina@arm.com>
9092         PR tree-optimization/109154
9093         * config/aarch64/aarch64.md (*mov<mode>_aarch64, *movsi_aarch64,
9094         *movdi_aarch64): Add new w -> Z case.
9095         * config/aarch64/iterators.md (Vbtype): Add QI and HI.
9097 2023-11-09  Tamar Christina  <tamar.christina@arm.com>
9099         PR tree-optimization/109154
9100         * config/aarch64/aarch64-protos.h (aarch64_simd_special_constant_p,
9101         aarch64_maybe_generate_simd_constant): New.
9102         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<VQMOV:mode>,
9103         *aarch64_simd_mov<VDMOV:mode>): Add new coden for special constants.
9104         * config/aarch64/aarch64.cc (aarch64_extract_vec_duplicate_wide_int):
9105         Take optional mode.
9106         (aarch64_simd_special_constant_p,
9107         aarch64_maybe_generate_simd_constant): New.
9108         * config/aarch64/aarch64.md (*movdi_aarch64): Add new codegen for
9109         special constants.
9110         * config/aarch64/constraints.md (Dx): new.
9112 2023-11-09  Tamar Christina  <tamar.christina@arm.com>
9114         PR tree-optimization/109154
9115         * internal-fn.def (COPYSIGN): New.
9116         * match.pd (UNCOND_BINARY, COND_BINARY): Map IFN_COPYSIGN to
9117         IFN_COND_COPYSIGN.
9118         * optabs.def (cond_copysign_optab, cond_len_copysign_optab): New.
9120 2023-11-09  Tamar Christina  <tamar.christina@arm.com>
9122         PR tree-optimization/109154
9123         * match.pd: Add new neg+abs rule, remove inverse copysign rule.
9125 2023-11-09  Tamar Christina  <tamar.christina@arm.com>
9127         PR tree-optimization/109154
9128         * match.pd: expand existing copysign optimizations.
9130 2023-11-09  Tatsuyuki Ishi  <ishitatsuyuki@gmail.com>
9132         PR driver/111605
9133         * collect2.cc (main): Do not prepend target triple to
9134         -fuse-ld=lld,mold.
9136 2023-11-09  Richard Biener  <rguenther@suse.de>
9138         PR tree-optimization/111133
9139         * tree-vect-stmts.cc (vect_build_scatter_store_calls):
9140         Remove and refactor to ...
9141         (vect_build_one_scatter_store_call): ... this new function.
9142         (vectorizable_store): Use vect_check_scalar_mask to record
9143         the SLP node for the mask operand.  Code generate scatters
9144         with builtin decls from the main scatter vectorization
9145         path and prepare that for SLP.
9146         * tree-vect-slp.cc (vect_get_operand_map): Do not look
9147         at the VDEF to decide between scatter or gather since that
9148         doesn't work for patterns.  Use the LHS being an SSA_NAME
9149         or not instead.
9151 2023-11-09  Pan Li  <pan2.li@intel.com>
9153         * config/riscv/riscv.cc (riscv_frm_emit_after_bb_end): Only
9154         perform once emit when at least one succ edge is abnormal.
9156 2023-11-09  Richard Biener  <rguenther@suse.de>
9158         * tree-vect-loop.cc (vect_verify_full_masking_avx512):
9159         Check we have integer mode masks as required by
9160         vect_get_loop_mask.
9162 2023-11-09  Richard Biener  <rguenther@suse.de>
9164         PR tree-optimization/112444
9165         * tree-ssa-sccvn.cc (visit_phi): Avoid using not visited
9166         defs as undefined vals.
9168 2023-11-09  YunQiang Su  <yunqiang.su@cipunited.com>
9170         * config/mips/mips.cc(mips_option_override): Set mips_abs to
9171         2008, if mips_abs is default and mips_nan is 2008.
9173 2023-11-09  Florian Weimer  <fweimer@redhat.com>
9175         * doc/invoke.texi (Warning Options): Document
9176         -Wreturn-mismatch.  Update -Wreturn-type documentation.
9178 2023-11-09  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
9180         * config/s390/s390.md: Remove UNSPEC_VEC_ELTSWAP.
9181         * config/s390/vector.md (eltswapv16qi): New expander.
9182         (*eltswapv16qi): New insn and splitter.
9183         (eltswapv8hi): New insn and splitter.
9184         (eltswap<mode>): New insn and splitter for modes V_HW_4 as well
9185         as V_HW_2.
9186         * config/s390/vx-builtins.md (eltswap<mode>): Remove.
9187         (*eltswapv16qi): Remove.
9188         (*eltswap<mode>): Remove.
9189         (*eltswap<mode>_emu): Remove.
9191 2023-11-09  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
9193         * config/s390/s390.cc (expand_perm_with_rot): Remove.
9194         (expand_perm_reverse_elements): New.
9195         (expand_perm_with_vster): Remove.
9196         (expand_perm_with_vstbrq): Remove.
9197         (vectorize_vec_perm_const_1): Replace removed functions with new
9198         one.
9200 2023-11-09  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
9202         * config/s390/s390.cc (expand_perm_with_merge): Deal with cases
9203         where vmr{l,h} are still applicable if the operands are swapped.
9204         (expand_perm_with_vpdi): Likewise for vpdi.
9206 2023-11-09  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
9208         * config/s390/s390.md (VX_CONV_INT): Remove iterator.
9209         (gf): Add float mappings.
9210         (TOINT, toint): New attribute.
9211         (*fixuns_trunc<VX_CONV_BFP:mode><VX_CONV_INT:mode>2_z13):
9212         Remove.
9213         (*fixuns_trunc<mode><toint>2_z13): Add.
9214         (*fix_trunc<VX_CONV_BFP:mode><VX_CONV_INT:mode>2_bfp_z13):
9215         Remove.
9216         (*fix_trunc<mode><toint>2_bfp_z13): Add.
9217         (*floatuns<VX_CONV_INT:mode><VX_CONV_BFP:mode>2_z13): Remove.
9218         (*floatuns<toint><mode>2_z13): Add.
9219         * config/s390/vector.md (VX_VEC_CONV_INT): Remove iterator.
9220         (float<VX_VEC_CONV_INT:mode><VX_VEC_CONV_BFP:mode>2): Remove.
9221         (float<tointvec><mode>2): Add.
9222         (floatuns<VX_VEC_CONV_INT:mode><VX_VEC_CONV_BFP:mode>2): Remove.
9223         (floatuns<tointvec><mode>2): Add.
9224         (fix_trunc<VX_VEC_CONV_BFP:mode><VX_VEC_CONV_INT:mode>2):
9225         Remove.
9226         (fix_trunc<mode><tointvec>2): Add.
9227         (fixuns_trunc<VX_VEC_CONV_BFP:mode><VX_VEC_CONV_INT:mode>2):
9228         Remove.
9229         (fixuns_trunc<VX_VEC_CONV_BFP:mode><tointvec>2): Add.
9231 2023-11-09  Jakub Jelinek  <jakub@redhat.com>
9233         PR c/112339
9234         * attribs.cc (attribute_ignored_p): Only return true for
9235         attr_namespace_ignored_p if as is NULL.
9236         (decl_attributes): Never add ignored attributes.
9238 2023-11-09  Jin Ma  <jinma@linux.alibaba.com>
9240         * config/riscv/bitmanip.md: Avoid the conflict between
9241         zbb and xtheadmemidx in patterns.
9243 2023-11-09  Richard Biener  <rguenther@suse.de>
9245         * tree-vect-stmts.cc (vectorizable_simd_clone_call): Record
9246         to the correct simd_clone_info.
9248 2023-11-09  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
9250         * config/riscv/riscv-vector-costs.cc (costs::preferred_new_lmul_p): Fix ICE.
9252 2023-11-09  Alexandre Oliva  <oliva@adacore.com>
9254         * tree-cfg.cc (assign_discriminators): Handle debug stmts.
9256 2023-11-08  Uros Bizjak  <ubizjak@gmail.com>
9258         PR target/82524
9259         * config/i386/i386.md (*add<mode>_1_slp):
9260         Split insn only for unmatched operand 0.
9261         (*sub<mode>_1_slp): Ditto.
9262         (*<any_logic:code><mode>_1_slp): Merge pattern from "*and<mode>_1_slp"
9263         and "*<any_logic:code><mode>_1_slp" using any_logic code iterator.
9264         Split insn only for unmatched operand 0.
9265         (*neg<mode>1_slp): Split insn only for unmatched operand 0.
9266         (*one_cmpl<mode>_1_slp): Ditto.
9267         (*ashl<mode>3_1_slp): Ditto.
9268         (*<any_shiftrt:insn><mode>_1_slp): Ditto.
9269         (*<any_rotate:insn><mode>_1_slp): Ditto.
9270         (*addqi_ext<mode>_1): Redefine as define_insn_and_split.  Add
9271         alternative 1 and split insn after reload for unmatched operand 0.
9272         (*<plusminus:insn>qi_ext<mode>_2): Merge pattern from
9273         "*addqi_ext<mode>_2" and "*subqi_ext<mode>_2" using plusminus code
9274         iterator. Redefine as define_insn_and_split.  Add alternative 1
9275         and split insn after reload for unmatched operand 0.
9276         (*subqi_ext<mode>_1): Redefine as define_insn_and_split.  Add
9277         alternative 1 and split insn after reload for unmatched operand 0.
9278         (*<any_logic:code>qi_ext<mode>_0): Merge pattern from
9279         "*andqi_ext<mode>_0" and and "*<any_logic:code>qi_ext<mode>_0" using
9280         any_logic code iterator.
9281         (*<any_logic:code>qi_ext<mode>_1): Merge pattern from
9282         "*andqi_ext<mode>_1" and "*<any_logic:code>qi_ext<mode>_1" using
9283         any_logic code iterator. Redefine as define_insn_and_split.  Add
9284         alternative 1 and split insn after reload for unmatched operand 0.
9285         (*<any_logic:code>qi_ext<mode>_1_cc): Merge pattern from
9286         "*andqi_ext<mode>_1_cc" and "*xorqi_ext<mode>_1_cc" using any_logic
9287         code iterator. Redefine as define_insn_and_split.  Add alternative 1
9288         and split insn after reload for unmatched operand 0.
9289         (*<any_logic:code>qi_ext<mode>_2): Merge pattern from
9290         "*andqi_ext<mode>_2" and "*<any_or:code>qi_ext<mode>_2" using
9291         any_logic code iterator. Redefine as define_insn_and_split.  Add
9292         alternative 1 and split insn after reload for unmatched operand 0.
9293         (*<any_logic:code>qi_ext<mode>_3): Redefine as define_insn_and_split.
9294         Add alternative 1 and split insn after reload for unmatched operand 0.
9295         (*negqi_ext<mode>_1): Rename from "*negqi_ext<mode>_2".  Add
9296         alternative 1 and split insn after reload for unmatched operand 0.
9297         (*one_cmplqi_ext<mode>_1): Ditto.
9298         (*ashlqi_ext<mode>_1): Ditto.
9299         (*<any_shiftrt:insn>qi_ext<mode>_1): Ditto.
9301 2023-11-08  Richard Biener  <rguenther@suse.de>
9303         * tree-vect-stmts.cc (vectorizable_load): Adjust offset
9304         vector gathering for SLP of emulated gathers.
9306 2023-11-08  Richard Biener  <rguenther@suse.de>
9308         * tree-vectorizer.h (vect_slp_child_index_for_operand):
9309         Add gatherscatter_p argument.
9310         * tree-vect-slp.cc (vect_slp_child_index_for_operand): Likewise.
9311         Pass it on.
9312         * tree-vect-stmts.cc (vect_check_store_rhs): Turn the rhs
9313         argument into an output, also output the SLP node associated
9314         with it.
9315         (vectorizable_simd_clone_call): Adjust.
9316         (vectorizable_store): Likewise.
9317         (vectorizable_load): Likewise.
9319 2023-11-08  Richard Biener  <rguenther@suse.de>
9321         * tree-vect-stmts.cc (vectorizable_load): Use the correct
9322         vectorized mask operand.
9324 2023-11-08  Lehua Ding  <lehua.ding@rivai.ai>
9326         * config/riscv/vector.md (*vsetvldi_no_side_effects_si_extend):
9327         New combine pattern.
9329 2023-11-08  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
9331         * config/riscv/riscv-vsetvl.cc: Fix ICE.
9333 2023-11-08  xuli  <xuli1@eswincomputing.com>
9335         * config/riscv/riscv-c.cc (riscv_check_builtin_call): Eliminate warning.
9337 2023-11-08  Hongyu Wang  <hongyu.wang@intel.com>
9339         PR target/112394
9340         * config/i386/constraints.md (jc): New constraint that prohibits
9341         EGPR on -mno-avx.
9342         * config/i386/i386.md (*movdi_internal): Change r constraint
9343         corresponds to Yd.
9344         (*movti_internal): Likewise.
9346 2023-11-08  Florian Weimer  <fweimer@redhat.com>
9348         * doc/invoke.texi (Warning Options): Mention C diagnostics
9349         for -fpermissive.
9351 2023-11-08  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
9353         PR target/112092
9354         * config/riscv/riscv-vector-builtins-bases.cc: Normalize the vsetvls.
9356 2023-11-08  Haochen Jiang  <haochen.jiang@intel.com>
9358         PR target/111907
9359         * config/i386/i386.md (avx_noavx512vl): New definition for isa
9360         attribute.
9361         * config/i386/sse.md (*andnot<mode>3): Change isa attribute from
9362         avx_noavx512f to avx_noavx512vl.
9364 2023-11-07  Pan Li  <pan2.li@intel.com>
9366         * config/riscv/autovec.md: Remove the size check of lfloor.
9367         * config/riscv/riscv-v.cc (expand_vec_lfloor): Leverage
9368         emit_vec_rounding_to_integer for floor.
9370 2023-11-07  Robin Dapp  <rdapp@ventanamicro.com>
9372         PR tree-optimization/112361
9373         PR target/112359
9374         PR middle-end/112406
9375         * tree-if-conv.cc (convert_scalar_cond_reduction): Remember if
9376         loop was versioned and only then create COND_OPs.
9377         (predicate_scalar_phi): Do not create COND_OP when not
9378         vectorizing.
9379         * tree-vect-loop.cc (vect_expand_fold_left): Re-create
9380         VEC_COND_EXPR.
9381         (vectorize_fold_left_reduction): Pass mask to
9382         vect_expand_fold_left.
9384 2023-11-07  Uros Bizjak  <ubizjak@gmail.com>
9386         * config/i386/predicates.md ("flags_reg_operand"):
9387         Make predicate special to avoid automatic mode checks.
9389 2023-11-07  Martin Jambor  <mjambor@suse.cz>
9391         * configure: Regenerate.
9393 2023-11-07  Kwok Cheung Yeung  <kcy@codesourcery.com>
9395         * lto-cgraph.cc (enum LTO_symtab_tags): Add tag for indirect
9396         functions.
9397         (output_offload_tables): Write indirect functions.
9398         (input_offload_tables): read indirect functions.
9399         * lto-section-names.h (OFFLOAD_IND_FUNC_TABLE_SECTION_NAME): New.
9400         * omp-builtins.def (BUILT_IN_GOMP_TARGET_MAP_INDIRECT_PTR): New.
9401         * omp-offload.cc (offload_ind_funcs): New.
9402         (omp_discover_implicit_declare_target): Add functions marked with
9403         'omp declare target indirect' to indirect functions list.
9404         (omp_finish_file): Add indirect functions to section for offload
9405         indirect functions.
9406         (execute_omp_device_lower): Redirect indirect calls on target by
9407         passing function pointer to BUILT_IN_GOMP_TARGET_MAP_INDIRECT_PTR.
9408         (pass_omp_device_lower::gate): Run pass_omp_device_lower if
9409         indirect functions are present on an accelerator device.
9410         * omp-offload.h (offload_ind_funcs): New.
9411         * tree-core.h (omp_clause_code): Add OMP_CLAUSE_INDIRECT.
9412         * tree.cc (omp_clause_num_ops): Add entry for OMP_CLAUSE_INDIRECT.
9413         (omp_clause_code_name): Likewise.
9414         * tree.h (OMP_CLAUSE_INDIRECT_EXPR): New.
9415         * config/gcn/mkoffload.cc (process_asm): Process offload_ind_funcs
9416         section.  Count number of indirect functions.
9417         (process_obj): Emit number of indirect functions.
9418         * config/nvptx/mkoffload.cc (ind_func_ids, ind_funcs_tail): New.
9419         (process): Emit offload_ind_func_table in PTX code.  Emit indirect
9420         function names and count in image.
9421         * config/nvptx/nvptx.cc (nvptx_record_offload_symbol): Mark
9422         indirect functions in PTX code with IND_FUNC_MAP.
9424 2023-11-07  Tobias Burnus  <tobias@codesourcery.com>
9426         * doc/invoke.texi (-fopenmp, -fopenmp-simd): Adjust wording for
9427         attribute syntax supported also in C.
9429 2023-11-07  Richard Sandiford  <richard.sandiford@arm.com>
9431         * config/aarch64/aarch64.cc (aarch64_print_operand): Add a %Z
9432         modifier for SVE registers.
9434 2023-11-07  Joseph Myers  <joseph@codesourcery.com>
9436         * builtins.def (DEF_C2X_BUILTIN): Rename to DEF_C23_BUILTIN and
9437         use flag_isoc23 and function_c23_misc.
9438         * config/rl78/rl78.cc (rl78_option_override): Compare
9439         lang_hooks.name with "GNU C23" not "GNU C2X".
9440         * coretypes.h (function_c2x_misc): Rename to function_c23_misc.
9441         * doc/cpp.texi (@code{__has_attribute}): Refer to C23 instead of
9442         C2x.
9443         * doc/extend.texi: Likewise.
9444         * doc/invoke.texi: Likewise.
9445         * dwarf2out.cc (highest_c_language, gen_compile_unit_die): Compare
9446         against and return "GNU C23" language string instead of "GNU C2X".
9447         * ginclude/float.h: Refer to C23 instead of C2X in comments.
9448         * ginclude/stdint-gcc.h: Likewise.
9449         * glimits.h: Likewise.
9450         * tree.h: Likewise.
9452 2023-11-07  Alexandre Oliva  <oliva@adacore.com>
9454         * doc/sourcebuild.texi (opt_mstrict_align): New target.
9456 2023-11-07  Lehua Ding  <lehua.ding@rivai.ai>
9458         * config/riscv/autovec-opt.md (*cond_len_<optab><v_double_trunc><mode>):
9459         New combine pattern.
9460         (*cond_len_<optab><v_quad_trunc><mode>): Ditto.
9461         (*cond_len_<optab><v_oct_trunc><mode>): Ditto.
9462         (*cond_len_extend<v_double_trunc><mode>): Ditto.
9463         (*cond_len_widen_reduc_plus_scal_<mode>): Ditto.
9465 2023-11-07  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
9467         PR target/112399
9468         * config/riscv/riscv-avlprop.cc
9469         (pass_avlprop::get_vlmax_ta_preferred_avl): Enhance AVL propagation.
9470         * config/riscv/t-riscv: Add new include.
9472 2023-11-07  Pan Li  <pan2.li@intel.com>
9474         * config/riscv/autovec.md: Remove the size check of lceil.l
9475         * config/riscv/riscv-v.cc (expand_vec_lceil):  Leverage
9476         emit_vec_rounding_to_integer for ceil.
9478 2023-11-06  John David Anglin  <danglin@gcc.gnu.org>
9480         * config/pa/pa.cc (pa_asm_trampoline_template): Fix typo.
9482 2023-11-06  John David Anglin  <danglin@gcc.gnu.org>
9484         * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 1.
9486 2023-11-06  David Malcolm  <dmalcolm@redhat.com>
9488         * diagnostic-show-locus.cc (class colorizer): Take just a
9489         pretty_printer rather than a diagnostic_context.
9490         (layout::layout): Make context param a const reference,
9491         and pretty_printer param non-optional.
9492         (layout::m_context): Drop field.
9493         (layout::m_options): New field.
9494         (layout::m_colorize_source_p): Drop field.
9495         (layout::m_show_labels_p): Drop field.
9496         (layout::m_show_line_numbers_p): Drop field.
9497         (layout::print_gap_in_line_numbering): Use m_options.
9498         (layout::calculate_line_spans): Likewise.
9499         (layout::calculate_linenum_width): Likewise.
9500         (layout::calculate_x_offset_display): Likewise.
9501         (layout::print_source_line): Likewise.
9502         (layout::start_annotation_line): Likewise.
9503         (layout::print_annotation_line): Likewise.
9504         (layout::print_line): Likewise.
9505         (gcc_rich_location::add_location_if_nearby): Update for changes to
9506         layout ctor.
9507         (diagnostic_show_locus): Likewise.
9508         (selftest::test_offset_impl): Likewise.
9509         (selftest::test_layout_x_offset_display_utf8): Likewise.
9510         (selftest::test_layout_x_offset_display_tab): Likewise.
9511         (selftest::test_tab_expansion): Likewise.
9512         * diagnostic.h (diagnostic_context::m_source_printing): Move
9513         declaration of struct outside diagnostic_context as...
9514         (struct diagnostic_source_printing_options)... this.
9516 2023-11-06  David Malcolm  <dmalcolm@redhat.com>
9518         * diagnostic.cc (diagnostic_context::push_diagnostics): Convert
9519         to...
9520         (diagnostic_option_classifier::push): ...this.
9521         (diagnostic_context::pop_diagnostics): Convert to...
9522         (diagnostic_option_classifier::pop): ...this.
9523         (diagnostic_context::initialize): Move code to...
9524         (diagnostic_option_classifier::init): ...this new function.
9525         (diagnostic_context::finish): Move code to...
9526         (diagnostic_option_classifier::fini): ...this new function.
9527         (diagnostic_context::classify_diagnostic): Convert to...
9528         (diagnostic_option_classifier::classify_diagnostic): ...this.
9529         (diagnostic_context::update_effective_level_from_pragmas): Convert
9530         to...
9531         (diagnostic_option_classifier::update_effective_level_from_pragmas):
9532         ...this.
9533         (diagnostic_context::diagnostic_enabled): Update for refactoring.
9534         * diagnostic.h (struct diagnostic_classification_change_t): Move into...
9535         (class diagnostic_option_classifier): ...this new class.
9536         (diagnostic_context::option_unspecified_p): Update for move of
9537         fields into m_option_classifier.
9538         (diagnostic_context::classify_diagnostic): Likewise.
9539         (diagnostic_context::push_diagnostics): Likewise.
9540         (diagnostic_context::pop_diagnostics): Likewise.
9541         (diagnostic_context::update_effective_level_from_pragmas): Delete.
9542         (diagnostic_context::m_classify_diagnostic): Move into class
9543         diagnostic_option_classifier.
9544         (diagnostic_context::m_option_classifier): Likewise.
9545         (diagnostic_context::m_classification_history): Likewise.
9546         (diagnostic_context::m_n_classification_history): Likewise.
9547         (diagnostic_context::m_push_list): Likewise.
9548         (diagnostic_context::m_n_push): Likewise.
9549         (diagnostic_context::m_option_classifier): New.
9551 2023-11-06  David Malcolm  <dmalcolm@redhat.com>
9553         * diagnostic.cc (diagnostic_context::set_urlifier): New.
9554         * diagnostic.h (diagnostic_context::set_urlifier): New decl.
9555         (diagnostic_context::m_urlifier): Make private.
9556         * gcc.cc (driver::global_initializations): Use set_urlifier rather
9557         than directly setting field.
9558         * toplev.cc (general_init): Likewise.
9560 2023-11-06  David Malcolm  <dmalcolm@redhat.com>
9562         * diagnostic.cc (diagnostic_context::check_max_errors): Replace
9563         uses of diagnostic_kind_count with simple field acesss.
9564         (diagnostic_context::report_diagnostic): Likewise.
9565         (diagnostic_text_output_format::~diagnostic_text_output_format):
9566         Replace use of diagnostic_kind_count with
9567         diagnostic_context::diagnostic_count.
9568         * diagnostic.h (diagnostic_kind_count): Delete.
9569         (errorcount): Replace use of diagnostic_kind_count with
9570         diagnostic_context::diagnostic_count.
9571         (warningcount): Likewise.
9572         (werrorcount): Likewise.
9573         (sorrycount): Likewise.
9575 2023-11-06  Christophe Lyon  <christophe.lyon@linaro.org>
9577         * doc/sourcebuild.texi (Other attributes): Document thread_fence
9578         effective-target.
9580 2023-11-06  Uros Bizjak  <ubizjak@gmail.com>
9582         * config/i386/constraints.md (Bc): Remove constraint.
9583         (Bn): Rewrite to use x86_extended_reg_mentioned_p predicate.
9584         * config/i386/i386.cc (ix86_memory_address_reg_class):
9585         Do not limit processing to TARGET_APX_EGPR.  Exit early for
9586         NULL insn.  Do not check recog_data.insn before calling
9587         extract_insn_cached.
9588         (ix86_insn_base_reg_class): Handle ADDR_GPR8.
9589         (ix86_regno_ok_for_insn_base_p): Ditto.
9590         (ix86_insn_index_reg_class): Ditto.
9591         * config/i386/i386.md (*cmpqi_ext<mode>_1_mem_rex64):
9592         Remove insn pattern and corresponding peephole2 pattern.
9593         (*cmpi_ext<mode>_1): Remove (m,Q) alternative.
9594         Change (QBc,Q) alternative to (QBn,Q).  Add "addr" attribute.
9595         (*cmpqi_ext<mode>_3_mem_rex64): Remove insn pattern
9596         and corresponding peephole2 pattern.
9597         (*cmpi_ext<mode>_3): Remove (Q,m) alternative.
9598         Change (Q,QnBc) alternative to (Q,QnBn).  Add "addr" attribute.
9599         (*extzvqi_mem_rex64): Remove insn pattern and
9600         corresponding peephole2 pattern.
9601         (*extzvqi): Remove (Q,m) alternative.  Change (Q,QnBc)
9602         alternative to (Q,QnBn).  Add "addr" attribute.
9603         (*insvqi_1_mem_rex64): Remove insn pattern and
9604         corresponding peephole2 pattern.
9605         (*insvqi_1): Remove (Q,m) alternative.  Change (Q,QnBc)
9606         alternative to (Q,QnBn).  Add "addr" attribute.
9607         (@insv<mode>_1): Ditto.
9608         (*addqi_ext<mode>_0): Remove (m,0,Q) alternative.  Change (QBc,0,Q)
9609         alternative to (QBn,0,Q).  Add "addr" attribute.
9610         (*subqi_ext<mode>_0): Ditto.
9611         (*andqi_ext<mode>_0): Ditto.
9612         (*<any_or:code>qi_ext<mode>_0): Ditto.
9613         (*addqi_ext<mode>_1): Remove (Q,0,m) alternative.  Change (Q,0,QnBc)
9614         alternative to (Q,0,QnBn).  Add "addr" attribute.
9615         (*andqi_ext<mode>_1): Ditto.
9616         (*andqi_ext<mode>_1_cc): Ditto.
9617         (*<any_or:code>qi_ext<mode>_1): Ditto.
9618         (*xorqi_ext<mode>_1_cc): Ditto.
9619         * config/i386/predicates.md (nonimm_x64constmem_operand):
9620         Remove predicate.
9621         (general_x64constmem_operand): Ditto.
9622         (norex_memory_operand): Ditto.
9624 2023-11-06  Joseph Myers  <joseph@codesourcery.com>
9626         PR c/107954
9627         * doc/cpp.texi (__STDC_VERSION__): Refer to -std=c23 and
9628         -std=gnu23 instead of -std=c2x and -std=gnu2x.
9629         * doc/extend.texi (Attribute Syntax): Refer to C23 and -std=c23
9630         instead of C2x and -std=c2x.
9631         * doc/invoke.texi (-Wc11-c23-compat, -std=c23, -std=gnu23)
9632         (-std=iso9899:2024): Document, with -Wc11-c2x-compat, -std=c2x and
9633         -std=gnu2x as deprecated aliases.  Update descriptions of C23.
9634         * doc/standards.texi (Standards): Describe C23 with C2X as an old
9635         name.
9637 2023-11-06  Thomas Schwinge  <thomas@codesourcery.com>
9639         * config/nvptx/nvptx.h (MAKE_DECL_ONE_ONLY): Define.
9641 2023-11-06  Richard Biener  <rguenther@suse.de>
9643         PR tree-optimization/112405
9644         * tree-vect-stmts.cc (vectorizable_simd_clone_call):
9645         Properly handle invariant and/or loop mask passing.
9647 2023-11-06  Pan Li  <pan2.li@intel.com>
9649         * config/riscv/autovec.md: Remove the size check of lround.
9650         * config/riscv/riscv-v.cc (expand_vec_lround): Leverage
9651         emit_vec_rounding_to_integer for round.
9653 2023-11-06  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
9655         * config/riscv/predicates.md: Adapt predicate.
9656         * config/riscv/riscv-protos.h (can_be_broadcasted_p): New function.
9657         * config/riscv/riscv-v.cc (can_be_broadcasted_p): Ditto.
9658         * config/riscv/vector.md (vec_duplicate<mode>): New pattern.
9659         (*vec_duplicate<mode>): Adapt vec_duplicate insn pattern.
9661 2023-11-06  Richard Biener  <rguenther@suse.de>
9663         PR tree-optimization/111950
9664         * tree-vect-loop-manip.cc (slpeel_duplicate_current_defs_from_edges):
9665         Remove.
9666         (find_guard_arg): Likewise.
9667         (slpeel_update_phi_nodes_for_guard2): Likewise.
9668         (slpeel_tree_duplicate_loop_to_edge_cfg): Remove calls to
9669         slpeel_duplicate_current_defs_from_edges, do not elide
9670         LC-PHIs for invariant values.
9671         (vect_do_peeling): Materialize PHI arguments for the edge
9672         around the epilog from the PHI defs of the main loop exit.
9674 2023-11-06  Richard Biener  <rguenther@suse.de>
9676         PR tree-optimization/112404
9677         * tree-vectorizer.h (get_mask_type_for_scalar_type): Declare
9678         overload with SLP node argument.
9679         * tree-vect-stmts.cc (get_mask_type_for_scalar_type): Implement it.
9680         (vect_check_scalar_mask): Use it.
9681         * tree-vect-slp.cc (vect_gather_slp_loads): Properly identify
9682         loads also for nodes with children, like .MASK_LOAD.
9683         * tree-vect-loop.cc (vect_analyze_loop_2): Look at the
9684         representative for load nodes and check whether it is a grouped
9685         access before looking for load-lanes support.
9687 2023-11-06  Robin Dapp  <rdapp@ventanamicro.com>
9689         PR tree-optimization/111760
9690         * config/riscv/autovec.md (vcond_mask_len_<mode><vm>): Add
9691         expander.
9692         * config/riscv/riscv-protos.h (enum insn_type): Add.
9693         * config/riscv/riscv-v.cc (needs_fp_rounding): Add !pred_mov.
9694         * doc/md.texi: Add vcond_mask_len.
9695         * gimple-match-exports.cc (maybe_resimplify_conditional_op):
9696         Create VCOND_MASK_LEN when length masking.
9697         * gimple-match.h (gimple_match_op::gimple_match_op): Always
9698         initialize len and bias.
9699         * internal-fn.cc (vec_cond_mask_len_direct): Add.
9700         (direct_vec_cond_mask_len_optab_supported_p): Add.
9701         (internal_fn_len_index): Add VCOND_MASK_LEN.
9702         (internal_fn_mask_index): Ditto.
9703         * internal-fn.def (VCOND_MASK_LEN): New internal function.
9704         * match.pd: Combine unconditional unary, binary and ternary
9705         operations into the respective COND_LEN operations.
9706         * optabs.def (OPTAB_D): Add vcond_mask_len optab.
9708 2023-11-06  Richard Sandiford  <richard.sandiford@arm.com>
9710         * explow.cc (align_dynamic_address): Do nothing if the required
9711         alignment is a byte.
9713 2023-11-06  Richard Sandiford  <richard.sandiford@arm.com>
9715         * function.h (get_stack_dynamic_offset): Declare.
9716         * function.cc (get_stack_dynamic_offset): New function,
9717         split out from...
9718         (get_stack_dynamic_offset): ...here.
9719         * explow.cc (allocate_dynamic_stack_space): Handle calls made
9720         after virtual registers have been instantiated.
9722 2023-11-06  liuhongt  <hongtao.liu@intel.com>
9724         PR target/112393
9725         * config/i386/i386-expand.cc (ix86_expand_vec_perm_vpermt2):
9726         Avoid generating RTL code when d->testing_p.
9728 2023-11-06  Richard Biener  <rguenther@suse.de>
9730         PR tree-optimization/112369
9731         * tree.cc (strip_float_extensions): Use element_precision.
9733 2023-11-06  Richard Biener  <rguenther@suse.de>
9735         PR middle-end/112296
9736         * doc/extend.texi (__builtin_constant_p): Clarify that
9737         side-effects are discarded.
9739 2023-11-06  Kewen Lin  <linkw@linux.ibm.com>
9741         PR target/111828
9742         * config.in: Regenerate.
9743         * config/rs6000/rs6000.cc (rs6000_update_ipa_fn_target_info): Guard
9744         inline asm handling under !HAVE_AS_POWER10_HTM.
9745         * configure: Regenerate.
9746         * configure.ac: Detect assembler support for HTM insns at power10.
9748 2023-11-06  xuli  <xuli1@eswincomputing.com>
9749             Pan Li  <pan2.li@intel.com>
9751         * config/riscv/riscv-c.cc (riscv_resolve_overloaded_builtin): New function for the hook.
9752         (riscv_register_pragmas): Register the hook.
9753         * config/riscv/riscv-protos.h (resolve_overloaded_builtin): New decl.
9754         * config/riscv/riscv-vector-builtins-bases.cc: New function impl.
9755         * config/riscv/riscv-vector-builtins-shapes.cc (build_one): Register overloaded function.
9756         * config/riscv/riscv-vector-builtins.cc (struct non_overloaded_registered_function_hasher):
9757         New hash table.
9758         (function_builder::add_function): Add overloaded arg.
9759         (function_builder::add_unique_function): Map overloaded function to non-overloaded function.
9760         (function_builder::add_overloaded_function): New API impl.
9761         (registered_function::overloaded_hash): Calculate hash value.
9762         (has_vxrm_or_frm_p): New function impl.
9763         (non_overloaded_registered_function_hasher::hash): Ditto.
9764         (non_overloaded_registered_function_hasher::equal): Ditto.
9765         (handle_pragma_vector): Allocate space for hash table.
9766         (resolve_overloaded_builtin): New function impl.
9767         * config/riscv/riscv-vector-builtins.h (function_base::may_require_frm_p): Ditto.
9768         (function_base::may_require_vxrm_p): Ditto.
9770 2023-11-06  Haochen Jiang  <haochen.jiang@intel.com>
9772         PR target/111889
9773         * config/i386/avx512bf16intrin.h: Push no-evex512 target.
9774         * config/i386/avx512bf16vlintrin.h: Ditto.
9775         * config/i386/avx512bitalgvlintrin.h: Ditto.
9776         * config/i386/avx512bwintrin.h: Ditto.
9777         * config/i386/avx512dqintrin.h: Ditto.
9778         * config/i386/avx512fintrin.h: Ditto.
9779         * config/i386/avx512fp16intrin.h: Ditto.
9780         * config/i386/avx512fp16vlintrin.h: Ditto.
9781         * config/i386/avx512ifmavlintrin.h: Ditto.
9782         * config/i386/avx512vbmi2vlintrin.h: Ditto.
9783         * config/i386/avx512vbmivlintrin.h: Ditto.
9784         * config/i386/avx512vlbwintrin.h: Ditto.
9785         * config/i386/avx512vldqintrin.h: Ditto.
9786         * config/i386/avx512vlintrin.h: Ditto.
9787         * config/i386/avx512vnnivlintrin.h: Ditto.
9788         * config/i386/avx512vp2intersectvlintrin.h: Ditto.
9789         * config/i386/avx512vpopcntdqvlintrin.h: Ditto.
9791 2023-11-06  Haochen Jiang  <haochen.jiang@intel.com>
9793         * config/i386/avx512bf16vlintrin.h
9794         (_mm_avx512_castsi128_ps): New.
9795         (_mm256_avx512_castsi256_ps): Ditto.
9796         (_mm_avx512_slli_epi32): Ditto.
9797         (_mm256_avx512_slli_epi32): Ditto.
9798         (_mm_avx512_cvtepi16_epi32): Ditto.
9799         (_mm256_avx512_cvtepi16_epi32): Ditto.
9800         (__attribute__): Change intrin call.
9801         * config/i386/avx512bwintrin.h
9802         (_mm_avx512_set_epi32): New.
9803         (_mm_avx512_set_epi16): Ditto.
9804         (_mm_avx512_set_epi8): Ditto.
9805         (__attribute__): Change intrin call.
9806         * config/i386/avx512fp16intrin.h: Ditto.
9807         * config/i386/avx512fp16vlintrin.h
9808         (_mm_avx512_set1_ps): New.
9809         (_mm256_avx512_set1_ps): Ditto.
9810         (_mm_avx512_and_si128): Ditto.
9811         (_mm256_avx512_and_si256): Ditto.
9812         (__attribute__): Change intrin call.
9813         * config/i386/avx512vlbwintrin.h
9814         (_mm_avx512_set1_epi32): New.
9815         (_mm_avx512_set1_epi16): Ditto.
9816         (_mm_avx512_set1_epi8): Ditto.
9817         (_mm256_avx512_set_epi16): Ditto.
9818         (_mm256_avx512_set_epi8): Ditto.
9819         (_mm256_avx512_set1_epi16): Ditto.
9820         (_mm256_avx512_set1_epi32): Ditto.
9821         (_mm256_avx512_set1_epi8): Ditto.
9822         (_mm_avx512_max_epi16): Ditto.
9823         (_mm_avx512_min_epi16): Ditto.
9824         (_mm_avx512_max_epu16): Ditto.
9825         (_mm_avx512_min_epu16): Ditto.
9826         (_mm_avx512_max_epi8): Ditto.
9827         (_mm_avx512_min_epi8): Ditto.
9828         (_mm_avx512_max_epu8): Ditto.
9829         (_mm_avx512_min_epu8): Ditto.
9830         (_mm256_avx512_max_epi16): Ditto.
9831         (_mm256_avx512_min_epi16): Ditto.
9832         (_mm256_avx512_max_epu16): Ditto.
9833         (_mm256_avx512_min_epu16): Ditto.
9834         (_mm256_avx512_insertf128_ps): Ditto.
9835         (_mm256_avx512_extractf128_pd): Ditto.
9836         (_mm256_avx512_extracti128_si256): Ditto.
9837         (_MM256_AVX512_REDUCE_OPERATOR_BASIC_EPI16): Ditto.
9838         (_MM256_AVX512_REDUCE_OPERATOR_MAX_MIN_EP16): Ditto.
9839         (_MM256_AVX512_REDUCE_OPERATOR_BASIC_EPI8): Ditto.
9840         (_MM256_AVX512_REDUCE_OPERATOR_MAX_MIN_EP8): Ditto.
9841         (__attribute__): Change intrin call.
9843 2023-11-06  Haochen Jiang  <haochen.jiang@intel.com>
9845         * config/i386/avx512bf16vlintrin.h: Change intrin call.
9846         * config/i386/avx512fintrin.h
9847         (_mm_avx512_undefined_ps): New.
9848         (_mm_avx512_undefined_pd): Ditto.
9849         (__attribute__): Change intrin call.
9850         * config/i386/avx512vbmivlintrin.h: Ditto.
9851         * config/i386/avx512vlbwintrin.h: Ditto.
9852         * config/i386/avx512vldqintrin.h: Ditto.
9853         * config/i386/avx512vlintrin.h
9854         (_mm_avx512_undefined_si128): New.
9855         (_mm256_avx512_undefined_ps): Ditto.
9856         (_mm256_avx512_undefined_pd): Ditto.
9857         (_mm256_avx512_undefined_si256): Ditto.
9858         (__attribute__): Change intrin call.
9860 2023-11-06  Haochen Jiang  <haochen.jiang@intel.com>
9862         * config/i386/avx512bitalgvlintrin.h: Change intrin call.
9863         * config/i386/avx512dqintrin.h: Ditto.
9864         * config/i386/avx512fintrin.h:
9865         (_mm_avx512_setzero_ps): New.
9866         (_mm_avx512_setzero_pd): Ditto.
9867         (__attribute__): Change intrin call.
9868         * config/i386/avx512fp16intrin.h: Ditto.
9869         * config/i386/avx512fp16vlintrin.h: Ditto.
9870         * config/i386/avx512vbmi2vlintrin.h: Ditto.
9871         * config/i386/avx512vbmivlintrin.h: Ditto.
9872         * config/i386/avx512vlbwintrin.h: Ditto.
9873         * config/i386/avx512vldqintrin.h: Ditto.
9874         * config/i386/avx512vlintrin.h
9875         (_mm_avx512_setzero_si128): New.
9876         (_mm256_avx512_setzero_pd): Ditto.
9877         (_mm256_avx512_setzero_ps): Ditto.
9878         (_mm256_avx512_setzero_si256): Ditto.
9879         (__attribute__): Change intrin call.
9880         * config/i386/avx512vpopcntdqvlintrin.h: Ditto.
9881         * config/i386/gfniintrin.h: Ditto.
9883 2023-11-05  Uros Bizjak  <ubizjak@gmail.com>
9885         * config/i386/i386.h (enum reg_class): Add LEGACY_INDEX_REGS.
9886         Rename LEGACY_REGS to LEGACY_GENERAL_REGS.
9887         (REG_CLASS_NAMES): Ditto.
9888         (REG_CLASS_CONTENTS): Ditto.
9889         * config/i386/constraints.md ("R"): Update for rename.
9891 2023-11-05  Richard Sandiford  <richard.sandiford@arm.com>
9893         * mode-switching.cc: Remove unused forward references.
9894         (seginfo): Remove bbnum.
9895         (new_seginfo): Remove associated argument.
9896         (optimize_mode_switching): Update calls accordingly.
9898 2023-11-05  Richard Sandiford  <richard.sandiford@arm.com>
9900         * read-rtl.cc (read_rtx_operand): Avoid spinning endlessly for
9901         invalid [...] operands.
9903 2023-11-05  Richard Sandiford  <richard.sandiford@arm.com>
9905         PR target/112105
9906         * config/aarch64/aarch64.cc (aarch64_modes_compatible_p): New
9907         function, with the core logic extracted from...
9908         (aarch64_can_change_mode_class): ...here.  Extend the previous rules
9909         to allow changes between partial SVE modes and other modes if
9910         the other mode is no bigger than an element, and if no other rule
9911         prevents it.  Use the aarch64_modes_tieable_p handling of
9912         partial Advanced SIMD structure modes.
9913         (aarch64_modes_tieable_p): Use aarch64_modes_compatible_p.
9914         Allow all vector mode ties that it allows.
9916 2023-11-05  Pan Li  <pan2.li@intel.com>
9918         * config/riscv/autovec.md: Remove the size check of lrint.
9919         * config/riscv/riscv-v.cc (emit_vec_narrow_cvt_x_f): New help
9920         emit func impl.
9921         (emit_vec_widden_cvt_x_f): New help emit func impl.
9922         (emit_vec_rounding_to_integer): New func impl to emit the
9923         rounding from FP to integer.
9924         (expand_vec_lrint): Leverage emit_vec_rounding_to_integer.
9925         * config/riscv/vector.md: Take V_VLSF for vfncvt.
9927 2023-11-05  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
9929         * config/riscv/vector.md: Fix bug.
9931 2023-11-04  Sergei Trofimovich  <siarheit@google.com>
9933         PR bootstrap/112379
9934         * gcc-urlifier.cc (get_url_suffix_for_quoted_text): Mark as
9935         ATTRIBUTE_UNUSED.
9937 2023-11-04  Pan Li  <pan2.li@intel.com>
9939         * config/riscv/vector-iterators.md: Remove HF modes.
9941 2023-11-04  David Malcolm  <dmalcolm@redhat.com>
9943         * diagnostic.cc: Include "pretty-print-urlifier.h".
9944         (diagnostic_context::initialize): Initialize m_urlifier.
9945         (diagnostic_context::finish): Clean up m_urlifier
9946         (diagnostic_report::diagnostic): m_urlifier to pp_format.
9947         * diagnostic.h (diagnostic_context::m_urlifier): New field.
9948         * gcc-urlifier.cc: New file.
9949         * gcc-urlifier.def: New file.
9950         * gcc-urlifier.h: New file.
9951         * gcc.cc: Include "gcc-urlifier.h".
9952         (driver::global_initializations): Initialize global_dc->m_urlifier.
9953         * pretty-print-urlifier.h: New file.
9954         * pretty-print.cc: Include "pretty-print-urlifier.h".
9955         (obstack_append_string): New.
9956         (urlify_quoted_string): New.
9957         (pp_format): Add "urlifier" param and use it to implement optional
9958         urlification of quoted text strings.
9959         (pp_output_formatted_text): Make buffer a const pointer.
9960         (selftest::pp_printf_with_urlifier): New.
9961         (selftest::test_urlification): New.
9962         (selftest::pretty_print_cc_tests): Call it.
9963         * pretty-print.h (class urlifier): New forward declaration.
9964         (pp_format): Add optional urlifier param.
9965         * selftest-run-tests.cc (selftest::run_tests): Call
9966         selftest::gcc_urlifier_cc_tests .
9967         * selftest.h (selftest::gcc_urlifier_cc_tests): New decl.
9968         * toplev.cc: Include "gcc-urlifier.h".
9969         (general_init): Initialize global_dc->m_urlifier.
9971 2023-11-04  David Malcolm  <dmalcolm@redhat.com>
9973         * Makefile.in (GCC_OBJS): Add gcc-urlifier.o.
9974         (OBJS): Likewise.
9976 2023-11-04  David Malcolm  <dmalcolm@redhat.com>
9978         * common.opt (fdiagnostics-text-art-charset=): Remove refererence
9979         to diagnostic-text-art.h.
9980         * coretypes.h (struct diagnostic_context): Replace forward decl
9981         with...
9982         (class diagnostic_context): ...this.
9983         * diagnostic-format-json.cc: Update for changes to
9984         diagnostic_context.
9985         * diagnostic-format-sarif.cc: Likewise.
9986         * diagnostic-show-locus.cc: Likewise.
9987         * diagnostic-text-art.h: Deleted file, moving content...
9988         (enum diagnostic_text_art_charset): ...to diagnostic.h,
9989         (DIAGNOSTICS_TEXT_ART_CHARSET_DEFAULT): ...deleting,
9990         (diagnostics_text_art_charset_init): ...deleting in favor of
9991         diagnostic_context::set_text_art_charset.
9992         * diagnostic.cc: Remove include of "diagnostic-text-art.h".
9993         (pedantic_warning_kind): Update for field renaming.
9994         (permissive_error_kind): Likewise.
9995         (permissive_error_option): Likewise.
9996         (diagnostic_initialize): Convert to...
9997         (diagnostic_context::initialize): ...this, updating for field
9998         renamings.
9999         (diagnostic_color_init): Convert to...
10000         (diagnostic_context::color_init): ...this.
10001         (diagnostic_urls_init): Convert to...
10002         (diagnostic_context::urls_init): ...this.
10003         (diagnostic_initialize_input_context): Convert to...
10004         (diagnostic_context::initialize_input_context): ...this.
10005         (diagnostic_finish): Convert to...
10006         (diagnostic_context::finish): ...this, updating for field
10007         renamings.
10008         (diagnostic_context::set_output_format): New.
10009         (diagnostic_context::set_client_data_hooks): New.
10010         (diagnostic_context::create_edit_context): New.
10011         (diagnostic_converted_column): Convert to...
10012         (diagnostic_context::converted_column): ...this.
10013         (diagnostic_get_location_text): Update for field renaming.
10014         (diagnostic_check_max_errors): Convert to...
10015         (diagnostic_context::check_max_errors): ...this, updating for
10016         field renamings.
10017         (diagnostic_action_after_output): Convert to...
10018         (diagnostic_context::action_after_output): ...this, updating for
10019         field renamings.
10020         (last_module_changed_p): Delete.
10021         (set_last_module): Delete.
10022         (includes_seen): Convert to...
10023         (diagnostic_context::includes_seen_p): ...this, updating for field
10024         renamings.
10025         (diagnostic_report_current_module): Convert to...
10026         (diagnostic_context::report_current_module): ...this, updating for
10027         field renamings, and replacing uses of last_module_changed_p and
10028         set_last_module to simple field accesses.
10029         (diagnostic_show_any_path): Convert to...
10030         (diagnostic_context::show_any_path): ...this.
10031         (diagnostic_classify_diagnostic): Convert to...
10032         (diagnostic_context::classify_diagnostic): ...this, updating for
10033         field renamings.
10034         (diagnostic_push_diagnostics): Convert to...
10035         (diagnostic_context::push_diagnostics): ...this, updating for field
10036         renamings.
10037         (diagnostic_pop_diagnostics): Convert to...
10038         (diagnostic_context::pop_diagnostics): ...this, updating for field
10039         renamings.
10040         (get_any_inlining_info): Convert to...
10041         (diagnostic_context::get_any_inlining_info): ...this, updating for
10042         field renamings.
10043         (update_effective_level_from_pragmas): Convert to...
10044         (diagnostic_context::update_effective_level_from_pragmas):
10045         ...this, updating for field renamings.
10046         (print_any_cwe): Convert to...
10047         (diagnostic_context::print_any_cwe): ...this.
10048         (print_any_rules): Convert to...
10049         (diagnostic_context::print_any_rules): ...this.
10050         (print_option_information): Convert to...
10051         (diagnostic_context::print_option_information): ...this, updating
10052         for field renamings.
10053         (diagnostic_enabled): Convert to...
10054         (diagnostic_context::diagnostic_enabled): ...this, updating for
10055         field renamings.
10056         (warning_enabled_at): Convert to...
10057         (diagnostic_context::warning_enabled_at): ...this.
10058         (diagnostic_report_diagnostic): Convert to...
10059         (diagnostic_context::report_diagnostic): ...this, updating for
10060         field renamings and conversions to member functions.
10061         (diagnostic_append_note): Update for field renaming.
10062         (diagnostic_impl): Use diagnostic_context::report_diagnostic
10063         directly.
10064         (diagnostic_n_impl): Likewise.
10065         (diagnostic_emit_diagram): Convert to...
10066         (diagnostic_context::emit_diagram): ...this, updating for field
10067         renamings.
10068         (error_recursion): Convert to...
10069         (diagnostic_context::error_recursion): ...this.
10070         (diagnostic_text_output_format::~diagnostic_text_output_format):
10071         Use accessor.
10072         (diagnostics_text_art_charset_init): Convert to...
10073         (diagnostic_context::set_text_art_charset): ...this.
10074         (assert_location_text): Update for field renamings.
10075         * diagnostic.h (enum diagnostic_text_art_charset): Move here from
10076         diagnostic-text-art.h.
10077         (struct diagnostic_context): Convert to...
10078         (class diagnostic_context): ...this.
10079         (diagnostic_context::ice_handler_callback_t): New typedef.
10080         (diagnostic_context::set_locations_callback_t): New typedef.
10081         (diagnostic_context::initialize): New decl.
10082         (diagnostic_context::color_init): New decl.
10083         (diagnostic_context::urls_init): New decl.
10084         (diagnostic_context::file_cache_init): New decl.
10085         (diagnostic_context::finish): New decl.
10086         (diagnostic_context::set_set_locations_callback): New.
10087         (diagnostic_context::initialize_input_context): New decl.
10088         (diagnostic_context::warning_enabled_at): New decl.
10089         (diagnostic_context::option_unspecified_p): New.
10090         (diagnostic_context::report_diagnostic): New decl.
10091         (diagnostic_context::report_current_module): New decl.
10092         (diagnostic_context::check_max_errors): New decl.
10093         (diagnostic_context::action_after_output): New decl.
10094         (diagnostic_context::classify_diagnostic): New decl.
10095         (diagnostic_context::push_diagnostics): New decl.
10096         (diagnostic_context::pop_diagnostics): New decl.
10097         (diagnostic_context::emit_diagram): New decl.
10098         (diagnostic_context::set_output_format): New decl.
10099         (diagnostic_context::set_text_art_charset): New decl.
10100         (diagnostic_context::set_client_data_hooks): New decl.
10101         (diagnostic_context::create_edit_context): New decl.
10102         (diagnostic_context::set_warning_as_error_requested): New.
10103         (diagnostic_context::set_report_bug): New.
10104         (diagnostic_context::set_extra_output_kind): New.
10105         (diagnostic_context::set_show_cwe): New.
10106         (diagnostic_context::set_show_rules): New.
10107         (diagnostic_context::set_path_format): New.
10108         (diagnostic_context::set_show_path_depths): New.
10109         (diagnostic_context::set_show_option_requested): New.
10110         (diagnostic_context::set_max_errors): New.
10111         (diagnostic_context::set_escape_format): New.
10112         (diagnostic_context::set_ice_handler_callback): New.
10113         (diagnostic_context::warning_as_error_requested_p): New.
10114         (diagnostic_context::show_path_depths_p): New.
10115         (diagnostic_context::get_path_format): New.
10116         (diagnostic_context::get_escape_format): New.
10117         (diagnostic_context::get_file_cache): New.
10118         (diagnostic_context::get_edit_context): New.
10119         (diagnostic_context::get_client_data_hooks): New.
10120         (diagnostic_context::get_diagram_theme): New.
10121         (diagnostic_context::converted_column): New decl.
10122         (diagnostic_context::diagnostic_count): New.
10123         (diagnostic_context::includes_seen_p): New decl.
10124         (diagnostic_context::print_any_cwe): New decl.
10125         (diagnostic_context::print_any_rules): New decl.
10126         (diagnostic_context::print_option_information): New decl.
10127         (diagnostic_context::show_any_path): New decl.
10128         (diagnostic_context::error_recursion): New decl.
10129         (diagnostic_context::diagnostic_enabled): New decl.
10130         (diagnostic_context::get_any_inlining_info): New decl.
10131         (diagnostic_context::update_effective_level_from_pragmas): New
10132         decl.
10133         (diagnostic_context::m_file_cache): Make private.
10134         (diagnostic_context::diagnostic_count): Rename to...
10135         (diagnostic_context::m_diagnostic_count): ...this and make
10136         private.
10137         (diagnostic_context::warning_as_error_requested): Rename to...
10138         (diagnostic_context::m_warning_as_error_requested): ...this and
10139         make private.
10140         (diagnostic_context::n_opts): Rename to...
10141         (diagnostic_context::m_n_opts): ...this and make private.
10142         (diagnostic_context::classify_diagnostic): Rename to...
10143         (diagnostic_context::m_classify_diagnostic): ...this and make
10144         private.
10145         (diagnostic_context::classification_history): Rename to...
10146         (diagnostic_context::m_classification_history): ...this and make
10147         private.
10148         (diagnostic_context::n_classification_history): Rename to...
10149         (diagnostic_context::m_n_classification_history): ...this and make
10150         private.
10151         (diagnostic_context::push_list): Rename to...
10152         (diagnostic_context::m_push_list): ...this and make private.
10153         (diagnostic_context::n_push): Rename to...
10154         (diagnostic_context::m_n_push): ...this and make private.
10155         (diagnostic_context::show_cwe): Rename to...
10156         (diagnostic_context::m_show_cwe): ...this and make private.
10157         (diagnostic_context::show_rules): Rename to...
10158         (diagnostic_context::m_show_rules): ...this and make private.
10159         (diagnostic_context::path_format): Rename to...
10160         (diagnostic_context::m_path_format): ...this and make private.
10161         (diagnostic_context::show_path_depths): Rename to...
10162         (diagnostic_context::m_show_path_depths): ...this and make
10163         private.
10164         (diagnostic_context::show_option_requested): Rename to...
10165         (diagnostic_context::m_show_option_requested): ...this and make
10166         private.
10167         (diagnostic_context::abort_on_error): Rename to...
10168         (diagnostic_context::m_abort_on_error): ...this.
10169         (diagnostic_context::show_column): Rename to...
10170         (diagnostic_context::m_show_column): ...this.
10171         (diagnostic_context::pedantic_errors): Rename to...
10172         (diagnostic_context::m_pedantic_errors): ...this.
10173         (diagnostic_context::permissive): Rename to...
10174         (diagnostic_context::m_permissive): ...this.
10175         (diagnostic_context::opt_permissive): Rename to...
10176         (diagnostic_context::m_opt_permissive): ...this.
10177         (diagnostic_context::fatal_errors): Rename to...
10178         (diagnostic_context::m_fatal_errors): ...this.
10179         (diagnostic_context::dc_inhibit_warnings): Rename to...
10180         (diagnostic_context::m_inhibit_warnings): ...this.
10181         (diagnostic_context::dc_warn_system_headers): Rename to...
10182         (diagnostic_context::m_warn_system_headers): ...this.
10183         (diagnostic_context::max_errors): Rename to...
10184         (diagnostic_context::m_max_errors): ...this and make private.
10185         (diagnostic_context::internal_error): Rename to...
10186         (diagnostic_context::m_internal_error): ...this.
10187         (diagnostic_context::option_enabled): Rename to...
10188         (diagnostic_context::m_option_enabled): ...this.
10189         (diagnostic_context::option_state): Rename to...
10190         (diagnostic_context::m_option_state): ...this.
10191         (diagnostic_context::option_name): Rename to...
10192         (diagnostic_context::m_option_name): ...this.
10193         (diagnostic_context::get_option_url): Rename to...
10194         (diagnostic_context::m_get_option_url): ...this.
10195         (diagnostic_context::print_path): Rename to...
10196         (diagnostic_context::m_print_path): ...this.
10197         (diagnostic_context::make_json_for_path): Rename to...
10198         (diagnostic_context::m_make_json_for_path): ...this.
10199         (diagnostic_context::x_data): Rename to...
10200         (diagnostic_context::m_client_aux_data): ...this.
10201         (diagnostic_context::last_location): Rename to...
10202         (diagnostic_context::m_last_location): ...this.
10203         (diagnostic_context::last_module): Rename to...
10204         (diagnostic_context::m_last_module): ...this and make private.
10205         (diagnostic_context::lock): Rename to...
10206         (diagnostic_context::m_lock): ...this and make private.
10207         (diagnostic_context::lang_mask): Rename to...
10208         (diagnostic_context::m_lang_mask): ...this.
10209         (diagnostic_context::inhibit_notes_p): Rename to...
10210         (diagnostic_context::m_inhibit_notes_p): ...this.
10211         (diagnostic_context::report_bug): Rename to...
10212         (diagnostic_context::m_report_bug): ...this and make private.
10213         (diagnostic_context::extra_output_kind): Rename to...
10214         (diagnostic_context::m_extra_output_kind): ...this and make
10215         private.
10216         (diagnostic_context::column_unit): Rename to...
10217         (diagnostic_context::m_column_unit): ...this and make private.
10218         (diagnostic_context::column_origin): Rename to...
10219         (diagnostic_context::m_column_origin): ...this and make private.
10220         (diagnostic_context::tabstop): Rename to...
10221         (diagnostic_context::m_tabstop): ...this and make private.
10222         (diagnostic_context::escape_format): Rename to...
10223         (diagnostic_context::m_escape_format): ...this and make private.
10224         (diagnostic_context::edit_context_ptr): Rename to...
10225         (diagnostic_context::m_edit_context_ptr): ...this and make
10226         private.
10227         (diagnostic_context::set_locations_cb): Rename to...
10228         (diagnostic_context::m_set_locations_cb): ...this and make
10229         private.
10230         (diagnostic_context::ice_handler_cb): Rename to...
10231         (diagnostic_context::m_ice_handler_cb): ...this and make private.
10232         (diagnostic_context::includes_seen): Rename to...
10233         (diagnostic_context::m_includes_seen): ...this and make private.
10234         (diagnostic_inhibit_notes): Update for field renaming.
10235         (diagnostic_context_auxiliary_data): Likewise.
10236         (diagnostic_abort_on_error): Convert from macro to inline function
10237         and update for field renaming.
10238         (diagnostic_kind_count): Convert from macro to inline function and
10239         use diagnostic_count accessor.
10240         (diagnostic_report_warnings_p): Update for field renaming.
10241         (diagnostic_initialize): Convert decl to inline function calling
10242         into diagnostic_context.
10243         (diagnostic_color_init): Likewise.
10244         (diagnostic_urls_init): Likewise.
10245         (diagnostic_urls_init): Likewise.
10246         (diagnostic_finish): Likewise.
10247         (diagnostic_report_current_module): Likewise.
10248         (diagnostic_show_any_path): Delete decl.
10249         (diagnostic_initialize_input_context): Convert decl to inline
10250         function calling into diagnostic_context.
10251         (diagnostic_classify_diagnostic): Likewise.
10252         (diagnostic_push_diagnostics): Likewise.
10253         (diagnostic_pop_diagnostics): Likewise.
10254         (diagnostic_report_diagnostic): Likewise.
10255         (diagnostic_action_after_output): Likewise.
10256         (diagnostic_check_max_errors): Likewise.
10257         (diagnostic_file_cache_fini): Delete decl.
10258         (diagnostic_converted_column): Delete decl.
10259         (warning_enabled_at): Convert decl to inline function calling into
10260         diagnostic_context.
10261         (option_unspecified_p): New.
10262         (diagnostic_emit_diagram): Delete decl.
10263         * gcc.cc: Remove include of "diagnostic-text-art.h".
10264         Update for changes to diagnostic_context.
10265         * input.cc (diagnostic_file_cache_init): Move implementation
10266         to...
10267         (diagnostic_context::file_cache_init): ...this new member
10268         function.
10269         (diagnostic_file_cache_fini): Delete.
10270         (diagnostics_file_cache_forcibly_evict_file): Update for
10271         m_file_cache becoming private.
10272         (location_get_source_line): Likewise.
10273         (get_source_file_content): Likewise.
10274         (location_missing_trailing_newline): Likewise.
10275         * input.h (diagnostics_file_cache_fini): Delete.
10276         * langhooks.cc: Update for changes to diagnostic_context.
10277         * lto-wrapper.cc: Likewise.
10278         * opts.cc: Remove include of "diagnostic-text-art.h".
10279         Update for changes to diagnostic_context.
10280         * selftest-diagnostic.cc: Update for changes to
10281         diagnostic_context.
10282         * toplev.cc: Likewise.
10283         * tree-diagnostic-path.cc: Likewise.
10284         * tree-diagnostic.cc: Likewise.
10286 2023-11-03  Martin Uecker  <uecker@tugraz.at>
10288         PR c/98541
10289         * gimple-ssa-warn-access.cc
10290         (pass_waccess::maybe_check_access_sizes): For VLA bounds
10291         in parameters, only warn about null pointers with 'static'.
10293 2023-11-03  Andre Vieira  <andre.simoesdiasvieira@arm.com>
10295         * tree-vect-stmts.cc (vectorizable_simd_clone_call): Allow unmasked
10296         calls to use masked simdclones.
10298 2023-11-03  David Malcolm  <dmalcolm@redhat.com>
10300         * diagnostic.cc (diagnostic_initialize): Update for consolidation
10301         of group-based fields.
10302         (diagnostic_report_diagnostic): Likewise.
10303         (diagnostic_context::begin_group): New, based on body of
10304         auto_diagnostic_group's ctor.
10305         (diagnostic_context::end_group): New, based on body of
10306         auto_diagnostic_group's dtor.
10307         (auto_diagnostic_group::auto_diagnostic_group): Convert to a call
10308         to begin_group.
10309         (auto_diagnostic_group::~auto_diagnostic_group): Convert to a call
10310         to end_group.
10311         * diagnostic.h (diagnostic_context::begin_group): New decl.
10312         (diagnostic_context::end_group): New decl.
10313         (diagnostic_context::diagnostic_group_nesting_depth): Rename to...
10314         (diagnostic_context::m_diagnostic_groups.m_nesting_depth):
10315         ...this.
10316         (diagnostic_context::diagnostic_group_emission_count): Rename
10317         to...
10318         (diagnostic_context::m_diagnostic_groups::m_emission_count):
10319         ...this.
10321 2023-11-03  Andrew MacLeod  <amacleod@redhat.com>
10323         PR tree-optimization/111766
10324         * range-op.cc (operator_equal::fold_range): Check constants
10325         against the bitmask.
10326         (operator_not_equal::fold_range): Ditto.
10327         * value-range.h (irange_bitmask::member_p): New.
10329 2023-11-03  Andrew MacLeod  <amacleod@redhat.com>
10331         * value-range.cc (irange_bitmask::adjust_range): New.
10332         (irange::intersect_bitmask): Call adjust_range.
10333         * value-range.h (irange_bitmask::adjust_range): New prototype.
10335 2023-11-03  Uros Bizjak  <ubizjak@gmail.com>
10337         * config/i386/i386.cc (ix86_memory_address_use_extended_reg_class_p):
10338         Rename to ...
10339         (ix86_memory_address_reg_class): ... this.  Generalize address
10340         register class handling to allow multiple address register classes.
10341         Return maximal class for unrecognized instructions.  Improve comments.
10342         (ix86_insn_base_reg_class): Rewrite to handle
10343         multiple address register classes.
10344         (ix86_regno_ok_for_insn_base_p): Ditto.
10345         (ix86_insn_index_reg_class): Ditto.
10346         * config/i386/i386.md: Rename "gpr32" attribute to "addr"
10347         and substitute its values with "0" -> "gpr16", "1" -> "*".
10348         (addr): New attribute to limit allowed address register set.
10349         (gpr32): Remove.
10350         * config/i386/mmx.md: Rename "gpr32" attribute to "addr"
10351         and substitute its values with "0" -> "gpr16", "1" -> "*".
10352         * config/i386/sse.md: Ditto.
10354 2023-11-03  Richard Biener  <rguenther@suse.de>
10356         * tree-vect-loop.cc (vectorizable_live_operation): Simplify
10357         LC PHI replacement.
10359 2023-11-03  Roger Sayle  <roger@nextmovesoftware.com>
10361         * config/arc/arc.md (addsi3): Fix GNU-style code formatting.
10362         (adddi3): Change define_expand to generate a *adddi3.
10363         (*adddi3): New define_insn_and_split to lower DImode additions
10364         during the split1 pass (after combine and before reload).
10365         (ashldi3): New define_expand to (only) generate *ashldi3_cnt1
10366         for DImode left shifts by a single bit.
10367         (*ashldi3_cnt1): New define_insn_and_split to lower DImode
10368         left shifts by one bit to an *adddi3.
10370 2023-11-03  Richard Sandiford  <richard.sandiford@arm.com>
10372         * config/aarch64/aarch64.md (*cmov_uxtw_insn_insv): Remove
10373         can_create_pseudo_p condition.
10375 2023-11-03  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
10377         * tree-vect-slp.cc (vect_get_and_check_slp_defs): Support SLP for dummy mask -1.
10378         * tree-vect-stmts.cc (vectorizable_load): Ditto.
10380 2023-11-03  Richard Biener  <rguenther@suse.de>
10382         PR tree-optimization/112366
10383         * tree-vect-loop.cc (vectorizable_live_operation): Remove
10384         assert.
10386 2023-11-03  Richard Biener  <rguenther@suse.de>
10388         PR tree-optimization/112310
10389         * tree-ssa-pre.cc (do_hoist_insertion): Keep the union
10390         of expressions, validate dependences are contained within
10391         the hoistable set before hoisting.
10393 2023-11-03  Pan Li  <pan2.li@intel.com>
10395         * config/riscv/autovec.md (lrint<mode><v_i_l_ll_convert>2): Remove.
10396         (lround<mode><v_i_l_ll_convert>2): Ditto.
10397         (lceil<mode><v_i_l_ll_convert>2): Ditto.
10398         (lfloor<mode><v_i_l_ll_convert>2): Ditto.
10399         (lrint<mode><v_f2si_convert>2): New pattern for cvt from
10400         FP to SI.
10401         (lround<mode><v_f2si_convert>2): Ditto.
10402         (lceil<mode><v_f2si_convert>2): Ditto.
10403         (lfloor<mode><v_f2si_convert>2): Ditto.
10404         (lrint<mode><v_f2di_convert>2): New pattern for cvt from
10405         FP to DI.
10406         (lround<mode><v_f2di_convert>2): Ditto.
10407         (lceil<mode><v_f2di_convert>2): Ditto.
10408         (lfloor<mode><v_f2di_convert>2): Ditto.
10409         * config/riscv/vector-iterators.md: Renew iterators for both
10410         the SI and DI.
10412 2023-11-03  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
10414         PR target/112326
10415         * config/riscv/riscv-avlprop.cc (get_insn_vtype_mode): New function.
10416         (simplify_replace_vlmax_avl): Ditto.
10417         (pass_avlprop::execute): Add immediate AVL simplification.
10418         * config/riscv/riscv-protos.h (imm_avl_p): Rename.
10419         * config/riscv/riscv-v.cc (const_vlmax_p): Ditto.
10420         (imm_avl_p): Ditto.
10421         (emit_vlmax_insn): Adapt for new interface name.
10422         * config/riscv/vector.md (mode_idx): New attribute.
10424 2023-11-03  Pan Li  <pan2.li@intel.com>
10426         Revert:
10427         2023-11-02  Pan Li  <pan2.li@intel.com>
10429         * config/riscv/autovec.md (lrint<mode><v_i_l_ll_convert>2): Remove.
10430         (lround<mode><v_i_l_ll_convert>2): Ditto.
10431         (lceil<mode><v_i_l_ll_convert>2): Ditto.
10432         (lfloor<mode><v_i_l_ll_convert>2): Ditto.
10433         (lrint<mode><v_f2si_convert>2): New pattern for cvt from
10434         FP to SI.
10435         (lround<mode><v_f2si_convert>2): Ditto.
10436         (lceil<mode><v_f2si_convert>2): Ditto.
10437         (lfloor<mode><v_f2si_convert>2): Ditto.
10438         (lrint<mode><v_f2di_convert>2): New pattern for cvt from
10439         FP to DI.
10440         (lround<mode><v_f2di_convert>2): Ditto.
10441         (lceil<mode><v_f2di_convert>2): Ditto.
10442         (lfloor<mode><v_f2di_convert>2): Ditto.
10443         * config/riscv/vector-iterators.md: Renew iterators for both
10444         the SI and DI.
10446 2023-11-02  Edwin Lu  <ewlu@rivosinc.com>
10448         * config/riscv/riscv.cc (riscv_sched_variable_issue): add disabled assert
10450 2023-11-02  Jeff Law  <jlaw@ventanamicro.com>
10452         * config/h8300/combiner.md: Add new patterns for single bit
10453         sign extractions.
10455 2023-11-02  Pan Li  <pan2.li@intel.com>
10457         * config/riscv/autovec.md (lrint<mode><v_i_l_ll_convert>2): Remove.
10458         (lround<mode><v_i_l_ll_convert>2): Ditto.
10459         (lceil<mode><v_i_l_ll_convert>2): Ditto.
10460         (lfloor<mode><v_i_l_ll_convert>2): Ditto.
10461         (lrint<mode><v_f2si_convert>2): New pattern for cvt from
10462         FP to SI.
10463         (lround<mode><v_f2si_convert>2): Ditto.
10464         (lceil<mode><v_f2si_convert>2): Ditto.
10465         (lfloor<mode><v_f2si_convert>2): Ditto.
10466         (lrint<mode><v_f2di_convert>2): New pattern for cvt from
10467         FP to DI.
10468         (lround<mode><v_f2di_convert>2): Ditto.
10469         (lceil<mode><v_f2di_convert>2): Ditto.
10470         (lfloor<mode><v_f2di_convert>2): Ditto.
10471         * config/riscv/vector-iterators.md: Renew iterators for both
10472         the SI and DI.
10474 2023-11-02  Sam James  <sam@gentoo.org>
10476         * doc/passes.texi (Dead code elimination): Explicitly say 'lifetime'
10477         as this has become the standard term for what we're doing here.
10479 2023-11-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
10481         * config/riscv/riscv-avlprop.cc
10482         (pass_avlprop::get_vlmax_ta_preferred_avl): Don't allow
10483         non-real insn AVL propation.
10485 2023-11-02  Robin Dapp  <rdapp@ventanamicro.com>
10487         PR middle-end/111401
10488         * internal-fn.cc (internal_fn_else_index): New function.
10489         * internal-fn.h (internal_fn_else_index): Define.
10490         * tree-if-conv.cc (convert_scalar_cond_reduction): Emit COND_OP
10491         if supported.
10492         (predicate_scalar_phi): Add whitespace.
10493         * tree-vect-loop.cc (fold_left_reduction_fn): Add IFN_COND_OP.
10494         (neutral_op_for_reduction): Return -0 for PLUS.
10495         (check_reduction_path): Don't count else operand in COND_OP.
10496         (vect_is_simple_reduction): Ditto.
10497         (vect_create_epilog_for_reduction): Fix whitespace.
10498         (vectorize_fold_left_reduction): Add COND_OP handling.
10499         (vectorizable_reduction): Don't count else operand in COND_OP.
10500         (vect_transform_reduction): Add COND_OP handling.
10501         * tree-vectorizer.h (neutral_op_for_reduction): Add default
10502         parameter.
10504 2023-11-02  Richard Biener  <rguenther@suse.de>
10506         PR tree-optimization/112320
10507         * gimple-fold.h (rewrite_to_defined_overflow): New overload
10508         for in-place operation.
10509         * gimple-fold.cc (rewrite_to_defined_overflow): Add stmt
10510         iterator argument to worker, define separate API for
10511         in-place and not in-place operation.
10512         * tree-if-conv.cc (predicate_statements): Simplify.
10513         * tree-scalar-evolution.cc (final_value_replacement_loop):
10514         Likewise.
10515         * tree-ssa-ifcombine.cc (pass_tree_ifcombine::execute): Adjust.
10516         * tree-ssa-reassoc.cc (update_range_test): Likewise.
10518 2023-11-02  Uros Bizjak  <ubizjak@gmail.com>
10520         * config/i386/i386.md: Move stack protector patterns
10521         above mov $0,%reg -> xor %reg,%reg peephole2 pattern.
10523 2023-11-02  liuhongt  <hongtao.liu@intel.com>
10525         * config/i386/mmx.md (cmlav4hf4): New expander.
10526         (cmla_conjv4hf4): Ditto.
10527         (cmulv4hf3): Ditto.
10528         (cmul_conjv4hf3): Ditto.
10530 2023-11-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
10532         * config/riscv/vector.md: Fix redundant codes in attributes.
10534 2023-11-02  xuli  <xuli1@eswincomputing.com>
10536         * config/riscv/riscv-vector-builtins-bases.cc: Expand non-tuple intrinsics.
10537         * config/riscv/riscv-vector-builtins-functions.def (vcreate): Define non-tuple intrinsics.
10538         * config/riscv/riscv-vector-builtins-shapes.cc (struct vcreate_def): Ditto.
10539         * config/riscv/riscv-vector-builtins.cc: Add arg types.
10541 2023-11-02  Pan Li  <pan2.li@intel.com>
10543         * tree-vect-stmts.cc (vectorizable_internal_function): Add type
10544         size check for vectype_out doesn't participating for optab query.
10545         (vectorizable_call): Remove the type size check.
10547 2023-11-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
10549         PR target/112327
10550         * config/riscv/vector.md: Add '0'.
10552 2023-11-01  Roger Sayle  <roger@nextmovesoftware.com>
10554         PR target/110551
10555         * config/i386/i386.md (*bmi2_umul<mode><dwi>3_1): Tidy condition
10556         as operands[2] with predicate register_operand must be !MEM_P.
10557         (peephole2): Optimize a mulx followed by a register-to-register
10558         move, to place result in the correct destination if possible.
10560 2023-11-01  Patrick O'Neill  <patrick@rivosinc.com>
10562         * config/riscv/sync.md:  Use riscv_subword_address function to
10563         calculate the address and shift in atomic_test_and_set.
10565 2023-11-01  Vineet Gupta  <vineetg@rivosinc.com>
10567         * config/riscv/riscv.cc (riscv_promote_function_mode): Fix mode
10568         returned for libcall case.
10570 2023-11-01  Martin Uecker  <uecker@tugraz.at>
10572         PR c/71219
10573         * doc/invoke.texi: Document -Walloc-size option.
10575 2023-11-01  Edwin Lu  <ewlu@rivosinc.com>
10577         * genautomata.cc (write_automata): move endif
10579 2023-11-01  Andre Vieira  <andre.simoesdiasvieira@arm.com>
10581         * omp-simd-clone.cc (simd_clone_adjust_return_type): Hoist out code to
10582         create return array and don't return new type.
10583         (simd_clone_adjust_argument_types): Hoist out code that creates
10584         ipa_param_body_adjustments and don't return them.
10585         (simd_clone_adjust): Call TARGET_SIMD_CLONE_ADJUST after return and
10586         argument types have been vectorized, create adjustments and return array
10587         after the hook.
10588         (expand_simd_clones): Call TARGET_SIMD_CLONE_ADJUST after return and
10589         argument types have been vectorized.
10591 2023-11-01  Uros Bizjak  <ubizjak@gmail.com>
10593         PR target/112332
10594         * config/i386/i386.md (stack_protexct_set_2 peephole2):
10595         Use general_gr_operand as operand 4 predicate.
10597 2023-11-01  Uros Bizjak  <ubizjak@gmail.com>
10599         * config/i386/i386.md (stack_protect_set): Explicitly
10600         generate scratch register in word mode.
10601         (@stack_protect_set_1_<mode>): Rename to ...
10602         (@stack_protect_set_1_<PTR:mode>_<SWI48:mode>): ... this.
10603         Use SWI48 mode iterator to match scratch register.
10604         (stack_protexct_set_1 peephole2): Use PTR, W and SWI48 mode
10605         iterators to match peephole sequence.  Use general_operand
10606         predicate for operand 4.  Allow different operand 2 and operand 3
10607         registers and use peep2_reg_dead_p to ensure new scratch
10608         register is dead before peephole seqeunce. Use peep2_reg_dead_p
10609         to ensure old scratch register is dead after peephole sequence.
10610         (*stack_protect_set_2_<mode>): Rename to ...
10611         (*stack_protect_set_2_<mode>_si): .. this.
10612         (*stack_protect_set_3): Rename to ...
10613         (*stack_protect_set_2_<mode>_di): ... this.
10614         Use PTR mode iterator to match stack protector memory move.
10615         Use earlyclobber for all alternatives of operand 1.
10616         (stack_protexct_set_2 peephole2): Use PTR, W and SWI48 mode
10617         iterators to match peephole sequence.  Use general_operand
10618         predicate for operand 4.  Allow different operand 2 and operand 3
10619         registers and use peep2_reg_dead_p to ensure new scratch
10620         register is dead before peephole seqeunce. Use peep2_reg_dead_p
10621         to ensure old scratch register is dead after peephole sequence.
10623 2023-11-01  xuli  <xuli1@eswincomputing.com>
10625         * config/riscv/riscv-vector-builtins-functions.def (vundefined): Add vundefine
10626         intrinsics for tuple types.
10627         * config/riscv/riscv-vector-builtins.cc: Ditto.
10628         * config/riscv/vector.md (@vundefined<mode>): Ditto.
10630 2023-11-01  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
10632         * tree-vect-slp.cc (vect_build_slp_tree_1): Fix whitespace.
10634 2023-10-31  David Malcolm  <dmalcolm@redhat.com>
10636         * Makefile.in (ANALYZER_OBJS): Add analyzer/record-layout.o.
10638 2023-10-31  David Malcolm  <dmalcolm@redhat.com>
10640         * input.cc (dump_location_info): Update for removal of
10641         MACRO_MAP_EXPANSION_POINT_LOCATION.
10642         * tree-diagnostic.cc (maybe_unwind_expanded_macro_loc):
10643         Likewise.
10645 2023-10-31  David Malcolm  <dmalcolm@redhat.com>
10647         * opts.cc (get_option_url): Update comment; the requirement to
10648         pass DOCUMENTATION_ROOT_URL's value via -D was removed in
10649         r10-8065-ge33a1eae25b8a8.
10651 2023-10-31  David Malcolm  <dmalcolm@redhat.com>
10653         * pretty-print.cc (pretty_printer::pretty_printer): Initialize
10654         m_skipping_null_url.
10655         (pp_begin_url): Handle URL being null.
10656         (pp_end_url): Likewise.
10657         (selftest::test_null_urls): New.
10658         (selftest::pretty_print_cc_tests): Call it.
10659         * pretty-print.h (pretty_printer::m_skipping_null_url): New.
10661 2023-10-31  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
10663         * tree-vect-slp.cc (vect_get_operand_map): Add MASK_LEN_GATHER_LOAD.
10664         (vect_build_slp_tree_1): Ditto.
10665         (vect_build_slp_tree_2): Ditto.
10667 2023-10-31  Cupertino Miranda  <cupertino.miranda@oracle.com>
10669         * config/bpf/bpf-passes.def (pass_lower_bpf_core): Added pass.
10670         * config/bpf/bpf-protos.h: Added prototype for new pass.
10671         * config/bpf/bpf.cc (bpf_delegitimize_address): New function.
10672         * config/bpf/bpf.md (mov_reloc_core<MM:mode>): Prefixed
10673         name with '*'.
10674         * config/bpf/core-builtins.cc (cr_builtins) Added access_node to
10675         struct.
10676         (is_attr_preserve_access): Improved check.
10677         (core_field_info): Make use of root_for_core_field_info
10678         function.
10679         (process_field_expr): Adapted to new functions.
10680         (pack_type): Small improvement.
10681         (bpf_handle_plugin_finish_type): Adapted to GTY(()).
10682         (bpf_init_core_builtins): Changed to new function names.
10683         (construct_builtin_core_reloc): Improved implementation.
10684         (bpf_resolve_overloaded_core_builtin): Changed how
10685         __builtin_preserve_access_index is converted.
10686         (compute_field_expr): Corrected implementation. Added
10687         access_node argument.
10688         (bpf_core_get_index): Added valid argument.
10689         (root_for_core_field_info, pack_field_expr)
10690         (core_expr_with_field_expr_plus_base, make_core_safe_access_index)
10691         (replace_core_access_index_comp_expr, maybe_get_base_for_field_expr)
10692         (core_access_clean, core_is_access_index, core_mark_as_access_index)
10693         (make_gimple_core_safe_access_index, execute_lower_bpf_core)
10694         (make_pass_lower_bpf_core): Added functions.
10695         (pass_data_lower_bpf_core): New pass struct.
10696         (pass_lower_bpf_core): New gimple_opt_pass class.
10697         (pack_field_expr_for_preserve_field)
10698         (bpf_replace_core_move_operands): Removed function.
10699         (bpf_enum_value_kind): Added GTY(()).
10700         * config/bpf/core-builtins.h (bpf_field_info_kind, bpf_type_id_kind)
10701         (bpf_type_info_kind, bpf_enum_value_kind): New enum.
10702         * config/bpf/t-bpf: Added pass bpf-passes.def to PASSES_EXTRA.
10704 2023-10-31  Neal Frager  <neal.frager@amd.com>
10706         * config/microblaze/microblaze.cc: Fix mcpu version check.
10708 2023-10-31  Patrick O'Neill  <patrick@rivosinc.com>
10710         * config/riscv/sync-rvwmo.md (atomic_load_rvwmo<mode>): Remove
10711         TARGET_ATOMIC constraint
10712         (atomic_store_rvwmo<mode>): Ditto.
10713         * config/riscv/sync-ztso.md (atomic_load_ztso<mode>): Ditto.
10714         (atomic_store_ztso<mode>): Ditto.
10715         * config/riscv/sync.md (atomic_load<mode>): Ditto.
10716         (atomic_store<mode>): Ditto.
10718 2023-10-31  Christoph Müllner  <christoph.muellner@vrull.eu>
10720         * config/riscv/riscv.cc (riscv_index_reg_class):
10721         Return GR_REGS for XTheadFMemIdx.
10722         (riscv_regno_ok_for_index_p): Add support for XTheadFMemIdx.
10723         * config/riscv/riscv.h (HARDFP_REG_P): New macro.
10724         * config/riscv/thead.cc (is_fmemidx_mode): New function.
10725         (th_memidx_classify_address_index): Add support for XTheadFMemIdx.
10726         (th_fmemidx_output_index): New function.
10727         (th_output_move): Add support for XTheadFMemIdx.
10728         * config/riscv/thead.md (TH_M_ANYF): New mode iterator.
10729         (TH_M_NOEXTF): Likewise.
10730         (*th_fmemidx_movsf_hardfloat): New INSN.
10731         (*th_fmemidx_movdf_hardfloat_rv64): Likewise.
10732         (*th_fmemidx_I_a): Likewise.
10733         (*th_fmemidx_I_c): Likewise.
10734         (*th_fmemidx_US_a): Likewise.
10735         (*th_fmemidx_US_c): Likewise.
10736         (*th_fmemidx_UZ_a): Likewise.
10737         (*th_fmemidx_UZ_c): Likewise.
10739 2023-10-31  Christoph Müllner  <christoph.muellner@vrull.eu>
10741         * config/riscv/constraints.md (th_m_mia): New constraint.
10742         (th_m_mib): Likewise.
10743         (th_m_mir): Likewise.
10744         (th_m_miu): Likewise.
10745         * config/riscv/riscv-protos.h (enum riscv_address_type):
10746         Add new address types ADDRESS_REG_REG, ADDRESS_REG_UREG,
10747         and ADDRESS_REG_WB and their documentation.
10748         (struct riscv_address_info): Add new field 'shift' and
10749         document the field usage for the new address types.
10750         (riscv_valid_base_register_p): New prototype.
10751         (th_memidx_legitimate_modify_p): Likewise.
10752         (th_memidx_legitimate_index_p): Likewise.
10753         (th_classify_address): Likewise.
10754         (th_output_move): Likewise.
10755         (th_print_operand_address): Likewise.
10756         * config/riscv/riscv.cc (riscv_index_reg_class):
10757         Return GR_REGS for XTheadMemIdx.
10758         (riscv_regno_ok_for_index_p): Add support for XTheadMemIdx.
10759         (riscv_classify_address): Call th_classify_address() on top.
10760         (riscv_output_move): Call th_output_move() on top.
10761         (riscv_print_operand_address): Call th_print_operand_address()
10762         on top.
10763         * config/riscv/riscv.h (HAVE_POST_MODIFY_DISP): New macro.
10764         (HAVE_PRE_MODIFY_DISP): Likewise.
10765         * config/riscv/riscv.md (zero_extendqi<SUPERQI:mode>2): Disable
10766         for XTheadMemIdx.
10767         (*zero_extendqi<SUPERQI:mode>2_internal): Convert to expand,
10768         create INSN with same name and disable it for XTheadMemIdx.
10769         (extendsidi2): Likewise.
10770         (*extendsidi2_internal): Disable for XTheadMemIdx.
10771         * config/riscv/thead.cc (valid_signed_immediate): New helper
10772         function.
10773         (th_memidx_classify_address_modify): New function.
10774         (th_memidx_legitimate_modify_p): Likewise.
10775         (th_memidx_output_modify): Likewise.
10776         (is_memidx_mode): Likewise.
10777         (th_memidx_classify_address_index): Likewise.
10778         (th_memidx_legitimate_index_p): Likewise.
10779         (th_memidx_output_index): Likewise.
10780         (th_classify_address): Likewise.
10781         (th_output_move): Likewise.
10782         (th_print_operand_address): Likewise.
10783         * config/riscv/thead.md (*th_memidx_operand): New splitter.
10784         (*th_memidx_zero_extendqi<SUPERQI:mode>2): New INSN.
10785         (*th_memidx_extendsidi2): Likewise.
10786         (*th_memidx_zero_extendsidi2): Likewise.
10787         (*th_memidx_zero_extendhi<GPR:mode>2): Likewise.
10788         (*th_memidx_extend<SHORT:mode><SUPERQI:mode>2): Likewise.
10789         (*th_memidx_bb_zero_extendsidi2): Likewise.
10790         (*th_memidx_bb_zero_extendhi<GPR:mode>2): Likewise.
10791         (*th_memidx_bb_extendhi<GPR:mode>2): Likewise.
10792         (*th_memidx_bb_extendqi<SUPERQI:mode>2): Likewise.
10793         (TH_M_ANYI): New mode iterator.
10794         (TH_M_NOEXTI): Likewise.
10795         (*th_memidx_I_a): New combiner optimization.
10796         (*th_memidx_I_b): Likewise.
10797         (*th_memidx_I_c): Likewise.
10798         (*th_memidx_US_a): Likewise.
10799         (*th_memidx_US_b): Likewise.
10800         (*th_memidx_US_c): Likewise.
10801         (*th_memidx_UZ_a): Likewise.
10802         (*th_memidx_UZ_b): Likewise.
10803         (*th_memidx_UZ_c): Likewise.
10805 2023-10-31  Carl Love  <cel@us.ibm.com>
10807         * doc/extend.texi (__builtin_bcdsub_le, __builtin_bcdsub_ge): Add
10808         documentation for the builti-ins.
10810 2023-10-31  Vladimir N. Makarov  <vmakarov@redhat.com>
10812         PR rtl-optimization/111971
10813         * lra-constraints.cc: (process_alt_operands): Don't check start
10814         hard regs for regs originated from register variables.
10816 2023-10-31  Robin Dapp  <rdapp@ventanamicro.com>
10818         * config/riscv/autovec.md (<ieee_fmaxmin_op><mode>3): fmax/fmin
10819         expanders.
10820         (cond_<ieee_fmaxmin_op><mode>): Ditto.
10821         (cond_len_<ieee_fmaxmin_op><mode>): Ditto.
10822         (reduc_fmax_scal_<mode>): Ditto.
10823         (reduc_fmin_scal_<mode>): Ditto.
10824         * config/riscv/riscv-v.cc (needs_fp_rounding): Add fmin/fmax.
10825         * config/riscv/vector-iterators.md (fmin): New UNSPEC.
10826         (UNSPEC_VFMIN): Ditto.
10827         * config/riscv/vector.md (@pred_<ieee_fmaxmin_op><mode>): Add
10828         UNSPEC insn patterns.
10829         (@pred_<ieee_fmaxmin_op><mode>_scalar): Ditto.
10831 2023-10-31  Robin Dapp  <rdapp@ventanamicro.com>
10833         PR bootstrap/84402
10834         PR target/111600
10835         * Makefile.in: Handle split insn-emit.cc.
10836         * configure: Regenerate.
10837         * configure.ac: Add --with-insnemit-partitions.
10838         * genemit.cc (output_peephole2_scratches): Print to file instead
10839         of stdout.
10840         (print_code): Ditto.
10841         (gen_rtx_scratch): Ditto.
10842         (gen_exp): Ditto.
10843         (gen_emit_seq): Ditto.
10844         (emit_c_code): Ditto.
10845         (gen_insn): Ditto.
10846         (gen_expand): Ditto.
10847         (gen_split): Ditto.
10848         (output_add_clobbers): Ditto.
10849         (output_added_clobbers_hard_reg_p): Ditto.
10850         (print_overload_arguments): Ditto.
10851         (print_overload_test): Ditto.
10852         (handle_overloaded_code_for): Ditto.
10853         (handle_overloaded_gen): Ditto.
10854         (print_header): New function.
10855         (handle_arg): New function.
10856         (main): Split output into 10 files.
10857         * gensupport.cc (count_patterns): New function.
10858         * gensupport.h (count_patterns): Define.
10859         * read-md.cc (md_reader::print_md_ptr_loc): Add file argument.
10860         * read-md.h (class md_reader): Change definition.
10862 2023-10-31  Alexandre Oliva  <oliva@adacore.com>
10864         PR tree-optimization/111943
10865         * gimple-harden-control-flow.cc: Adjust copyright year.
10866         (rt_bb_visited): Add vfalse and vtrue data members.
10867         Zero-initialize them in the ctor.
10868         (rt_bb_visited::insert_exit_check_on_edge): Upon encountering
10869         abnormal edges, insert initializers for vfalse and vtrue on
10870         entry, and insert the check sequence guarded by a conditional
10871         in the dest block.
10873 2023-10-31  Richard Biener  <rguenther@suse.de>
10875         PR tree-optimization/112305
10876         * tree-scalar-evolution.h (expression_expensive): Adjust.
10877         * tree-scalar-evolution.cc (expression_expensive): Record
10878         when we see a COND_EXPR.
10879         (final_value_replacement_loop): When the replacement contains
10880         a COND_EXPR, rewrite it to defined overflow.
10881         * tree-ssa-loop-ivopts.cc (may_eliminate_iv): Adjust.
10883 2023-10-31  Xi Ruoyao  <xry111@xry111.site>
10885         PR target/112299
10886         * config/loongarch/loongarch-opts.h (HAVE_AS_TLS): Define to 0
10887         if not defined yet.
10889 2023-10-31  Lehua Ding  <lehua.ding@rivai.ai>
10891         * gimple-match.h (gimple_match_op::gimple_match_op):
10892         Add interfaces for more arguments.
10893         (gimple_match_op::set_op): Add interfaces for more arguments.
10894         * match.pd: Add support of combining cond_len_op + vec_cond
10896 2023-10-31  Haochen Jiang  <haochen.jiang@intel.com>
10898         * config/i386/avx512cdintrin.h (target): Push evex512 for
10899         avx512cd.
10900         * config/i386/avx512vlintrin.h (target): Split avx512cdvl part
10901         out from avx512vl.
10902         * config/i386/i386-builtin.def (BDESC): Do not check evex512
10903         for builtins not needed.
10905 2023-10-31  Lehua Ding  <lehua.ding@rivai.ai>
10907         * config/riscv/autovec.md (<float_cvt><mode><vnnconvert>2):
10908         Change to define_expand.
10910 2023-10-31  liuhongt  <hongtao.liu@intel.com>
10912         PR target/112276
10913         * config/i386/mmx.md (*mmx_pblendvb_v8qi_1): Change
10914         define_split to define_insn_and_split to handle
10915         immediate_operand for comparison.
10916         (*mmx_pblendvb_v8qi_2): Ditto.
10917         (*mmx_pblendvb_<mode>_1): Ditto.
10918         (*mmx_pblendvb_v4qi_2): Ditto.
10919         (<code><mode>3): Remove define_split after it.
10920         (<code>v8qi3): Ditto.
10921         (<code><mode>3): Ditto.
10922         (<ode>v2hi3): Ditto.
10924 2023-10-31  Andrew Pinski  <pinskia@gmail.com>
10926         * match.pd (`a == 1 ? b : a OP b`): New pattern.
10927         (`a == -1 ? b : a & b`): New pattern.
10929 2023-10-31  Andrew Pinski  <pinskia@gmail.com>
10931         * match.pd: (`a == 0 ? b : b + a`,
10932         `a == 0 ? b : b - a`): New patterns.
10934 2023-10-31  Neal Frager  <neal.frager@amd.com>
10936         * config/microblaze/microblaze.cc: Fix mcpu version check.
10938 2023-10-30  Mayshao  <mayshao-oc@zhaoxin.com>
10940         * common/config/i386/cpuinfo.h (get_zhaoxin_cpu): Recognize yongfeng.
10941         * common/config/i386/i386-common.cc: Add yongfeng.
10942         * common/config/i386/i386-cpuinfo.h (enum processor_subtypes):
10943         Add ZHAOXIN_FAM7H_YONGFENG.
10944         * config.gcc: Add yongfeng.
10945         * config/i386/driver-i386.cc (host_detect_local_cpu):
10946         Let -march=native recognize yongfeng processors.
10947         * config/i386/i386-c.cc (ix86_target_macros_internal): Add yongfeng.
10948         * config/i386/i386-options.cc (m_YONGFENG): New definition.
10949         (m_ZHAOXIN): Ditto.
10950         * config/i386/i386.h (enum processor_type): Add PROCESSOR_YONGFENG.
10951         * config/i386/i386.md: Add yongfeng.
10952         * config/i386/lujiazui.md: Fix typo.
10953         * config/i386/x86-tune-costs.h (struct processor_costs):
10954         Add yongfeng costs.
10955         * config/i386/x86-tune-sched.cc (ix86_issue_rate): Add yongfeng.
10956         (ix86_adjust_cost): Ditto.
10957         * config/i386/x86-tune.def (X86_TUNE_SCHEDULE): Replace
10958         m_LUJIAZUI with m_ZHAOXIN.
10959         (X86_TUNE_PARTIAL_REG_DEPENDENCY): Ditto.
10960         (X86_TUNE_SSE_PARTIAL_REG_DEPENDENCY): Ditto.
10961         (X86_TUNE_SSE_PARTIAL_REG_FP_CONVERTS_DEPENDENCY): Ditto.
10962         (X86_TUNE_SSE_PARTIAL_REG_CONVERTS_DEPENDENCY): Ditto.
10963         (X86_TUNE_MOVX): Ditto.
10964         (X86_TUNE_MEMORY_MISMATCH_STALL): Ditto.
10965         (X86_TUNE_FUSE_CMP_AND_BRANCH_32): Ditto.
10966         (X86_TUNE_FUSE_CMP_AND_BRANCH_64): Ditto.
10967         (X86_TUNE_FUSE_CMP_AND_BRANCH_SOFLAGS): Ditto.
10968         (X86_TUNE_FUSE_ALU_AND_BRANCH): Ditto.
10969         (X86_TUNE_ACCUMULATE_OUTGOING_ARGS): Ditto.
10970         (X86_TUNE_USE_LEAVE): Ditto.
10971         (X86_TUNE_PUSH_MEMORY): Ditto.
10972         (X86_TUNE_LCP_STALL): Ditto.
10973         (X86_TUNE_INTEGER_DFMODE_MOVES): Ditto.
10974         (X86_TUNE_OPT_AGU): Ditto.
10975         (X86_TUNE_PREFER_KNOWN_REP_MOVSB_STOSB): Ditto.
10976         (X86_TUNE_MISALIGNED_MOVE_STRING_PRO_EPILOGUES): Ditto.
10977         (X86_TUNE_USE_SAHF): Ditto.
10978         (X86_TUNE_USE_BT): Ditto.
10979         (X86_TUNE_AVOID_FALSE_DEP_FOR_BMI): Ditto.
10980         (X86_TUNE_ONE_IF_CONV_INSN): Ditto.
10981         (X86_TUNE_AVOID_MFENCE): Ditto.
10982         (X86_TUNE_EXPAND_ABS): Ditto.
10983         (X86_TUNE_USE_SIMODE_FIOP): Ditto.
10984         (X86_TUNE_USE_FFREEP): Ditto.
10985         (X86_TUNE_EXT_80387_CONSTANTS): Ditto.
10986         (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL): Ditto.
10987         (X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Ditto.
10988         (X86_TUNE_SSE_TYPELESS_STORES): Ditto.
10989         (X86_TUNE_SSE_LOAD0_BY_PXOR): Ditto.
10990         (X86_TUNE_USE_GATHER_2PARTS): Add m_YONGFENG.
10991         (X86_TUNE_USE_GATHER_4PARTS): Ditto.
10992         (X86_TUNE_USE_GATHER_8PARTS): Ditto.
10993         (X86_TUNE_AVOID_128FMA_CHAINS): Ditto.
10994         * doc/extend.texi: Add details about yongfeng.
10995         * doc/invoke.texi: Ditto.
10996         * config/i386/yongfeng.md: New file to describe yongfeng processor.
10998 2023-10-30  Martin Jambor  <mjambor@suse.cz>
11000         PR ipa/111157
11001         * ipa-prop.h (struct ipa_argagg_value): Newf flag killed.
11002         * ipa-modref.cc (ipcp_argagg_and_kill_overlap_p): New function.
11003         (update_signature): Mark any any IPA-CP aggregate constants at
11004         positions known to be killed as killed.  Move check that there is
11005         clone_info after this pruning.
11006         * ipa-cp.cc (ipa_argagg_value_list::dump): Dump the killed flag.
11007         (ipa_argagg_value_list::push_adjusted_values): Clear the new flag.
11008         (push_agg_values_from_plats): Likewise.
11009         (ipa_push_agg_values_from_jfunc): Likewise.
11010         (estimate_local_effects): Likewise.
11011         (push_agg_values_for_index_from_edge): Likewise.
11012         * ipa-prop.cc (write_ipcp_transformation_info): Stream the killed
11013         flag.
11014         (read_ipcp_transformation_info): Likewise.
11015         (ipcp_get_aggregate_const): Update comment, assert that encountered
11016         record does not have killed flag set.
11017         (ipcp_transform_function): Prune all aggregate constants with killed
11018         set.
11020 2023-10-30  Martin Jambor  <mjambor@suse.cz>
11022         PR ipa/111157
11023         * ipa-prop.h (ipcp_transformation): New member function template
11024         remove_argaggs_if.
11025         * ipa-sra.cc (zap_useless_ipcp_results): Use remove_argaggs_if to
11026         filter aggreagate constants.
11028 2023-10-30  Roger Sayle  <roger@nextmovesoftware.com>
11030         PR middle-end/101955
11031         * config/arc/arc.md (*extvsi_1_0): New define_insn_and_split
11032         to convert sign extract of the least significant bit into an
11033         AND $1 then a NEG when !TARGET_BARREL_SHIFTER.
11035 2023-10-30  Roger Sayle  <roger@nextmovesoftware.com>
11037         * config/arc/arc.cc (arc_rtx_costs): Improve cost estimates.
11038         Provide reasonable values for SHIFTS and ROTATES by constant
11039         bit counts depending upon TARGET_BARREL_SHIFTER.
11040         (arc_insn_cost): Use insn attributes if the instruction is
11041         recognized.  Avoid calling get_attr_length for type "multi",
11042         i.e. define_insn_and_split patterns without explicit type.
11043         Fall-back to set_rtx_cost for single_set and pattern_cost
11044         otherwise.
11045         * config/arc/arc.h (COSTS_N_BYTES): Define helper macro.
11046         (BRANCH_COST): Improve/correct definition.
11047         (LOGICAL_OP_NON_SHORT_CIRCUIT): Preserve previous behavior.
11049 2023-10-30  Roger Sayle  <roger@nextmovesoftware.com>
11051         * config/arc/arc.cc (arc_split_ashl): Use lsl16 on TARGET_SWAP.
11052         (arc_split_ashr): Use swap and sign-extend on TARGET_SWAP.
11053         (arc_split_lshr): Use lsr16 on TARGET_SWAP.
11054         (arc_split_rotl): Use swap on TARGET_SWAP.
11055         (arc_split_rotr): Likewise.
11056         * config/arc/arc.md (ANY_ROTATE): New code iterator.
11057         (<ANY_ROTATE>si2_cnt16): New define_insn for alternate form of
11058         swap instruction on TARGET_SWAP.
11059         (ashlsi2_cnt16): Rename from *ashlsi16_cnt16 and move earlier.
11060         (lshrsi2_cnt16): New define_insn for LSR16 instruction.
11061         (*ashlsi2_cnt16): See above.
11063 2023-10-30  Richard Ball  <richard.ball@arm.com>
11065         * config/arm/aout.h: Change to use the Lrtx label.
11066         * config/arm/arm.h (CASE_VECTOR_PC_RELATIVE): Remove arm targets
11067         from (!target_pure_code) condition.
11068         (ADDR_VEC_ALIGN): Add align for tables in rodata section.
11069         * config/arm/arm.cc (arm_output_casesi): Alter the function to include
11070         .Lrtx label and remove adr instructions.
11071         * config/arm/arm.md
11072         (arm_casesi_internal): Use force_reg to generate ldr instructions that
11073         would otherwise be out of range, and change rtl to accommodate force reg.
11074         Additionally remove unnecessary register temp.
11075         (casesi): Remove pure code check for Arm.
11076         * config/arm/elf.h (JUMP_TABLES_IN_TEXT_SECTION): Remove arm
11077         targets from JUMP_TABLES_IN_TEXT_SECTION definition.
11079 2023-10-30  Jeevitha Palanisamy  <jeevitha@linux.ibm.com>
11081         PR target/106907
11082         * config/rs6000/rs6000.cc (altivec_expand_vec_perm_const): Change bitwise
11083         xor to an equality and fix comment indentation.
11085 2023-10-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
11087         * config/riscv/riscv-protos.h (sew64_scalar_helper): Fix bug.
11088         * config/riscv/riscv-v.cc (sew64_scalar_helper): Ditto.
11089         * config/riscv/vector.md: Ditto.
11091 2023-10-30  liuhongt  <hongtao.liu@intel.com>
11093         PR target/104610
11094         * config/i386/i386-expand.cc (ix86_expand_branch): Handle
11095         512-bit vector with vpcmpeq + kortest.
11096         * config/i386/i386.md (cbranchxi4): New expander.
11097         * config/i386/sse.md: (cbranch<mode>4): Extend to V16SImode
11098         and V8DImode.
11100 2023-10-30  Haochen Gui  <guihaoc@gcc.gnu.org>
11102         PR target/111449
11103         * expr.cc (qi_vector_mode_supported_p): Rename to...
11104         (by_pieces_mode_supported_p): ...this, and extends it to do
11105         the checking for both scalar and vector mode.
11106         (widest_fixed_size_mode_for_size): Call
11107         by_pieces_mode_supported_p to examine the mode.
11108         (op_by_pieces_d::smallest_fixed_size_mode_for_size): Likewise.
11110 2023-10-29  Martin Uecker  <uecker@tugraz.at>
11112         PR tree-optimization/109334
11113         * tree-object-size.cc (parm_object_size): Allow size
11114         computation for implicit access attributes.
11116 2023-10-29  Max Filippov  <jcmvbkbc@gmail.com>
11118         * config/xtensa/xtensa.h (TARGET_SALT): Change HW version from
11119         260000 (which corresponds to RF-2014.0) to 270000 (which
11120         corresponds to RG-2015.0, the release where salt/saltu opcodes
11121         were introduced).
11123 2023-10-29  Pan Li  <pan2.li@intel.com>
11125         * config/riscv/riscv-avlprop.cc (pass_avlprop::execute): Use
11126         reference type to prevent copying.
11128 2023-10-27  Vladimir N. Makarov  <vmakarov@redhat.com>
11130         PR rtl-optimization/112107
11131         * ira-costs.cc: (calculate_equiv_gains): Use NONDEBUG_INSN_P
11132         instead of INSN_P.
11134 2023-10-27  Andrew Stubbs  <ams@codesourcery.com>
11136         PR target/112088
11137         * config/gcn/gcn.cc (gcn_expand_epilogue): Fix kernel epilogue register
11138         conflict.
11140 2023-10-27  Andrew Stubbs  <ams@codesourcery.com>
11142         * config/gcn/gcn-valu.md
11143         (vec_extract<V_1REG:mode><V_1REG_ALT:mode>_nop): Mention "operands" in
11144         condition to silence the warnings.
11145         (vec_extract<V_2REG:mode><V_2REG_ALT:mode>_nop): Likewise.
11146         * config/gcn/gcn.md (*movti_insn): Likewise.
11148 2023-10-27  Richard Sandiford  <richard.sandiford@arm.com>
11150         * recog.cc (insn_propagation::apply_to_pattern_1): Handle shared
11151         ASM_OPERANDS.
11153 2023-10-27  Yangyu Chen  <chenyangyu@isrc.iscas.ac.cn>
11155         * config/riscv/riscv.cc (rocket_tune_info): Fix int_div cost.
11156         (sifive_7_tune_info, thead_c906_tune_info): Likewise.
11158 2023-10-27  Robin Dapp  <rdapp@ventanamicro.com>
11160         * config/riscv/autovec.md (rawmemchr<ANYI:mode>): New expander.
11161         * config/riscv/riscv-protos.h (gen_no_side_effects_vsetvl_rtx):
11162         Define.
11163         (expand_rawmemchr): Define.
11164         * config/riscv/riscv-v.cc (force_vector_length_operand): Remove
11165         static.
11166         (expand_block_move): Move from here...
11167         * config/riscv/riscv-string.cc (expand_block_move): ...to here.
11168         (expand_rawmemchr): Add vectorized expander.
11169         * internal-fn.cc (expand_RAWMEMCHR): Fix typo.
11171 2023-10-27  Vladimir N. Makarov  <vmakarov@redhat.com>
11173         * ira-costs.cc: (get_equiv_regno, calculate_equiv_gains):
11174         Process reg equivalence invariants.
11176 2023-10-27  Uros Bizjak  <ubizjak@gmail.com>
11178         * config/i386/x86-tune.def (X86_TUNE_PARTIAL_MEMORY_READ_STALL):
11179         i386: Fiy typo in "partial_memory_read_stall" tune option.
11181 2023-10-27  Victor Do Nascimento  <victor.donascimento@arm.com>
11183         * config/aarch64/aarch64.cc (aarch64_print_operand): Add
11184         support for CONST_STRING.
11186 2023-10-27  Roger Sayle  <roger@nextmovesoftware.com>
11188         PR target/110551
11189         * config/i386/i386.md (<u>mul<mode><dwi>3): Make operands 1 and
11190         2 take "regiser_operand" and "nonimmediate_operand" respectively.
11191         (<u>mulqihi3): Likewise.
11192         (*bmi2_umul<mode><dwi>3_1): Operand 2 needs to be register_operand
11193         matching the %d constraint.  Use umul_highpart RTX to represent
11194         the highpart multiplication.
11195         (*umul<mode><dwi>3_1):  Operand 2 should use regiser_operand
11196         predicate, and "a" rather than "0" as operands 0 and 2 have
11197         different modes.
11198         (define_split): For mul to mulx conversion, use the new
11199         umul_highpart RTX representation.
11200         (*mul<mode><dwi>3_1):  Operand 1 should be register_operand
11201         and the constraint %a as operands 0 and 1 have different modes.
11202         (*<u>mulqihi3_1): Operand 1 should be register_operand matching
11203         the constraint %0.
11204         (define_peephole2): Providing widening multiplication variants
11205         of the peephole2s that tweak highpart multiplication register
11206         allocation.
11208 2023-10-27  Lewis Hyatt  <lhyatt@gmail.com>
11210         PR preprocessor/87299
11211         * toplev.cc (no_backend): New static global.
11212         (finalize): Remove argument no_backend, which is now a
11213         static global.
11214         (process_options): Likewise.
11215         (do_compile): Likewise.
11216         (target_reinit): Don't do anything in preprocess-only mode.
11217         (toplev::main): Adapt to no_backend change.
11218         (toplev::finalize): Likewise.
11220 2023-10-27  Andrew Pinski  <apinski@marvell.com>
11222         PR tree-optimization/101590
11223         PR tree-optimization/94884
11224         * match.pd (`(X BIT_OP Y) CMP X`): New pattern.
11226 2023-10-27  liuhongt  <hongtao.liu@intel.com>
11228         PR target/103861
11229         * config/i386/i386-expand.cc (ix86_expand_sse_movcc): Handle
11230         V2HF/V2BF/V4HF/V4BFmode.
11231         * config/i386/i386.cc (ix86_get_mask_mode): Return QImode when
11232         data_mode is V4HF/V2HFmode.
11233         * config/i386/mmx.md (vec_cmpv4hfqi): New expander.
11234         (vcond_mask_<mode>v4hi): Ditto.
11235         (vcond_mask_<mode>qi): Ditto.
11236         (vec_cmpv2hfqi): Ditto.
11237         (vcond_mask_<mode>v2hi): Ditto.
11238         (mmx_plendvb_<mode>): Add 2 combine splitters after the
11239         patterns.
11240         (mmx_pblendvb_v8qi): Ditto.
11241         (<code>v2hi3): Add a combine splitter after the pattern.
11242         (<code><mode>3): Ditto.
11243         (<code>v8qi3): Ditto.
11244         (<code><mode>3): Ditto.
11245         * config/i386/sse.md (vcond<mode><mode>): Merge this with ..
11246         (vcond<sseintvecmodelower><mode>): .. this into ..
11247         (vcond<VI2HFBF_AVX512VL:mode><VHF_AVX512VL:mode>): .. this,
11248         and extend to V8BF/V16BF/V32BFmode.
11250 2023-10-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
11252         * config/riscv/riscv-opts.h (TARGET_MAX_LMUL): New macro.
11253         * config/riscv/riscv-v.cc (preferred_simd_mode): Adapt macro.
11254         (autovectorize_vector_modes): Ditto.
11255         (can_find_related_mode_p): Ditto.
11257 2023-10-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
11259         PR target/111318
11260         PR target/111888
11261         * config.gcc: Add AVL propagation pass.
11262         * config/riscv/riscv-passes.def (INSERT_PASS_AFTER): Ditto.
11263         * config/riscv/riscv-protos.h (make_pass_avlprop): Ditto.
11264         * config/riscv/t-riscv: Ditto.
11265         * config/riscv/riscv-avlprop.cc: New file.
11267 2023-10-26  David Malcolm  <dmalcolm@redhat.com>
11269         * doc/extend.texi (Common Function Attributes): Add
11270         null_terminated_string_arg.
11272 2023-10-26  Andrew Pinski  <pinskia@gmail.com>
11274         PR tree-optimization/111957
11275         * match.pd (`a != C1 ? abs(a) : C2`): New pattern.
11277 2023-10-26  Aldy Hernandez  <aldyh@redhat.com>
11279         * range-op-float.cc (range_operator::fold_range): Delete unused
11280         variable.
11282 2023-10-26  Aldy Hernandez  <aldyh@redhat.com>
11284         * range-op-float.cc (range_operator::fold_range): Remove
11285         superfluous code.
11286         (range_operator::rv_fold): Remove unneeded arguments.
11287         (operator_plus::rv_fold): Same.
11288         (operator_minus::rv_fold): Same.
11289         (operator_mult::rv_fold): Same.
11290         (operator_div::rv_fold): Same.
11291         * range-op-mixed.h: Remove lb, ub, and maybe_nan arguments from
11292         rv_fold methods.
11293         * range-op.h: Same.
11295 2023-10-26  Aldy Hernandez  <aldyh@redhat.com>
11297         * range-op-float.cc (range_operator::fold_range): Pass frange
11298         argument to rv_fold.
11299         (range_operator::rv_fold): Add frange argument.
11300         (operator_plus::rv_fold): Same.
11301         (operator_minus::rv_fold): Same.
11302         (operator_mult::rv_fold): Same.
11303         (operator_div::rv_fold): Same.
11304         * range-op-mixed.h: Add frange argument to rv_fold methods.
11305         * range-op.h: Same.
11307 2023-10-26  Richard Ball  <richard.ball@arm.com>
11309         * config/arm/aout.h (ASM_OUTPUT_ADDR_DIFF_ELT): Add table output
11310         for different machine modes for arm.
11311         * config/arm/arm-protos.h (arm_output_casesi): New prototype.
11312         * config/arm/arm.h (CASE_VECTOR_PC_RELATIVE): Make arm use
11313         ASM_OUTPUT_ADDR_DIFF_ELT.
11314         (CASE_VECTOR_SHORTEN_MODE): Change table size calculation for
11315         TARGET_ARM.
11316         (LABEL_ALIGN_AFTER_BARRIER): Change to accommodate .p2align 2
11317         for TARGET_ARM.
11318         * config/arm/arm.cc (arm_output_casesi): New function.
11319         * config/arm/arm.md (arm_casesi_internal): Change casesi expand
11320         and insn.
11321         for arm to use new function arm_output_casesi.
11323 2023-10-26  Iain Sandoe  <iain@sandoe.co.uk>
11325         * config/darwin.h
11326         (darwin_label_is_anonymous_local_objc_name): Make metadata names
11327         linker-visibile for GNU objective C.
11329 2023-10-26  Vladimir N. Makarov  <vmakarov@redhat.com>
11331         * dwarf2out.cc (reg_loc_descriptor): Use lra_eliminate_regs when
11332         LRA is used.
11333         * ira-costs.cc: Include regset.h.
11334         (equiv_can_be_consumed_p, get_equiv_regno, calculate_equiv_gains):
11335         New functions.
11336         (find_costs_and_classes): Call calculate_equiv_gains and redefine
11337         mem_cost of pseudos with equivs when LRA is used.
11338         * var-tracking.cc: Include ira.h and lra.h.
11339         (vt_initialize): Use lra_eliminate_regs when LRA is used.
11341 2023-10-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
11343         * doc/md.texi: Adapt COND_LEN pseudo code.
11345 2023-10-26  Roger Sayle  <roger@nextmovesoftware.com>
11346             Richard Biener  <rguenther@suse.de>
11348         PR rtl-optimization/91865
11349         * combine.cc (make_compound_operation): Avoid creating a
11350         ZERO_EXTEND of a ZERO_EXTEND.
11352 2023-10-26  Jiahao Xu  <xujiahao@loongson.cn>
11354         * config/loongarch/lasx.md (vcond_mask_<ILASX:mode><ILASX:mode>): Change to
11355         (vcond_mask_<mode><mode256_i>): this.
11356         * config/loongarch/lsx.md (vcond_mask_<ILSX:mode><ILSX:mode>): Change to
11357         (vcond_mask_<mode><mode_i>): this.
11359 2023-10-26  Thomas Schwinge  <thomas@codesourcery.com>
11361         * ipa-icf.cc (sem_item::target_supports_symbol_aliases_p):
11362         'gcc_checking_assert (TARGET_SUPPORTS_ALIASES);' before
11363         'return true;'.
11364         * ipa-visibility.cc (function_and_variable_visibility): Change
11365         '#ifdef ASM_OUTPUT_DEF' to 'if (TARGET_SUPPORTS_ALIASES)'.
11366         * varasm.cc (output_constant_pool_contents)
11367         [#ifdef ASM_OUTPUT_DEF]:
11368         'gcc_checking_assert (TARGET_SUPPORTS_ALIASES);'.
11369         (do_assemble_alias) [#ifdef ASM_OUTPUT_DEF]:
11370         'if (!TARGET_SUPPORTS_ALIASES)',
11371         'gcc_checking_assert (seen_error ());'.
11372         (assemble_alias): Change '#if !defined (ASM_OUTPUT_DEF)' to
11373         'if (!TARGET_SUPPORTS_ALIASES)'.
11374         (default_asm_output_anchor):
11375         'gcc_checking_assert (TARGET_SUPPORTS_ALIASES);'.
11377 2023-10-26  Alexandre Oliva  <oliva@adacore.com>
11379         PR tree-optimization/111520
11380         * gimple-harden-conditionals.cc
11381         (pass_harden_compares::execute): Set EH edge probability and
11382         EH block execution count.
11384 2023-10-26  Alexandre Oliva  <oliva@adacore.com>
11386         * tree-eh.h (make_eh_edges): Rename to...
11387         (make_eh_edge): ... this.
11388         * tree-eh.cc: Likewise.  Adjust all callers...
11389         * gimple-harden-conditionals.cc: ... here, ...
11390         * gimple-harden-control-flow.cc: ... here, ...
11391         * tree-cfg.cc: ... here, ...
11392         * tree-inline.cc: ... and here.
11394 2023-10-25  Iain Sandoe  <iain@sandoe.co.uk>
11396         * config/darwin.cc (darwin_override_options): Handle fPIE.
11398 2023-10-25  Iain Sandoe  <iain@sandoe.co.uk>
11400         * config.gcc: Use -E to to sed to indicate that we are using
11401         extended REs.
11403 2023-10-25  Jason Merrill  <jason@redhat.com>
11405         * tree-core.h (struct tree_base): Update address_space comment.
11407 2023-10-25  Wilco Dijkstra  <wilco.dijkstra@arm.com>
11409         * config/aarch64/aarch64.cc (aarch64_internal_mov_immediate)
11410         Add support for immediates using MOV/EOR bitmask.
11412 2023-10-25  Uros Bizjak  <ubizjak@gmail.com>
11414         PR target/111698
11415         * config/i386/x86-tune.def (X86_TUNE_PARTIAL_MEMORY_READ_STALL):
11416         New tune.
11417         * config/i386/i386.h (TARGET_PARTIAL_MEMORY_READ_STALL): New macro.
11418         * config/i386/i386.md: New peephole pattern to narrow test
11419         instructions with immediate operands that test memory locations
11420         for zero.
11422 2023-10-25  Andrew MacLeod  <amacleod@redhat.com>
11424         * value-range.cc (irange::union_append): New.
11425         (irange::union_): Call union_append when appropriate.
11426         * value-range.h (irange::union_append): New prototype.
11428 2023-10-25  Chenghui Pan  <panchenghui@loongson.cn>
11430         * config/loongarch/lasxintrin.h (__lasx_xvftintrnel_l_s): Fix comments.
11431         (__lasx_xvfrintrne_s): Ditto.
11432         (__lasx_xvfrintrne_d): Ditto.
11433         (__lasx_xvfrintrz_s): Ditto.
11434         (__lasx_xvfrintrz_d): Ditto.
11435         (__lasx_xvfrintrp_s): Ditto.
11436         (__lasx_xvfrintrp_d): Ditto.
11437         (__lasx_xvfrintrm_s): Ditto.
11438         (__lasx_xvfrintrm_d): Ditto.
11439         * config/loongarch/lsxintrin.h (__lsx_vftintrneh_l_s): Ditto.
11440         (__lsx_vfrintrne_s): Ditto.
11441         (__lsx_vfrintrne_d): Ditto.
11442         (__lsx_vfrintrz_s): Ditto.
11443         (__lsx_vfrintrz_d): Ditto.
11444         (__lsx_vfrintrp_s): Ditto.
11445         (__lsx_vfrintrp_d): Ditto.
11446         (__lsx_vfrintrm_s): Ditto.
11447         (__lsx_vfrintrm_d): Ditto.
11449 2023-10-25  chenxiaolong  <chenxiaolong@loongson.cn>
11451         * config/loongarch/loongarch.md (get_thread_pointer<mode>):Adds the
11452         instruction template corresponding to the __builtin_thread_pointer
11453         function.
11454         * doc/extend.texi:Add the __builtin_thread_pointer function support
11455         description to the documentation.
11457 2023-10-25  Richard Sandiford  <richard.sandiford@arm.com>
11459         * Makefile.in (OBJS): Add rtl-ssa/movement.o.
11460         * rtl-ssa/access-utils.h (accesses_include_nonfixed_hard_registers)
11461         (single_set_info): New functions.
11462         (remove_uses_of_def, accesses_reference_same_resource): Declare.
11463         (insn_clobbers_resources): Likewise.
11464         * rtl-ssa/accesses.cc (rtl_ssa::remove_uses_of_def): New function.
11465         (rtl_ssa::accesses_reference_same_resource): Likewise.
11466         (rtl_ssa::insn_clobbers_resources): Likewise.
11467         * rtl-ssa/movement.h (can_move_insn_p): Declare.
11468         * rtl-ssa/movement.cc: New file.
11470 2023-10-25  Richard Sandiford  <richard.sandiford@arm.com>
11472         * rtl-ssa/functions.h (function_info::remains_available_at_insn):
11473         New member function.
11474         * rtl-ssa/accesses.cc (function_info::remains_available_at_insn):
11475         Likewise.
11476         (function_info::make_use_available): Avoid false negatives for
11477         queries within an EBB.
11479 2023-10-25  Richard Sandiford  <richard.sandiford@arm.com>
11481         * rtl-ssa/changes.cc: Include sreal.h.
11482         (rtl_ssa::changes_are_worthwhile): When optimizing for speed,
11483         scale the cost of each instruction by its execution frequency.
11485 2023-10-25  Richard Sandiford  <richard.sandiford@arm.com>
11487         * rtl-ssa/access-utils.h (next_call_clobbers): New function.
11488         (is_single_dominating_def, remains_available_on_exit): Replace with...
11489         * rtl-ssa/functions.h (function_info::is_single_dominating_def)
11490         (function_info::remains_available_on_exit): ...these new member
11491         functions.
11492         (function_info::m_clobbered_by_calls): New member variable.
11493         * rtl-ssa/functions.cc (function_info::function_info): Explicitly
11494         initialize m_clobbered_by_calls.
11495         * rtl-ssa/insns.cc (function_info::record_call_clobbers): Update
11496         m_clobbered_by_calls for each call-clobber note.
11497         * rtl-ssa/member-fns.inl (function_info::is_single_dominating_def):
11498         New function.  Check for call clobbers.
11499         * rtl-ssa/accesses.cc (function_info::remains_available_on_exit):
11500         Likewise.
11502 2023-10-25  Richard Sandiford  <richard.sandiford@arm.com>
11504         * rtl-ssa/internals.h (build_info::exit_block_dominator): New
11505         member variable.
11506         * rtl-ssa/blocks.cc (build_info::build_info): Initialize it.
11507         (bb_walker::bb_walker): Use it, moving the computation of the
11508         dominator to...
11509         (function_info::process_all_blocks): ...here.
11510         (function_info::place_phis): Add dominance frontiers for the
11511         exit block.
11513 2023-10-25  Richard Sandiford  <richard.sandiford@arm.com>
11515         * rtl-ssa/functions.h (function_info::process_uses_of_deleted_def):
11516         New member function.
11517         * rtl-ssa/changes.cc (function_info::process_uses_of_deleted_def):
11518         Likewise.
11519         (function_info::change_insns): Use it.
11521 2023-10-25  Richard Sandiford  <richard.sandiford@arm.com>
11523         * rtl-ssa/changes.cc (function_info::finalize_new_accesses):
11524         If a change describes a set of memory, ensure that that set
11525         is kept, regardless of the insn pattern.
11527 2023-10-25  Richard Sandiford  <richard.sandiford@arm.com>
11529         * rtl-ssa/changes.cc (function_info::apply_changes_to_insn): Remove
11530         call to add_reg_unused_notes and instead...
11531         (function_info::change_insns): ...use a separate loop here.
11533 2023-10-25  Richard Sandiford  <richard.sandiford@arm.com>
11535         * rtl-ssa/blocks.cc (function_info::add_artificial_accesses): Force
11536         global registers to be live on exit.  Handle any block with zero
11537         successors like an exit block.
11539 2023-10-25  Thomas Schwinge  <thomas@codesourcery.com>
11541         * omp-oacc-kernels-decompose.cc (omp_oacc_kernels_decompose_1):
11542         Handle 'OMP_CLAUSE_SELF' like 'OMP_CLAUSE_IF'.
11543         * omp-expand.cc (expand_omp_target): Handle 'OMP_CLAUSE_SELF' for
11544         'GF_OMP_TARGET_KIND_OACC_DATA_KERNELS'.
11546 2023-10-25  Thomas Schwinge  <thomas@codesourcery.com>
11548         * tree-core.h (omp_clause_code): Move 'OMP_CLAUSE_SELF' after
11549         'OMP_CLAUSE_IF'.
11550         * tree-pretty-print.cc (dump_omp_clause): Adjust.
11551         * tree.cc (omp_clause_num_ops, omp_clause_code_name): Likewise.
11552         * tree.h: Likewise.
11554 2023-10-25  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
11556         * config/riscv/riscv-protos.h (has_vl_op): Export from riscv-vsetvl to riscv-v
11557         (tail_agnostic_p): Ditto.
11558         (validate_change_or_fail): Ditto.
11559         (nonvlmax_avl_type_p): Ditto.
11560         (vlmax_avl_p): Ditto.
11561         (get_sew): Ditto.
11562         (enum vlmul_type): Ditto.
11563         (count_regno_occurrences): Ditto.
11564         * config/riscv/riscv-v.cc (has_vl_op): Ditto.
11565         (get_default_ta): Ditto.
11566         (tail_agnostic_p): Ditto.
11567         (validate_change_or_fail): Ditto.
11568         (nonvlmax_avl_type_p): Ditto.
11569         (vlmax_avl_p): Ditto.
11570         (get_sew): Ditto.
11571         (enum vlmul_type): Ditto.
11572         (get_vlmul): Ditto.
11573         (count_regno_occurrences): Ditto.
11574         * config/riscv/riscv-vsetvl.cc (vlmax_avl_p): Ditto.
11575         (has_vl_op): Ditto.
11576         (get_sew): Ditto.
11577         (get_vlmul): Ditto.
11578         (get_default_ta): Ditto.
11579         (tail_agnostic_p): Ditto.
11580         (count_regno_occurrences): Ditto.
11581         (validate_change_or_fail): Ditto.
11583 2023-10-25  Chung-Lin Tang  <cltang@codesourcery.com>
11585         * gimplify.cc (gimplify_scan_omp_clauses): Add OMP_CLAUSE_SELF case.
11586         (gimplify_adjust_omp_clauses): Likewise.
11587         * omp-expand.cc (expand_omp_target): Add OMP_CLAUSE_SELF expansion code,
11588         * omp-low.cc (scan_sharing_clauses): Add OMP_CLAUSE_SELF case.
11589         * tree-core.h (enum omp_clause_code): Add OMP_CLAUSE_SELF enum.
11590         * tree-nested.cc (convert_nonlocal_omp_clauses): Add OMP_CLAUSE_SELF
11591         case.
11592         (convert_local_omp_clauses): Likewise.
11593         * tree-pretty-print.cc (dump_omp_clause): Add OMP_CLAUSE_SELF case.
11594         * tree.cc (omp_clause_num_ops): Add OMP_CLAUSE_SELF entry.
11595         (omp_clause_code_name): Likewise.
11596         * tree.h (OMP_CLAUSE_SELF_EXPR): New macro.
11598 2023-10-25  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
11600         * config/riscv/riscv-protos.h (vlmax_avl_type_p): New function.
11601         * config/riscv/riscv-v.cc (vlmax_avl_type_p): Ditto.
11602         * config/riscv/riscv-vsetvl.cc (get_avl): Adapt function.
11603         * config/riscv/vector.md: Change avl_type into avl_type_idx.
11605 2023-10-24  Richard Sandiford  <richard.sandiford@arm.com>
11607         * recog.cc (constrain_operands): Remove UNARY_P handling.
11608         * reload.cc (find_reloads): Likewise.
11610 2023-10-24  Jose E. Marchesi  <jose.marchesi@oracle.com>
11612         * gcov-io.h: Fix record length encoding in comment.
11614 2023-10-24  Roger Sayle  <roger@nextmovesoftware.com>
11616         * config/i386/i386-features.cc (compute_convert_gain): Provide
11617         more accurate values (sizes) for inter-unit moves with -Os.
11619 2023-10-24  Roger Sayle  <roger@nextmovesoftware.com>
11620             Claudiu Zissulescu  <claziss@gmail.com>
11622         * config/arc/arc-protos.h (output_shift): Rename to...
11623         (output_shift_loop): Tweak API to take an explicit rtx_code.
11624         (arc_split_ashl): Prototype new function here.
11625         (arc_split_ashr): Likewise.
11626         (arc_split_lshr): Likewise.
11627         (arc_split_rotl): Likewise.
11628         (arc_split_rotr): Likewise.
11629         * config/arc/arc.cc (output_shift): Delete local prototype.  Rename.
11630         (output_shift_loop): New function replacing output_shift to output
11631         a zero overheap loop for SImode shifts and rotates on ARC targets
11632         without barrel shifter (i.e. no hardware support for these insns).
11633         (arc_split_ashl): New helper function to split *ashlsi3_nobs.
11634         (arc_split_ashr): New helper function to split *ashrsi3_nobs.
11635         (arc_split_lshr): New helper function to split *lshrsi3_nobs.
11636         (arc_split_rotl): New helper function to split *rotlsi3_nobs.
11637         (arc_split_rotr): New helper function to split *rotrsi3_nobs.
11638         (arc_print_operand): Correct whitespace.
11639         (arc_rtx_costs): Likewise.
11640         (hwloop_optimize): Likewise.
11641         * config/arc/arc.md (ANY_SHIFT_ROTATE): New define_code_iterator.
11642         (define_code_attr insn): New code attribute to map to pattern name.
11643         (<ANY_SHIFT_ROTATE>si3): New expander unifying previous ashlsi3,
11644         ashrsi3 and lshrsi3 define_expands.  Adds rotlsi3 and rotrsi3.
11645         (*<ANY_SHIFT_ROTATE>si3_nobs): New define_insn_and_split that
11646         unifies the previous *ashlsi3_nobs, *ashrsi3_nobs and *lshrsi3_nobs.
11647         We now call arc_split_<insn> in arc.cc to implement each split.
11648         (shift_si3): Delete define_insn, all shifts/rotates are now split.
11649         (shift_si3_loop): Rename to...
11650         (<insn>si3_loop): define_insn to handle loop implementations of
11651         SImode shifts and rotates, calling ouput_shift_loop for template.
11652         (rotrsi3): Rename to...
11653         (*rotrsi3_insn): define_insn for TARGET_BARREL_SHIFTER's ror.
11654         (*rotlsi3): New define_insn_and_split to transform left rotates
11655         into right rotates before reload.
11656         (rotlsi3_cnt1): New define_insn_and_split to implement a left
11657         rotate by one bit using an add.f followed by an adc.
11658         * config/arc/predicates.md (shiftr4_operator): Delete.
11660 2023-10-24  Claudiu Zissulescu  <claziss@gmail.com>
11662         * config/arc/arc.md (mulsi3_700): Update pattern.
11663         (mulsi3_v2): Likewise.
11664         * config/arc/predicates.md (mpy_dest_reg_operand): Remove it.
11666 2023-10-24  Andrew Pinski  <pinskia@gmail.com>
11668         PR tree-optimization/104376
11669         PR tree-optimization/101541
11670         * tree-ssa-phiopt.cc (factor_out_conditional_operation):
11671         Allow nop conversions even if it is defined by a statement
11672         inside the conditional.
11674 2023-10-24  Andrew Pinski  <pinskia@gmail.com>
11676         PR tree-optimization/111913
11677         * match.pd (`popcount(X&Y) + popcount(X|Y)`): Add the resulting
11678         type for popcount.
11680 2023-10-24  Richard Sandiford  <richard.sandiford@arm.com>
11682         * rtl-ssa/blocks.cc (function_info::create_degenerate_phi): Check
11683         whether the requested phi already exists.
11685 2023-10-24  Richard Sandiford  <richard.sandiford@arm.com>
11687         * rtl-ssa.h: Include cfgbuild.h.
11688         * rtl-ssa/movement.h (can_insert_after): Replace is_jump with the
11689         more comprehensive control_flow_insn_p.
11691 2023-10-24  Richard Sandiford  <richard.sandiford@arm.com>
11693         * rtl-ssa/changes.cc (function_info::perform_pending_updates): Check
11694         whether an insn has been replaced by a note.
11696 2023-10-24  Richard Sandiford  <richard.sandiford@arm.com>
11698         * rtl-ssa/member-fns.inl (first_any_insn_use): Handle null
11699         m_first_use.
11701 2023-10-24  Richard Sandiford  <richard.sandiford@arm.com>
11703         * config/i386/i386-expand.cc (ix86_split_mmx_punpck): Allow the
11704         destination to be wider than the sources.  Take the mode from the
11705         first source.
11706         (ix86_expand_sse_extend): Pass the destination directly to
11707         ix86_split_mmx_punpck, rather than using a fresh register that
11708         is half the size.
11710 2023-10-24  Richard Sandiford  <richard.sandiford@arm.com>
11712         * config/i386/predicates.md (aeswidekl_operation): Protect
11713         REGNO check with REG_P.
11715 2023-10-24  Richard Sandiford  <richard.sandiford@arm.com>
11717         * config/aarch64/aarch64.cc (aarch64_insn_cost): New function.
11718         (TARGET_INSN_COST): Define.
11720 2023-10-24  Richard Sandiford  <richard.sandiford@arm.com>
11722         * config/aarch64/atomics.md (aarch64_atomic_exchange<mode>): Require
11723         !TARGET_LSE.
11725 2023-10-24  xuli  <xuli1@eswincomputing.com>
11727         PR target/111935
11728         * config/riscv/riscv-vector-builtins-bases.cc: fix bug.
11730 2023-10-24  Mark Harmstone  <mark@harmstone.com>
11732         * opts.cc (debug_type_names): Remove stabs and xcoff.
11733         (df_set_names): Adjust.
11735 2023-10-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
11737         PR target/111947
11738         * config/riscv/riscv-vsetvl.cc (pre_vsetvl::compute_lcm_local_properties): Add REGNO check.
11740 2023-10-23  Lewis Hyatt  <lhyatt@gmail.com>
11742         PR preprocessor/36887
11743         * toplev.h (ident_hash_extra): Declare...
11744         * stringpool.cc (ident_hash_extra): ...this new global variable.
11745         (init_stringpool): Handle ident_hash_extra as well as ident_hash.
11746         (ggc_mark_stringpool): Likewise.
11747         (ggc_purge_stringpool): Likewise.
11748         (struct string_pool_data_extra): New struct.
11749         (spd2): New GC root variable.
11750         (gt_pch_save_stringpool): Use spd2 to handle ident_hash_extra,
11751         analogous to how spd is used to handle ident_hash.
11752         (gt_pch_restore_stringpool): Likewise.
11754 2023-10-23  Robin Dapp  <rdapp@ventanamicro.com>
11756         PR tree-optimization/111794
11757         * tree-vect-stmts.cc (vectorizable_assignment): Add
11758         same-precision exception for dest and source.
11760 2023-10-23  Robin Dapp  <rdapp@ventanamicro.com>
11762         * config/riscv/autovec.md (popcount<mode>2): New expander.
11763         * config/riscv/riscv-protos.h (expand_popcount): Define.
11764         * config/riscv/riscv-v.cc (expand_popcount): Vectorize popcount
11765         with the WWG algorithm.
11767 2023-10-23  Richard Biener  <rguenther@suse.de>
11769         PR tree-optimization/111916
11770         * tree-sra.cc (sra_modify_assign): Do not lower all
11771         BIT_FIELD_REF reads that are sra_handled_bf_read_p.
11773 2023-10-23  Richard Biener  <rguenther@suse.de>
11775         PR tree-optimization/111915
11776         * tree-vect-slp.cc (vect_build_slp_tree_1): Check all
11777         accesses are either grouped or not.
11779 2023-10-23  Richard Biener  <rguenther@suse.de>
11781         PR ipa/111914
11782         * tree-inline.cc (setup_one_parameter): Move code emitting
11783         a dummy load when not optimizing ...
11784         (initialize_inlined_parameters): ... here to after when
11785         we remapped the parameter type.
11787 2023-10-23  Oleg Endo  <olegendo@gcc.gnu.org>
11789         PR target/111001
11790         * config/sh/sh_treg_combine.cc (sh_treg_combine::record_set_of_reg):
11791         Skip over nop move insns.
11793 2023-10-23  Tamar Christina  <tamar.christina@arm.com>
11795         PR tree-optimization/111860
11796         * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
11797         Drop .MEM nodes only.
11799 2023-10-23  Andrew Pinski  <apinski@marvell.com>
11801         * match.pd (`(A - B) CMP 0 ? (A - B) : (B - A)`):
11802         New patterns.
11804 2023-10-23  Andrew Pinski  <pinskia@gmail.com>
11806         * convert.cc (convert_to_pointer_1): Return error_mark_node
11807         after an error.
11808         (convert_to_real_1): Likewise.
11809         (convert_to_integer_1): Likewise.
11810         (convert_to_complex_1): Likewise.
11812 2023-10-23  Andrew Pinski  <pinskia@gmail.com>
11814         PR c/111903
11815         * convert.cc (convert_to_complex_1): Return
11816         error_mark_node if either convert was an error
11817         when converting from a scalar.
11819 2023-10-23  Richard Biener  <rguenther@suse.de>
11821         PR tree-optimization/111917
11822         * tree-ssa-loop-unswitch.cc (hoist_guard): Always insert
11823         new conditional after last stmt.
11825 2023-10-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
11827         PR target/111927
11828         * config/riscv/riscv-vsetvl.cc: Fix bug.
11830 2023-10-23  Pan Li  <pan2.li@intel.com>
11832         * config/riscv/riscv-v.cc (emit_vec_cvt_x_f_rtz): Add insn type
11833         arg.
11834         (expand_vec_trunc): Take MA instead of MU for cvt_x_f_rtz.
11836 2023-10-23  Xi Ruoyao  <xry111@xry111.site>
11838         * doc/invoke.texi (-mexplicit-relocs=style): Document.
11839         (-mexplicit-relocs): Document as an alias of
11840         -mexplicit-relocs=always.
11841         (-mno-explicit-relocs): Document as an alias of
11842         -mexplicit-relocs=none.
11843         (-mcmodel=extreme): Mention -mexplicit-relocs=always instead of
11844         -mexplicit-relocs.
11846 2023-10-23  Xi Ruoyao  <xry111@xry111.site>
11848         * config/loongarch/predicates.md (symbolic_pcrel_operand): New
11849         predicate.
11850         * config/loongarch/loongarch.md (define_peephole2): Optimize
11851         la.local + ld/st to pcalau12i + ld/st if the address is only used
11852         once if -mexplicit-relocs=auto and -mcmodel=normal or medium.
11854 2023-10-23  Xi Ruoyao  <xry111@xry111.site>
11856         * config/loongarch/loongarch.cc (loongarch_explicit_relocs_p):
11857         Return true for TLS symbol types if -mexplicit-relocs=auto.
11858         (loongarch_call_tls_get_addr): Replace TARGET_EXPLICIT_RELOCS
11859         with la_opt_explicit_relocs != EXPLICIT_RELOCS_NONE.
11860         (loongarch_legitimize_tls_address): Likewise.
11861         * config/loongarch/loongarch.md (@tls_low<mode>): Remove
11862         TARGET_EXPLICIT_RELOCS from insn condition.
11864 2023-10-23  Xi Ruoyao  <xry111@xry111.site>
11866         * config/loongarch/loongarch-protos.h
11867         (loongarch_explicit_relocs_p): Declare new function.
11868         * config/loongarch/loongarch.cc (loongarch_explicit_relocs_p):
11869         Implement.
11870         (loongarch_symbol_insns): Call loongarch_explicit_relocs_p for
11871         SYMBOL_GOT_DISP, instead of using TARGET_EXPLICIT_RELOCS.
11872         (loongarch_split_symbol): Call loongarch_explicit_relocs_p for
11873         deciding if return early, instead of using
11874         TARGET_EXPLICIT_RELOCS.
11875         (loongarch_output_move): CAll loongarch_explicit_relocs_p
11876         instead of using TARGET_EXPLICIT_RELOCS.
11877         * config/loongarch/loongarch.md (*low<mode>): Remove
11878         TARGET_EXPLICIT_RELOCS from insn condition.
11879         (@ld_from_got<mode>): Likewise.
11880         * config/loongarch/predicates.md (move_operand): Call
11881         loongarch_explicit_relocs_p instead of using
11882         TARGET_EXPLICIT_RELOCS.
11884 2023-10-23  Xi Ruoyao  <xry111@xry111.site>
11886         * config/loongarch/genopts/loongarch-strings: Add strings for
11887         -mexplicit-relocs={auto,none,always}.
11888         * config/loongarch/genopts/loongarch.opt.in: Add options for
11889         -mexplicit-relocs={auto,none,always}.
11890         * config/loongarch/loongarch-str.h: Regenerate.
11891         * config/loongarch/loongarch.opt: Regenerate.
11892         * config/loongarch/loongarch-def.h
11893         (EXPLICIT_RELOCS_AUTO): Define.
11894         (EXPLICIT_RELOCS_NONE): Define.
11895         (EXPLICIT_RELOCS_ALWAYS): Define.
11896         (N_EXPLICIT_RELOCS_TYPES): Define.
11897         * config/loongarch/loongarch.cc
11898         (loongarch_option_override_internal): Error out if the old-style
11899         -m[no-]explicit-relocs option is used with
11900         -mexplicit-relocs={auto,none,always} together.  Map
11901         -mno-explicit-relocs to -mexplicit-relocs=none and
11902         -mexplicit-relocs to -mexplicit-relocs=always for backward
11903         compatibility.  Set a proper default for -mexplicit-relocs=
11904         based on configure-time probed linker capability.  Update a
11905         diagnostic message to mention -mexplicit-relocs=always instead
11906         of the old-style -mexplicit-relocs.
11907         (loongarch_handle_model_attribute): Update a diagnostic message
11908         to mention -mexplicit-relocs=always instead of the old-style
11909         -mexplicit-relocs.
11910         * config/loongarch/loongarch.h (TARGET_EXPLICIT_RELOCS): Define.
11912 2023-10-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
11914         * config/riscv/riscv-vsetvl.cc (pre_vsetvl::fuse_local_vsetvl_info): Fix typo.
11915         (pre_vsetvl::pre_global_vsetvl_info): Ditto.
11917 2023-10-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
11919         * config/riscv/vector.md: Fix avl_type attribute of tuple mov<mode>.
11921 2023-10-23  Kewen Lin  <linkw@linux.ibm.com>
11923         PR tree-optimization/111784
11924         * tree-vect-stmts.cc (vectorizable_store): Adjust costing way for
11925         adjacent vector stores, by costing them with the total number
11926         rather than costing them one by one.
11927         (vectorizable_load): Adjust costing way for adjacent vector
11928         loads, by costing them with the total number rather than costing
11929         them one by one.
11931 2023-10-23  Haochen Jiang  <haochen.jiang@intel.com>
11933         PR target/111753
11934         * config/i386/i386.cc (ix86_standard_x87sse_constant_load_p):
11935         Do not split to xmm16+ when !TARGET_AVX512VL.
11937 2023-10-23  Pan Li  <pan2.li@intel.com>
11939         * config/riscv/riscv-protos.h (enum insn_type): Add new type
11940         values.
11941         * config/riscv/riscv-v.cc (emit_vec_cvt_x_f): Add undef merge
11942         operand handling.
11943         (expand_vec_ceil): Take MA instead of MU for tmp register.
11944         (expand_vec_floor): Ditto.
11945         (expand_vec_nearbyint): Ditto.
11946         (expand_vec_rint): Ditto.
11947         (expand_vec_round): Ditto.
11948         (expand_vec_roundeven): Ditto.
11950 2023-10-23  Lulu Cheng  <chenglulu@loongson.cn>
11952         * config/loongarch/loongarch.h (CLEAR_INSN_CACHE): New definition.
11954 2023-10-23  Haochen Gui  <guihaoc@gcc.gnu.org>
11956         PR target/111449
11957         * expr.cc (can_use_qi_vectors): New function to return true if
11958         we know how to implement OP using vectors of bytes.
11959         (qi_vector_mode_supported_p): New function to check if optabs
11960         exists for the mode and certain by pieces operations.
11961         (widest_fixed_size_mode_for_size): Replace the second argument
11962         with the type of by pieces operations.  Call can_use_qi_vectors
11963         and qi_vector_mode_supported_p to do the check.  Call
11964         scalar_mode_supported_p to check if the scalar mode is supported.
11965         (by_pieces_ninsns): Pass the type of by pieces operation to
11966         widest_fixed_size_mode_for_size.
11967         (class op_by_pieces_d): Remove m_qi_vector_mode.  Add m_op to
11968         record the type of by pieces operations.
11969         (op_by_pieces_d::op_by_pieces_d): Change last argument to the
11970         type of by pieces operations, initialize m_op with it.  Pass
11971         m_op to function widest_fixed_size_mode_for_size.
11972         (op_by_pieces_d::get_usable_mode): Pass m_op to function
11973         widest_fixed_size_mode_for_size.
11974         (op_by_pieces_d::smallest_fixed_size_mode_for_size): Call
11975         can_use_qi_vectors and qi_vector_mode_supported_p to do the
11976         check.
11977         (op_by_pieces_d::run): Pass m_op to function
11978         widest_fixed_size_mode_for_size.
11979         (move_by_pieces_d::move_by_pieces_d): Set m_op to MOVE_BY_PIECES.
11980         (store_by_pieces_d::store_by_pieces_d): Set m_op with the op.
11981         (can_store_by_pieces): Pass the type of by pieces operations to
11982         widest_fixed_size_mode_for_size.
11983         (clear_by_pieces): Initialize class store_by_pieces_d with
11984         CLEAR_BY_PIECES.
11985         (compare_by_pieces_d::compare_by_pieces_d): Set m_op to
11986         COMPARE_BY_PIECES.
11988 2023-10-23  liuhongt  <hongtao.liu@intel.com>
11990         PR tree-optimization/111820
11991         PR tree-optimization/111833
11992         * tree-vect-loop-manip.cc (vect_can_peel_nonlinear_iv_p): Give
11993         up vectorization for nonlinear iv vect_step_op_mul when
11994         step_expr is not exact_log2 and niters is greater than
11995         TYPE_PRECISION (TREE_TYPE (step_expr)). Also don't vectorize
11996         for nagative niters_skip which will be used by fully masked
11997         loop.
11998         (vect_can_advance_ivs_p): Pass whole phi_info to
11999         vect_can_peel_nonlinear_iv_p.
12000         * tree-vect-loop.cc (vect_peel_nonlinear_iv_init): Optimize
12001         init_expr * pow (step_expr, skipn) to init_expr
12002         << (log2 (step_expr) * skipn) when step_expr is exact_log2.
12004 2023-10-23  liuhongt  <hongtao.liu@intel.com>
12006         * config/i386/mmx.md (mmx_pinsrw): Remove.
12008 2023-10-22  Andrew Pinski  <pinskia@gmail.com>
12010         PR target/110986
12011         * config/aarch64/aarch64.md (*cmov<mode>_insn_insv): New pattern.
12012         (*cmov_uxtw_insn_insv): Likewise.
12014 2023-10-22  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
12016         * doc/invoke.texi: Document the new -nodefaultrpaths option.
12017         * doc/install.texi: Document the new --with-darwin-extra-rpath
12018         option.
12020 2023-10-22  Iain Sandoe  <iain@sandoe.co.uk>
12022         * Makefile.in: set ENABLE_DARWIN_AT_RPATH in site.tmp.
12024 2023-10-22  Iain Sandoe  <iain@sandoe.co.uk>
12026         * configure.ac: Add --with-darwin-extra-rpath option.
12027         * config/darwin.h: Handle DARWIN_EXTRA_RPATH.
12028         * config.in: Regenerate.
12029         * configure: Regenerate.
12031 2023-10-22  Iain Sandoe  <iain@sandoe.co.uk>
12033         * aclocal.m4: Regenerate.
12034         * configure: Regenerate.
12035         * configure.ac: Handle Darwin rpaths.
12036         * config/darwin.h: Handle Darwin rpaths.
12037         * config/darwin.opt: Handle Darwin rpaths.
12038         * Makefile.in:  Handle Darwin rpaths.
12040 2023-10-22  Iain Sandoe  <iain@sandoe.co.uk>
12042         * gcc.cc (RUNPATH_OPTION): New.
12043         (do_spec_1): Provide '%P' as a spec to insert rpaths for
12044         each compiler startfile path.
12046 2023-10-22  Andrew Burgess  <andrew.burgess@embecosm.com>
12047             Maxim Blinov  <maxim.blinov@embecosm.com>
12048             Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
12049             Iain Sandoe  <iain@sandoe.co.uk>
12051         * config.gcc: Default to heap trampolines on macOS 11 and above.
12052         * config/i386/darwin.h: Define X86_CUSTOM_FUNCTION_TEST.
12053         * config/i386/i386.h: Define X86_CUSTOM_FUNCTION_TEST.
12054         * config/i386/i386.cc: Use X86_CUSTOM_FUNCTION_TEST.
12056 2023-10-22  Andrew Burgess  <andrew.burgess@embecosm.com>
12057             Maxim Blinov  <maxim.blinov@embecosm.com>
12058             Iain Sandoe  <iain@sandoe.co.uk>
12059             Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
12061         * builtins.def (BUILT_IN_NESTED_PTR_CREATED): Define.
12062         (BUILT_IN_NESTED_PTR_DELETED): Ditto.
12063         * common.opt (ftrampoline-impl): Add option to control
12064         generation of trampoline instantiation (heap or stack).
12065         * coretypes.h: Define enum trampoline_impl.
12066         * tree-nested.cc (convert_tramp_reference_op): Don't bother calling
12067         __builtin_adjust_trampoline for heap trampolines.
12068         (finalize_nesting_tree_1): Emit calls to
12069         __builtin_nested_...{created,deleted} if we're generating with
12070         -ftrampoline-impl=heap.
12071         * tree.cc (build_common_builtin_nodes): Build
12072         __builtin_nested_...{created,deleted}.
12073         * doc/invoke.texi (-ftrampoline-impl): Document.
12075 2023-10-22  Tsukasa OI  <research_trasio@irq.a4lg.com>
12077         * common/config/riscv/riscv-common.cc (riscv_subset_list::parse):
12078         Prohibit 'E' and 'H' combinations.
12080 2023-10-22  Tsukasa OI  <research_trasio@irq.a4lg.com>
12082         * common/config/riscv/riscv-common.cc (riscv_ext_version_table):
12083         Change version number of the 'Zfa' extension to 1.0.
12085 2023-10-21  Pan Li  <pan2.li@intel.com>
12087         PR target/111857
12088         * config/riscv/riscv-opts.h (TARGET_VECTOR_VLS): Remove.
12089         * config/riscv/riscv-protos.h (vls_mode_valid_p): New func decl.
12090         * config/riscv/riscv-v.cc (autovectorize_vector_modes): Replace
12091         macro reference to func.
12092         (vls_mode_valid_p): New func impl for vls mode valid or not.
12093         * config/riscv/riscv-vector-switch.def (VLS_ENTRY): Replace
12094         macro reference to func.
12095         * config/riscv/vector-iterators.md: Ditto.
12097 2023-10-20  Roger Sayle  <roger@nextmovesoftware.com>
12098             Uros Bizjak  <ubizjak@gmail.com>
12100         PR middle-end/101955
12101         PR tree-optimization/106245
12102         * config/i386/i386.md (*extv<mode>_1_0): New define_insn_and_split.
12104 2023-10-20  David Edelsohn  <dje.gcc@gmail.com>
12106         * gimple-harden-control-flow.cc: Include memmodel.h.
12108 2023-10-20  David Edelsohn  <dje.gcc@gmail.com>
12110         * gimple-harden-control-flow.cc: Include tm_p.h.
12112 2023-10-20  Andre Vieira  <andre.simoesdiasvieira@arm.com>
12114         PR tree-optimization/111882
12115         * tree-if-conv.cc (get_bitfield_rep): Return NULL_TREE for bitfields
12116         with non-constant offsets.
12118 2023-10-20  Tamar Christina  <tamar.christina@arm.com>
12120         PR tree-optimization/111866
12121         * tree-vect-loop-manip.cc (vect_do_peeling): Pass null as vinfo to
12122         vect_set_loop_condition during prolog peeling.
12124 2023-10-20  Richard Biener  <rguenther@suse.de>
12126         PR tree-optimization/111445
12127         * tree-scalar-evolution.cc (simple_iv_with_niters):
12128         Add missing check for a sign-conversion.
12130 2023-10-20  Richard Biener  <rguenther@suse.de>
12132         PR tree-optimization/110243
12133         PR tree-optimization/111336
12134         * tree-ssa-loop-ivopts.cc (strip_offset_1): Rewrite
12135         operations with undefined behavior on overflow to
12136         unsigned arithmetic.
12138 2023-10-20  Richard Biener  <rguenther@suse.de>
12140         PR tree-optimization/111891
12141         * tree-vect-stmts.cc (vectorizable_simd_clone_call): Fix
12142         assert.
12144 2023-10-20  Andrew Stubbs  <ams@codesourcery.com>
12146         * config.gcc: Allow --with-arch=gfx1030.
12147         * config/gcn/gcn-hsa.h (NO_XNACK): gfx1030 does not support xnack.
12148         (ASM_SPEC): gfx1030 needs -mattr=+wavefrontsize64 set.
12149         * config/gcn/gcn-opts.h (enum processor_type): Add PROCESSOR_GFX1030.
12150         (TARGET_GFX1030): New.
12151         (TARGET_RDNA2): New.
12152         * config/gcn/gcn-valu.md (@dpp_move<mode>): Disable for RDNA2.
12153         (addc<mode>3<exec_vcc>): Add RDNA2 syntax variant.
12154         (subc<mode>3<exec_vcc>): Likewise.
12155         (<convop><mode><vndi>2_exec): Add RDNA2 alternatives.
12156         (vec_cmp<mode>di): Likewise.
12157         (vec_cmp<u><mode>di): Likewise.
12158         (vec_cmp<mode>di_exec): Likewise.
12159         (vec_cmp<u><mode>di_exec): Likewise.
12160         (vec_cmp<mode>di_dup): Likewise.
12161         (vec_cmp<mode>di_dup_exec): Likewise.
12162         (reduc_<reduc_op>_scal_<mode>): Disable for RDNA2.
12163         (*<reduc_op>_dpp_shr_<mode>): Likewise.
12164         (*plus_carry_dpp_shr_<mode>): Likewise.
12165         (*plus_carry_in_dpp_shr_<mode>): Likewise.
12166         * config/gcn/gcn.cc (gcn_option_override): Recognise gfx1030.
12167         (gcn_global_address_p): RDNA2 only allows smaller offsets.
12168         (gcn_addr_space_legitimate_address_p): Likewise.
12169         (gcn_omp_device_kind_arch_isa): Recognise gfx1030.
12170         (gcn_expand_epilogue): Use VGPRs instead of SGPRs.
12171         (output_file_start): Configure gfx1030.
12172         * config/gcn/gcn.h (TARGET_CPU_CPP_BUILTINS): Add __RDNA2__;
12173         (ASSEMBLER_DIALECT): New.
12174         * config/gcn/gcn.md (rdna): New define_attr.
12175         (enabled): Use "rdna" attribute.
12176         (gcn_return): Remove s_dcache_wb.
12177         (addcsi3_scalar): Add RDNA2 syntax variant.
12178         (addcsi3_scalar_zero): Likewise.
12179         (addptrdi3): Likewise.
12180         (mulsi3): v_mul_lo_i32 should be v_mul_lo_u32 on all ISA.
12181         (*memory_barrier): Add RDNA2 syntax variant.
12182         (atomic_load<mode>): Add RDNA2 cache control variants, and disable
12183         scalar atomics for RDNA2.
12184         (atomic_store<mode>): Likewise.
12185         (atomic_exchange<mode>): Likewise.
12186         * config/gcn/gcn.opt (gpu_type): Add gfx1030.
12187         * config/gcn/mkoffload.cc (EF_AMDGPU_MACH_AMDGCN_GFX1030): New.
12188         (main): Recognise -march=gfx1030.
12189         * config/gcn/t-omp-device: Add gfx1030 isa.
12191 2023-10-20  Richard Biener  <rguenther@suse.de>
12193         PR tree-optimization/111000
12194         * stor-layout.h (element_precision): Move ..
12195         * tree.h (element_precision): .. here.
12196         * tree-ssa-loop-im.cc (movement_possibility_1): Restrict
12197         motion of shifts and rotates.
12199 2023-10-20  Alexandre Oliva  <oliva@adacore.com>
12201         * tree-core.h (ECF_XTHROW): New macro.
12202         * tree.cc (set_call_expr): Add expected_throw attribute when
12203         ECF_XTHROW is set.
12204         (build_common_builtin_node): Add ECF_XTHROW to
12205         __cxa_end_cleanup and _Unwind_Resume or _Unwind_SjLj_Resume.
12206         * calls.cc (flags_from_decl_or_type): Check for expected_throw
12207         attribute to set ECF_XTHROW.
12208         * gimple.cc (gimple_build_call_from_tree): Propagate
12209         ECF_XTHROW from decl flags to gimple call...
12210         (gimple_call_flags): ... and back.
12211         * gimple.h (GF_CALL_XTHROW): New gf_mask flag.
12212         (gimple_call_set_expected_throw): New.
12213         (gimple_call_expected_throw_p): New.
12214         * Makefile.in (OBJS): Add gimple-harden-control-flow.o.
12215         * builtins.def (BUILT_IN___HARDCFR_CHECK): New.
12216         * common.opt (fharden-control-flow-redundancy): New.
12217         (-fhardcfr-check-returning-calls): New.
12218         (-fhardcfr-check-exceptions): New.
12219         (-fhardcfr-check-noreturn-calls=*): New.
12220         (Enum hardcfr_check_noreturn_calls): New.
12221         (fhardcfr-skip-leaf): New.
12222         * doc/invoke.texi: Document them.
12223         (hardcfr-max-blocks, hardcfr-max-inline-blocks): New params.
12224         * flag-types.h (enum hardcfr_noret): New.
12225         * gimple-harden-control-flow.cc: New.
12226         * params.opt (-param=hardcfr-max-blocks=): New.
12227         (-param=hradcfr-max-inline-blocks=): New.
12228         * passes.def (pass_harden_control_flow_redundancy): Add.
12229         * tree-pass.h (make_pass_harden_control_flow_redundancy):
12230         Declare.
12231         * doc/extend.texi: Document expected_throw attribute.
12233 2023-10-20  Alex Coplan  <alex.coplan@arm.com>
12235         * rtl-ssa/changes.cc (function_info::change_insns): Ensure we call
12236         ::remove_insn on deleted insns.
12238 2023-10-20  Richard Biener  <rguenther@suse.de>
12240         * doc/generic.texi ({L,R}ROTATE_EXPR): Document.
12242 2023-10-20  Oleg Endo  <olegendo@gcc.gnu.org>
12244         PR target/101177
12245         * config/sh/sh.md (unnamed split pattern): Fix comparison of
12246         find_regno_note result.
12248 2023-10-20  Richard Biener  <rguenther@suse.de>
12250         * tree-vect-loop.cc (update_epilogue_loop_vinfo): Rewrite
12251         both STMT_VINFO_GATHER_SCATTER_P and VMAT_GATHER_SCATTER
12252         stmt refs.
12254 2023-10-20  Richard Biener  <rguenther@suse.de>
12256         * tree-vect-slp.cc (off_map, off_op0_map, off_arg2_map,
12257         off_arg3_arg2_map): New.
12258         (vect_get_operand_map): Get flag whether the stmt was
12259         recognized as gather or scatter and use the above
12260         accordingly.
12261         (vect_get_and_check_slp_defs): Adjust.
12262         (vect_build_slp_tree_2): Likewise.
12264 2023-10-20  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
12266         * config/riscv/riscv-vsetvl.cc (pre_vsetvl::fuse_local_vsetvl_info): Rename variables.
12267         (pre_vsetvl::pre_global_vsetvl_info): Ditto.
12268         (pre_vsetvl::emit_vsetvl): Ditto.
12270 2023-10-20  Tamar Christina  <tamar.christina@arm.com>
12271              Andre Vieira  <andre.simoesdiasvieira@arm.com>
12273         * tree-if-conv.cc (if_convertible_loop_p_1): Move check from here ...
12274         (get_loop_body_if_conv_order): ... to here.
12275         (if_convertible_loop_p): Remove single_exit check.
12276         (tree_if_conversion): Move single_exit check to if-conversion part and
12277         support multiple exits.
12279 2023-10-20  Tamar Christina  <tamar.christina@arm.com>
12280              Andre Vieira  <andre.simoesdiasvieira@arm.com>
12282         * tree-vect-patterns.cc (vect_init_pattern_stmt): Copy STMT_VINFO_TYPE
12283         from original statement.
12284         (vect_recog_bitfield_ref_pattern): Support bitfields in gcond.
12286 2023-10-20  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
12288         PR target/111848
12289         * config/riscv/riscv-selftests.cc (run_const_vector_selftests): Adapt selftest.
12290         * config/riscv/riscv-v.cc (expand_const_vector): Change it into vec_duplicate splitter.
12292 2023-10-20  Lehua Ding  <lehua.ding@rivai.ai>
12294         PR target/111037
12295         PR target/111234
12296         PR target/111725
12297         * config/riscv/riscv-vsetvl.cc (bitmap_union_of_preds_with_entry): New.
12298         (debug): Removed.
12299         (compute_reaching_defintion): New.
12300         (enum vsetvl_type): Moved.
12301         (vlmax_avl_p): Moved.
12302         (enum emit_type): Moved.
12303         (vlmul_to_str): Moved.
12304         (vlmax_avl_insn_p): Removed.
12305         (policy_to_str): Moved.
12306         (loop_basic_block_p): Removed.
12307         (valid_sew_p): Removed.
12308         (vsetvl_insn_p): Moved.
12309         (vsetvl_vtype_change_only_p): Removed.
12310         (after_or_same_p): Removed.
12311         (before_p): Removed.
12312         (anticipatable_occurrence_p): Removed.
12313         (available_occurrence_p): Removed.
12314         (insn_should_be_added_p): Removed.
12315         (get_all_sets): Moved.
12316         (get_same_bb_set): Moved.
12317         (gen_vsetvl_pat): Removed.
12318         (calculate_vlmul): Moved.
12319         (get_max_int_sew): New.
12320         (emit_vsetvl_insn): Removed.
12321         (get_max_float_sew): New.
12322         (eliminate_insn): Removed.
12323         (insert_vsetvl): Removed.
12324         (count_regno_occurrences): Moved.
12325         (get_vl_vtype_info): Removed.
12326         (enum def_type): Moved.
12327         (validate_change_or_fail): Moved.
12328         (change_insn): Removed.
12329         (get_all_real_uses): Moved.
12330         (get_forward_read_vl_insn): Removed.
12331         (get_backward_fault_first_load_insn): Removed.
12332         (change_vsetvl_insn): Removed.
12333         (avl_source_has_vsetvl_p): Removed.
12334         (source_equal_p): Moved.
12335         (calculate_sew): Removed.
12336         (same_equiv_note_p): Moved.
12337         (get_expr_id): New.
12338         (incompatible_avl_p): Removed.
12339         (get_regno): New.
12340         (different_sew_p): Removed.
12341         (get_bb_index): New.
12342         (different_lmul_p): Removed.
12343         (has_no_uses): Moved.
12344         (different_ratio_p): Removed.
12345         (different_tail_policy_p): Removed.
12346         (different_mask_policy_p): Removed.
12347         (possible_zero_avl_p): Removed.
12348         (enum demand_flags): New.
12349         (second_ratio_invalid_for_first_sew_p): Removed.
12350         (second_ratio_invalid_for_first_lmul_p): Removed.
12351         (enum class): New.
12352         (float_insn_valid_sew_p): Removed.
12353         (second_sew_less_than_first_sew_p): Removed.
12354         (first_sew_less_than_second_sew_p): Removed.
12355         (class vsetvl_info): New.
12356         (compare_lmul): Removed.
12357         (second_lmul_less_than_first_lmul_p): Removed.
12358         (second_ratio_less_than_first_ratio_p): Removed.
12359         (DEF_INCOMPATIBLE_COND): Removed.
12360         (greatest_sew): Removed.
12361         (first_sew): Removed.
12362         (second_sew): Removed.
12363         (first_vlmul): Removed.
12364         (second_vlmul): Removed.
12365         (first_ratio): Removed.
12366         (second_ratio): Removed.
12367         (vlmul_for_first_sew_second_ratio): Removed.
12368         (vlmul_for_greatest_sew_second_ratio): Removed.
12369         (ratio_for_second_sew_first_vlmul): Removed.
12370         (class vsetvl_block_info): New.
12371         (DEF_SEW_LMUL_FUSE_RULE): New.
12372         (always_unavailable): Removed.
12373         (avl_unavailable_p): Removed.
12374         (class demand_system): New.
12375         (sew_unavailable_p): Removed.
12376         (lmul_unavailable_p): Removed.
12377         (ge_sew_unavailable_p): Removed.
12378         (ge_sew_lmul_unavailable_p): Removed.
12379         (ge_sew_ratio_unavailable_p): Removed.
12380         (DEF_UNAVAILABLE_COND): Removed.
12381         (same_sew_lmul_demand_p): Removed.
12382         (propagate_avl_across_demands_p): Removed.
12383         (reg_available_p): Removed.
12384         (support_relaxed_compatible_p): Removed.
12385         (demands_can_be_fused_p): Removed.
12386         (earliest_pred_can_be_fused_p): Removed.
12387         (vsetvl_dominated_by_p): Removed.
12388         (avl_info::avl_info): Removed.
12389         (avl_info::single_source_equal_p): Removed.
12390         (avl_info::multiple_source_equal_p): Removed.
12391         (DEF_SEW_LMUL_RULE): New.
12392         (avl_info::operator=): Removed.
12393         (avl_info::operator==): Removed.
12394         (DEF_POLICY_RULE): New.
12395         (avl_info::operator!=): Removed.
12396         (avl_info::has_non_zero_avl): Removed.
12397         (vl_vtype_info::vl_vtype_info): Removed.
12398         (vl_vtype_info::operator==): Removed.
12399         (DEF_AVL_RULE): New.
12400         (vl_vtype_info::operator!=): Removed.
12401         (vl_vtype_info::same_avl_p): Removed.
12402         (vl_vtype_info::same_vtype_p): Removed.
12403         (vl_vtype_info::same_vlmax_p): Removed.
12404         (vector_insn_info::operator>=): Removed.
12405         (vector_insn_info::operator==): Removed.
12406         (class pre_vsetvl): New.
12407         (vector_insn_info::parse_insn): Removed.
12408         (vector_insn_info::compatible_p): Removed.
12409         (vector_insn_info::skip_avl_compatible_p): Removed.
12410         (vector_insn_info::compatible_avl_p): Removed.
12411         (vector_insn_info::compatible_vtype_p): Removed.
12412         (vector_insn_info::available_p): Removed.
12413         (vector_insn_info::fuse_avl): Removed.
12414         (vector_insn_info::fuse_sew_lmul): Removed.
12415         (vector_insn_info::fuse_tail_policy): Removed.
12416         (vector_insn_info::fuse_mask_policy): Removed.
12417         (vector_insn_info::local_merge): Removed.
12418         (vector_insn_info::global_merge): Removed.
12419         (vector_insn_info::get_avl_or_vl_reg): Removed.
12420         (vector_insn_info::update_fault_first_load_avl): Removed.
12421         (vector_insn_info::dump): Removed.
12422         (vector_infos_manager::vector_infos_manager): Removed.
12423         (vector_infos_manager::create_expr): Removed.
12424         (vector_infos_manager::get_expr_id): Removed.
12425         (vector_infos_manager::all_same_ratio_p): Removed.
12426         (vector_infos_manager::all_avail_in_compatible_p): Removed.
12427         (vector_infos_manager::all_same_avl_p): Removed.
12428         (vector_infos_manager::expr_set_num): Removed.
12429         (vector_infos_manager::release): Removed.
12430         (vector_infos_manager::create_bitmap_vectors): Removed.
12431         (vector_infos_manager::free_bitmap_vectors): Removed.
12432         (vector_infos_manager::dump): Removed.
12433         (class pass_vsetvl): Adjust.
12434         (pass_vsetvl::get_vector_info): Removed.
12435         (pass_vsetvl::get_block_info): Removed.
12436         (pass_vsetvl::update_vector_info): Removed.
12437         (pass_vsetvl::update_block_info): Removed.
12438         (pre_vsetvl::compute_avl_def_data): New.
12439         (pass_vsetvl::simple_vsetvl): Removed.
12440         (pass_vsetvl::compute_local_backward_infos): Removed.
12441         (pass_vsetvl::need_vsetvl): Removed.
12442         (pass_vsetvl::transfer_before): Removed.
12443         (pass_vsetvl::transfer_after): Removed.
12444         (pre_vsetvl::compute_vsetvl_def_data): New.
12445         (pass_vsetvl::emit_local_forward_vsetvls): Removed.
12446         (pass_vsetvl::prune_expressions): Removed.
12447         (pass_vsetvl::compute_local_properties): Removed.
12448         (pre_vsetvl::compute_lcm_local_properties): New.
12449         (pass_vsetvl::earliest_fusion): Removed.
12450         (pre_vsetvl::fuse_local_vsetvl_info): New.
12451         (pass_vsetvl::vsetvl_fusion): Removed.
12452         (pass_vsetvl::can_refine_vsetvl_p): Removed.
12453         (pre_vsetvl::earliest_fuse_vsetvl_info): New.
12454         (pass_vsetvl::refine_vsetvls): Removed.
12455         (pass_vsetvl::cleanup_vsetvls): Removed.
12456         (pass_vsetvl::commit_vsetvls): Removed.
12457         (pass_vsetvl::pre_vsetvl): Removed.
12458         (pass_vsetvl::get_vsetvl_at_end): Removed.
12459         (local_avl_compatible_p): Removed.
12460         (pass_vsetvl::local_eliminate_vsetvl_insn): Removed.
12461         (pre_vsetvl::pre_global_vsetvl_info): New.
12462         (get_first_vsetvl_before_rvv_insns): Removed.
12463         (pass_vsetvl::global_eliminate_vsetvl_insn): Removed.
12464         (pre_vsetvl::emit_vsetvl): New.
12465         (pass_vsetvl::ssa_post_optimization): Removed.
12466         (pre_vsetvl::cleaup): New.
12467         (pre_vsetvl::remove_avl_operand): New.
12468         (pass_vsetvl::df_post_optimization): Removed.
12469         (pre_vsetvl::remove_unused_dest_operand): New.
12470         (pass_vsetvl::init): Removed.
12471         (pass_vsetvl::done): Removed.
12472         (pass_vsetvl::compute_probabilities): Removed.
12473         (pass_vsetvl::lazy_vsetvl): Adjust.
12474         (pass_vsetvl::execute): Adjust.
12475         * config/riscv/riscv-vsetvl.def (DEF_INCOMPATIBLE_COND): Removed.
12476         (DEF_SEW_LMUL_RULE): New.
12477         (DEF_SEW_LMUL_FUSE_RULE): Removed.
12478         (DEF_POLICY_RULE): New.
12479         (DEF_UNAVAILABLE_COND): Removed
12480         (DEF_AVL_RULE): New demand type.
12481         (sew_lmul): New demand type.
12482         (ratio_only): New demand type.
12483         (sew_only): New demand type.
12484         (ge_sew): New demand type.
12485         (ratio_and_ge_sew): New demand type.
12486         (tail_mask_policy): New demand type.
12487         (tail_policy_only): New demand type.
12488         (mask_policy_only): New demand type.
12489         (ignore_policy): New demand type.
12490         (avl): New demand type.
12491         (non_zero_avl): New demand type.
12492         (ignore_avl): New demand type.
12493         * config/riscv/t-riscv: Removed riscv-vsetvl.h
12494         * config/riscv/riscv-vsetvl.h: Removed.
12496 2023-10-20  Alexandre Oliva  <oliva@adacore.com>
12498         * tree-eh.cc (make_eh_edges): Return the new edge.
12499         * tree-eh.h (make_eh_edges): Likewise.
12501 2023-10-19  Marek Polacek  <polacek@redhat.com>
12503         * doc/contrib.texi: Add entry for Patrick Palka.
12505 2023-10-19  Andre Vieira  <andre.simoesdiasvieira@arm.com>
12507         * omp-simd-clone.cc (simd_clone_adjust_argument_types): Make function
12508         compatible with mask parameters in clone.
12509         * tree-vect-stmts.cc (vect_build_all_ones_mask): Allow vector boolean
12510         typed masks.
12511         (vectorizable_simd_clone_call): Enable the use of masked clones in
12512         fully masked loops.
12514 2023-10-19  Andre Vieira  <andre.simoesdiasvieira@arm.com>
12516         PR tree-optimization/110485
12517         * tree-vect-stmts.cc (vectorizable_simd_clone_call): Disable partial
12518         vectors usage if a notinbranch simdclone has been selected.
12520 2023-10-19  Andre Vieira  <andre.simoesdiasvieira@arm.com>
12522         * tree-vect-data-refs.cc (vect_get_smallest_scalar_type): Special case
12523         simd clone calls and only use types that are mapped to vectors.
12524         (simd_clone_call_p): New helper function.
12526 2023-10-19  Andre Vieira  <andre.simoesdiasvieira@arm.com>
12528         * tree-parloops.cc (try_transform_to_exit_first_loop_alt): Accept
12529         poly NIT and ALT_BOUND.
12531 2023-10-19  Andre Vieira  <andre.simoesdiasvieira@arm.com>
12533         * tree-parloops.cc (create_loop_fn): Copy specific target and
12534         optimization options to clone.
12536 2023-10-19  Andre Vieira  <andre.simoesdiasvieira@arm.com>
12538         * omp-simd-clone.cc (simd_clone_subparts): Remove.
12539         (simd_clone_init_simd_arrays): Replace simd_clone_supbarts with
12540         TYPE_VECTOR_SUBPARTS.
12541         (ipa_simd_modify_function_body): Likewise.
12542         * tree-vect-stmts.cc (vectorizable_simd_clone_call): Likewise.
12543         (simd_clone_subparts): Remove.
12545 2023-10-19  Jason Merrill  <jason@redhat.com>
12547         * ABOUT-GCC-NLS: Add usage guidance.
12549 2023-10-19  Jason Merrill  <jason@redhat.com>
12551         * diagnostic-core.h (permerror): Rename new overloads...
12552         (permerror_opt): To this.
12553         * diagnostic.cc: Likewise.
12555 2023-10-19  Tamar Christina  <tamar.christina@arm.com>
12557         PR tree-optimization/111860
12558         * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
12559         Remove PHI nodes that dominate loop.
12561 2023-10-19  Richard Biener  <rguenther@suse.de>
12563         PR tree-optimization/111131
12564         * tree-vect-loop.cc (update_epilogue_loop_vinfo): Make
12565         sure to update all gather/scatter stmt DRs, not only those
12566         that eventually got VMAT_GATHER_SCATTER set.
12567         * tree-vect-slp.cc (_slp_oprnd_info::first_gs_info): Add.
12568         (vect_get_and_check_slp_defs): Handle gathers/scatters,
12569         adding the offset as SLP operand and comparing base and scale.
12570         (vect_build_slp_tree_1): Handle gathers.
12571         (vect_build_slp_tree_2): Likewise.
12573 2023-10-19  Richard Biener  <rguenther@suse.de>
12575         * tree-vect-stmts.cc (vect_build_gather_load_calls): Rename
12576         to ...
12577         (vect_build_one_gather_load_call): ... this.  Refactor,
12578         inline widening/narrowing support ...
12579         (vectorizable_load): ... here, do gather vectorization
12580         with builtin decls along other gather vectorization.
12582 2023-10-19  Alex Coplan  <alex.coplan@arm.com>
12584         * config/aarch64/aarch64.md (load_pair_dw_tftf): Rename to ...
12585         (load_pair_dw_<TX:mode><TX2:mode>): ... this.
12586         (store_pair_dw_tftf): Rename to ...
12587         (store_pair_dw_<TX:mode><TX2:mode>): ... this.
12588         * config/aarch64/iterators.md (TX2): New.
12590 2023-10-19  Alex Coplan  <alex.coplan@arm.com>
12592         * rtl-ssa/changes.cc (function_info::finalize_new_accesses): Add new
12593         parameter to give final insn position, infer use of mem if it isn't
12594         specified explicitly.
12595         (function_info::change_insns): Pass down final insn position to
12596         finalize_new_accesses.
12597         * rtl-ssa/functions.h: Add parameter to finalize_new_accesses.
12599 2023-10-19  Alex Coplan  <alex.coplan@arm.com>
12601         * rtl-ssa/accesses.cc (function_info::reparent_use): New.
12602         * rtl-ssa/functions.h (function_info): Declare new member
12603         function reparent_use.
12605 2023-10-19  Alex Coplan  <alex.coplan@arm.com>
12607         * rtl-ssa/access-utils.h (drop_memory_access): New.
12609 2023-10-19  Alex Coplan  <alex.coplan@arm.com>
12611         * rtl-ssa/insns.cc (function_info::add_insn_after): Ensure we
12612         update the prev pointer on the following nondebug insn in the
12613         case that !insn->is_debug_insn () && next->is_debug_insn ().
12615 2023-10-19  Haochen Jiang  <haochen.jiang@intel.com>
12617         * config/i386/i386.h: Correct the ISA enabled for Arrow Lake.
12618         Also make Clearwater Forest depends on Sierra Forest.
12619         * config/i386/i386-options.cc: Revise the order of the macro
12620         definition to avoid confusion.
12621         * doc/extend.texi: Revise documentation.
12622         * doc/invoke.texi: Correct documentation.
12624 2023-10-19  Andrew Stubbs  <ams@codesourcery.com>
12626         * config.gcc (amdgcn): Switch default to --with-arch=gfx900.
12627         Implement support for --with-multilib-list.
12628         * config/gcn/t-gcn-hsa: Likewise.
12629         * doc/install.texi: Likewise.
12630         * doc/invoke.texi: Mark Fiji deprecated.
12632 2023-10-19  Jiahao Xu  <xujiahao@loongson.cn>
12634         * config/loongarch/loongarch.cc (loongarch_vector_costs): Inherit from
12635         vector_costs.  Add a constructor.
12636         (loongarch_vector_costs::add_stmt_cost): Use adjust_cost_for_freq to
12637         adjust the cost for inner loops.
12638         (loongarch_vector_costs::count_operations): New function.
12639         (loongarch_vector_costs::determine_suggested_unroll_factor): Ditto.
12640         (loongarch_vector_costs::finish_cost): Ditto.
12641         (loongarch_builtin_vectorization_cost): Adjust.
12642         * config/loongarch/loongarch.opt (loongarch-vect-unroll-limit): New parameter.
12643         (loongarcg-vect-issue-info): Ditto.
12644         (mmemvec-cost): Delete.
12645         * config/loongarch/genopts/loongarch.opt.in
12646         (loongarch-vect-unroll-limit): Ditto.
12647         (loongarcg-vect-issue-info): Ditto.
12648         (mmemvec-cost): Delete.
12649         * doc/invoke.texi (loongarcg-vect-unroll-limit): Document new option.
12651 2023-10-19  Jiahao Xu  <xujiahao@loongson.cn>
12653         * config/loongarch/lasx.md
12654         (vec_widen_<su>mult_even_v8si): New patterns.
12655         (vec_widen_<su>add_hi_<mode>): Ditto.
12656         (vec_widen_<su>add_lo_<mode>): Ditto.
12657         (vec_widen_<su>sub_hi_<mode>): Ditto.
12658         (vec_widen_<su>sub_lo_<mode>): Ditto.
12659         (vec_widen_<su>mult_hi_<mode>): Ditto.
12660         (vec_widen_<su>mult_lo_<mode>): Ditto.
12661         * config/loongarch/loongarch.md (u_bool): New iterator.
12662         * config/loongarch/loongarch-protos.h
12663         (loongarch_expand_vec_widen_hilo): New prototype.
12664         * config/loongarch/loongarch.cc
12665         (loongarch_expand_vec_interleave): New function.
12666         (loongarch_expand_vec_widen_hilo): New function.
12668 2023-10-19  Jiahao Xu  <xujiahao@loongson.cn>
12670         * config/loongarch/lasx.md
12671         (avg<mode>3_ceil): New patterns.
12672         (uavg<mode>3_ceil): Ditto.
12673         (avg<mode>3_floor): Ditto.
12674         (uavg<mode>3_floor): Ditto.
12675         (usadv32qi): Ditto.
12676         (ssadv32qi): Ditto.
12677         * config/loongarch/lsx.md
12678         (avg<mode>3_ceil): New patterns.
12679         (uavg<mode>3_ceil): Ditto.
12680         (avg<mode>3_floor): Ditto.
12681         (uavg<mode>3_floor): Ditto.
12682         (usadv16qi): Ditto.
12683         (ssadv16qi): Ditto.
12685 2023-10-18  Andrew Pinski  <pinskia@gmail.com>
12687         PR middle-end/111863
12688         * expr.cc (do_store_flag): Don't over write arg0
12689         when stripping off `& POW2`.
12691 2023-10-18  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
12693         PR tree-optimization/111648
12694         * fold-const.cc (valid_mask_for_fold_vec_perm_cst_p): If a1
12695         chooses base element from arg, ensure that it's a natural stepped
12696         sequence.
12697         (build_vec_cst_rand): New param natural_stepped and use it to
12698         construct a naturally stepped sequence.
12699         (test_nunits_min_2): Add new unit tests Case 6 and Case 7.
12701 2023-10-18  Dimitar Dimitrov  <dimitar@dinux.eu>
12703         * config/pru/pru.cc (pru_insn_cost): New function.
12704         (TARGET_INSN_COST): Define for PRU.
12706 2023-10-18  Andrew Carlotti  <andrew.carlotti@arm.com>
12708         * config/aarch64/aarch64.cc (aarch64_test_fractional_cost):
12709         Test <= instead of testing < twice.
12711 2023-10-18  Jakub Jelinek  <jakub@redhat.com>
12713         PR bootstrap/111852
12714         * cse.cc (cse_insn): Add workaround for GCC 4.8-4.9, instead of
12715         using rtx_def type for memory_extend_buf, use unsigned char
12716         arrayy with size of rtx_def and its alignment.
12718 2023-10-18  Jason Merrill  <jason@redhat.com>
12720         * doc/invoke.texi: Move -fpermissive to Warning Options.
12721         * diagnostic.cc (update_effective_level_from_pragmas): Remove
12722         redundant system header check.
12723         (diagnostic_report_diagnostic): Move down syshdr/-w check.
12724         (diagnostic_impl): Handle DK_PERMERROR with an option number.
12725         (permerror): Add new overloads.
12726         * diagnostic-core.h (permerror): Declare them.
12728 2023-10-18  Tobias Burnus  <tobias@codesourcery.com>
12730         * gimplify.cc (gimplify_bind_expr): Remove "omp allocate" attribute
12731         to avoid that auxillary statement list reaches LTO.
12733 2023-10-18  Jakub Jelinek  <jakub@redhat.com>
12735         PR tree-optimization/111845
12736         * tree-ssa-math-opts.cc (match_uaddc_usubc): Remember temporary
12737         statements for the 4 operand addition or subtraction of 3 operands
12738         from 1 operand cases and remove them when successful.  Look for
12739         nested additions even from rhs[2], not just rhs[1].
12741 2023-10-18  Tobias Burnus  <tobias@codesourcery.com>
12743         PR target/111093
12744         * config/nvptx/nvptx.cc (nvptx_option_override): Issue fatal error
12745         instead of an assert ICE when no -march= has been specified.
12747 2023-10-18  Iain Sandoe  <iain@sandoe.co.uk>
12749         * config.in: Regenerate.
12750         * config/darwin.cc (darwin_file_start): Add assembler directives
12751         for the target OS version, where these are supported by the
12752         assembler.
12753         (darwin_override_options): Check for building >= macOS 10.14.
12754         * configure: Regenerate.
12755         * configure.ac: Check for assembler support of .build_version
12756         directives.
12758 2023-10-18  Tamar Christina  <tamar.christina@arm.com>
12760         PR tree-optimization/109154
12761         * tree-if-conv.cc (INCLUDE_ALGORITHM): Remove.
12762         (typedef struct ifcvt_arg_entry): New.
12763         (cmp_arg_entry): New.
12764         (gen_phi_arg_condition, gen_phi_nest_statement,
12765         predicate_scalar_phi): Use them.
12767 2023-10-18  Tamar Christina  <tamar.christina@arm.com>
12769         PR tree-optimization/109154
12770         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<VDMOV:mode>):
12771         Rewrite to new syntax.
12772         (*aarch64_simd_mov<VQMOV:mode): Rewrite to new syntax and merge in
12773         splits.
12775 2023-10-18  Tamar Christina  <tamar.christina@arm.com>
12777         PR tree-optimization/109154
12778         * tree-if-conv.cc (if_convertible_stmt_p): Allow any const IFN.
12780 2023-10-18  Tamar Christina  <tamar.christina@arm.com>
12782         PR tree-optimization/109154
12783         * match.pd: Add new cond_op rule.
12785 2023-10-18  Xi Ruoyao  <xry111@xry111.site>
12787         * config/loongarch/loongarch.md (movfcc): Use fcmp.caf.s for
12788         zeroing a fcc.
12790 2023-10-18  Richard Biener  <rguenther@suse.de>
12792         * tree-vect-stmts.cc (vectorizable_simd_clone_call):
12793         Relax check to again allow passing integer mode masks
12794         as traditional vectors.
12796 2023-10-18  Tamar Christina  <tamar.christina@arm.com>
12798         * tree-loop-distribution.cc (copy_loop_before): Request no LCSSA.
12799         * tree-vect-loop-manip.cc (adjust_phi_and_debug_stmts): Add additional
12800         asserts.
12801         (slpeel_tree_duplicate_loop_to_edge_cfg): Keep LCSSA during peeling.
12802         (find_guard_arg): Look value up through explicit edge and original defs.
12803         (vect_do_peeling): Use it.
12804         (slpeel_update_phi_nodes_for_guard2): Take explicit exit edge.
12805         (slpeel_update_phi_nodes_for_lcssa, slpeel_update_phi_nodes_for_loops):
12806         Remove.
12807         * tree-vect-loop.cc (vect_create_epilog_for_reduction): Initialize phi.
12808         * tree-vectorizer.h (slpeel_tree_duplicate_loop_to_edge_cfg): Add
12809         optional param to turn off LCSSA mode.
12811 2023-10-18  Tamar Christina  <tamar.christina@arm.com>
12813         * tree-if-conv.cc (tree_if_conversion): Record exits in aux.
12814         * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg): Use
12815         it.
12816         * tree-vect-loop.cc (vect_get_loop_niters): Determine main exit.
12817         (vec_init_loop_exit_info): Extend analysis when multiple exits.
12818         (vect_analyze_loop_form): Record conds and determine main cond.
12819         (vect_create_loop_vinfo): Extend bookkeeping of conds.
12820         (vect_analyze_loop): Release conds.
12821         * tree-vectorizer.h (LOOP_VINFO_LOOP_CONDS,
12822         LOOP_VINFO_LOOP_IV_COND):  New.
12823         (struct vect_loop_form_info): Add conds, alt_loop_conds;
12824         (struct loop_vec_info): Add conds, loop_iv_cond.
12826 2023-10-18  Tamar Christina  <tamar.christina@arm.com>
12828         * tree-loop-distribution.cc (copy_loop_before): Pass exit explicitly.
12829         (loop_distribution::distribute_loop): Bail out of not single exit.
12830         * tree-scalar-evolution.cc (get_loop_exit_condition): New.
12831         * tree-scalar-evolution.h (get_loop_exit_condition): New.
12832         * tree-vect-data-refs.cc (vect_enhance_data_refs_alignment): Pass exit
12833         explicitly.
12834         * tree-vect-loop-manip.cc (vect_set_loop_condition_partial_vectors,
12835         vect_set_loop_condition_partial_vectors_avx512,
12836         vect_set_loop_condition_normal, vect_set_loop_condition): Explicitly
12837         take exit.
12838         (slpeel_tree_duplicate_loop_to_edge_cfg): Explicitly take exit and
12839         return new peeled corresponding peeled exit.
12840         (slpeel_can_duplicate_loop_p): Explicitly take exit.
12841         (find_loop_location): Handle not knowing an explicit exit.
12842         (vect_update_ivs_after_vectorizer, vect_gen_vector_loop_niters_mult_vf,
12843         find_guard_arg, slpeel_update_phi_nodes_for_loops,
12844         slpeel_update_phi_nodes_for_guard2): Use new exits.
12845         (vect_do_peeling): Update bookkeeping to keep track of exits.
12846         * tree-vect-loop.cc (vect_get_loop_niters): Explicitly take exit to
12847         analyze.
12848         (vec_init_loop_exit_info): New.
12849         (_loop_vec_info::_loop_vec_info): Initialize vec_loop_iv,
12850         vec_epilogue_loop_iv, scalar_loop_iv.
12851         (vect_analyze_loop_form): Initialize exits.
12852         (vect_create_loop_vinfo): Set main exit.
12853         (vect_create_epilog_for_reduction, vectorizable_live_operation,
12854         vect_transform_loop): Use it.
12855         (scale_profile_for_vect_loop): Explicitly take exit to scale.
12856         * tree-vectorizer.cc (set_uid_loop_bbs): Initialize loop exit.
12857         * tree-vectorizer.h (LOOP_VINFO_IV_EXIT, LOOP_VINFO_EPILOGUE_IV_EXIT,
12858         LOOP_VINFO_SCALAR_IV_EXIT): New.
12859         (struct loop_vec_info): Add vec_loop_iv, vec_epilogue_loop_iv,
12860         scalar_loop_iv.
12861         (vect_set_loop_condition, slpeel_can_duplicate_loop_p,
12862         slpeel_tree_duplicate_loop_to_edge_cfg): Take explicit exits.
12863         (vec_init_loop_exit_info): New.
12864         (struct vect_loop_form_info): Add loop_exit.
12866 2023-10-18  Tamar Christina  <tamar.christina@arm.com>
12868         * tree-vect-stmts.cc (vectorizable_comparison): Refactor, splitting body
12869         to ...
12870         (vectorizable_comparison_1): ...This.
12872 2023-10-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
12874         * config/riscv/riscv-v.cc (shuffle_consecutive_patterns): New function.
12875         (expand_vec_perm_const_1): Add consecutive pattern recognition.
12877 2023-10-18  Haochen Jiang  <haochen.jiang@intel.com>
12879         * common/config/i386/cpuinfo.h (get_intel_cpu): Add Panther
12880         Lake.
12881         * common/config/i386/i386-common.cc (processor_name):
12882         Ditto.
12883         (processor_alias_table): Ditto.
12884         * common/config/i386/i386-cpuinfo.h (enum processor_types):
12885         Add INTEL_PANTHERLAKE.
12886         * config.gcc: Add -march=pantherlake.
12887         * config/i386/driver-i386.cc (host_detect_local_cpu): Refactor
12888         the if clause. Handle pantherlake.
12889         * config/i386/i386-c.cc (ix86_target_macros_internal):
12890         Handle pantherlake.
12891         * config/i386/i386-options.cc (processor_cost_table): Ditto.
12892         (m_PANTHERLAKE): New.
12893         (m_CORE_HYBRID): Add pantherlake.
12894         * config/i386/i386.h (enum processor_type): Ditto.
12895         * doc/extend.texi: Ditto.
12896         * doc/invoke.texi: Ditto.
12898 2023-10-18  Haochen Jiang  <haochen.jiang@intel.com>
12900         * config/i386/i386-options.cc (m_CORE_HYBRID): New.
12901         * config/i386/x86-tune.def: Replace hybrid client tune to
12902         m_CORE_HYBRID.
12904 2023-10-18  Haochen Jiang  <haochen.jiang@intel.com>
12906         * common/config/i386/cpuinfo.h
12907         (get_intel_cpu): Handle Clearwater Forest.
12908         * common/config/i386/i386-common.cc (processor_name):
12909         Add Clearwater Forest.
12910         (processor_alias_table): Ditto.
12911         * common/config/i386/i386-cpuinfo.h (enum processor_types):
12912         Add INTEL_CLEARWATERFOREST.
12913         * config.gcc: Add -march=clearwaterforest.
12914         * config/i386/driver-i386.cc (host_detect_local_cpu): Handle
12915         clearwaterforest.
12916         * config/i386/i386-c.cc (ix86_target_macros_internal): Ditto.
12917         * config/i386/i386-options.cc (processor_cost_table): Ditto.
12918         (m_CLEARWATERFOREST): New.
12919         (m_CORE_ATOM): Add clearwaterforest.
12920         * config/i386/i386.h (enum processor_type): Ditto.
12921         * doc/extend.texi: Ditto.
12922         * doc/invoke.texi: Ditto.
12924 2023-10-18  liuhongt  <hongtao.liu@intel.com>
12926         * config/i386/mmx.md (fma<mode>4): New expander.
12927         (fms<mode>4): Ditto.
12928         (fnma<mode>4): Ditto.
12929         (fnms<mode>4): Ditto.
12930         (vec_fmaddsubv4hf4): Ditto.
12931         (vec_fmsubaddv4hf4): Ditto.
12933 2023-10-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
12935         PR target/111832
12936         * config/riscv/riscv-vector-costs.cc (get_biggest_mode): New function.
12938 2023-10-17  Richard Sandiford  <richard.sandiford@arm.com>
12940         * config/aarch64/aarch64.cc (aarch64_layout_frame): Don't make
12941         the position of the LR save slot dependent on stack clash
12942         protection unless shadow call stacks are enabled.
12944 2023-10-17  Richard Sandiford  <richard.sandiford@arm.com>
12946         * config/aarch64/aarch64.h (aarch64_frame): Add vectors that
12947         store the list saved GPRs, FPRs and predicate registers.
12948         * config/aarch64/aarch64.cc (aarch64_layout_frame): Initialize
12949         the lists of saved registers.  Use them to choose push candidates.
12950         Invalidate pop candidates if we're not going to do a pop.
12951         (aarch64_next_callee_save): Delete.
12952         (aarch64_save_callee_saves): Take a list of registers,
12953         rather than a range.  Make !skip_wb select only write-back
12954         candidates.
12955         (aarch64_expand_prologue): Update calls accordingly.
12956         (aarch64_restore_callee_saves): Take a list of registers,
12957         rather than a range.  Always skip pop candidates.  Also skip
12958         LR if shadow call stacks are enabled.
12959         (aarch64_expand_epilogue): Update calls accordingly.
12961 2023-10-17  Richard Sandiford  <richard.sandiford@arm.com>
12963         * cfgbuild.h (find_sub_basic_blocks): Declare.
12964         * cfgbuild.cc (update_profile_for_new_sub_basic_block): New function,
12965         split out from...
12966         (find_many_sub_basic_blocks): ...here.
12967         (find_sub_basic_blocks): New function.
12968         * function.cc (thread_prologue_and_epilogue_insns): Handle
12969         epilogues that contain jumps.
12971 2023-10-17  Andrew Pinski  <apinski@marvell.com>
12973         PR tree-optimization/110817
12974         * tree-ssanames.cc (ssa_name_has_boolean_range): Remove the
12975         check for boolean type as they don't have "[0,1]" range.
12977 2023-10-17  Andrew Pinski  <pinskia@gmail.com>
12979         PR tree-optimization/111432
12980         * match.pd (`a & (x | CST)`): New pattern.
12982 2023-10-17  Andre Vieira  <andre.simoesdiasvieira@arm.com>
12984         * tree-cfg.cc (move_sese_region_to_fn): Initialize profile_count for
12985         new basic block.
12987 2023-10-17  Richard Biener  <rguenther@suse.de>
12989         PR tree-optimization/111846
12990         * tree-vectorizer.h (_slp_tree::simd_clone_info): Add.
12991         (SLP_TREE_SIMD_CLONE_INFO): New.
12992         * tree-vect-slp.cc (_slp_tree::_slp_tree): Initialize
12993         SLP_TREE_SIMD_CLONE_INFO.
12994         (_slp_tree::~_slp_tree): Release it.
12995         * tree-vect-stmts.cc (vectorizable_simd_clone_call): Use
12996         SLP_TREE_SIMD_CLONE_INFO or STMT_VINFO_SIMD_CLONE_INFO
12997         dependent on if we're doing SLP.
12999 2023-10-17  Jakub Jelinek  <jakub@redhat.com>
13001         * wide-int-print.h (print_dec_buf_size): For length, divide number
13002         of bits by 3 and add 3 instead of division by 4 and adding 4.
13003         * wide-int-print.cc (print_decs): Remove superfluous ()s.  Don't call
13004         print_hex, instead call print_decu on either negated value after
13005         printing - or on wi itself.
13006         (print_decu): Don't call print_hex, instead print even large numbers
13007         decimally.
13008         (pp_wide_int_large): Assume len from print_dec_buf_size is big enough
13009         even if it returns false.
13010         * pretty-print.h (pp_wide_int): Use print_dec_buf_size to check if
13011         pp_wide_int_large should be used.
13012         * tree-pretty-print.cc (dump_generic_node): Use print_hex_buf_size
13013         to compute needed buffer size.
13015 2023-10-17  Richard Biener  <rguenther@suse.de>
13017         PR middle-end/111818
13018         * tree-ssa.cc (maybe_optimize_var): When clearing
13019         DECL_NOT_GIMPLE_REG_P always rewrite into SSA.
13021 2023-10-17  Richard Biener  <rguenther@suse.de>
13023         PR tree-optimization/111807
13024         * tree-sra.cc (build_ref_for_model): Only call
13025         build_reconstructed_reference when the offsets are the same.
13027 2023-10-17  Vineet Gupta  <vineetg@rivosinc.com>
13029         PR target/111466
13030         * expr.cc (expand_expr_real_2): Do not clear SUBREG_PROMOTED_VAR_P.
13032 2023-10-17  Chenghui Pan  <panchenghui@loongson.cn>
13034         * config/loongarch/loongarch.cc (loongarch_expand_vector_group_init):
13035         fix impl related to vec_initv32qiv16qi template to avoid ICE.
13037 2023-10-17  Lulu Cheng  <chenglulu@loongson.cn>
13038             Chenghua Xu  <xuchenghua@loongson.cn>
13040         * config/loongarch/loongarch.h (ASM_OUTPUT_ALIGN_WITH_NOP):
13041         Delete.
13043 2023-10-17  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
13045         * config/riscv/riscv-vector-costs.cc (max_number_of_live_regs): Fix big LMUL issue.
13046         (get_store_value): New function.
13048 2023-10-16  Jeff Law  <jlaw@ventanamicro.com>
13050         * explow.cc (probe_stack_range): Handle case when expand_binop
13051         does not construct its result in the expected location.
13053 2023-10-16  David Malcolm  <dmalcolm@redhat.com>
13055         * diagnostic.cc (diagnostic_initialize): When LANG=C, update
13056         default for -fdiagnostics-text-art-charset from emoji to ascii.
13057         * doc/invoke.texi (fdiagnostics-text-art-charset): Document the above.
13059 2023-10-16  David Malcolm  <dmalcolm@redhat.com>
13061         * diagnostic.cc (diagnostic_initialize): Ensure
13062         context->extra_output_kind is initialized.
13064 2023-10-16  Uros Bizjak  <ubizjak@gmail.com>
13066         * config/i386/i386.cc (ix86_can_inline_p):
13067         Handle CM_LARGE and CM_LARGE_PIC.
13068         (x86_elf_aligned_decl_common): Ditto.
13069         (x86_output_aligned_bss): Ditto.
13070         * config/i386/i386.opt: Update doc for -mlarge-data-threshold=.
13071         * doc/invoke.texi: Update doc for -mlarge-data-threshold=.
13073 2023-10-16  Christoph Müllner  <christoph.muellner@vrull.eu>
13075         * config/riscv/riscv-protos.h (emit_block_move): Remove redundant
13076         prototype.  Improve comment.
13077         * config/riscv/riscv.cc (riscv_block_move_straight): Move from riscv.cc
13078         into riscv-string.cc.
13079         (riscv_adjust_block_mem, riscv_block_move_loop): Likewise.
13080         (riscv_expand_block_move): Likewise.
13081         * config/riscv/riscv-string.cc (riscv_block_move_straight): Add moved
13082         function.
13083         (riscv_adjust_block_mem, riscv_block_move_loop): Likewise.
13084         (riscv_expand_block_move): Likewise.
13086 2023-10-16  Manolis Tsamis  <manolis.tsamis@vrull.eu>
13088         * Makefile.in: Add fold-mem-offsets.o.
13089         * passes.def: Schedule a new pass.
13090         * tree-pass.h (make_pass_fold_mem_offsets): Declare.
13091         * common.opt: New options.
13092         * doc/invoke.texi: Document new option.
13093         * fold-mem-offsets.cc: New file.
13095 2023-10-16  Andrew Pinski  <pinskia@gmail.com>
13097         PR tree-optimization/101541
13098         * match.pd (A CMP 0 ? A : -A): Improve
13099         using bitwise_equal_p.
13101 2023-10-16  Andrew Pinski  <pinskia@gmail.com>
13103         PR tree-optimization/31531
13104         * match.pd (~X op ~Y): Allow for an optional nop convert.
13105         (~X op C): Likewise.
13107 2023-10-16  Roger Sayle  <roger@nextmovesoftware.com>
13109         * config/arc/arc.md (*ashlsi3_1): New pre-reload splitter to
13110         use bset dst,0,src to implement 1<<x on !TARGET_BARREL_SHIFTER.
13112 2023-10-16  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
13114         * config/s390/vector.md (popcountv8hi2_vx): Sign extend each
13115         unsigned vector element.
13117 2023-10-16  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
13119         * config/riscv/riscv-vector-costs.cc (costs::preferred_new_lmul_p): Use VLS modes.
13121 2023-10-16  Jiufu Guo  <guojiufu@linux.ibm.com>
13123         * fold-const.cc (expr_not_equal_to): Replace get_global_range_query
13124         by get_range_query.
13125         * gimple-fold.cc (size_must_be_zero_p): Likewise.
13126         * gimple-range-fold.cc (fur_source::fur_source): Likewise.
13127         * gimple-ssa-warn-access.cc (check_nul_terminated_array): Likewise.
13128         * tree-dfa.cc (get_ref_base_and_extent): Likewise.
13130 2023-10-16  liuhongt  <hongtao.liu@intel.com>
13132         * config/i386/mmx.md (V2FI_32): New mode iterator
13133         (movd_v2hf_to_sse): Rename to ..
13134         (movd_<mode>_to_sse): .. this.
13135         (movd_v2hf_to_sse_reg): Rename to ..
13136         (movd_<mode>_to_sse_reg): .. this.
13137         (fix<fixunssuffix>_trunc<mode><mmxintvecmodelower>2): New
13138         expander.
13139         (fix<fixunssuffix>_truncv2hfv2si2): Ditto.
13140         (float<floatunssuffix><mmxintvecmodelower><mode>2): Ditto.
13141         (float<floatunssuffix>v2siv2hf2): Ditto.
13142         (extendv2hfv2sf2): Ditto.
13143         (truncv2sfv2hf2): Ditto.
13144         * config/i386/sse.md (*vec_concatv8hf_movss): Rename to ..
13145         (*vec_concat<mode>_movss): .. this.
13147 2023-10-16  liuhongt  <hongtao.liu@intel.com>
13149         * config/i386/i386-expand.cc (ix86_sse_copysign_to_positive):
13150         Handle HFmode.
13151         (ix86_expand_round_sse4): Ditto.
13152         * config/i386/i386.md (roundhf2): New expander.
13153         (lroundhf<mode>2): Ditto.
13154         (lrinthf<mode>2): Ditto.
13155         (l<rounding_insn>hf<mode>2): Ditto.
13156         * config/i386/mmx.md (sqrt<mode>2): Ditto.
13157         (btrunc<mode>2): Ditto.
13158         (nearbyint<mode>2): Ditto.
13159         (rint<mode>2): Ditto.
13160         (lrint<mode><mmxintvecmodelower>2): Ditto.
13161         (floor<mode>2): Ditto.
13162         (lfloor<mode><mmxintvecmodelower>2): Ditto.
13163         (ceil<mode>2): Ditto.
13164         (lceil<mode><mmxintvecmodelower>2): Ditto.
13165         (round<mode>2): Ditto.
13166         (lround<mode><mmxintvecmodelower>2): Ditto.
13167         * config/i386/sse.md (lrint<mode><sseintvecmodelower>2): Ditto.
13168         (lfloor<mode><sseintvecmodelower>2): Ditto.
13169         (lceil<mode><sseintvecmodelower>2): Ditto.
13170         (lround<mode><sseintvecmodelower>2): Ditto.
13171         (sse4_1_round<ssescalarmodesuffix>): Extend to V8HF.
13172         (round<mode>2): Extend to V8HF/V16HF/V32HF.
13174 2023-10-15  Tobias Burnus  <tobias@codesourcery.com>
13176         * doc/invoke.texi (-fopenacc, -fopenmp, -fopenmp-simd): Use @samp not
13177         @code; document more completely the supported Fortran sentinels.
13179 2023-10-15  Roger Sayle  <roger@nextmovesoftware.com>
13181         * optabs.cc (expand_subword_shift): Call simplify_expand_binop
13182         instead of expand_binop.  Optimize cases (i.e. avoid generating
13183         RTL) when CARRIES or INTO_INPUT is zero.  Use one_cmpl_optab
13184         (i.e. NOT) instead of xor_optab with ~0 to calculate ~OP1.
13186 2023-10-15  Jakub Jelinek  <jakub@redhat.com>
13188         PR tree-optimization/111800
13189         * wide-int-print.h (print_dec_buf_size, print_decs_buf_size,
13190         print_decu_buf_size, print_hex_buf_size): New inline functions.
13191         * wide-int.cc (assert_deceq): Use print_dec_buf_size.
13192         (assert_hexeq): Use print_hex_buf_size.
13193         * wide-int-print.cc (print_decs): Use print_decs_buf_size.
13194         (print_decu): Use print_decu_buf_size.
13195         (print_hex): Use print_hex_buf_size.
13196         (pp_wide_int_large): Use print_dec_buf_size.
13197         * value-range.cc (irange_bitmask::dump): Use print_hex_buf_size.
13198         * value-range-pretty-print.cc (vrange_printer::print_irange_bitmasks):
13199         Likewise.
13200         * tree-ssa-loop-niter.cc (do_warn_aggressive_loop_optimizations): Use
13201         print_dec_buf_size.  Use TYPE_SIGN macro in print_dec call argument.
13203 2023-10-15  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
13205         * combine.cc (simplify_compare_const): Fix handling of unsigned
13206         constants.
13208 2023-10-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
13210         * config/riscv/vector-iterators.md: Fix vsingle incorrect attribute for RVVM2x2QI.
13212 2023-10-14  Tobias Burnus  <tobias@codesourcery.com>
13214         * gimplify.cc (gimplify_bind_expr): Handle Fortran's
13215         'omp allocate' for stack variables.
13217 2023-10-14  Jakub Jelinek  <jakub@redhat.com>
13219         PR c/102989
13220         * tree-core.h (struct tree_base): Remove int_length.offset
13221         member, change type of int_length.unextended and int_length.extended
13222         from unsigned char to unsigned short.
13223         * tree.h (TREE_INT_CST_OFFSET_NUNITS): Remove.
13224         (wi::extended_tree <N>::get_len): Don't use TREE_INT_CST_OFFSET_NUNITS,
13225         instead compute it at runtime from TREE_INT_CST_EXT_NUNITS and
13226         TREE_INT_CST_NUNITS.
13227         * tree.cc (wide_int_to_tree_1): Don't assert
13228         TREE_INT_CST_OFFSET_NUNITS value.
13229         (make_int_cst): Don't initialize TREE_INT_CST_OFFSET_NUNITS.
13230         * wide-int.h (WIDE_INT_MAX_ELTS): Change from 255 to 1024.
13231         (WIDEST_INT_MAX_ELTS): Change from 510 to 2048, adjust comment.
13232         (trailing_wide_int_storage): Change m_len type from unsigned char *
13233         to unsigned short *.
13234         (trailing_wide_int_storage::trailing_wide_int_storage): Change second
13235         argument from unsigned char * to unsigned short *.
13236         (trailing_wide_ints): Change m_max_len type from unsigned char to
13237         unsigned short.  Change m_len element type from
13238         struct{unsigned char len;} to unsigned short.
13239         (trailing_wide_ints <N>::operator []): Remove .len from m_len
13240         accesses.
13241         * value-range-storage.h (irange_storage::lengths_address): Change
13242         return type from const unsigned char * to const unsigned short *.
13243         (irange_storage::write_lengths_address): Change return type from
13244         unsigned char * to unsigned short *.
13245         * value-range-storage.cc (irange_storage::write_lengths_address):
13246         Likewise.
13247         (irange_storage::lengths_address): Change return type from
13248         const unsigned char * to const unsigned short *.
13249         (write_wide_int): Change len argument type from unsigned char *&
13250         to unsigned short *&.
13251         (irange_storage::set_irange): Change len variable type from
13252         unsigned char * to unsigned short *.
13253         (read_wide_int): Change len argument type from unsigned char to
13254         unsigned short.  Use trailing_wide_int_storage <unsigned short>
13255         instead of trailing_wide_int_storage and
13256         trailing_wide_int <unsigned short> instead of trailing_wide_int.
13257         (irange_storage::get_irange): Change len variable type from
13258         unsigned char * to unsigned short *.
13259         (irange_storage::size): Multiply n by sizeof (unsigned short)
13260         in len_size variable initialization.
13261         (irange_storage::dump): Change len variable type from
13262         unsigned char * to unsigned short *.
13264 2023-10-14  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
13266         * config/riscv/vector-iterators.md: Remove redundant iterators.
13268 2023-10-13  Andrew MacLeod  <amacleod@redhat.com>
13270         PR tree-optimization/111622
13271         * value-relation.cc (equiv_oracle::add_partial_equiv): Do not
13272         register a partial equivalence if an operand has no uses.
13274 2023-10-13  Richard Biener  <rguenther@suse.de>
13276         PR tree-optimization/111795
13277         * tree-vect-stmts.cc (vectorizable_simd_clone_call): Handle
13278         integer mode mask arguments.
13280 2023-10-13  Richard Biener  <rguenther@suse.de>
13282         * tree-vect-slp.cc (mask_call_maps): New.
13283         (vect_get_operand_map): Handle IFN_MASK_CALL.
13284         (vect_build_slp_tree_1): Likewise.
13285         * tree-vect-stmts.cc (vectorizable_simd_clone_call): Handle
13286         SLP.
13288 2023-10-13  Richard Biener  <rguenther@suse.de>
13290         PR tree-optimization/111779
13291         * tree-sra.cc (sra_handled_bf_read_p): New function.
13292         (build_access_from_expr_1): Handle some BIT_FIELD_REFs.
13293         (sra_modify_expr): Likewise.
13294         (make_fancy_name_1): Skip over BIT_FIELD_REF.
13296 2023-10-13  Richard Biener  <rguenther@suse.de>
13298         PR tree-optimization/111773
13299         * tree-ssa-dce.cc (mark_stmt_if_obviously_necessary): Do
13300         not elide noreturn calls that are reflected to the IL.
13302 2023-10-13  Kito Cheng  <kito.cheng@sifive.com>
13304         * config/riscv/riscv.cc (riscv_legitimize_poly_move): Bump
13305         max_power to 64.
13306         * config/riscv/riscv.h (MAX_POLY_VARIANT): New.
13308 2023-10-13  Pan Li  <pan2.li@intel.com>
13310         * config/riscv/autovec.md (lfloor<mode><v_i_l_ll_convert>2): New
13311         pattern for lfloor/lfloorf.
13312         * config/riscv/riscv-protos.h (enum insn_type): New enum value.
13313         (expand_vec_lfloor): New func decl for expanding lfloor.
13314         * config/riscv/riscv-v.cc (expand_vec_lfloor): New func impl
13315         for expanding lfloor.
13317 2023-10-13  Pan Li  <pan2.li@intel.com>
13319         * config/riscv/autovec.md (lceil<mode><v_i_l_ll_convert>2): New
13320         pattern] for lceil/lceilf.
13321         * config/riscv/riscv-protos.h (enum insn_type): New enum value.
13322         (expand_vec_lceil): New func decl for expanding lceil.
13323         * config/riscv/riscv-v.cc (expand_vec_lceil): New func impl
13324         for expanding lceil.
13326 2023-10-12  Michael Meissner  <meissner@linux.ibm.com>
13328         PR target/111778
13329         * config/rs6000/rs6000.cc (can_be_built_by_li_lis_and_rldicl): Protect
13330         code from shifts that are undefined.
13331         (can_be_built_by_li_lis_and_rldicr): Likewise.
13332         (can_be_built_by_li_and_rldic): Protect code from shifts that
13333         undefined.  Also replace uses of 1ULL with HOST_WIDE_INT_1U.
13335 2023-10-12  Alex Coplan  <alex.coplan@arm.com>
13337         * reg-notes.def (NOALIAS): Correct comment.
13339 2023-10-12  Jakub Jelinek  <jakub@redhat.com>
13341         PR bootstrap/111787
13342         * tree.h (wi::int_traits <unextended_tree>::needs_write_val_arg): New
13343         static data member.
13344         (int_traits <extended_tree <N>>::needs_write_val_arg): Likewise.
13345         (wi::ints_for): Provide separate partial specializations for
13346         generic_wide_int <extended_tree <N>> and INL_CONST_PRECISION or that
13347         and CONST_PRECISION, rather than using
13348         int_traits <extended_tree <N> >::precision_type as the second template
13349         argument.
13350         * rtl.h (wi::int_traits <rtx_mode_t>::needs_write_val_arg): New
13351         static data member.
13352         * double-int.h (wi::int_traits <double_int>::needs_write_val_arg):
13353         Likewise.
13355 2023-10-12  Mary Bennett  <mary.bennett@embecosm.com>
13357         PR middle-end/111777
13358         * doc/extend.texi: Change subsubsection to subsection for
13359         CORE-V built-ins.
13361 2023-10-12  Tamar Christina  <tamar.christina@arm.com>
13363         * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins): Add undef.
13365 2023-10-12  Jakub Jelinek  <jakub@redhat.com>
13367         * wide-int.h (widest_int_storage <N>::write_val): If l is small
13368         and there is space in u.val array, store a canary value at the
13369         end when checking.
13370         (widest_int_storage <N>::set_len): Check the canary hasn't been
13371         overwritten.
13373 2023-10-12  Jakub Jelinek  <jakub@redhat.com>
13375         PR c/102989
13376         * wide-int.h: Adjust file comment.
13377         (WIDE_INT_MAX_INL_ELTS): Define to former value of WIDE_INT_MAX_ELTS.
13378         (WIDE_INT_MAX_INL_PRECISION): Define.
13379         (WIDE_INT_MAX_ELTS): Change to 255.  Assert that WIDE_INT_MAX_INL_ELTS
13380         is smaller than WIDE_INT_MAX_ELTS.
13381         (RWIDE_INT_MAX_ELTS, RWIDE_INT_MAX_PRECISION, WIDEST_INT_MAX_ELTS,
13382         WIDEST_INT_MAX_PRECISION): Define.
13383         (WI_BINARY_RESULT_VAR, WI_UNARY_RESULT_VAR): Change write_val callers
13384         to pass 0 as a new argument.
13385         (class widest_int_storage): Likewise.
13386         (widest_int, widest2_int): Change typedefs to use widest_int_storage
13387         rather than fixed_wide_int_storage.
13388         (enum wi::precision_type): Add INL_CONST_PRECISION enumerator.
13389         (struct binary_traits): Add partial specializations for
13390         INL_CONST_PRECISION.
13391         (generic_wide_int): Add needs_write_val_arg static data member.
13392         (int_traits): Likewise.
13393         (wide_int_storage): Replace val non-static data member with a union
13394         u of it and HOST_WIDE_INT *valp.  Declare copy constructor, copy
13395         assignment operator and destructor.  Add unsigned int argument to
13396         write_val.
13397         (wide_int_storage::wide_int_storage): Initialize precision to 0
13398         in the default ctor.  Remove unnecessary {}s around STATIC_ASSERTs.
13399         Assert in non-default ctor T's precision_type is not
13400         INL_CONST_PRECISION and allocate u.valp for large precision.  Add
13401         copy constructor.
13402         (wide_int_storage::~wide_int_storage): New.
13403         (wide_int_storage::operator=): Add copy assignment operator.  In
13404         assignment operator remove unnecessary {}s around STATIC_ASSERTs,
13405         assert ctor T's precision_type is not INL_CONST_PRECISION and
13406         if precision changes, deallocate and/or allocate u.valp.
13407         (wide_int_storage::get_val): Return u.valp rather than u.val for
13408         large precision.
13409         (wide_int_storage::write_val): Likewise.  Add an unused unsigned int
13410         argument.
13411         (wide_int_storage::set_len): Use write_val instead of writing val
13412         directly.
13413         (wide_int_storage::from, wide_int_storage::from_array): Adjust
13414         write_val callers.
13415         (wide_int_storage::create): Allocate u.valp for large precisions.
13416         (wi::int_traits <wide_int_storage>::get_binary_precision): New.
13417         (fixed_wide_int_storage::fixed_wide_int_storage): Make default
13418         ctor defaulted.
13419         (fixed_wide_int_storage::write_val): Add unused unsigned int argument.
13420         (fixed_wide_int_storage::from, fixed_wide_int_storage::from_array):
13421         Adjust write_val callers.
13422         (wi::int_traits <fixed_wide_int_storage>::get_binary_precision): New.
13423         (WIDEST_INT): Define.
13424         (widest_int_storage): New template class.
13425         (wi::int_traits <widest_int_storage>): New.
13426         (trailing_wide_int_storage::write_val): Add unused unsigned int
13427         argument.
13428         (wi::get_binary_precision): Use
13429         wi::int_traits <WI_BINARY_RESULT (T1, T2)>::get_binary_precision
13430         rather than get_precision on get_binary_result.
13431         (wi::copy): Adjust write_val callers.  Don't call set_len if
13432         needs_write_val_arg.
13433         (wi::bit_not): If result.needs_write_val_arg, call write_val
13434         again with upper bound estimate of len.
13435         (wi::sext, wi::zext, wi::set_bit): Likewise.
13436         (wi::bit_and, wi::bit_and_not, wi::bit_or, wi::bit_or_not,
13437         wi::bit_xor, wi::add, wi::sub, wi::mul, wi::mul_high, wi::div_trunc,
13438         wi::div_floor, wi::div_ceil, wi::div_round, wi::divmod_trunc,
13439         wi::mod_trunc, wi::mod_floor, wi::mod_ceil, wi::mod_round,
13440         wi::lshift, wi::lrshift, wi::arshift): Likewise.
13441         (wi::bswap, wi::bitreverse): Assert result.needs_write_val_arg
13442         is false.
13443         (gt_ggc_mx, gt_pch_nx): Remove generic template for all
13444         generic_wide_int, instead add functions and templates for each
13445         storage of generic_wide_int.  Make functions for
13446         generic_wide_int <wide_int_storage> and templates for
13447         generic_wide_int <widest_int_storage <N>> deleted.
13448         (wi::mask, wi::shifted_mask): Adjust write_val calls.
13449         * wide-int.cc (zeros): Decrease array size to 1.
13450         (BLOCKS_NEEDED): Use CEIL.
13451         (canonize): Use HOST_WIDE_INT_M1.
13452         (wi::from_buffer): Pass 0 to write_val.
13453         (wi::to_mpz): Use CEIL.
13454         (wi::from_mpz): Likewise.  Pass 0 to write_val.  Use
13455         WIDE_INT_MAX_INL_ELTS instead of WIDE_INT_MAX_ELTS.
13456         (wi::mul_internal): Use WIDE_INT_MAX_INL_PRECISION instead of
13457         MAX_BITSIZE_MODE_ANY_INT in automatic array sizes, for prec
13458         above WIDE_INT_MAX_INL_PRECISION estimate precision from
13459         lengths of operands.  Use XALLOCAVEC allocated buffers for
13460         prec above WIDE_INT_MAX_INL_PRECISION.
13461         (wi::divmod_internal): Likewise.
13462         (wi::lshift_large): For len > WIDE_INT_MAX_INL_ELTS estimate
13463         it from xlen and skip.
13464         (rshift_large_common): Remove xprecision argument, add len
13465         argument with len computed in caller.  Don't return anything.
13466         (wi::lrshift_large, wi::arshift_large): Compute len here
13467         and pass it to rshift_large_common, for lengths above
13468         WIDE_INT_MAX_INL_ELTS using estimations from xlen if possible.
13469         (assert_deceq, assert_hexeq): For lengths above
13470         WIDE_INT_MAX_INL_ELTS use XALLOCAVEC allocated buffer.
13471         (test_printing): Use WIDE_INT_MAX_INL_PRECISION instead of
13472         WIDE_INT_MAX_PRECISION.
13473         * wide-int-print.h (WIDE_INT_PRINT_BUFFER_SIZE): Use
13474         WIDE_INT_MAX_INL_PRECISION instead of WIDE_INT_MAX_PRECISION.
13475         * wide-int-print.cc (print_decs, print_decu, print_hex): For
13476         lengths above WIDE_INT_MAX_INL_ELTS use XALLOCAVEC allocated buffer.
13477         * tree.h (wi::int_traits<extended_tree <N>>): Change precision_type
13478         to INL_CONST_PRECISION for N == ADDR_MAX_PRECISION.
13479         (widest_extended_tree): Use WIDEST_INT_MAX_PRECISION instead of
13480         WIDE_INT_MAX_PRECISION.
13481         (wi::ints_for): Use int_traits <extended_tree <N> >::precision_type
13482         instead of hard coded CONST_PRECISION.
13483         (widest2_int_cst): Use WIDEST_INT_MAX_PRECISION instead of
13484         WIDE_INT_MAX_PRECISION.
13485         (wi::extended_tree <N>::get_len): Use WIDEST_INT_MAX_PRECISION rather
13486         than WIDE_INT_MAX_PRECISION.
13487         (wi::ints_for::zero): Use
13488         wi::int_traits <wi::extended_tree <N> >::precision_type instead of
13489         wi::CONST_PRECISION.
13490         * tree.cc (build_replicated_int_cst): Formatting fix.  Use
13491         WIDE_INT_MAX_INL_ELTS rather than WIDE_INT_MAX_ELTS.
13492         * print-tree.cc (print_node): Don't print TREE_UNAVAILABLE on
13493         INTEGER_CSTs, TREE_VECs or SSA_NAMEs.
13494         * double-int.h (wi::int_traits <double_int>::precision_type): Change
13495         to INL_CONST_PRECISION from CONST_PRECISION.
13496         * poly-int.h (struct poly_coeff_traits): Add partial specialization
13497         for wi::INL_CONST_PRECISION.
13498         * cfgloop.h (bound_wide_int): New typedef.
13499         (struct nb_iter_bound): Change bound type from widest_int to
13500         bound_wide_int.
13501         (struct loop): Change nb_iterations_upper_bound,
13502         nb_iterations_likely_upper_bound and nb_iterations_estimate type from
13503         widest_int to bound_wide_int.
13504         * cfgloop.cc (record_niter_bound): Return early if wi::min_precision
13505         of i_bound is too large for bound_wide_int.  Adjustments for the
13506         widest_int to bound_wide_int type change in non-static data members.
13507         (get_estimated_loop_iterations, get_max_loop_iterations,
13508         get_likely_max_loop_iterations): Adjustments for the widest_int to
13509         bound_wide_int type change in non-static data members.
13510         * tree-vect-loop.cc (vect_transform_loop): Likewise.
13511         * tree-ssa-loop-niter.cc (do_warn_aggressive_loop_optimizations): Use
13512         XALLOCAVEC allocated buffer for i_bound len above
13513         WIDE_INT_MAX_INL_ELTS.
13514         (record_estimate): Return early if wi::min_precision of i_bound is too
13515         large for bound_wide_int.  Adjustments for the widest_int to
13516         bound_wide_int type change in non-static data members.
13517         (wide_int_cmp): Use bound_wide_int instead of widest_int.
13518         (bound_index): Use bound_wide_int instead of widest_int.
13519         (discover_iteration_bound_by_body_walk): Likewise.  Use
13520         widest_int::from to convert it to widest_int when passed to
13521         record_niter_bound.
13522         (maybe_lower_iteration_bound): Use widest_int::from to convert it to
13523         widest_int when passed to record_niter_bound.
13524         (estimate_numbers_of_iteration): Don't record upper bound if
13525         loop->nb_iterations has too large precision for bound_wide_int.
13526         (n_of_executions_at_most): Use widest_int::from.
13527         * tree-ssa-loop-ivcanon.cc (remove_redundant_iv_tests): Adjust for
13528         the widest_int to bound_wide_int changes.
13529         * match.pd (fold_sign_changed_comparison simplification): Use
13530         wide_int::from on wi::to_wide instead of wi::to_widest.
13531         * value-range.h (irange::maybe_resize): Avoid using memcpy on
13532         non-trivially copyable elements.
13533         * value-range.cc (irange_bitmask::dump): Use XALLOCAVEC allocated
13534         buffer for mask or value len above WIDE_INT_PRINT_BUFFER_SIZE.
13535         * fold-const.cc (fold_convert_const_int_from_int, fold_unary_loc):
13536         Use wide_int::from on wi::to_wide instead of wi::to_widest.
13537         * tree-ssa-ccp.cc (bit_value_binop): Zero extend r1max from width
13538         before calling wi::udiv_trunc.
13539         * lto-streamer-out.cc (output_cfg): Adjustments for the widest_int to
13540         bound_wide_int type change in non-static data members.
13541         * lto-streamer-in.cc (input_cfg): Likewise.
13542         (lto_input_tree_1): Use WIDE_INT_MAX_INL_ELTS rather than
13543         WIDE_INT_MAX_ELTS.  For length above WIDE_INT_MAX_INL_ELTS use
13544         XALLOCAVEC allocated buffer.  Formatting fix.
13545         * data-streamer-in.cc (streamer_read_wide_int,
13546         streamer_read_widest_int): Likewise.
13547         * tree-affine.cc (aff_combination_expand): Use placement new to
13548         construct name_expansion.
13549         (free_name_expansion): Destruct name_expansion.
13550         * gimple-ssa-strength-reduction.cc (struct slsr_cand_d): Change
13551         index type from widest_int to offset_int.
13552         (class incr_info_d): Change incr type from widest_int to offset_int.
13553         (alloc_cand_and_find_basis, backtrace_base_for_ref,
13554         restructure_reference, slsr_process_ref, create_mul_ssa_cand,
13555         create_mul_imm_cand, create_add_ssa_cand, create_add_imm_cand,
13556         slsr_process_add, cand_abs_increment, replace_mult_candidate,
13557         replace_unconditional_candidate, incr_vec_index,
13558         create_add_on_incoming_edge, create_phi_basis_1,
13559         replace_conditional_candidate, record_increment,
13560         record_phi_increments_1, phi_incr_cost_1, phi_incr_cost,
13561         lowest_cost_path, total_savings, ncd_with_phi, ncd_of_cand_and_phis,
13562         nearest_common_dominator_for_cands, insert_initializers,
13563         all_phi_incrs_profitable_1, replace_one_candidate,
13564         replace_profitable_candidates): Use offset_int rather than widest_int
13565         and wi::to_offset rather than wi::to_widest.
13566         * real.cc (real_to_integer): Use WIDE_INT_MAX_INL_ELTS rather than
13567         2 * WIDE_INT_MAX_ELTS and for words above that use XALLOCAVEC
13568         allocated buffer.
13569         * tree-ssa-loop-ivopts.cc (niter_for_exit): Use placement new
13570         to construct tree_niter_desc and destruct it on failure.
13571         (free_tree_niter_desc): Destruct tree_niter_desc if value is non-NULL.
13572         * gengtype.cc (main): Remove widest_int handling.
13573         * graphite-isl-ast-to-gimple.cc (widest_int_from_isl_expr_int): Use
13574         WIDEST_INT_MAX_ELTS instead of WIDE_INT_MAX_ELTS.
13575         * gimple-ssa-warn-alloca.cc (pass_walloca::execute): Use
13576         WIDE_INT_MAX_INL_PRECISION instead of WIDE_INT_MAX_PRECISION and
13577         assert get_len () fits into it.
13578         * value-range-pretty-print.cc (vrange_printer::print_irange_bitmasks):
13579         For mask or value lengths above WIDE_INT_MAX_INL_ELTS use XALLOCAVEC
13580         allocated buffer.
13581         * gimple-ssa-sprintf.cc (adjust_range_for_overflow): Use
13582         wide_int::from on wi::to_wide instead of wi::to_widest.
13583         * omp-general.cc (score_wide_int): New typedef.
13584         (omp_context_compute_score): Use score_wide_int instead of widest_int
13585         and adjust for those changes.
13586         (struct omp_declare_variant_entry): Change score and
13587         score_in_declare_simd_clone non-static data member type from widest_int
13588         to score_wide_int.
13589         (omp_resolve_late_declare_variant, omp_resolve_declare_variant): Use
13590         score_wide_int instead of widest_int and adjust for those changes.
13591         (omp_lto_output_declare_variant_alt): Likewise.
13592         (omp_lto_input_declare_variant_alt): Likewise.
13593         * godump.cc (go_output_typedef): Assert get_len () is smaller than
13594         WIDE_INT_MAX_INL_ELTS.
13596 2023-10-12  Pan Li  <pan2.li@intel.com>
13598         * config/riscv/autovec.md (lround<mode><v_i_l_ll_convert>2): New
13599         pattern for lround/lroundf.
13600         * config/riscv/riscv-protos.h (enum insn_type): New enum value.
13601         (expand_vec_lround): New func decl for expanding lround.
13602         * config/riscv/riscv-v.cc (expand_vec_lround): New func impl
13603         for expanding lround.
13605 2023-10-12  Jakub Jelinek  <jakub@redhat.com>
13607         * dwarf2out.h (wide_int_ptr): Remove.
13608         (dw_wide_int_ptr): New typedef.
13609         (struct dw_val_node): Change type of val_wide from wide_int_ptr
13610         to dw_wide_int_ptr.
13611         (struct dw_wide_int): New type.
13612         (dw_wide_int::elt): New method.
13613         (dw_wide_int::operator ==): Likewise.
13614         * dwarf2out.cc (get_full_len): Change argument type to
13615         const dw_wide_int & from const wide_int &.  Use CEIL.  Call
13616         get_precision method instead of calling wi::get_precision.
13617         (alloc_dw_wide_int): New function.
13618         (add_AT_wide): Change w argument type to const wide_int_ref &
13619         from const wide_int &.  Use alloc_dw_wide_int.
13620         (mem_loc_descriptor, loc_descriptor): Use alloc_dw_wide_int.
13621         (insert_wide_int): Change val argument type to const wide_int_ref &
13622         from const wide_int &.
13623         (add_const_value_attribute): Pass rtx_mode_t temporary directly to
13624         add_AT_wide instead of using a temporary variable.
13626 2023-10-12  Richard Biener  <rguenther@suse.de>
13628         PR tree-optimization/111764
13629         * tree-vect-loop.cc (check_reduction_path): Remove the attempt
13630         to allow x + x via special-casing of assigns.
13632 2023-10-12  Hu, Lin1  <lin1.hu@intel.com>
13634         * common/config/i386/cpuinfo.h (get_available_features):
13635         Detect USER_MSR.
13636         * common/config/i386/i386-common.cc (OPTION_MASK_ISA2_USER_MSR_SET): New.
13637         (OPTION_MASK_ISA2_USER_MSR_UNSET): Ditto.
13638         (ix86_handle_option): Handle -musermsr.
13639         * common/config/i386/i386-cpuinfo.h (enum processor_features):
13640         Add FEATURE_USER_MSR.
13641         * common/config/i386/i386-isas.h: Add ISA_NAME_TABLE_ENTRY for usermsr.
13642         * config.gcc: Add usermsrintrin.h
13643         * config/i386/cpuid.h (bit_USER_MSR): New.
13644         * config/i386/i386-builtin-types.def:
13645         Add DEF_FUNCTION_TYPE (VOID, UINT64, UINT64).
13646         * config/i386/i386-builtins.cc (ix86_init_mmx_sse_builtins):
13647         Add __builtin_urdmsr and __builtin_uwrmsr.
13648         * config/i386/i386-builtins.h (ix86_builtins):
13649         Add IX86_BUILTIN_URDMSR and IX86_BUILTIN_UWRMSR.
13650         * config/i386/i386-c.cc (ix86_target_macros_internal):
13651         Define __USER_MSR__.
13652         * config/i386/i386-expand.cc (ix86_expand_builtin):
13653         Handle new builtins.
13654         * config/i386/i386-isa.def (USER_MSR): Add DEF_PTA(USER_MSR).
13655         * config/i386/i386-options.cc (ix86_valid_target_attribute_inner_p):
13656         Handle usermsr.
13657         * config/i386/i386.md (urdmsr): New define_insn.
13658         (uwrmsr): Ditto.
13659         * config/i386/i386.opt: Add option -musermsr.
13660         * config/i386/x86gprintrin.h: Include usermsrintrin.h
13661         * doc/extend.texi: Document usermsr.
13662         * doc/invoke.texi: Document -musermsr.
13663         * doc/sourcebuild.texi: Document target usermsr.
13664         * config/i386/usermsrintrin.h: New file.
13666 2023-10-12  Yang Yujie  <yangyujie@loongson.cn>
13668         * config.gcc: Add loongarch-driver.h to tm_files.
13669         * config/loongarch/loongarch.h: Do not include loongarch-driver.h.
13670         * config/loongarch/t-loongarch: Append loongarch-multilib.h to $(GTM_H)
13671         instead of $(TM_H) for building generator programs.
13673 2023-10-12  Kewen Lin  <linkw@linux.ibm.com>
13675         PR target/111367
13676         * config/rs6000/rs6000.md (stack_protect_setsi): Support prefixed
13677         instruction emission and incorporate to stack_protect_set<mode>.
13678         (stack_protect_setdi): Rename to ...
13679         (stack_protect_set<mode>): ... this, adjust constraint.
13680         (stack_protect_testsi): Support prefixed instruction emission and
13681         incorporate to stack_protect_test<mode>.
13682         (stack_protect_testdi): Rename to ...
13683         (stack_protect_test<mode>): ... this, adjust constraint.
13685 2023-10-12  Kewen Lin  <linkw@linux.ibm.com>
13687         * tree-vect-stmts.cc (vectorizable_store): Consider generated
13688         VEC_PERM_EXPR stmt for VMAT_CONTIGUOUS_REVERSE in costing as
13689         vec_perm.
13691 2023-10-12  Kewen Lin  <linkw@linux.ibm.com>
13693         * tree-vect-stmts.cc (vect_model_store_cost): Remove.
13694         (vectorizable_store): Adjust the costing for the remaining memory
13695         access types VMAT_CONTIGUOUS{, _DOWN, _REVERSE}.
13697 2023-10-12  Kewen Lin  <linkw@linux.ibm.com>
13699         * tree-vect-stmts.cc (vect_model_store_cost): Assert it will never
13700         get VMAT_CONTIGUOUS_PERMUTE and remove VMAT_CONTIGUOUS_PERMUTE related
13701         handlings.
13702         (vectorizable_store): Adjust the cost handling on
13703         VMAT_CONTIGUOUS_PERMUTE without calling vect_model_store_cost.
13705 2023-10-12  Kewen Lin  <linkw@linux.ibm.com>
13707         * tree-vect-stmts.cc (vect_model_store_cost): Assert it will never
13708         get VMAT_LOAD_STORE_LANES.
13709         (vectorizable_store): Adjust the cost handling on VMAT_LOAD_STORE_LANES
13710         without calling vect_model_store_cost.  Factor out new lambda function
13711         update_prologue_cost.
13713 2023-10-12  Kewen Lin  <linkw@linux.ibm.com>
13715         * tree-vect-stmts.cc (vect_model_store_cost): Assert it won't get
13716         VMAT_ELEMENTWISE and VMAT_STRIDED_SLP any more, and remove their
13717         related handlings.
13718         (vectorizable_store): Adjust the cost handling on VMAT_ELEMENTWISE
13719         and VMAT_STRIDED_SLP without calling vect_model_store_cost.
13721 2023-10-12  Kewen Lin  <linkw@linux.ibm.com>
13723         * tree-vect-stmts.cc (vectorizable_store): Adjust costing on
13724         vectorizable_scan_store without calling vect_model_store_cost
13725         any more.
13727 2023-10-12  Kewen Lin  <linkw@linux.ibm.com>
13729         * tree-vect-stmts.cc (vect_model_store_cost): Assert it won't get
13730         VMAT_GATHER_SCATTER any more, remove VMAT_GATHER_SCATTER related
13731         handlings and the related parameter gs_info.
13732         (vect_build_scatter_store_calls): Add the handlings on costing with
13733         one more argument cost_vec.
13734         (vectorizable_store): Adjust the cost handling on VMAT_GATHER_SCATTER
13735         without calling vect_model_store_cost any more.
13737 2023-10-12  Kewen Lin  <linkw@linux.ibm.com>
13739         * tree-vect-stmts.cc (vectorizable_store): Move and duplicate the call
13740         to vect_model_store_cost down to some different transform paths
13741         according to the handlings of different vect_memory_access_types
13742         or some special handling need.
13744 2023-10-12  Kewen Lin  <linkw@linux.ibm.com>
13746         * tree-vect-stmts.cc (vectorizable_store): Ensure the generated
13747         vector store for some case of VMAT_ELEMENTWISE is supported.
13749 2023-10-12  Mo, Zewei  <zewei.mo@intel.com>
13750             Hu Lin1  <lin1.hu@intel.com>
13751             Hongyu Wang  <hongyu.wang@intel.com>
13753         * config/i386/i386.cc (gen_push2): New function to emit push2
13754         and adjust cfa offset.
13755         (ix86_pro_and_epilogue_can_use_push2_pop2): New function to
13756         determine whether push2/pop2 can be used.
13757         (ix86_compute_frame_layout): Adjust preferred stack boundary
13758         and stack alignment needed for push2/pop2.
13759         (ix86_emit_save_regs): Emit push2 when available.
13760         (ix86_emit_restore_reg_using_pop2): New function to emit pop2
13761         and adjust cfa info.
13762         (ix86_emit_restore_regs_using_pop2): New function to loop
13763         through the saved regs and call above.
13764         (ix86_expand_epilogue): Call ix86_emit_restore_regs_using_pop2
13765         when push2pop2 available.
13766         * config/i386/i386.md (push2_di): New pattern for push2.
13767         (pop2_di): Likewise for pop2.
13769 2023-10-12  Pan Li  <pan2.li@intel.com>
13771         * config/riscv/autovec.md (lrint<mode><vlconvert>2): Rename from.
13772         (lrint<mode><v_i_l_ll_convert>2): Rename to.
13773         * config/riscv/vector-iterators.md: Rename and remove TARGET_64BIT.
13775 2023-10-11  Kito Cheng  <kito.cheng@sifive.com>
13777         * config/riscv/riscv-opts.h (TARGET_MIN_VLEN_OPTS): New.
13779 2023-10-11  Jeff Law  <jlaw@ventanamicro.com>
13781         * config/riscv/riscv.md (jump): Adjust sequence to use a "jump"
13782         pseudo op instead of a "call" pseudo op.
13784 2023-10-11  Kito Cheng  <kito.cheng@sifive.com>
13786         * config/riscv/riscv-subset.h (riscv_subset_list::parse_single_std_ext):
13787         New.
13788         (riscv_subset_list::parse_single_multiletter_ext): Ditto.
13789         (riscv_subset_list::clone): Ditto.
13790         (riscv_subset_list::parse_single_ext): Ditto.
13791         (riscv_subset_list::set_loc): Ditto.
13792         (riscv_set_arch_by_subset_list): Ditto.
13793         * common/config/riscv/riscv-common.cc
13794         (riscv_subset_list::parse_single_std_ext): New.
13795         (riscv_subset_list::parse_single_multiletter_ext): Ditto.
13796         (riscv_subset_list::clone): Ditto.
13797         (riscv_subset_list::parse_single_ext): Ditto.
13798         (riscv_subset_list::set_loc): Ditto.
13799         (riscv_set_arch_by_subset_list): Ditto.
13801 2023-10-11  Kito Cheng  <kito.cheng@sifive.com>
13803         * config/riscv/riscv.cc (riscv_convert_vector_bits): Get setting
13804         from argument rather than get setting from global setting.
13805         (riscv_override_options_internal): New, splited from
13806         riscv_override_options, also take a gcc_options argument.
13807         (riscv_option_override): Splited most part to
13808         riscv_override_options_internal.
13810 2023-10-11  Kito Cheng  <kito.cheng@sifive.com>
13812         * doc/options.texi (Mask): Document TARGET_<NAME>_P and
13813         TARGET_<NAME>_OPTS_P.
13814         (InverseMask): Ditto.
13815         * opth-gen.awk (Mask): Generate TARGET_<NAME>_P and
13816         TARGET_<NAME>_OPTS_P macro.
13817         (InverseMask): Ditto.
13819 2023-10-11  Andrew Pinski  <pinskia@gmail.com>
13821         PR tree-optimization/111282
13822         * match.pd (`a & ~(a ^ b)`, `a & (a == b)`,
13823         `a & ((~a) ^ b)`): New patterns.
13825 2023-10-11  Mary Bennett  <mary.bennett@embecosm.com>
13827         * common/config/riscv/riscv-common.cc: Add the XCValu
13828         extension.
13829         * config/riscv/constraints.md: Add builtins for the XCValu
13830         extension.
13831         * config/riscv/predicates.md (immediate_register_operand):
13832         Likewise.
13833         * config/riscv/corev.def: Likewise.
13834         * config/riscv/corev.md: Likewise.
13835         * config/riscv/riscv-builtins.cc (AVAIL): Likewise.
13836         (RISCV_ATYPE_UHI): Likewise.
13837         * config/riscv/riscv-ftypes.def: Likewise.
13838         * config/riscv/riscv.opt: Likewise.
13839         * config/riscv/riscv.cc (riscv_print_operand): Likewise.
13840         * doc/extend.texi: Add XCValu documentation.
13841         * doc/sourcebuild.texi: Likewise.
13843 2023-10-11  Mary Bennett  <mary.bennett@embecosm.com>
13845         * common/config/riscv/riscv-common.cc: Add XCVmac.
13846         * config/riscv/riscv-ftypes.def: Add XCVmac builtins.
13847         * config/riscv/riscv-builtins.cc: Likewise.
13848         * config/riscv/riscv.md: Likewise.
13849         * config/riscv/riscv.opt: Likewise.
13850         * doc/extend.texi: Add XCVmac builtin documentation.
13851         * doc/sourcebuild.texi: Likewise.
13852         * config/riscv/corev.def: New file.
13853         * config/riscv/corev.md: New file.
13855 2023-10-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
13857         * config/riscv/autovec.md: Fix index bug.
13858         * config/riscv/riscv-protos.h (gather_scatter_valid_offset_mode_p): New function.
13859         * config/riscv/riscv-v.cc (expand_gather_scatter): Fix index bug.
13860         (gather_scatter_valid_offset_mode_p): New function.
13862 2023-10-11  Pan Li  <pan2.li@intel.com>
13864         * config/riscv/autovec.md (lrint<mode><vlconvert>2): New pattern
13865         for lrint/lintf.
13866         * config/riscv/riscv-protos.h (expand_vec_lrint): New func decl
13867         for expanding lint.
13868         * config/riscv/riscv-v.cc (emit_vec_cvt_x_f): New helper func impl
13869         for vfcvt.x.f.v.
13870         (expand_vec_lrint): New function impl for expanding lint.
13871         * config/riscv/vector-iterators.md: New mode attr and iterator.
13873 2023-10-11  Richard Biener  <rguenther@suse.de>
13874             Jakub Jelinek  <jakub@redhat.com>
13876         PR tree-optimization/111519
13877         * tree-ssa-strlen.cc (strlen_pass::count_nonzero_bytes): Add vuse
13878         argument and pass it through to recursive calls and
13879         count_nonzero_bytes_addr calls.  Don't shadow the stmt argument, but
13880         change stmt for gimple_assign_single_p statements for which we don't
13881         immediately punt.
13882         (strlen_pass::count_nonzero_bytes_addr): Add vuse argument and pass
13883         it through to recursive calls and count_nonzero_bytes calls.  Don't
13884         use get_strinfo if gimple_vuse (stmt) is different from vuse.  Don't
13885         shadow the stmt argument.
13887 2023-10-11  Roger Sayle  <roger@nextmovesoftware.com>
13889         PR middle-end/101955
13890         PR tree-optimization/106245
13891         * simplify-rtx.cc (simplify_relational_operation_1): Simplify
13892         the RTL (ne:SI (subreg:QI (ashift:SI x 7) 0) 0) to (and:SI x 1).
13894 2023-10-11  liuhongt  <hongtao.liu@intel.com>
13896         PR target/111745
13897         * config/i386/mmx.md (divv4hf3): Refine predicate of
13898         operands[2] with register_operand.
13900 2023-10-10  Andrew Waterman  <andrew@sifive.com>
13901             Philipp Tomsich  <philipp.tomsich@vrull.eu>
13902             Jeff Law  <jlaw@ventanamicro.com>
13904         * config/riscv/riscv.cc (struct machine_function): Track if a
13905         far-branch/jump is used within a function (and $ra needs to be
13906         saved).
13907         (riscv_print_operand): Implement 'N' (inverse integer branch).
13908         (riscv_far_jump_used_p): Implement.
13909         (riscv_save_return_addr_reg_p): New function.
13910         (riscv_save_reg_p): Use riscv_save_return_addr_reg_p.
13911         * config/riscv/riscv.h (FIXED_REGISTERS): Update $ra.
13912         (CALL_USED_REGISTERS): Update $ra.
13913         * config/riscv/riscv.md: Add new types "ret" and "jalr".
13914         (length attribute): Handle long conditional and unconditional
13915         branches.
13916         (conditional branch pattern): Handle case where jump can not
13917         reach the intended target.
13918         (indirect_jump, tablejump): Use new "jalr" type.
13919         (simple_return): Use new "ret" type.
13920         (simple_return_internal, eh_return_internal): Likewise.
13921         (gpr_restore_return, riscv_mret): Likewise.
13922         (riscv_uret, riscv_sret): Likewise.
13923         * config/riscv/generic.md (generic_branch): Also recognize jalr & ret
13924         types.
13925         * config/riscv/sifive-7.md (sifive_7_jump): Likewise.
13927 2023-10-10  Andrew Pinski  <pinskia@gmail.com>
13929         PR tree-optimization/111679
13930         * match.pd (`a | ((~a) ^ b)`): New pattern.
13932 2023-10-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
13934         PR target/111751
13935         * config/riscv/autovec.md: Add VLS BOOL modes.
13937 2023-10-10  Richard Biener  <rguenther@suse.de>
13939         PR tree-optimization/111751
13940         * fold-const.cc (fold_view_convert_expr): Up the buffer size
13941         to 128 bytes.
13942         * tree-ssa-sccvn.cc (visit_reference_op_load): Special case
13943         constants, giving up when re-interpretation to the target type
13944         fails.
13946 2023-10-10  Richard Biener  <rguenther@suse.de>
13948         PR tree-optimization/111751
13949         * tree-ssa-sccvn.cc (visit_reference_op_load): Exempt
13950         BLKmode result from the padding bits check.
13952 2023-10-10  Claudiu Zissulescu  <claziss@gmail.com>
13954         * config/arc/arc.cc (arc_select_cc_mode): Match NEG code with
13955         the first operand.
13956         * config/arc/arc.md (addsi_compare): Make pattern canonical.
13957         (addsi_compare_2): Fix identation, constraint letters.
13958         (addsi_compare_3): Likewise.
13960 2023-10-09  Eugene Rozenfeld  <erozen@microsoft.com>
13962         * auto-profile.cc (afdo_calculate_branch_prob): Fix count comparisons
13963         * tree-vect-loop-manip.cc (vect_do_peeling): Guard against zero count
13964         when scaling loop profile
13966 2023-10-09  Andrew MacLeod  <amacleod@redhat.com>
13968         PR tree-optimization/111694
13969         * gimple-range-cache.cc (ranger_cache::fill_block_cache): Adjust
13970         equivalence range.
13971         * value-relation.cc (adjust_equivalence_range): New.
13972         * value-relation.h (adjust_equivalence_range): New prototype.
13974 2023-10-09  Andrew MacLeod  <amacleod@redhat.com>
13976         * gimple-range-gori.cc (gori_compute::compute_operand1_range): Do
13977         not call get_identity_relation.
13978         (gori_compute::compute_operand2_range): Ditto.
13979         * value-relation.cc (get_identity_relation): Remove.
13980         * value-relation.h (get_identity_relation): Remove protyotype.
13982 2023-10-09  Robin Dapp  <rdapp@ventanamicro.com>
13984         * config/riscv/riscv-cores.def (RISCV_TUNE): Add parameter.
13985         * config/riscv/riscv-opts.h (enum riscv_microarchitecture_type):
13986         Add generic_ooo.
13987         * config/riscv/riscv.cc (riscv_sched_adjust_cost): Implement
13988         scheduler hook.
13989         (TARGET_SCHED_ADJUST_COST): Define.
13990         * config/riscv/riscv.md (no,yes"): Include generic-ooo.md
13991         * config/riscv/riscv.opt: Add -madjust-lmul-cost.
13992         * config/riscv/generic-ooo.md: New file.
13993         * config/riscv/vector.md: Add vsetvl_pre.
13995 2023-10-09  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
13997         * config/riscv/riscv-opts.h (TARGET_VECTOR_MISALIGN_SUPPORTED): New macro.
13998         * config/riscv/riscv.cc (riscv_support_vector_misalignment): Depend on movmisalign pattern.
13999         * config/riscv/vector.md (movmisalign<mode>): New pattern.
14001 2023-10-09  Xianmiao Qu  <cooper.qu@linux.alibaba.com>
14003         * config/riscv/thead.cc (th_mempair_save_regs): Fix missing CFI
14004         directives for store-pair instruction.
14006 2023-10-09  Richard Biener  <rguenther@suse.de>
14008         PR tree-optimization/111715
14009         * alias.cc (reference_alias_ptr_type_1): When we have
14010         a type-punning ref at the base search for the access
14011         path part that's still semantically valid.
14013 2023-10-09  Pan Li  <pan2.li@intel.com>
14015         * config/riscv/riscv-v.cc (shuffle_bswap_pattern): New func impl
14016         for shuffle bswap.
14017         (expand_vec_perm_const_1): Add handling for shuffle bswap pattern.
14019 2023-10-09  Roger Sayle  <roger@nextmovesoftware.com>
14021         * config/i386/i386-expand.cc (ix86_split_ashr): Split shifts by
14022         one into ashr[sd]i3_carry followed by rcr[sd]i2, if TARGET_USE_RCR
14023         or -Oz.
14024         (ix86_split_lshr): Likewise, split shifts by one bit into
14025         lshr[sd]i3_carry followed by rcr[sd]i2, if TARGET_USE_RCR or -Oz.
14026         * config/i386/i386.h (TARGET_USE_RCR): New backend macro.
14027         * config/i386/i386.md (rcrsi2): New define_insn for rcrl.
14028         (rcrdi2): New define_insn for rcrq.
14029         (<anyshiftrt><mode>3_carry): New define_insn for right shifts that
14030         set the carry flag from the least significant bit, modelled using
14031         UNSPEC_CC_NE.
14032         * config/i386/x86-tune.def (X86_TUNE_USE_RCR): New tuning parameter
14033         controlling use of rcr 1 vs. shrd, which is significantly faster on
14034         AMD processors.
14036 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14038         * config/i386/i386.opt: Allow -mno-evex512.
14040 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14041             Hu, Lin1  <lin1.hu@intel.com>
14043         * config/i386/sse.md (V48H_AVX512VL): Add TARGET_EVEX512.
14044         (VFH): Ditto.
14045         (VF2H): Ditto.
14046         (VFH_AVX512VL): Ditto.
14047         (VHFBF): Ditto.
14048         (VHF_AVX512VL): Ditto.
14049         (VI2H_AVX512VL): Ditto.
14050         (VI2F_256_512): Ditto.
14051         (VF48_I1248): Remove unused iterator.
14052         (VF48H_AVX512VL): Add TARGET_EVEX512.
14053         (VF_AVX512): Remove unused iterator.
14054         (REDUC_PLUS_MODE): Add TARGET_EVEX512.
14055         (REDUC_SMINMAX_MODE): Ditto.
14056         (FMAMODEM): Ditto.
14057         (VFH_SF_AVX512VL): Ditto.
14058         (VEC_PERM_AVX2): Ditto.
14060 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14061             Hu, Lin1  <lin1.hu@intel.com>
14063         * config/i386/sse.md (VI1_AVX512VL): Add TARGET_EVEX512.
14064         (VI8_FVL): Ditto.
14065         (VI1_AVX512F): Ditto.
14066         (VI1_AVX512VNNI): Ditto.
14067         (VI1_AVX512VL_F): Ditto.
14068         (VI12_VI48F_AVX512VL): Ditto.
14069         (*avx512f_permvar_truncv32hiv32qi_1): Ditto.
14070         (sdot_prod<mode>): Ditto.
14071         (VEC_PERM_AVX2): Ditto.
14072         (VPERMI2): Ditto.
14073         (VPERMI2I): Ditto.
14074         (vpmadd52<vpmadd52type>v8di): Ditto.
14075         (usdot_prod<mode>): Ditto.
14076         (vpdpbusd_v16si): Ditto.
14077         (vpdpbusds_v16si): Ditto.
14078         (vpdpwssd_v16si): Ditto.
14079         (vpdpwssds_v16si): Ditto.
14080         (VI48_AVX512VP2VL): Ditto.
14081         (avx512vp2intersect_2intersectv16si): Ditto.
14082         (VF_AVX512BF16VL): Ditto.
14083         (VF1_AVX512_256): Ditto.
14085 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14087         * config/i386/i386-expand.cc (ix86_expand_vector_init_duplicate):
14088         Make sure there is EVEX512 enabled.
14089         (ix86_expand_vecop_qihi2): Refuse V32QI->V32HI when no EVEX512.
14090         * config/i386/i386.cc (ix86_hard_regno_mode_ok): Disable 64 bit mask
14091         when !TARGET_EVEX512.
14092         * config/i386/i386.md (avx512bw_512): New.
14093         (SWI1248_AVX512BWDQ_64): Add TARGET_EVEX512.
14094         (*zero_extendsidi2): Change isa to avx512bw_512.
14095         (kmov_isa): Ditto.
14096         (*anddi_1): Ditto.
14097         (*andn<mode>_1): Change isa to kmov_isa.
14098         (*<code><mode>_1): Ditto.
14099         (*notxor<mode>_1): Ditto.
14100         (*one_cmpl<mode>2_1): Ditto.
14101         (*one_cmplsi2_1_zext): Change isa to avx512bw_512.
14102         (*ashl<mode>3_1): Change isa to kmov_isa.
14103         (*lshr<mode>3_1): Ditto.
14104         * config/i386/sse.md (VI12HFBF_AVX512VL): Add TARGET_EVEX512.
14105         (VI1248_AVX512VLBW): Ditto.
14106         (VHFBF_AVX512VL): Ditto.
14107         (VI): Ditto.
14108         (VIHFBF): Ditto.
14109         (VI_AVX2): Ditto.
14110         (VI1_AVX512): Ditto.
14111         (VI12_256_512_AVX512VL): Ditto.
14112         (VI2_AVX2_AVX512BW): Ditto.
14113         (VI2_AVX512VNNIBW): Ditto.
14114         (VI2_AVX512VL): Ditto.
14115         (VI2HFBF_AVX512VL): Ditto.
14116         (VI8_AVX2_AVX512BW): Ditto.
14117         (VIMAX_AVX2_AVX512BW): Ditto.
14118         (VIMAX_AVX512VL): Ditto.
14119         (VI12_AVX2_AVX512BW): Ditto.
14120         (VI124_AVX2_24_AVX512F_1_AVX512BW): Ditto.
14121         (VI248_AVX512VL): Ditto.
14122         (VI248_AVX512VLBW): Ditto.
14123         (VI248_AVX2_8_AVX512F_24_AVX512BW): Ditto.
14124         (VI248_AVX512BW): Ditto.
14125         (VI248_AVX512BW_AVX512VL): Ditto.
14126         (VI248_512): Ditto.
14127         (VI124_256_AVX512F_AVX512BW): Ditto.
14128         (VI_AVX512BW): Ditto.
14129         (VIHFBF_AVX512BW): Ditto.
14130         (SWI1248_AVX512BWDQ): Ditto.
14131         (SWI1248_AVX512BW): Ditto.
14132         (SWI1248_AVX512BWDQ2): Ditto.
14133         (*knotsi_1_zext): Ditto.
14134         (define_split for zero_extend + not): Ditto.
14135         (kunpckdi): Ditto.
14136         (REDUC_SMINMAX_MODE): Ditto.
14137         (VEC_EXTRACT_MODE): Ditto.
14138         (*avx512bw_permvar_truncv16siv16hi_1): Ditto.
14139         (*avx512bw_permvar_truncv16siv16hi_1_hf): Ditto.
14140         (truncv32hiv32qi2): Ditto.
14141         (avx512bw_<code>v32hiv32qi2): Ditto.
14142         (avx512bw_<code>v32hiv32qi2_mask): Ditto.
14143         (avx512bw_<code>v32hiv32qi2_mask_store): Ditto.
14144         (usadv64qi): Ditto.
14145         (VEC_PERM_AVX2): Ditto.
14146         (AVX512ZEXTMASK): Ditto.
14147         (SWI24_MASK): New.
14148         (vec_pack_trunc_<mode>): Change iterator to SWI24_MASK.
14149         (avx512bw_packsswb<mask_name>): Add TARGET_EVEX512.
14150         (avx512bw_packssdw<mask_name>): Ditto.
14151         (avx512bw_interleave_highv64qi<mask_name>): Ditto.
14152         (avx512bw_interleave_lowv64qi<mask_name>): Ditto.
14153         (<mask_codefor>avx512bw_pshuflwv32hi<mask_name>): Ditto.
14154         (<mask_codefor>avx512bw_pshufhwv32hi<mask_name>): Ditto.
14155         (vec_unpacks_lo_di): Ditto.
14156         (SWI48x_MASK): New.
14157         (vec_unpacks_hi_<mode>): Change iterator to SWI48x_MASK.
14158         (avx512bw_umulhrswv32hi3<mask_name>): Add TARGET_EVEX512.
14159         (VI1248_AVX512VL_AVX512BW): Ditto.
14160         (avx512bw_<code>v32qiv32hi2<mask_name>): Ditto.
14161         (*avx512bw_zero_extendv32qiv32hi2_1): Ditto.
14162         (*avx512bw_zero_extendv32qiv32hi2_2): Ditto.
14163         (<insn>v32qiv32hi2): Ditto.
14164         (pbroadcast_evex_isa): Change isa attribute to avx512bw_512.
14165         (VPERMI2): Add TARGET_EVEX512.
14166         (VPERMI2I): Ditto.
14168 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14170         * config/i386/i386-expand.cc (ix86_expand_sse2_mulvxdi3):
14171         Add TARGET_EVEX512 for 512 bit usage.
14172         * config/i386/i386.cc (standard_sse_constant_opcode): Ditto.
14173         * config/i386/sse.md (VF1_VF2_AVX512DQ): Ditto.
14174         (VF1_128_256VL): Ditto.
14175         (VF2_AVX512VL): Ditto.
14176         (VI8_256_512): Ditto.
14177         (<mask_codefor>fixuns_trunc<mode><sseintvecmodelower>2<mask_name>):
14178         Ditto.
14179         (AVX512_VEC): Ditto.
14180         (AVX512_VEC_2): Ditto.
14181         (VI4F_BRCST32x2): Ditto.
14182         (VI8F_BRCST64x2): Ditto.
14184 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14186         * config/i386/i386-builtins.cc
14187         (ix86_vectorize_builtin_gather): Disable 512 bit gather
14188         when !TARGET_EVEX512.
14189         * config/i386/i386-expand.cc (ix86_valid_mask_cmp_mode):
14190         Add TARGET_EVEX512.
14191         (ix86_expand_int_sse_cmp): Ditto.
14192         (ix86_expand_vector_init_one_nonzero): Disable subroutine
14193         when !TARGET_EVEX512.
14194         (ix86_emit_swsqrtsf): Add TARGET_EVEX512.
14195         (ix86_vectorize_vec_perm_const): Disable subroutine when
14196         !TARGET_EVEX512.
14197         * config/i386/i386.cc
14198         (standard_sse_constant_p): Add TARGET_EVEX512.
14199         (standard_sse_constant_opcode): Ditto.
14200         (ix86_get_ssemov): Ditto.
14201         (ix86_legitimate_constant_p): Ditto.
14202         (ix86_vectorize_builtin_scatter): Diable 512 bit scatter
14203         when !TARGET_EVEX512.
14204         * config/i386/i386.md (avx512f_512): New.
14205         (movxi): Add TARGET_EVEX512.
14206         (*movxi_internal_avx512f): Ditto.
14207         (*movdi_internal): Change alternative 12 to ?Yv. Adjust mode
14208         for alternative 13.
14209         (*movsi_internal): Change alternative 8 to ?Yv. Adjust mode for
14210         alternative 9.
14211         (*movhi_internal): Change alternative 11 to *Yv.
14212         (*movdf_internal): Change alternative 12 to Yv.
14213         (*movsf_internal): Change alternative 5 to Yv. Adjust mode for
14214         alternative 5 and 6.
14215         (*mov<mode>_internal): Change alternative 4 to Yv.
14216         (define_split for convert SF to DF): Add TARGET_EVEX512.
14217         (extendbfsf2_1): Ditto.
14218         * config/i386/predicates.md (bcst_mem_operand): Disable predicate
14219         for 512 bit when !TARGET_EVEX512.
14220         * config/i386/sse.md (VMOVE): Add TARGET_EVEX512.
14221         (V48_AVX512VL): Ditto.
14222         (V48_256_512_AVX512VL): Ditto.
14223         (V48H_AVX512VL): Ditto.
14224         (VI12_AVX512VL): Ditto.
14225         (V): Ditto.
14226         (V_512): Ditto.
14227         (V_256_512): Ditto.
14228         (VF): Ditto.
14229         (VF1_VF2_AVX512DQ): Ditto.
14230         (VFH): Ditto.
14231         (VFB): Ditto.
14232         (VF1): Ditto.
14233         (VF1_AVX2): Ditto.
14234         (VF2): Ditto.
14235         (VF2H): Ditto.
14236         (VF2_512_256): Ditto.
14237         (VF2_512_256VL): Ditto.
14238         (VF_512): Ditto.
14239         (VFB_512): Ditto.
14240         (VI48_AVX512VL): Ditto.
14241         (VI1248_AVX512VLBW): Ditto.
14242         (VF_AVX512VL): Ditto.
14243         (VFH_AVX512VL): Ditto.
14244         (VF1_AVX512VL): Ditto.
14245         (VI): Ditto.
14246         (VIHFBF): Ditto.
14247         (VI_AVX2): Ditto.
14248         (VI8): Ditto.
14249         (VI8_AVX512VL): Ditto.
14250         (VI2_AVX512F): Ditto.
14251         (VI4_AVX512F): Ditto.
14252         (VI4_AVX512VL): Ditto.
14253         (VI48_AVX512F_AVX512VL): Ditto.
14254         (VI8_AVX2_AVX512F): Ditto.
14255         (VI8_AVX_AVX512F): Ditto.
14256         (V8FI): Ditto.
14257         (V16FI): Ditto.
14258         (VI124_AVX2_24_AVX512F_1_AVX512BW): Ditto.
14259         (VI248_AVX512VLBW): Ditto.
14260         (VI248_AVX2_8_AVX512F_24_AVX512BW): Ditto.
14261         (VI248_AVX512BW): Ditto.
14262         (VI248_AVX512BW_AVX512VL): Ditto.
14263         (VI48_AVX512F): Ditto.
14264         (VI48_AVX_AVX512F): Ditto.
14265         (VI12_AVX_AVX512F): Ditto.
14266         (VI148_512): Ditto.
14267         (VI124_256_AVX512F_AVX512BW): Ditto.
14268         (VI48_512): Ditto.
14269         (VI_AVX512BW): Ditto.
14270         (VIHFBF_AVX512BW): Ditto.
14271         (VI4F_256_512): Ditto.
14272         (VI48F_256_512): Ditto.
14273         (VI48F): Ditto.
14274         (VI12_VI48F_AVX512VL): Ditto.
14275         (V32_512): Ditto.
14276         (AVX512MODE2P): Ditto.
14277         (STORENT_MODE): Ditto.
14278         (REDUC_PLUS_MODE): Ditto.
14279         (REDUC_SMINMAX_MODE): Ditto.
14280         (*andnot<mode>3): Change isa attribute to avx512f_512.
14281         (*andnot<mode>3): Ditto.
14282         (<code><mode>3): Ditto.
14283         (<code>tf3): Ditto.
14284         (FMAMODEM): Add TARGET_EVEX512.
14285         (FMAMODE_AVX512): Ditto.
14286         (VFH_SF_AVX512VL): Ditto.
14287         (avx512f_fix_notruncv16sfv16si<mask_name><round_name>): Ditto.
14288         (fix<fixunssuffix>_truncv16sfv16si2<mask_name><round_saeonly_name>):
14289         Ditto.
14290         (avx512f_cvtdq2pd512_2): Ditto.
14291         (avx512f_cvtpd2dq512<mask_name><round_name>): Ditto.
14292         (fix<fixunssuffix>_truncv8dfv8si2<mask_name><round_saeonly_name>):
14293         Ditto.
14294         (<mask_codefor>avx512f_cvtpd2ps512<mask_name><round_name>): Ditto.
14295         (vec_unpacks_lo_v16sf): Ditto.
14296         (vec_unpacks_hi_v16sf): Ditto.
14297         (vec_unpacks_float_hi_v16si): Ditto.
14298         (vec_unpacks_float_lo_v16si): Ditto.
14299         (vec_unpacku_float_hi_v16si): Ditto.
14300         (vec_unpacku_float_lo_v16si): Ditto.
14301         (vec_pack_sfix_trunc_v8df): Ditto.
14302         (avx512f_vec_pack_sfix_v8df): Ditto.
14303         (<mask_codefor>avx512f_unpckhps512<mask_name>): Ditto.
14304         (<mask_codefor>avx512f_unpcklps512<mask_name>): Ditto.
14305         (<mask_codefor>avx512f_movshdup512<mask_name>): Ditto.
14306         (<mask_codefor>avx512f_movsldup512<mask_name>): Ditto.
14307         (AVX512_VEC): Ditto.
14308         (AVX512_VEC_2): Ditto.
14309         (vec_extract_lo_v64qi): Ditto.
14310         (vec_extract_hi_v64qi): Ditto.
14311         (VEC_EXTRACT_MODE): Ditto.
14312         (<mask_codefor>avx512f_unpckhpd512<mask_name>): Ditto.
14313         (avx512f_movddup512<mask_name>): Ditto.
14314         (avx512f_unpcklpd512<mask_name>): Ditto.
14315         (*<avx512>_vternlog<mode>_all): Ditto.
14316         (*<avx512>_vpternlog<mode>_1): Ditto.
14317         (*<avx512>_vpternlog<mode>_2): Ditto.
14318         (*<avx512>_vpternlog<mode>_3): Ditto.
14319         (avx512f_shufps512_mask): Ditto.
14320         (avx512f_shufps512_1<mask_name>): Ditto.
14321         (avx512f_shufpd512_mask): Ditto.
14322         (avx512f_shufpd512_1<mask_name>): Ditto.
14323         (<mask_codefor>avx512f_interleave_highv8di<mask_name>): Ditto.
14324         (<mask_codefor>avx512f_interleave_lowv8di<mask_name>): Ditto.
14325         (vec_dupv2df<mask_name>): Ditto.
14326         (trunc<pmov_src_lower><mode>2): Ditto.
14327         (*avx512f_<code><pmov_src_lower><mode>2): Ditto.
14328         (*avx512f_vpermvar_truncv8div8si_1): Ditto.
14329         (avx512f_<code><pmov_src_lower><mode>2_mask): Ditto.
14330         (avx512f_<code><pmov_src_lower><mode>2_mask_store): Ditto.
14331         (truncv8div8qi2): Ditto.
14332         (avx512f_<code>v8div16qi2): Ditto.
14333         (*avx512f_<code>v8div16qi2_store_1): Ditto.
14334         (*avx512f_<code>v8div16qi2_store_2): Ditto.
14335         (avx512f_<code>v8div16qi2_mask): Ditto.
14336         (*avx512f_<code>v8div16qi2_mask_1): Ditto.
14337         (*avx512f_<code>v8div16qi2_mask_store_1): Ditto.
14338         (avx512f_<code>v8div16qi2_mask_store_2): Ditto.
14339         (vec_widen_umult_even_v16si<mask_name>): Ditto.
14340         (*vec_widen_umult_even_v16si<mask_name>): Ditto.
14341         (vec_widen_smult_even_v16si<mask_name>): Ditto.
14342         (*vec_widen_smult_even_v16si<mask_name>): Ditto.
14343         (VEC_PERM_AVX2): Ditto.
14344         (one_cmpl<mode>2): Ditto.
14345         (<mask_codefor>one_cmpl<mode>2<mask_name>): Ditto.
14346         (*one_cmpl<mode>2_pternlog_false_dep): Ditto.
14347         (define_split to xor): Ditto.
14348         (*andnot<mode>3): Ditto.
14349         (define_split for ior): Ditto.
14350         (*iornot<mode>3): Ditto.
14351         (*xnor<mode>3): Ditto.
14352         (*<nlogic><mode>3): Ditto.
14353         (<mask_codefor>avx512f_interleave_highv16si<mask_name>): Ditto.
14354         (<mask_codefor>avx512f_interleave_lowv16si<mask_name>): Ditto.
14355         (avx512f_pshufdv3_mask): Ditto.
14356         (avx512f_pshufd_1<mask_name>): Ditto.
14357         (*vec_extractv4ti): Ditto.
14358         (VEXTRACTI128_MODE): Ditto.
14359         (define_split to vec_extract): Ditto.
14360         (VI1248_AVX512VL_AVX512BW): Ditto.
14361         (<mask_codefor>avx512f_<code>v16qiv16si2<mask_name>): Ditto.
14362         (<insn>v16qiv16si2): Ditto.
14363         (avx512f_<code>v16hiv16si2<mask_name>): Ditto.
14364         (<insn>v16hiv16si2): Ditto.
14365         (avx512f_zero_extendv16hiv16si2_1): Ditto.
14366         (avx512f_<code>v8qiv8di2<mask_name>): Ditto.
14367         (*avx512f_<code>v8qiv8di2<mask_name>_1): Ditto.
14368         (*avx512f_<code>v8qiv8di2<mask_name>_2): Ditto.
14369         (<insn>v8qiv8di2): Ditto.
14370         (avx512f_<code>v8hiv8di2<mask_name>): Ditto.
14371         (<insn>v8hiv8di2): Ditto.
14372         (avx512f_<code>v8siv8di2<mask_name>): Ditto.
14373         (*avx512f_zero_extendv8siv8di2_1): Ditto.
14374         (*avx512f_zero_extendv8siv8di2_2): Ditto.
14375         (<insn>v8siv8di2): Ditto.
14376         (avx512f_roundps512_sfix): Ditto.
14377         (vashrv8di3): Ditto.
14378         (vashrv16si3): Ditto.
14379         (pbroadcast_evex_isa): Change isa attribute to avx512f_512.
14380         (vec_dupv4sf): Add TARGET_EVEX512.
14381         (*vec_dupv4si): Ditto.
14382         (*vec_dupv2di): Ditto.
14383         (vec_dup<mode>): Change isa attribute to avx512f_512.
14384         (VPERMI2): Add TARGET_EVEX512.
14385         (VPERMI2I): Ditto.
14386         (VEC_INIT_MODE): Ditto.
14387         (VEC_INIT_HALF_MODE): Ditto.
14388         (<mask_codefor>avx512f_vcvtph2ps512<mask_name><round_saeonly_name>):
14389         Ditto.
14390         (avx512f_vcvtps2ph512_mask_sae): Ditto.
14391         (<mask_codefor>avx512f_vcvtps2ph512<mask_name><round_saeonly_name>):
14392         Ditto.
14393         (*avx512f_vcvtps2ph512<merge_mask_name>): Ditto.
14394         (INT_BROADCAST_MODE): Ditto.
14396 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14398         * config/i386/i386-expand.cc (ix86_broadcast_from_constant):
14399         Disable zmm broadcast for !TARGET_EVEX512.
14400         * config/i386/i386-options.cc (ix86_option_override_internal):
14401         Do not use PVW_512 when no-evex512.
14402         (ix86_simd_clone_adjust): Add evex512 target into string.
14403         * config/i386/i386.cc (type_natural_mode): Report ABI warning
14404         when using zmm register w/o evex512.
14405         (ix86_return_in_memory): Do not allow zmm when !TARGET_EVEX512.
14406         (ix86_hard_regno_mode_ok): Ditto.
14407         (ix86_set_reg_reg_cost): Ditto.
14408         (ix86_rtx_costs): Ditto.
14409         (ix86_vector_mode_supported_p): Ditto.
14410         (ix86_preferred_simd_mode): Ditto.
14411         (ix86_get_mask_mode): Ditto.
14412         (ix86_simd_clone_compute_vecsize_and_simdlen): Disable 512 bit
14413         libmvec call when !TARGET_EVEX512.
14414         (ix86_simd_clone_usable): Ditto.
14415         * config/i386/i386.h (BIGGEST_ALIGNMENT): Disable 512 alignment
14416         when !TARGET_EVEX512
14417         (MOVE_MAX): Do not use PVW_512 when !TARGET_EVEX512.
14418         (STORE_MAX_PIECES): Ditto.
14420 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14422         * config/i386/i386-builtin.def (BDESC): Add
14423         OPTION_MASK_ISA2_EVEX512.
14425 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14427         * config/i386/i386-builtin.def (BDESC): Add
14428         OPTION_MASK_ISA2_EVEX512.
14430 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14432         * config/i386/i386-builtin.def (BDESC): Add
14433         OPTION_MASK_ISA2_EVEX512.
14435 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14437         * config/i386/i386-builtin.def (BDESC): Add
14438         OPTION_MASK_ISA2_EVEX512.
14440 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14442         * config/i386/i386-builtin.def (BDESC): Add
14443         OPTION_MASK_ISA2_EVEX512.
14444         * config/i386/i386-builtins.cc
14445         (ix86_init_mmx_sse_builtins): Ditto.
14447 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14448             Hu, Lin1  <lin1.hu@intel.com>
14450         * config/i386/avx512fp16intrin.h: Add evex512 target for 512 bit
14451         intrins.
14453 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14455         * config.gcc: Add avx512bitalgvlintrin.h.
14456         * config/i386/avx5124fmapsintrin.h: Add evex512 target for 512 bit
14457         intrins.
14458         * config/i386/avx5124vnniwintrin.h: Ditto.
14459         * config/i386/avx512bf16intrin.h: Ditto.
14460         * config/i386/avx512bitalgintrin.h: Add evex512 target for 512 bit
14461         intrins. Split 128/256 bit intrins to avx512bitalgvlintrin.h.
14462         * config/i386/avx512erintrin.h: Add evex512 target for 512 bit
14463         intrins
14464         * config/i386/avx512ifmaintrin.h: Ditto
14465         * config/i386/avx512pfintrin.h: Ditto
14466         * config/i386/avx512vbmi2intrin.h: Ditto.
14467         * config/i386/avx512vbmiintrin.h: Ditto.
14468         * config/i386/avx512vnniintrin.h: Ditto.
14469         * config/i386/avx512vp2intersectintrin.h: Ditto.
14470         * config/i386/avx512vpopcntdqintrin.h: Ditto.
14471         * config/i386/gfniintrin.h: Ditto.
14472         * config/i386/immintrin.h: Add avx512bitalgvlintrin.h.
14473         * config/i386/vaesintrin.h: Add evex512 target for 512 bit intrins.
14474         * config/i386/vpclmulqdqintrin.h: Ditto.
14475         * config/i386/avx512bitalgvlintrin.h: New.
14477 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14479         * config/i386/avx512bwintrin.h: Add evex512 target for 512 bit
14480         intrins.
14482 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14484         * config/i386/avx512dqintrin.h: Add evex512 target for 512 bit
14485         intrins.
14487 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14489         * config/i386/avx512fintrin.h: Add evex512 target for 512 bit intrins.
14491 2023-10-09  Haochen Jiang  <haochen.jiang@intel.com>
14493         * common/config/i386/i386-common.cc
14494         (OPTION_MASK_ISA2_EVEX512_SET): New.
14495         (OPTION_MASK_ISA2_EVEX512_UNSET): Ditto.
14496         (ix86_handle_option): Handle EVEX512.
14497         * config/i386/i386-c.cc
14498         (ix86_target_macros_internal): Handle EVEX512. Add __EVEX256__
14499         when AVX512VL is set.
14500         * config/i386/i386-options.cc: (isa2_opts): Handle EVEX512.
14501         (ix86_valid_target_attribute_inner_p): Ditto.
14502         (ix86_option_override_internal): Set EVEX512 target if it is not
14503         explicitly set when AVX512 is enabled. Disable
14504         AVX512{PF,ER,4VNNIW,4FAMPS} for -mno-evex512.
14505         * config/i386/i386.opt: Add mevex512. Temporaily RejectNegative.
14507 2023-10-09  Haochen Gui  <guihaoc@gcc.gnu.org>
14509         PR target/88558
14510         * config/rs6000/rs6000.md (lrint<mode>di2): Remove TARGET_FPRND
14511         from insn condition.
14512         (lrint<mode>si2): New insn pattern for 32bit lrint.
14514 2023-10-09  Haochen Gui  <guihaoc@gcc.gnu.org>
14516         PR target/88558
14517         * config/rs6000/rs6000.cc (rs6000_hard_regno_mode_ok_uncached):
14518         Enable SImode on FP registers for P7.
14519         * config/rs6000/rs6000.md (*movsi_internal1): Add fmr for SImode
14520         move between FP registers.  Set attribute isa of stfiwx to "*"
14521         and attribute of stxsiwx to "p7".
14523 2023-10-09  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
14525         * config/s390/s390.md: Make use of new copysign RTL.
14527 2023-10-09  Hongyu Wang  <hongyu.wang@intel.com>
14529         * config/i386/sse.md (vec_concatv2di): Replace constraint "m"
14530         with "jm" for alternative 0 and 1 of operand 2.
14531         (sse4_1_<code><mode>3<mask_name>): Replace constraint "Bm" with
14532         "ja" for alternative 0 and 1 of operand2.
14534 2023-10-08  David Malcolm  <dmalcolm@redhat.com>
14536         PR analyzer/111155
14537         * text-art/table.cc (table::maybe_set_cell_span): New.
14538         (table::add_other_table): New.
14539         * text-art/table.h (class table::cell_placement): Add class table
14540         as a friend.
14541         (table::add_rows): New.
14542         (table::add_row): Reimplement in terms of add_rows.
14543         (table::maybe_set_cell_span): New decl.
14544         (table::add_other_table): New decl.
14545         * text-art/types.h (operator+): New operator for rect + coord.
14547 2023-10-08  David Malcolm  <dmalcolm@redhat.com>
14549         * genmatch.cc (main): Update for "m_" prefix of some fields of
14550         line_maps.
14551         * input.cc (make_location): Update for removal of
14552         COMBINE_LOCATION_DATA.
14553         (dump_line_table_statistics): Update for "m_" prefix of some
14554         fields of line_maps.
14555         (location_with_discriminator): Update for removal of
14556         COMBINE_LOCATION_DATA.
14557         (line_table_test::line_table_test): Update for "m_" prefix of some
14558         fields of line_maps.
14559         * toplev.cc (general_init): Likewise.
14560         * tree.cc (set_block): Update for removal of
14561         COMBINE_LOCATION_DATA.
14562         (set_source_range): Likewise.
14564 2023-10-08  David Malcolm  <dmalcolm@redhat.com>
14566         * input.cc (make_location): Move implementation to
14567         line_maps::make_location.
14569 2023-10-08  David Malcolm  <dmalcolm@redhat.com>
14571         PR driver/111700
14572         * input.cc (file_cache::add_file): Update leading comment to
14573         clarify that it can fail.
14574         (file_cache::lookup_or_add_file): Likewise.
14575         (file_cache::get_source_file_content): Gracefully handle
14576         lookup_or_add_file failing.
14578 2023-10-08  liuhongt  <hongtao.liu@intel.com>
14580         * config/i386/i386.cc (ix86_build_const_vector): Handle V2HF
14581         and V4HFmode.
14582         (ix86_build_signbit_mask): Ditto.
14583         * config/i386/mmx.md (mmxintvecmode): Ditto.
14584         (<code><mode>2): New define_expand.
14585         (*mmx_<code><mode>): New define_insn_and_split.
14586         (*mmx_nabs<mode>2): Ditto.
14587         (*mmx_andnot<mode>3): New define_insn.
14588         (<code><mode>3): Ditto.
14589         (copysign<mode>3): New define_expand.
14590         (xorsign<mode>3): Ditto.
14591         (signbit<mode>2): Ditto.
14593 2023-10-08  liuhongt  <hongtao.liu@intel.com>
14595         * config/i386/mmx.md (VHF_32_64): New mode iterator.
14596         (<insn><mode>3): New define_expand, merged from ..
14597         (<insn>v4hf3): .. this and
14598         (<insn>v2hf3): .. this.
14599         (movd_v2hf_to_sse_reg): New define_expand, splitted from ..
14600         (movd_v2hf_to_sse): .. this.
14601         (<code><mode>3): New define_expand.
14603 2023-10-08  Jiufu Guo  <guojiufu@linux.ibm.com>
14605         * config/rs6000/rs6000.cc (can_be_built_by_li_and_rldic): New function.
14606         (rs6000_emit_set_long_const): Call can_be_built_by_li_and_rldic.
14608 2023-10-08  Jiufu Guo  <guojiufu@linux.ibm.com>
14610         * config/rs6000/rs6000.cc (can_be_built_by_li_lis_and_rldicl): New
14611         function.
14612         (can_be_built_by_li_lis_and_rldicr): New function.
14613         (rs6000_emit_set_long_const): Call can_be_built_by_li_lis_and_rldicr and
14614         can_be_built_by_li_lis_and_rldicl.
14616 2023-10-08  Jiufu Guo  <guojiufu@linux.ibm.com>
14618         * config/rs6000/rs6000.cc (can_be_rotated_to_negative_lis): New
14619         function.
14620         (can_be_built_by_li_and_rotldi): Rename to ...
14621         (can_be_built_by_li_lis_and_rotldi): ... this function.
14622         (rs6000_emit_set_long_const): Call can_be_built_by_li_lis_and_rotldi.
14624 2023-10-08  Jiufu Guo  <guojiufu@linux.ibm.com>
14626         * config/rs6000/rs6000.cc (can_be_built_by_li_and_rotldi): New function.
14627         (rs6000_emit_set_long_const): Call can_be_built_by_li_and_rotldi.
14629 2023-10-08  Yanzhang Wang  <yanzhang.wang@intel.com>
14631         * config/riscv/linux.h: Pass the static-pie specific options to
14632         the linker.
14634 2023-10-07  Saurabh Jha  <saurabh.jha@arm.com>
14636         * config/aarch64/aarch64-cores.def (AARCH64_CORE): Add support for
14637         cortex-x4 core.
14638         * config/aarch64/aarch64-tune.md: Regenerated.
14639         * doc/invoke.texi: Add command-line option for cortex-x4 core.
14641 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
14642             Hongyu Wang  <hongyu.wang@intel.com>
14643             Hongtao Liu  <hongtao.liu@intel.com>
14645         * config/i386/constraints.md (jb): New constraint for vsib memory
14646         that does not allow gpr32.
14647         * config/i386/i386.md: (setcc_<mode>_sse): Replace m to jm for avx
14648         alternative and set attr_gpr32 to 0.
14649         (movmsk_df): Split avx/noavx alternatives and  replace "r" to "jr" for
14650         avx alternative.
14651         (<sse>_rcp<mode>2): Split avx/noavx alternatives and replace
14652         "m/Bm" to "jm/ja" for avx alternative, set its gpr32 attr to 0.
14653         (*rsqrtsf2_sse): Likewise.
14654         * config/i386/mmx.md (mmx_pmovmskb): Split alternative 1 to
14655         avx/noavx and assign jr/r constraint to dest.
14656         * config/i386/sse.md (<sse>_movmsk<ssemodesuffix><avxsizesuffix>):
14657         Split avx/noavx alternatives and replace "r" to "jr" for avx alternative.
14658         (*<sse>_movmsk<ssemodesuffix><avxsizesuffix>_<u>ext): Likewise.
14659         (*<sse>_movmsk<ssemodesuffix><avxsizesuffix>_lt): Likewise.
14660         (*<sse>_movmsk<ssemodesuffix><avxsizesuffix>_<u>ext_lt): Likewise.
14661         (*<sse>_movmsk<ssemodesuffix><avxsizesuffix>_shift): Likewise.
14662         (*<sse>_movmsk<ssemodesuffix><avxsizesuffix>_<u>ext_shift): Likewise.
14663         (<sse2_avx2>_pmovmskb): Likewise.
14664         (*<sse2_avx2>_pmovmskb_zext): Likewise.
14665         (*sse2_pmovmskb_ext): Likewise.
14666         (*<sse2_avx2>_pmovmskb_lt): Likewise.
14667         (*<sse2_avx2>_pmovmskb_zext_lt): Likewise.
14668         (*sse2_pmovmskb_ext_lt): Likewise.
14669         (<sse>_rcp<mode>2): Split avx/noavx alternatives and replace
14670         "m/Bm" to "jm/ja" for avx alternative, set its attr_gpr32 to 0.
14671         (sse_vmrcpv4sf2): Likewise.
14672         (*sse_vmrcpv4sf2): Likewise.
14673         (rsqrt<mode>2): Likewise.
14674         (sse_vmrsqrtv4sf2): Likewise.
14675         (*sse_vmrsqrtv4sf2): Likewise.
14676         (avx_h<insn>v4df3): Likewise.
14677         (sse3_hsubv2df3): Likewise.
14678         (avx_h<insn>v8sf3): Likewise.
14679         (sse3_h<insn>v4sf3): Likewise.
14680         (<sse3>_lddqu<avxsizesuffix>): Likewise.
14681         (avx_cmp<mode>3): Likewise.
14682         (avx_vmcmp<mode>3): Likewise.
14683         (*sse2_gt<mode>3): Likewise.
14684         (sse_ldmxcsr): Likewise.
14685         (sse_stmxcsr): Likewise.
14686         (avx_vtest<ssemodesuffix><avxsizesuffix>): Replace m to jm for
14687         avx alternative and set attr_gpr32 to 0.
14688         (avx2_permv2ti): Likewise.
14689         (*avx_vperm2f128<mode>_full): Likewise.
14690         (*avx_vperm2f128<mode>_nozero): Likewise.
14691         (vec_set_lo_v32qi): Likewise.
14692         (<avx_avx2>_maskload<ssemodesuffix><avxsizesuffix>): Likewise.
14693         (<avx_avx2>_maskstore<ssemodesuffix><avxsi)zesuffix>: Likewise.
14694         (avx_cmp<mode>3): Likewise.
14695         (avx_vmcmp<mode>3): Likewise.
14696         (*<sse>_maskcmp<mode>3_comm): Likewise.
14697         (*avx2_gathersi<VEC_GATHER_MODE:mode>): Replace Tv to jb and set
14698         attr_gpr32 to 0.
14699         (*avx2_gathersi<VEC_GATHER_MODE:mode>_2): Likewise.
14700         (*avx2_gatherdi<VEC_GATHER_MODE:mode>): Likewise.
14701         (*avx2_gatherdi<VEC_GATHER_MODE:mode>_2): Likewise.
14702         (*avx2_gatherdi<VI4F_256:mode>_3): Likewise.
14703         (*avx2_gatherdi<VI4F_256:mode>_4): Likewise.
14704         (avx_vbroadcastf128_<mode>): Restrict non-egpr alternative to
14705         noavx512vl, set its constraint to jm and set attr_gpr32 to 0.
14706         (vec_set_lo_<mode><mask_name>): Likewise.
14707         (vec_set_lo_<mode><mask_name>): Likewise for SF/SI modes.
14708         (vec_set_hi_<mode><mask_name>): Likewise.
14709         (vec_set_hi_<mode><mask_name>): Likewise for SF/SI modes.
14710         (vec_set_hi_<mode>): Likewise.
14711         (vec_set_lo_<mode>): Likewise.
14712         (avx2_set_hi_v32qi): Likewise.
14714 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
14715             Hongyu Wang  <hongyu.wang@intel.com>
14716             Hongtao Liu  <hongtao.liu@intel.com>
14718         * config/i386/i386.md (*movhi_internal): Split out non-gpr
14719         supported pextrw with mem constraint to avx/noavx alternatives,
14720         set jm and attr gpr32 0 to the noavx alternative.
14721         (*mov<mode>_internal): Likewise.
14722         * config/i386/mmx.md (mmx_pshufbv8qi3): Change "r/m/Bm" to
14723         "jr/jm/ja" and set_attr gpr32 0 for noavx alternative.
14724         (mmx_pshufbv4qi3): Likewise.
14725         (*mmx_pinsrd): Likewise.
14726         (*mmx_pinsrb): Likewise.
14727         (*pinsrb): Likewise.
14728         (mmx_pshufbv8qi3): Likewise.
14729         (mmx_pshufbv4qi3): Likewise.
14730         (@sse4_1_insertps_<mode>): Likewise.
14731         (*mmx_pextrw): Split altrenatives and map non-EGPR
14732         constraints, attr_gpr32 and attr_isa to noavx mnemonics.
14733         (*movv2qi_internal): Likewise.
14734         (*pextrw): Likewise.
14735         (*mmx_pextrb): Likewise.
14736         (*mmx_pextrb_zext): Likewise.
14737         (*pextrb): Likewise.
14738         (*pextrb_zext): Likewise.
14739         (vec_extractv2si_1): Likewise.
14740         (vec_extractv2si_1_zext): Likewise.
14741         * config/i386/sse.md: (vi128_h_r): New mode attr for
14742         pinsr{bw}/pextr{bw} with reg operand.
14743         (*abs<mode>2): Split altrenatives and %v in mnemonics, map
14744         non-EGPR constraints, gpr32 and isa attrs to noavx mnemonics.
14745         (*vec_extract<mode>): Likewise.
14746         (*vec_extract<mode>): Likewise for HFBF pattern.
14747         (*vec_extract<PEXTR_MODE12:mode>_zext): Likewise.
14748         (*vec_extractv4si_1): Likewise.
14749         (*vec_extractv4si_zext): Likewise.
14750         (*vec_extractv2di_1): Likewise.
14751         (*vec_concatv2si_sse4_1): Likewise.
14752         (<sse2p4_1>_pinsr<ssemodesuffix>): Likewise.
14753         (vec_concatv2di): Likewise.
14754         (*sse4_1_<code>v2qiv2di2<mask_name>_1): Likewise.
14755         (ssse3_avx2>_pshufb<mode>3<mask_name>): Change "r/m/Bm" to
14756         "jr/jm/ja" and set_attr gpr32 0 for noavx alternative, split
14757         %v for avx/noavx alternatives if necessary.
14758         (*vec_concatv2sf_sse4_1): Likewise.
14759         (*sse4_1_extractps): Likewise.
14760         (vec_set<mode>_0): Likewise for VI4F_128.
14761         (*vec_setv4sf_sse4_1): Likewise.
14762         (@sse4_1_insertps<mode>): Likewise.
14763         (ssse3_pmaddubsw128): Likewise.
14764         (*<ssse3_avx2>_pmulhrsw<mode>3<mask_name>): Likewise.
14765         (<sse4_1_avx2>_packusdw<mask_name>): Likewise.
14766         (<ssse3_avx2>_palignr<mode>): Likewise.
14767         (<vi8_sse4_1_avx2_avx512>_movntdqa): Likewise.
14768         (<sse4_1_avx2>_mpsadbw): Likewise.
14769         (*sse4_1_mulv2siv2di3<mask_name>): Likewise.
14770         (*<sse4_1_avx2>_mul<mode>3<mask_name>): Likewise.
14771         (*sse4_1_<code><mode>3<mask_name>): Likewise.
14772         (*<code>v8hi3): Likewise.
14773         (*<code>v16qi3): Likewise.
14774         (*sse4_1_<code>v8qiv8hi2<mask_name>_1): Likewise.
14775         (*sse4_1_zero_extendv8qiv8hi2_3): Likewise.
14776         (*sse4_1_zero_extendv8qiv8hi2_4): Likewise.
14777         (*sse4_1_<code>v4qiv4si2<mask_name>_1): Likewise.
14778         (*sse4_1_<code>v4hiv4si2<mask_name>_1): Likewise.
14779         (*sse4_1_zero_extendv4hiv4si2_3): Likewise.
14780         (*sse4_1_zero_extendv4hiv4si2_4): Likewise.
14781         (*sse4_1_<code>v2hiv2di2<mask_name>_1): Likewise.
14782         (*sse4_1_<code>v2siv2di2<mask_name>_1): Likewise.
14783         (*sse4_1_zero_extendv2siv2di2_3): Likewise.
14784         (*sse4_1_zero_extendv2siv2di2_4): Likewise.
14785         (aesdec): Likewise.
14786         (aesdeclast): Likewise.
14787         (aesenc): Likewise.
14788         (aesenclast): Likewise.
14789         (pclmulqdq): Likewise.
14790         (vgf2p8affineinvqb_<mode><mask_name>): Likewise.
14791         (vgf2p8affineqb_<mode><mask_name>): Likewise.
14792         (vgf2p8mulb_<mode><mask_name>): Likewise.
14794 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
14795             Hongyu Wang  <hongyu.wang@intel.com>
14796             Hongtao Liu  <hongtao.liu@intel.com>
14798         * config/i386/i386-protos.h (x86_evex_reg_mentioned_p): New
14799         prototype.
14800         * config/i386/i386.cc (x86_evex_reg_mentioned_p): New
14801         function.
14802         * config/i386/i386.md (sse4_1_round<mode>2): Set attr gpr32 0
14803         and constraint jm to all non-evex alternatives, adjust
14804         alternative outputs if evex reg is mentioned.
14805         * config/i386/sse.md (<sse4_1>_ptest<mode>): Set attr gpr32 0
14806         and constraint jm/ja to all non-evex alternatives.
14807         (ptesttf2): Likewise.
14808         (<sse4_1>_round<ssemodesuffix><avxsizesuffix): Likewise.
14809         (sse4_1_round<ssescalarmodesuffix>): Likewise.
14810         (sse4_2_pcmpestri): Likewise.
14811         (sse4_2_pcmpestrm): Likewise.
14812         (sse4_2_pcmpestr_cconly): Likewise.
14813         (sse4_2_pcmpistr): Likewise.
14814         (sse4_2_pcmpistri): Likewise.
14815         (sse4_2_pcmpistrm): Likewise.
14816         (sse4_2_pcmpistr_cconly): Likewise.
14817         (aesimc): Likewise.
14818         (aeskeygenassist): Likewise.
14820 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
14821             Hongyu Wang  <hongyu.wang@intel.com>
14822             Hongtao Liu  <hongtao.liu@intel.com>
14824         * config/i386/sse.md (avx2_ph<plusminus_mnemonic>wv16hi3): Set
14825         attr gpr32 0 and constraint jm/ja to all mem alternatives.
14826         (ssse3_ph<plusminus_mnemonic>wv8hi3): Likewise.
14827         (ssse3_ph<plusminus_mnemonic>wv4hi3): Likewise.
14828         (avx2_ph<plusminus_mnemonic>dv8si3): Likewise.
14829         (ssse3_ph<plusminus_mnemonic>dv4si3): Likewise.
14830         (ssse3_ph<plusminus_mnemonic>dv2si3): Likewise.
14831         (<ssse3_avx2>_psign<mode>3): Likewise.
14832         (ssse3_psign<mode>3): Likewise.
14833         (<sse4_1>_blend<ssemodesuffix><avxsizesuffix): Likewise.
14834         (<sse4_1>_blendv<ssemodesuffix><avxsizesuffix): Likewise.
14835         (*<sse4_1>_blendv<ssemodesuffix><avxsizesuffix>_lt): Likewise.
14836         (*<sse4_1>_blendv<ssefltmodesuff)ix><avxsizesuffix>_not_ltint: Likewise.
14837         (<sse4_1>_dp<ssemodesuffix><avxsizesuffix>): Likewise.
14838         (<sse4_1_avx2>_mpsadbw): Likewise.
14839         (<sse4_1_avx2>_pblendvb): Likewise.
14840         (*<sse4_1_avx2>_pblendvb_lt): Likewise.
14841         (sse4_1_pblend<ssemodesuffix>): Likewise.
14842         (*avx2_pblend<ssemodesuffix>): Likewise.
14843         (avx2_permv2ti): Likewise.
14844         (*avx_vperm2f128<mode>_nozero): Likewise.
14845         (*avx2_eq<mode>3): Likewise.
14846         (*sse4_1_eqv2di3): Likewise.
14847         (sse4_2_gtv2di3): Likewise.
14848         (avx2_gt<mode>3): Likewise.
14850 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
14851             Hongyu Wang  <hongyu.wang@intel.com>
14852             Hongtao Liu  <hongtao.liu@intel.com>
14854         * config/i386/i386.md (<xsave>): Set attr gpr32 0 and constraint
14855         jm.
14856         (<xsave>_rex64): Likewise.
14857         (<xrstor>_rex64): Likewise.
14858         (<xrstor>64): Likewise.
14859         (fxsave64): Likewise.
14860         (fxstore64): Likewise.
14862 2023-10-07  Hongyu Wang  <hongyu.wang@intel.com>
14863             Kong Lingling  <lingling.kong@intel.com>
14864             Hongtao Liu  <hongtao.liu@intel.com>
14866         * config/i386/i386.cc (ix86_get_ssemov): Check if egpr is used,
14867         adjust mnemonic for vmovduq/vmovdqa.
14868         * config/i386/sse.md (*<extract_type>_vinsert<shuffletype><extract_suf>_0):
14869         Check if egpr is used, adjust mnemonic for vmovdqu/vmovdqa.
14870         (avx_vec_concat<mode>): Likewise, and separate alternative 0 to
14871         avx_noavx512f.
14873 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
14874             Hongyu Wang  <hongyu.wang@intel.com>
14875             Hongtao Liu  <hongtao.liu@intel.com>
14877         * config/i386/i386.cc (map_egpr_constraints): New funciton to
14878         map common constraints to EGPR prohibited constraints.
14879         (ix86_md_asm_adjust): Calls map_egpr_constraints.
14880         * config/i386/i386.opt: Add option mapx-inline-asm-use-gpr32.
14882 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
14883             Hongyu Wang  <hongyu.wang@intel.com>
14884             Hongtao Liu  <hongtao.liu@intel.com>
14886         * config/i386/i386-protos.h (ix86_insn_base_reg_class): New
14887         prototype.
14888         (ix86_regno_ok_for_insn_base_p): Likewise.
14889         (ix86_insn_index_reg_class): Likewise.
14890         * config/i386/i386.cc (ix86_memory_address_use_extended_reg_class_p):
14891         New helper function to scan the insn.
14892         (ix86_insn_base_reg_class): New function to choose BASE_REG_CLASS.
14893         (ix86_regno_ok_for_insn_base_p): Likewise for base regno.
14894         (ix86_insn_index_reg_class): Likewise for INDEX_REG_CLASS.
14895         * config/i386/i386.h (INSN_BASE_REG_CLASS): Define.
14896         (REGNO_OK_FOR_INSN_BASE_P): Likewise.
14897         (INSN_INDEX_REG_CLASS): Likewise.
14898         (enum reg_class): Add INDEX_GPR16.
14899         (GENERAL_GPR16_REGNO_P): Define.
14900         * config/i386/i386.md (gpr32): New attribute.
14902 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
14903             Hongyu Wang  <hongyu.wang@intel.com>
14904             Hongtao Liu  <hongtao.liu@intel.com>
14906         * config/i386/constraints.md (jr): New register constraint
14907         that prohibits EGPR.
14908         (jR): Constraint that force usage of EGPR.
14909         (jm): New memory constraint that prohibits EGPR.
14910         (ja): Likewise for Bm constraint.
14911         (jb): Likewise for Tv constraint.
14912         (j<): New auto-dec memory constraint that prohibits EGPR.
14913         (j>): Likewise for ">" constraint.
14914         (jo): Likewise for "o" constraint.
14915         (jv): Likewise for "V" constraint.
14916         (jp): Likewise for "p" constraint.
14917         * config/i386/i386.h (enum reg_class): Add new reg class
14918         GENERAL_GPR16.
14920 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
14921             Hongyu Wang  <hongyu.wang@intel.com>
14922             Hongtao Liu  <hongtao.liu@intel.com>
14924         * config/i386/i386-protos.h (x86_extended_rex2reg_mentioned_p):
14925         New function prototype.
14926         * config/i386/i386.cc (regclass_map): Add mapping for 16 new
14927         general registers.
14928         (debugger64_register_map): Likewise.
14929         (ix86_conditional_register_usage): Clear REX2 register when APX
14930         disabled.
14931         (ix86_code_end): Add handling for REX2 reg.
14932         (print_reg): Likewise.
14933         (ix86_output_jmp_thunk_or_indirect): Likewise.
14934         (ix86_output_indirect_branch_via_reg): Likewise.
14935         (ix86_attr_length_vex_default): Likewise.
14936         (ix86_emit_save_regs): Adjust to allow saving r31.
14937         (ix86_register_priority): Set REX2 reg priority same as REX.
14938         (x86_extended_reg_mentioned_p): Add check for REX2 regs.
14939         (x86_extended_rex2reg_mentioned_p): New function.
14940         * config/i386/i386.h (CALL_USED_REGISTERS): Add new extended
14941         registers.
14942         (REG_ALLOC_ORDER): Likewise.
14943         (FIRST_REX2_INT_REG): Define.
14944         (LAST_REX2_INT_REG): Ditto.
14945         (GENERAL_REGS): Add 16 new registers.
14946         (INT_SSE_REGS): Likewise.
14947         (FLOAT_INT_REGS): Likewise.
14948         (FLOAT_INT_SSE_REGS): Likewise.
14949         (INT_MASK_REGS): Likewise.
14950         (ALL_REGS):Likewise.
14951         (REX2_INT_REG_P): Define.
14952         (REX2_INT_REGNO_P): Ditto.
14953         (GENERAL_REGNO_P): Add REX2_INT_REGNO_P.
14954         (REGNO_OK_FOR_INDEX_P): Ditto.
14955         (REG_OK_FOR_INDEX_NONSTRICT_P): Add new extended registers.
14956         * config/i386/i386.md: Add 16 new integer general
14957         registers.
14959 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
14960             Hongyu Wang  <hongyu.wang@intel.com>
14961             Hongtao Liu  <hongtao.liu@intel.com>
14963         * common/config/i386/cpuinfo.h (XSTATE_APX_F): New macro.
14964         (XCR_APX_F_ENABLED_MASK): Likewise.
14965         (get_available_features): Detect APX_F under
14966         * common/config/i386/i386-common.cc (OPTION_MASK_ISA2_APX_F_SET): New.
14967         (OPTION_MASK_ISA2_APX_F_UNSET): Likewise.
14968         (ix86_handle_option): Handle -mapxf.
14969         * common/config/i386/i386-cpuinfo.h (FEATURE_APX_F): New.
14970         * common/config/i386/i386-isas.h: Add entry for APX_F.
14971         * config/i386/cpuid.h (bit_APX_F): New.
14972         * config/i386/i386.h (bit_APX_F): (TARGET_APX_EGPR,
14973         TARGET_APX_PUSH2POP2, TARGET_APX_NDD): New define.
14974         * config/i386/i386-opts.h (enum apx_features): New enum.
14975         * config/i386/i386-isa.def (APX_F): New DEF_PTA.
14976         * config/i386/i386-options.cc (ix86_function_specific_save):
14977         Save ix86_apx_features.
14978         (ix86_function_specific_restore): Restore it.
14979         (ix86_valid_target_attribute_inner_p): Add mapxf.
14980         (ix86_option_override_internal): Set ix86_apx_features for PTA
14981         and TARGET_APX_F. Also reports error when APX_F is set but not
14982         having TARGET_64BIT.
14983         * config/i386/i386.opt: (-mapxf): New ISA flag option.
14984         (-mapx=): New enumeration option.
14985         (apx_features): New enum type.
14986         (apx_none): New enum value.
14987         (apx_egpr): Likewise.
14988         (apx_push2pop2): Likewise.
14989         (apx_ndd): Likewise.
14990         (apx_all): Likewise.
14991         * doc/invoke.texi: Document mapxf.
14993 2023-10-07  Hongyu Wang  <hongyu.wang@intel.com>
14994             Kong Lingling  <lingling.kong@intel.com>
14995             Hongtao Liu  <hongtao.liu@intel.com>
14997         * addresses.h (index_reg_class): New wrapper function like
14998         base_reg_class.
14999         * doc/tm.texi: Document INSN_INDEX_REG_CLASS.
15000         * doc/tm.texi.in: Ditto.
15001         * lra-constraints.cc (index_part_to_reg): Pass index_class.
15002         (process_address_1): Calls index_reg_class with curr_insn and
15003         replace INDEX_REG_CLASS with its return value index_cl.
15004         * reload.cc (find_reloads_address): Likewise.
15005         (find_reloads_address_1): Likewise.
15007 2023-10-07  Kong Lingling  <lingling.kong@intel.com>
15008             Hongyu Wang  <hongyu.wang@intel.com>
15009             Hongtao Liu  <hongtao.liu@intel.com>
15011         * addresses.h (base_reg_class): Add insn argument and new macro
15012         INSN_BASE_REG_CLASS.
15013         (regno_ok_for_base_p_1): Add insn argument and new macro
15014         REGNO_OK_FOR_INSN_BASE_P.
15015         (regno_ok_for_base_p): Add insn argument and parse to ok_for_base_p_1.
15016         * doc/tm.texi: Document INSN_BASE_REG_CLASS and
15017         REGNO_OK_FOR_INSN_BASE_P.
15018         * doc/tm.texi.in: Ditto.
15019         * lra-constraints.cc (process_address_1): Pass insn to
15020         base_reg_class.
15021         (curr_insn_transform): Ditto.
15022         * reload.cc (find_reloads): Ditto.
15023         (find_reloads_address): Ditto.
15024         (find_reloads_address_1): Ditto.
15025         (find_reloads_subreg_address): Ditto.
15026         * reload1.cc (maybe_fix_stack_asms): Ditto.
15028 2023-10-07  Jiufu Guo  <guojiufu@linux.ibm.com>
15030         PR target/108338
15031         * config/rs6000/rs6000.md (movsf_from_si): Update to generate mtvsrws
15032         for P9.
15034 2023-10-07  Jiufu Guo  <guojiufu@linux.ibm.com>
15036         PR target/108338
15037         * config/rs6000/predicates.md (lowpart_subreg_operator): New
15038         define_predicate.
15039         * config/rs6000/rs6000.md (any_rshift): New code_iterator.
15040         (movsf_from_si2): Rename to ...
15041         (movsf_from_si2_<code>): ... this.
15043 2023-10-07  Pan Li  <pan2.li@intel.com>
15045         PR target/111634
15046         * config/riscv/riscv.cc (riscv_legitimize_address): Ensure
15047         object is a REG before extracting its' REGNO.
15049 2023-10-06  Roger Sayle  <roger@nextmovesoftware.com>
15051         * config/i386/i386-expand.cc (ix86_split_ashl): Split shifts by
15052         one into add3_cc_overflow_1 followed by add3_carry.
15053         * config/i386/i386.md (@add<mode>3_cc_overflow_1): Renamed from
15054         "*add<mode>3_cc_overflow_1" to provide generator function.
15056 2023-10-06  Roger Sayle  <roger@nextmovesoftware.com>
15057             Uros Bizjak  <ubizjak@gmail.com>
15059         * config/i386/i386.cc (ix86_avoid_lea_for_addr): Split LEAs used
15060         to perform left shifts into shorter instructions with -Oz.
15062 2023-10-06  Vineet Gupta  <vineetg@rivosinc.com>
15064         * config/riscv/riscv.md (mvconst_internal): Add !ira_in_progress.
15066 2023-10-06  Sandra Loosemore  <sandra@codesourcery.com>
15068         * doc/extend.texi (Function Attributes): Mention standard attribute
15069         syntax.
15070         (Variable Attributes): Likewise.
15071         (Type Attributes): Likewise.
15072         (Attribute Syntax): Likewise.
15074 2023-10-06  Andrew Stubbs  <ams@codesourcery.com>
15076         * config/gcn/gcn-valu.md (*mov<mode>): Convert to compact syntax.
15077         (mov<mode>_exec): Likewise.
15078         (mov<mode>_sgprbase): Likewise.
15079         * config/gcn/gcn.md (*mov<mode>_insn): Likewise.
15080         (*movti_insn): Likewise.
15082 2023-10-06  Andrew Stubbs  <ams@codesourcery.com>
15084         * config/gcn/gcn.cc (print_operand): Adjust xcode type to fix warning.
15086 2023-10-06  Andrew Pinski  <pinskia@gmail.com>
15088         PR middle-end/111699
15089         * match.pd ((c ? a : b) op d, (c ? a : b) op (c ? d : e),
15090         (v ? w : 0) ? a : b, c1 ? c2 ? a : b : b): Enable only for GIMPLE.
15092 2023-10-06  Jakub Jelinek  <jakub@redhat.com>
15094         * ipa-prop.h (ipa_bits): Remove.
15095         (struct ipa_jump_func): Remove bits member.
15096         (struct ipcp_transformation): Remove bits member, adjust
15097         ctor and dtor.
15098         (ipa_get_ipa_bits_for_value): Remove.
15099         * ipa-prop.cc (struct ipa_bit_ggc_hash_traits): Remove.
15100         (ipa_bits_hash_table): Remove.
15101         (ipa_print_node_jump_functions_for_edge): Don't print bits.
15102         (ipa_get_ipa_bits_for_value): Remove.
15103         (ipa_set_jfunc_bits): Remove.
15104         (ipa_compute_jump_functions_for_edge): For pointers query
15105         pointer alignment before ipa_set_jfunc_vr and update_bitmask
15106         in there.  For integral types, just rely on bitmask already
15107         being handled in value ranges.
15108         (ipa_check_create_edge_args): Don't create ipa_bits_hash_table.
15109         (ipcp_transformation_initialize): Neither here.
15110         (ipcp_transformation_t::duplicate): Don't copy bits vector.
15111         (ipa_write_jump_function): Don't stream bits here.
15112         (ipa_read_jump_function): Neither here.
15113         (useful_ipcp_transformation_info_p): Don't test bits vec.
15114         (write_ipcp_transformation_info): Don't stream bits here.
15115         (read_ipcp_transformation_info): Neither here.
15116         (ipcp_get_parm_bits): Get mask and value from m_vr rather
15117         than bits.
15118         (ipcp_update_bits): Remove.
15119         (ipcp_update_vr): For pointers, set_ptr_info_alignment from
15120         bitmask stored in value range.
15121         (ipcp_transform_function): Don't test bits vector, don't call
15122         ipcp_update_bits.
15123         * ipa-cp.cc (propagate_bits_across_jump_function): Don't use
15124         jfunc->bits, instead get mask and value from jfunc->m_vr.
15125         (ipcp_store_bits_results): Remove.
15126         (ipcp_store_vr_results): Incorporate parts of
15127         ipcp_store_bits_results here, merge the bitmasks with value
15128         range if both are supplied.
15129         (ipcp_driver): Don't call ipcp_store_bits_results.
15130         * ipa-sra.cc (zap_useless_ipcp_results): Remove *ts->bits
15131         clearing.
15133 2023-10-06  Pan Li  <pan2.li@intel.com>
15135         * config/riscv/autovec.md: Update comments.
15137 2023-10-05  John David Anglin  <danglin@gcc.gnu.org>
15139         * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Delete.
15141 2023-10-05  Andrew MacLeod  <amacleod@redhat.com>
15143         * timevar.def (TV_TREE_FAST_VRP): New.
15144         * tree-pass.h (make_pass_fast_vrp): New prototype.
15145         * tree-vrp.cc (class fvrp_folder): New.
15146         (fvrp_folder::fvrp_folder): New.
15147         (fvrp_folder::~fvrp_folder): New.
15148         (fvrp_folder::value_of_expr): New.
15149         (fvrp_folder::value_on_edge): New.
15150         (fvrp_folder::value_of_stmt): New.
15151         (fvrp_folder::pre_fold_bb): New.
15152         (fvrp_folder::post_fold_bb): New.
15153         (fvrp_folder::pre_fold_stmt): New.
15154         (fvrp_folder::fold_stmt): New.
15155         (execute_fast_vrp): New.
15156         (pass_data_fast_vrp): New.
15157         (pass_vrp:execute): Check for fast VRP pass.
15158         (make_pass_fast_vrp): New.
15160 2023-10-05  Andrew MacLeod  <amacleod@redhat.com>
15162         * gimple-range.cc (dom_ranger::dom_ranger): New.
15163         (dom_ranger::~dom_ranger): New.
15164         (dom_ranger::range_of_expr): New.
15165         (dom_ranger::edge_range): New.
15166         (dom_ranger::range_on_edge): New.
15167         (dom_ranger::range_in_bb): New.
15168         (dom_ranger::range_of_stmt): New.
15169         (dom_ranger::maybe_push_edge): New.
15170         (dom_ranger::pre_bb): New.
15171         (dom_ranger::post_bb): New.
15172         * gimple-range.h (class dom_ranger): New.
15174 2023-10-05  Andrew MacLeod  <amacleod@redhat.com>
15176         * gimple-range-gori.cc (gori_stmt_info::gori_stmt_info): New.
15177         (gori_calc_operands): New.
15178         (gori_on_edge): New.
15179         (gori_name_helper): New.
15180         (gori_name_on_edge): New.
15181         * gimple-range-gori.h (gori_on_edge): New prototype.
15182         (gori_name_on_edge): New prototype.
15184 2023-10-05  Sergei Trofimovich  <siarheit@google.com>
15186         PR ipa/111283
15187         PR gcov-profile/111559
15188         * ipa-utils.cc (ipa_merge_profiles): Avoid producing
15189         uninitialized probabilities when merging counters with zero
15190         denominators.
15192 2023-10-05  Uros Bizjak  <ubizjak@gmail.com>
15194         PR target/111657
15195         * config/i386/i386-expand.cc (alg_usable_p): Reject libcall
15196         strategy for non-default address spaces.
15197         (decide_alg): Use loop strategy as a fallback strategy for
15198         non-default address spaces.
15200 2023-10-05  Jakub Jelinek  <jakub@redhat.com>
15202         * sreal.cc (verify_aritmetics): Rename to ...
15203         (verify_arithmetics): ... this.
15204         (sreal_verify_arithmetics): Adjust caller.
15206 2023-10-05  Martin Jambor  <mjambor@suse.cz>
15208         Revert:
15209         2023-10-03  Martin Jambor  <mjambor@suse.cz>
15211         PR ipa/108007
15212         * cgraph.h (cgraph_edge): Add a parameter to
15213         redirect_call_stmt_to_callee.
15214         * ipa-param-manipulation.h (ipa_param_adjustments): Add a
15215         parameter to modify_call.
15216         * cgraph.cc (cgraph_edge::redirect_call_stmt_to_callee): New
15217         parameter killed_ssas, pass it to padjs->modify_call.
15218         * ipa-param-manipulation.cc (purge_transitive_uses): New function.
15219         (ipa_param_adjustments::modify_call): New parameter killed_ssas.
15220         Instead of substituting uses, invoke purge_transitive_uses.  If
15221         hash of killed SSAs has not been provided, create a temporary one
15222         and release SSAs that have been added to it.
15223         * tree-inline.cc (redirect_all_calls): Create
15224         id->killed_new_ssa_names earlier, pass it to edge redirection,
15225         adjust a comment.
15226         (copy_body): Release SSAs in id->killed_new_ssa_names.
15228 2023-10-05  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
15230         * config/riscv/autovec.md (@vec_series<mode>): Remove @.
15231         (vec_series<mode>): Ditto.
15232         * config/riscv/riscv-v.cc (expand_const_vector): Ditto.
15233         (shuffle_decompress_patterns): Ditto.
15235 2023-10-05  Claudiu Zissulescu  <claziss@gmail.com>
15237         * config/arc/arc-passes.def: Remove arc_ifcvt pass.
15238         * config/arc/arc-protos.h (arc_ccfsm_branch_deleted_p): Remove.
15239         (arc_ccfsm_record_branch_deleted): Likewise.
15240         (arc_ccfsm_cond_exec_p): Likewise.
15241         (arc_ccfsm): Likewise.
15242         (arc_ccfsm_record_condition): Likewise.
15243         (make_pass_arc_ifcvt): Likewise.
15244         * config/arc/arc.cc (arc_ccfsm): Remove.
15245         (arc_ccfsm_current): Likewise.
15246         (ARC_CCFSM_BRANCH_DELETED_P): Likewise.
15247         (ARC_CCFSM_RECORD_BRANCH_DELETED): Likewise.
15248         (ARC_CCFSM_COND_EXEC_P): Likewise.
15249         (CCFSM_ISCOMPACT): Likewise.
15250         (CCFSM_DBR_ISCOMPACT): Likewise.
15251         (machine_function): Remove ccfsm related fields.
15252         (arc_ifcvt): Remove pass.
15253         (arc_print_operand): Remove `#` punct operand and other ccfsm
15254         related code.
15255         (arc_ccfsm_advance): Remove.
15256         (arc_ccfsm_at_label): Likewise.
15257         (arc_ccfsm_record_condition): Likewise.
15258         (arc_ccfsm_post_advance): Likewise.
15259         (arc_ccfsm_branch_deleted_p): Likewise.
15260         (arc_ccfsm_record_branch_deleted): Likewise.
15261         (arc_ccfsm_cond_exec_p): Likewise.
15262         (arc_get_ccfsm_cond): Likewise.
15263         (arc_final_prescan_insn): Remove ccfsm references.
15264         (arc_internal_label): Likewise.
15265         (arc_reorg): Likewise.
15266         (arc_output_libcall): Likewise.
15267         * config/arc/arc.md: Remove ccfsm references and update related
15268         instruction patterns.
15270 2023-10-05  Claudiu Zissulescu  <claziss@gmail.com>
15272         * config/arc/arc.cc (arc_init): Remove '^' punct char.
15273         (arc_print_operand): Remove related code.
15274         * config/arc/arc.md: Update patterns which uses '%&'.
15276 2023-10-05  Claudiu Zissulescu  <claziss@gmail.com>
15278         * config/arc/arc-protos.h (arc_clear_unalign): Remove.
15279         (arc_toggle_unalign): Likewise.
15280         * config/arc/arc.cc (machine_function) Remove unalign.
15281         (arc_init): Remove `&` punct character.
15282         (arc_print_operand): Remove `&` related functions.
15283         (arc_verify_short): Update function's number of parameters.
15284         (output_short_suffix): Update function.
15285         (arc_short_long): Likewise.
15286         (arc_clear_unalign): Remove.
15287         (arc_toggle_unalign): Likewise.
15288         * config/arc/arc.h (ASM_OUTPUT_CASE_END): Remove.
15289         (ASM_OUTPUT_ALIGN): Update.
15290         * config/arc/arc.md: Remove all `%&` references.
15291         * config/arc/arc.opt (mannotate-align): Ignore option.
15292         * doc/invoke.texi (mannotate-align): Update description.
15294 2023-10-05  Richard Biener  <rguenther@suse.de>
15296         * tree-vect-slp.cc (vect_build_slp_tree_1): Do not
15297         ask for internal_fn_p (CFN_LAST).
15299 2023-10-05  Richard Biener  <rguenther@suse.de>
15301         * tree-ssa-sccvn.cc (rpo_elim::eliminate_avail): Not
15302         visited value numbers are available itself.
15304 2023-10-05  Richard Biener  <rguenther@suse.de>
15306         PR ipa/111643
15307         * doc/extend.texi (attribute flatten): Clarify.
15309 2023-10-04  Roger Sayle  <roger@nextmovesoftware.com>
15311         * config/arc/arc-protos.h (emit_shift): Delete prototype.
15312         (arc_pre_reload_split): New function prototype.
15313         * config/arc/arc.cc (emit_shift): Delete function.
15314         (arc_pre_reload_split): New predicate function, copied from i386,
15315         to schedule define_insn_and_split splitters to the split1 pass.
15316         * config/arc/arc.md (ashlsi3): Expand RTL template unconditionally.
15317         (ashrsi3): Likewise.
15318         (lshrsi3): Likewise.
15319         (shift_si3): Move after other shift patterns, and disable when
15320         operands[2] is one (which is handled by its own define_insn).
15321         Use shiftr4_operator, instead of shift4_operator, as this is no
15322         longer used for left shifts.
15323         (shift_si3_loop): Likewise.  Additionally remove match_scratch.
15324         (*ashlsi3_nobs): New pre-reload define_insn_and_split.
15325         (*ashrsi3_nobs): Likewise.
15326         (*lshrsi3_nobs): Likewise.
15327         (rotrsi3_cnt1): Rename define_insn from *rotrsi3_cnt1.
15328         (add_shift): Rename define_insn from *add_shift.
15329         * config/arc/predicates.md (shiftl4_operator): Delete.
15330         (shift4_operator): Delete.
15332 2023-10-04  Roger Sayle  <roger@nextmovesoftware.com>
15334         * config/arc/arc.md (ashlsi3_cnt1): Rename define_insn *ashlsi2_cnt1.
15335         Change type attribute to "unary", as this doesn't have operands[2].
15336         Change length attribute to "*,4" to allow compact representation.
15337         (lshrsi3_cnt1): Rename define_insn from *lshrsi3_cnt1.  Change
15338         insn type attribute to "unary", as this doesn't have operands[2].
15339         (ashrsi3_cnt1): Rename define_insn from *ashrsi3_cnt1.  Change
15340         insn type attribute to "unary", as this doesn't have operands[2].
15342 2023-10-04  Roger Sayle  <roger@nextmovesoftware.com>
15344         PR rtl-optimization/110701
15345         * combine.cc (record_dead_and_set_regs_1): Split comment into
15346         pieces placed before the relevant clauses.  When the SET_DEST
15347         is a partial_subreg_p, mark the bits outside of the updated
15348         portion of the destination as undefined.
15350 2023-10-04  Kito Cheng  <kito.cheng@sifive.com>
15352         PR bootstrap/111664
15353         * opt-read.awk: Drop multidimensional arrays.
15354         * opth-gen.awk: Ditto.
15356 2023-10-04  Xi Ruoyao  <xry111@xry111.site>
15358         * config/loongarch/loongarch.md (UNSPEC_FCOPYSIGN): Delete.
15359         (copysign<mode>3): Use copysign RTL instead of UNSPEC.
15361 2023-10-04  Jakub Jelinek  <jakub@redhat.com>
15363         PR middle-end/111369
15364         * match.pd (x == cstN ? cst4 : cst3): Use
15365         build_nonstandard_integer_type only if type1 is BOOLEAN_TYPE.
15366         Fix comment typo.  Formatting fix.
15367         (a?~t:t -> (-(a))^t): Always convert to type rather
15368         than using build_nonstandard_integer_type.  Perform negation
15369         only if type has precision > 1 and is not signed BOOLEAN_TYPE.
15371 2023-10-04  Jakub Jelinek  <jakub@redhat.com>
15373         PR tree-optimization/111668
15374         * match.pd (a ? CST1 : CST2): Handle the a ? -1 : 0 and
15375         a ? 0 : -1 cases before the powerof2cst cases and differentiate
15376         between 1-bit precision types, larger precision boolean types
15377         and other integral types.  Fix comment pastos and formatting.
15379 2023-10-03  Andrew MacLeod  <amacleod@redhat.com>
15381         * tree-ssanames.cc (set_range_info): Use get_ptr_info for
15382         pointers rather than range_info_get_range.
15384 2023-10-03  Martin Jambor  <mjambor@suse.cz>
15386         * ipa-modref.h (modref_summary::dump): Make const.
15387         * ipa-modref.cc (modref_summary::dump): Likewise.
15388         (dump_lto_records): Dump to out instead of dump_file.
15390 2023-10-03  Martin Jambor  <mjambor@suse.cz>
15392         PR ipa/110378
15393         * ipa-param-manipulation.cc
15394         (ipa_param_body_adjustments::mark_dead_statements): Verify that any
15395         return uses of PARAM will be removed.
15396         (ipa_param_body_adjustments::mark_clobbers_dead): Likewise.
15397         * ipa-sra.cc (isra_param_desc): New fields
15398         remove_only_when_retval_removed and split_only_when_retval_removed.
15399         (struct gensum_param_desc): Likewise.  Fix comment long line.
15400         (ipa_sra_function_summaries::duplicate): Copy the new flags.
15401         (dump_gensum_param_descriptor): Dump the new flags.
15402         (dump_isra_param_descriptor): Likewise.
15403         (isra_track_scalar_value_uses): New parameter desc.  Set its flag
15404         remove_only_when_retval_removed when encountering a simple return.
15405         (isra_track_scalar_param_local_uses): Replace parameter call_uses_p
15406         with desc.  Pass it to isra_track_scalar_value_uses and set its
15407         call_uses.
15408         (ptr_parm_has_nonarg_uses): Accept parameter descriptor as a
15409         parameter.  If there is a direct return use, mark any..
15410         (create_parameter_descriptors): Pass the whole parameter descriptor to
15411         isra_track_scalar_param_local_uses and ptr_parm_has_nonarg_uses.
15412         (process_scan_results): Copy the new flags.
15413         (isra_write_node_summary): Stream the new flags.
15414         (isra_read_node_info): Likewise.
15415         (adjust_parameter_descriptions): Check that transformations
15416         requring return removal only happen when return value is removed.
15417         Restructure main loop.  Adjust dump message.
15419 2023-10-03  Martin Jambor  <mjambor@suse.cz>
15421         PR ipa/108007
15422         * cgraph.h (cgraph_edge): Add a parameter to
15423         redirect_call_stmt_to_callee.
15424         * ipa-param-manipulation.h (ipa_param_adjustments): Add a
15425         parameter to modify_call.
15426         * cgraph.cc (cgraph_edge::redirect_call_stmt_to_callee): New
15427         parameter killed_ssas, pass it to padjs->modify_call.
15428         * ipa-param-manipulation.cc (purge_transitive_uses): New function.
15429         (ipa_param_adjustments::modify_call): New parameter killed_ssas.
15430         Instead of substituting uses, invoke purge_transitive_uses.  If
15431         hash of killed SSAs has not been provided, create a temporary one
15432         and release SSAs that have been added to it.
15433         * tree-inline.cc (redirect_all_calls): Create
15434         id->killed_new_ssa_names earlier, pass it to edge redirection,
15435         adjust a comment.
15436         (copy_body): Release SSAs in id->killed_new_ssa_names.
15438 2023-10-03  Andrew MacLeod  <amacleod@redhat.com>
15440         * passes.def (pass_vrp): Pass "final pass" flag as parameter.
15441         * tree-vrp.cc (vrp_pass_num): Remove.
15442         (pass_vrp::my_pass): Remove.
15443         (pass_vrp::pass_vrp): Add warn_p as a parameter.
15444         (pass_vrp::final_p): New.
15445         (pass_vrp::set_pass_param): Set final_p param.
15446         (pass_vrp::execute): Call execute_range_vrp with no conditions.
15447         (make_pass_vrp): Pass additional parameter.
15448         (make_pass_early_vrp): Ditto.
15450 2023-10-03  Andrew MacLeod  <amacleod@redhat.com>
15452         * tree-ssanames.cc (set_range_info): Return true only if the
15453         current value changes.
15455 2023-10-03  David Malcolm  <dmalcolm@redhat.com>
15457         * diagnostic.cc (diagnostic_set_info_translated): Update for "m_"
15458         prefixes to text_info fields.
15459         (diagnostic_report_diagnostic): Likewise.
15460         (verbatim): Use text_info ctor.
15461         (simple_diagnostic_path::add_event): Likewise.
15462         (simple_diagnostic_path::add_thread_event): Likewise.
15463         * dumpfile.cc (dump_pretty_printer::decode_format): Update for
15464         "m_" prefixes to text_info fields.
15465         (dump_context::dump_printf_va): Use text_info ctor.
15466         * graphviz.cc (graphviz_out::graphviz_out): Use text_info ctor.
15467         (graphviz_out::print): Likewise.
15468         * opt-problem.cc (opt_problem::opt_problem): Likewise.
15469         * pretty-print.cc (pp_format): Update for "m_" prefixes to
15470         text_info fields.
15471         (pp_printf): Use text_info ctor.
15472         (pp_verbatim): Likewise.
15473         (assert_pp_format_va): Likewise.
15474         * pretty-print.h (struct text_info): Add ctors.  Add "m_" prefix
15475         to all fields.
15476         * text-art/styled-string.cc (styled_string::from_fmt_va): Use
15477         text_info ctor.
15478         * tree-diagnostic.cc (default_tree_printer): Update for "m_"
15479         prefixes to text_info fields.
15480         * tree-pretty-print.h (pp_ti_abstract_origin): Likewise.
15482 2023-10-03  Roger Sayle  <roger@nextmovesoftware.com>
15484         * config/arc/arc.md (CC_ltu): New mode iterator for CC and CC_C.
15485         (scc_ltu_<mode>): New define_insn to handle LTU form of scc_insn.
15486         (*scc_insn): Don't split to a conditional move sequence for LTU.
15488 2023-10-03  Andrea Corallo  <andrea.corallo@arm.com>
15490         * config/aarch64/aarch64.md (@ccmp<CC_ONLY:mode><GPI:mode>)
15491         (@ccmp<CC_ONLY:mode><GPI:mode>_rev, *call_insn, *call_value_insn)
15492         (*mov<mode>_aarch64, load_pair_sw_<SX:mode><SX2:mode>)
15493         (load_pair_dw_<DX:mode><DX2:mode>)
15494         (store_pair_sw_<SX:mode><SX2:mode>)
15495         (store_pair_dw_<DX:mode><DX2:mode>, *extendsidi2_aarch64)
15496         (*zero_extendsidi2_aarch64, *load_pair_zero_extendsidi2_aarch64)
15497         (*extend<SHORT:mode><GPI:mode>2_aarch64)
15498         (*zero_extend<SHORT:mode><GPI:mode>2_aarch64)
15499         (*extendqihi2_aarch64, *zero_extendqihi2_aarch64)
15500         (*add<mode>3_aarch64, *addsi3_aarch64_uxtw, *add<mode>3_poly_1)
15501         (add<mode>3_compare0, *addsi3_compare0_uxtw)
15502         (*add<mode>3_compareC_cconly, add<mode>3_compareC)
15503         (*add<mode>3_compareV_cconly_imm, add<mode>3_compareV_imm)
15504         (*add<mode>3nr_compare0, subdi3, subv<GPI:mode>_imm)
15505         (*cmpv<GPI:mode>_insn, sub<mode>3_compare1_imm, neg<mode>2)
15506         (cmp<mode>, fcmp<mode>, fcmpe<mode>, *cmov<mode>_insn)
15507         (*cmovsi_insn_uxtw, <optab><mode>3, *<optab>si3_uxtw)
15508         (*and<mode>3_compare0, *andsi3_compare0_uxtw, one_cmpl<mode>2)
15509         (*<NLOGICAL:optab>_one_cmpl<mode>3, *and<mode>3nr_compare0)
15510         (*aarch64_ashl_sisd_or_int_<mode>3)
15511         (*aarch64_lshr_sisd_or_int_<mode>3)
15512         (*aarch64_ashr_sisd_or_int_<mode>3, *ror<mode>3_insn)
15513         (*<optab>si3_insn_uxtw, <optab>_trunc<fcvt_target><GPI:mode>2)
15514         (<optab><fcvt_target><GPF:mode>2)
15515         (<FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3)
15516         (<FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3)
15517         (*aarch64_<optab><mode>3_cssc, copysign<GPF:mode>3_insn): Update
15518         to new syntax.
15519         * config/aarch64/aarch64-sve2.md (@aarch64_scatter_stnt<mode>)
15520         (@aarch64_scatter_stnt_<SVE_FULL_SDI:mode><SVE_PARTIAL_I:mode>)
15521         (*aarch64_mul_unpredicated_<mode>)
15522         (@aarch64_pred_<sve_int_op><mode>, *cond_<sve_int_op><mode>_2)
15523         (*cond_<sve_int_op><mode>_3, *cond_<sve_int_op><mode>_any)
15524         (*cond_<sve_int_op><mode>_z, @aarch64_pred_<sve_int_op><mode>)
15525         (*cond_<sve_int_op><mode>_2, *cond_<sve_int_op><mode>_3)
15526         (*cond_<sve_int_op><mode>_any, @aarch64_sve_<sve_int_op><mode>)
15527         (@aarch64_sve_<sve_int_op>_lane_<mode>)
15528         (@aarch64_sve_add_mul_lane_<mode>)
15529         (@aarch64_sve_sub_mul_lane_<mode>, @aarch64_sve2_xar<mode>)
15530         (*aarch64_sve2_bcax<mode>, @aarch64_sve2_eor3<mode>)
15531         (*aarch64_sve2_nor<mode>, *aarch64_sve2_nand<mode>)
15532         (*aarch64_sve2_bsl<mode>, *aarch64_sve2_nbsl<mode>)
15533         (*aarch64_sve2_bsl1n<mode>, *aarch64_sve2_bsl2n<mode>)
15534         (*aarch64_sve2_sra<mode>, @aarch64_sve_add_<sve_int_op><mode>)
15535         (*aarch64_sve2_<su>aba<mode>, @aarch64_sve_add_<sve_int_op><mode>)
15536         (@aarch64_sve_add_<sve_int_op>_lane_<mode>)
15537         (@aarch64_sve_qadd_<sve_int_op><mode>)
15538         (@aarch64_sve_qadd_<sve_int_op>_lane_<mode>)
15539         (@aarch64_sve_sub_<sve_int_op><mode>)
15540         (@aarch64_sve_sub_<sve_int_op>_lane_<mode>)
15541         (@aarch64_sve_qsub_<sve_int_op><mode>)
15542         (@aarch64_sve_qsub_<sve_int_op>_lane_<mode>)
15543         (@aarch64_sve_<sve_fp_op><mode>, @aarch64_<sve_fp_op>_lane_<mode>)
15544         (@aarch64_pred_<sve_int_op><mode>)
15545         (@aarch64_pred_<sve_fp_op><mode>, *cond_<sve_int_op><mode>_2)
15546         (*cond_<sve_int_op><mode>_z, @aarch64_sve_<optab><mode>)
15547         (@aarch64_<optab>_lane_<mode>, @aarch64_sve_<optab><mode>)
15548         (@aarch64_<optab>_lane_<mode>, @aarch64_pred_<sve_fp_op><mode>)
15549         (*cond_<sve_fp_op><mode>_any_relaxed)
15550         (*cond_<sve_fp_op><mode>_any_strict)
15551         (@aarch64_pred_<sve_int_op><mode>, *cond_<sve_int_op><mode>)
15552         (@aarch64_pred_<sve_fp_op><mode>, *cond_<sve_fp_op><mode>)
15553         (*cond_<sve_fp_op><mode>_strict): Update to new syntax.
15554         * config/aarch64/aarch64-sve.md (*aarch64_sve_mov<mode>_ldr_str)
15555         (*aarch64_sve_mov<mode>_no_ldr_str, @aarch64_pred_mov<mode>)
15556         (*aarch64_sve_mov<mode>, aarch64_wrffr)
15557         (mask_scatter_store<mode><v_int_container>)
15558         (*mask_scatter_store<mode><v_int_container>_<su>xtw_unpacked)
15559         (*mask_scatter_store<mode><v_int_container>_sxtw)
15560         (*mask_scatter_store<mode><v_int_container>_uxtw)
15561         (@aarch64_scatter_store_trunc<VNx4_NARROW:mode><VNx4_WIDE:mode>)
15562         (@aarch64_scatter_store_trunc<VNx2_NARROW:mode><VNx2_WIDE:mode>)
15563         (*aarch64_scatter_store_trunc<VNx2_NARROW:mode><VNx2_WIDE:mode>_sxtw)
15564         (*aarch64_scatter_store_trunc<VNx2_NARROW:mode><VNx2_WIDE:mode>_uxtw)
15565         (*vec_duplicate<mode>_reg, vec_shl_insert_<mode>)
15566         (vec_series<mode>, @extract_<last_op>_<mode>)
15567         (@aarch64_pred_<optab><mode>, *cond_<optab><mode>_2)
15568         (*cond_<optab><mode>_any, @aarch64_pred_<optab><mode>)
15569         (@aarch64_sve_revbhw_<SVE_ALL:mode><PRED_HSD:mode>)
15570         (@cond_<optab><mode>)
15571         (*<optab><SVE_PARTIAL_I:mode><SVE_HSDI:mode>2)
15572         (@aarch64_pred_sxt<SVE_FULL_HSDI:mode><SVE_PARTIAL_I:mode>)
15573         (@aarch64_cond_sxt<SVE_FULL_HSDI:mode><SVE_PARTIAL_I:mode>)
15574         (*cond_uxt<mode>_2, *cond_uxt<mode>_any, *cnot<mode>)
15575         (*cond_cnot<mode>_2, *cond_cnot<mode>_any)
15576         (@aarch64_pred_<optab><mode>, *cond_<optab><mode>_2_relaxed)
15577         (*cond_<optab><mode>_2_strict, *cond_<optab><mode>_any_relaxed)
15578         (*cond_<optab><mode>_any_strict, @aarch64_pred_<optab><mode>)
15579         (*cond_<optab><mode>_2, *cond_<optab><mode>_3)
15580         (*cond_<optab><mode>_any, add<mode>3, sub<mode>3)
15581         (@aarch64_pred_<su>abd<mode>, *aarch64_cond_<su>abd<mode>_2)
15582         (*aarch64_cond_<su>abd<mode>_3, *aarch64_cond_<su>abd<mode>_any)
15583         (@aarch64_sve_<optab><mode>, @aarch64_pred_<optab><mode>)
15584         (*cond_<optab><mode>_2, *cond_<optab><mode>_z)
15585         (@aarch64_pred_<optab><mode>, *cond_<optab><mode>_2)
15586         (*cond_<optab><mode>_3, *cond_<optab><mode>_any, <optab><mode>3)
15587         (*cond_bic<mode>_2, *cond_bic<mode>_any)
15588         (@aarch64_pred_<optab><mode>, *cond_<optab><mode>_2_const)
15589         (*cond_<optab><mode>_any_const, *cond_<sve_int_op><mode>_m)
15590         (*cond_<sve_int_op><mode>_z, *sdiv_pow2<mode>3)
15591         (*cond_<sve_int_op><mode>_2, *cond_<sve_int_op><mode>_any)
15592         (@aarch64_pred_<optab><mode>, *cond_<optab><mode>_2_relaxed)
15593         (*cond_<optab><mode>_2_strict, *cond_<optab><mode>_any_relaxed)
15594         (*cond_<optab><mode>_any_strict, @aarch64_pred_<optab><mode>)
15595         (*cond_<optab><mode>_2_relaxed, *cond_<optab><mode>_2_strict)
15596         (*cond_<optab><mode>_2_const_relaxed)
15597         (*cond_<optab><mode>_2_const_strict)
15598         (*cond_<optab><mode>_3_relaxed, *cond_<optab><mode>_3_strict)
15599         (*cond_<optab><mode>_any_relaxed, *cond_<optab><mode>_any_strict)
15600         (*cond_<optab><mode>_any_const_relaxed)
15601         (*cond_<optab><mode>_any_const_strict)
15602         (@aarch64_pred_<optab><mode>, *cond_add<mode>_2_const_relaxed)
15603         (*cond_add<mode>_2_const_strict)
15604         (*cond_add<mode>_any_const_relaxed)
15605         (*cond_add<mode>_any_const_strict, @aarch64_pred_<optab><mode>)
15606         (*cond_<optab><mode>_2_relaxed, *cond_<optab><mode>_2_strict)
15607         (*cond_<optab><mode>_any_relaxed, *cond_<optab><mode>_any_strict)
15608         (@aarch64_pred_<optab><mode>, *cond_sub<mode>_3_const_relaxed)
15609         (*cond_sub<mode>_3_const_strict, *cond_sub<mode>_const_relaxed)
15610         (*cond_sub<mode>_const_strict, *aarch64_pred_abd<mode>_relaxed)
15611         (*aarch64_pred_abd<mode>_strict)
15612         (*aarch64_cond_abd<mode>_2_relaxed)
15613         (*aarch64_cond_abd<mode>_2_strict)
15614         (*aarch64_cond_abd<mode>_3_relaxed)
15615         (*aarch64_cond_abd<mode>_3_strict)
15616         (*aarch64_cond_abd<mode>_any_relaxed)
15617         (*aarch64_cond_abd<mode>_any_strict, @aarch64_pred_<optab><mode>)
15618         (@aarch64_pred_fma<mode>, *cond_fma<mode>_2, *cond_fma<mode>_4)
15619         (*cond_fma<mode>_any, @aarch64_pred_fnma<mode>)
15620         (*cond_fnma<mode>_2, *cond_fnma<mode>_4, *cond_fnma<mode>_any)
15621         (<sur>dot_prod<vsi2qi>, @aarch64_<sur>dot_prod_lane<vsi2qi>)
15622         (@<sur>dot_prod<vsi2qi>, @aarch64_<sur>dot_prod_lane<vsi2qi>)
15623         (@aarch64_sve_add_<optab><vsi2qi>, @aarch64_pred_<optab><mode>)
15624         (*cond_<optab><mode>_2_relaxed, *cond_<optab><mode>_2_strict)
15625         (*cond_<optab><mode>_4_relaxed, *cond_<optab><mode>_4_strict)
15626         (*cond_<optab><mode>_any_relaxed, *cond_<optab><mode>_any_strict)
15627         (@aarch64_<optab>_lane_<mode>, @aarch64_pred_<optab><mode>)
15628         (*cond_<optab><mode>_4_relaxed, *cond_<optab><mode>_4_strict)
15629         (*cond_<optab><mode>_any_relaxed, *cond_<optab><mode>_any_strict)
15630         (@aarch64_<optab>_lane_<mode>, @aarch64_sve_tmad<mode>)
15631         (@aarch64_sve_<sve_fp_op>vnx4sf)
15632         (@aarch64_sve_<sve_fp_op>_lanevnx4sf)
15633         (@aarch64_sve_<sve_fp_op><mode>, *vcond_mask_<mode><vpred>)
15634         (@aarch64_sel_dup<mode>, @aarch64_pred_cmp<cmp_op><mode>)
15635         (*cmp<cmp_op><mode>_cc, *cmp<cmp_op><mode>_ptest)
15636         (@aarch64_pred_fcm<cmp_op><mode>, @fold_extract_<last_op>_<mode>)
15637         (@aarch64_fold_extract_vector_<last_op>_<mode>)
15638         (@aarch64_sve_splice<mode>)
15639         (@aarch64_sve_<optab>_nontrunc<SVE_FULL_F:mode><SVE_FULL_HSDI:mode>)
15640         (@aarch64_sve_<optab>_trunc<VNx2DF_ONLY:mode><VNx4SI_ONLY:mode>)
15641         (*cond_<optab>_nontrunc<SVE_FULL_F:mode><SVE_FULL_HSDI:mode>_relaxed)
15642         (*cond_<optab>_nontrunc<SVE_FULL_F:mode><SVE_FULL_HSDI:mode>_strict)
15643         (*cond_<optab>_trunc<VNx2DF_ONLY:mode><VNx4SI_ONLY:mode>)
15644         (@aarch64_sve_<optab>_nonextend<SVE_FULL_HSDI:mode><SVE_FULL_F:mode>)
15645         (@aarch64_sve_<optab>_extend<VNx4SI_ONLY:mode><VNx2DF_ONLY:mode>)
15646         (*cond_<optab>_nonextend<SVE_FULL_HSDI:mode><SVE_FULL_F:mode>_relaxed)
15647         (*cond_<optab>_nonextend<SVE_FULL_HSDI:mode><SVE_FULL_F:mode>_strict)
15648         (*cond_<optab>_extend<VNx4SI_ONLY:mode><VNx2DF_ONLY:mode>)
15649         (@aarch64_sve_<optab>_trunc<SVE_FULL_SDF:mode><SVE_FULL_HSF:mode>)
15650         (*cond_<optab>_trunc<SVE_FULL_SDF:mode><SVE_FULL_HSF:mode>)
15651         (@aarch64_sve_<optab>_trunc<VNx4SF_ONLY:mode><VNx8BF_ONLY:mode>)
15652         (*cond_<optab>_trunc<VNx4SF_ONLY:mode><VNx8BF_ONLY:mode>)
15653         (@aarch64_sve_<optab>_nontrunc<SVE_FULL_HSF:mode><SVE_FULL_SDF:mode>)
15654         (*cond_<optab>_nontrunc<SVE_FULL_HSF:mode><SVE_FULL_SDF:mode>)
15655         (@aarch64_brk<brk_op>, *aarch64_sve_<inc_dec><mode>_cntp): Update
15656         to new syntax.
15657         * config/aarch64/aarch64-simd.md (aarch64_simd_dup<mode>)
15658         (load_pair<DREG:mode><DREG2:mode>)
15659         (vec_store_pair<DREG:mode><DREG2:mode>, aarch64_simd_stp<mode>)
15660         (aarch64_simd_mov_from_<mode>low)
15661         (aarch64_simd_mov_from_<mode>high, and<mode>3<vczle><vczbe>)
15662         (ior<mode>3<vczle><vczbe>, aarch64_simd_ashr<mode><vczle><vczbe>)
15663         (aarch64_simd_bsl<mode>_internal<vczle><vczbe>)
15664         (*aarch64_simd_bsl<mode>_alt<vczle><vczbe>)
15665         (aarch64_simd_bsldi_internal, aarch64_simd_bsldi_alt)
15666         (store_pair_lanes<mode>, *aarch64_combine_internal<mode>)
15667         (*aarch64_combine_internal_be<mode>, *aarch64_combinez<mode>)
15668         (*aarch64_combinez_be<mode>)
15669         (aarch64_cm<optab><mode><vczle><vczbe>, *aarch64_cm<optab>di)
15670         (aarch64_cm<optab><mode><vczle><vczbe>, *aarch64_mov<mode>)
15671         (*aarch64_be_mov<mode>, *aarch64_be_movoi): Update to new syntax.
15673 2023-10-03  Andrea Corallo  <andrea.corallo@arm.com>
15675         * gensupport.cc (convert_syntax): Skip spaces before "cons:"
15676         in new compact pattern syntax.
15678 2023-10-03  Richard Sandiford  <richard.sandiford@arm.com>
15680         * gensupport.cc (convert_syntax): Updated to support unordered
15681         constraints in compact syntax.
15683 2023-10-02  Michael Meissner  <meissner@linux.ibm.com>
15685         * config/rs6000/rs6000.md (UNSPEC_COPYSIGN): Delete.
15686         (copysign<mode>3_fcpsg): Use copysign RTL instead of UNSPEC.
15687         (copysign<mode>3_hard): Likewise.
15688         (copysign<mode>3_soft): Likewise.
15689         * config/rs6000/vector.md (vector_copysign<mode>3): Use copysign RTL
15690         instead of UNSPEC.
15691         * config/rs6000/vsx.md (vsx_copysign<mode>3): Use copysign RTL instead
15692         of UNSPEC.
15694 2023-10-02  David Malcolm  <dmalcolm@redhat.com>
15696         * diagnostic-format-json.cc (toplevel_array): Remove global in
15697         favor of json_output_format::m_top_level_array.
15698         (cur_group): Likewise, for json_output_format::m_cur_group.
15699         (cur_children_array): Likewise, for
15700         json_output_format::m_cur_children_array.
15701         (class json_output_format): New.
15702         (json_begin_diagnostic): Remove, in favor of
15703         json_output_format::on_begin_diagnostic.
15704         (json_end_diagnostic): Convert to...
15705         (json_output_format::on_end_diagnostic): ...this.
15706         (json_begin_group): Remove, in favor of
15707         json_output_format::on_begin_group.
15708         (json_end_group): Remove, in favor of
15709         json_output_format::on_end_group.
15710         (json_flush_to_file): Remove, in favor of
15711         json_output_format::flush_to_file.
15712         (json_stderr_final_cb): Remove, in favor of json_output_format
15713         dtor.
15714         (json_output_base_file_name): Remove global.
15715         (class json_stderr_output_format): New.
15716         (json_file_final_cb): Remove.
15717         (class json_file_output_format): New.
15718         (json_emit_diagram): Remove.
15719         (diagnostic_output_format_init_json): Update.
15720         (diagnostic_output_format_init_json_file): Update.
15721         * diagnostic-format-sarif.cc (the_builder): Remove this global,
15722         moving to a field of the sarif_output_format.
15723         (sarif_builder::maybe_make_artifact_content_object): Use the
15724         context's m_file_cache.
15725         (get_source_lines): Convert to...
15726         (sarif_builder::get_source_lines): ...this, using context's
15727         m_file_cache.
15728         (sarif_begin_diagnostic): Remove, in favor of
15729         sarif_output_format::on_begin_diagnostic.
15730         (sarif_end_diagnostic): Remove, in favor of
15731         sarif_output_format::on_end_diagnostic.
15732         (sarif_begin_group): Remove, in favor of
15733         sarif_output_format::on_begin_group.
15734         (sarif_end_group): Remove, in favor of
15735         sarif_output_format::on_end_group.
15736         (sarif_flush_to_file): Delete.
15737         (sarif_stderr_final_cb): Delete.
15738         (sarif_output_base_file_name): Delete.
15739         (sarif_file_final_cb): Delete.
15740         (class sarif_output_format): New.
15741         (sarif_emit_diagram): Delete.
15742         (class sarif_stream_output_format): New.
15743         (class sarif_file_output_format): New.
15744         (diagnostic_output_format_init_sarif): Update.
15745         (diagnostic_output_format_init_sarif_stderr): Update.
15746         (diagnostic_output_format_init_sarif_file): Update.
15747         (diagnostic_output_format_init_sarif_stream): Update.
15748         * diagnostic-show-locus.cc (diagnostic_show_locus): Update.
15749         * diagnostic.cc (default_diagnostic_final_cb): Delete, moving to
15750         diagnostic_text_output_format's dtor.
15751         (diagnostic_initialize): Update, making a new instance of
15752         diagnostic_text_output_format.
15753         (diagnostic_finish): Delete m_output_format, rather than calling
15754         final_cb.
15755         (diagnostic_report_diagnostic): Assert that m_output_format is
15756         non-NULL.  Replace call to begin_group_cb with call to
15757         m_output_format->on_begin_group.  Replace call to
15758         diagnostic_starter with call to
15759         m_output_format->on_begin_diagnostic.  Replace call to
15760         diagnostic_finalizer with call to
15761         m_output_format->on_end_diagnostic.
15762         (diagnostic_emit_diagram): Replace both optional call to
15763         m_diagrams.m_emission_cb and default implementation with call to
15764         m_output_format->on_diagram.  Move default implementation to
15765         diagnostic_text_output_format::on_diagram.
15766         (auto_diagnostic_group::~auto_diagnostic_group): Replace call to
15767         end_group_cb with call to m_output_format->on_end_group.
15768         (diagnostic_text_output_format::~diagnostic_text_output_format):
15769         New, based on default_diagnostic_final_cb.
15770         (diagnostic_text_output_format::on_begin_diagnostic): New, based
15771         on code from diagnostic_report_diagnostic.
15772         (diagnostic_text_output_format::on_end_diagnostic): Likewise.
15773         (diagnostic_text_output_format::on_diagram): New, based on code
15774         from diagnostic_emit_diagram.
15775         * diagnostic.h (class diagnostic_output_format): New.
15776         (class diagnostic_text_output_format): New.
15777         (diagnostic_context::begin_diagnostic): Move to...
15778         (diagnostic_context::m_text_callbacks::begin_diagnostic): ...here.
15779         (diagnostic_context::start_span): Move to...
15780         (diagnostic_context::m_text_callbacks::start_span): ...here.
15781         (diagnostic_context::end_diagnostic): Move to...
15782         (diagnostic_context::m_text_callbacks::end_diagnostic): ...here.
15783         (diagnostic_context::begin_group_cb): Remove, in favor of
15784         m_output_format->on_begin_group.
15785         (diagnostic_context::end_group_cb): Remove, in favor of
15786         m_output_format->on_end_group.
15787         (diagnostic_context::final_cb): Remove, in favor of
15788         m_output_format's dtor.
15789         (diagnostic_context::m_output_format): New field.
15790         (diagnostic_context::m_diagrams.m_emission_cb): Remove, in favor
15791         of m_output_format->on_diagram.
15792         (diagnostic_starter): Update.
15793         (diagnostic_finalizer): Update.
15794         (diagnostic_output_format_init_sarif_stream): New.
15795         * input.cc (location_get_source_line): Move implementation apart from
15796         call to diagnostic_file_cache_init to...
15797         (file_cache::get_source_line): ...this new function...
15798         (location_get_source_line): ...and reintroduce, rewritten in terms of
15799         file_cache::get_source_line.
15800         (get_source_file_content): Likewise, refactor into...
15801         (file_cache::get_source_file_content): ...this new function.
15802         * input.h (file_cache::get_source_line): New decl.
15803         (file_cache::get_source_file_content): New decl.
15804         * selftest-diagnostic.cc
15805         (test_diagnostic_context::test_diagnostic_context): Update.
15806         * tree-diagnostic-path.cc (event_range::print): Update for
15807         change to diagnostic_context's start_span callback.
15809 2023-10-02  David Malcolm  <dmalcolm@redhat.com>
15811         * diagnostic-show-locus.cc: Update for reorganization of
15812         source-printing fields of diagnostic_context.
15813         * diagnostic.cc (diagnostic_set_caret_max_width): Likewise.
15814         (diagnostic_initialize): Likewise.
15815         * diagnostic.h (diagnostic_context::show_caret): Move to...
15816         (diagnostic_context::m_source_printing::enabled): ...here.
15817         (diagnostic_context::caret_max_width): Move to...
15818         (diagnostic_context::m_source_printing::max_width): ...here.
15819         (diagnostic_context::caret_chars): Move to...
15820         (diagnostic_context::m_source_printing::caret_chars): ...here.
15821         (diagnostic_context::colorize_source_p): Move to...
15822         (diagnostic_context::m_source_printing::colorize_source_p): ...here.
15823         (diagnostic_context::show_labels_p): Move to...
15824         (diagnostic_context::m_source_printing::show_labels_p): ...here.
15825         (diagnostic_context::show_line_numbers_p): Move to...
15826         (diagnostic_context::m_source_printing::show_line_numbers_p): ...here.
15827         (diagnostic_context::min_margin_width): Move to...
15828         (diagnostic_context::m_source_printing::min_margin_width): ...here.
15829         (diagnostic_context::show_ruler_p): Move to...
15830         (diagnostic_context::m_source_printing::show_ruler_p): ...here.
15831         (diagnostic_same_line): Update for above changes.
15832         * opts.cc (common_handle_option): Update for reorganization of
15833         source-printing fields of diagnostic_context.
15834         * selftest-diagnostic.cc
15835         (test_diagnostic_context::test_diagnostic_context): Likewise.
15836         * toplev.cc (general_init): Likewise.
15837         * tree-diagnostic-path.cc (struct event_range): Likewise.
15839 2023-10-02  David Malcolm  <dmalcolm@redhat.com>
15841         * diagnostic.cc (diagnostic_initialize): Initialize
15842         set_locations_cb to nullptr.
15844 2023-10-02  Wilco Dijkstra  <wilco.dijkstra@arm.com>
15846         PR target/111235
15847         * config/arm/constraints.md: Remove Pf constraint.
15848         * config/arm/sync.md (arm_atomic_load<mode>): Add new pattern.
15849         (arm_atomic_load_acquire<mode>): Likewise.
15850         (arm_atomic_store<mode>): Likewise.
15851         (arm_atomic_store_release<mode>): Likewise.
15852         (atomic_load<mode>): Switch patterns to define_expand.
15853         (atomic_store<mode>): Likewise.
15854         (arm_atomic_loaddi2_ldrd): Remove predication.
15855         (arm_load_exclusive<mode>): Likewise.
15856         (arm_load_acquire_exclusive<mode>): Likewise.
15857         (arm_load_exclusivesi): Likewise.
15858         (arm_load_acquire_exclusivesi): Likewise.
15859         (arm_load_exclusivedi): Likewise.
15860         (arm_load_acquire_exclusivedi): Likewise.
15861         (arm_store_exclusive<mode>): Likewise.
15862         (arm_store_release_exclusivedi): Likewise.
15863         (arm_store_release_exclusive<mode>): Likewise.
15864         * config/arm/unspecs.md: Add VUNSPEC_LDR and VUNSPEC_STR.
15866 2023-10-02  Tamar Christina  <tamar.christina@arm.com>
15868         Revert:
15869         2023-10-02  Tamar Christina  <tamar.christina@arm.com>
15871         PR tree-optimization/109154
15872         * tree-if-conv.cc (INCLUDE_ALGORITHM): Remove.
15873         (cmp_arg_entry): New.
15874         (predicate_scalar_phi): Use it.
15876 2023-10-02  Tamar Christina  <tamar.christina@arm.com>
15878         * config/aarch64/aarch64-simd.md (xorsign<mode>3): Renamed to..
15879         (@xorsign<mode>3): ...This.
15880         * config/aarch64/aarch64.md (xorsign<mode>3): Renamed to...
15881         (@xorsign<mode>3): ..This and emit vectors directly
15882         * config/aarch64/iterators.md (VCONQ): Add SF and DF.
15884 2023-10-02  Tamar Christina  <tamar.christina@arm.com>
15886         * emit-rtl.cc (validate_subreg): Relax subreg rule.
15888 2023-10-02  Tamar Christina  <tamar.christina@arm.com>
15890         PR tree-optimization/109154
15891         * tree-if-conv.cc (INCLUDE_ALGORITHM): Remove.
15892         (cmp_arg_entry): New.
15893         (predicate_scalar_phi): Use it.
15895 2023-10-02  Richard Sandiford  <richard.sandiford@arm.com>
15897         PR bootstrap/111642
15898         * rtl-tests.cc (const_poly_int_tests<N>::run): Use a local
15899         poly_int64 typedef.
15900         * simplify-rtx.cc (simplify_const_poly_int_tests<N>::run): Likewise.
15902 2023-10-02  Joern Rennecke  <joern.rennecke@embecosm.com>
15903             Juzhe-Zhong  <juzhe.zhong@rivai.ai>
15905         * config/riscv/riscv-protos.h (riscv_vector::expand_block_move):
15906         Declare.
15907         * config/riscv/riscv-v.cc (riscv_vector::expand_block_move):
15908         New function.
15909         * config/riscv/riscv.md (cpymemsi): Use riscv_vector::expand_block_move.
15910         Change to ..
15911         (cpymem<P:mode>) .. this.
15913 2023-10-01  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
15915         * combine.cc (simplify_compare_const): Properly handle unsigned
15916         constants while narrowing comparison of memory and constants.
15918 2023-10-01  Feng Wang  <wangfeng@eswincomputing.com>
15920         * config/riscv/riscv-opts.h (MASK_ZICSR): Delete.
15921         (MASK_ZIFENCEI): Delete;
15922         (MASK_ZIHINTNTL): Ditto.
15923         (MASK_ZIHINTPAUSE): Ditto.
15924         (TARGET_ZICSR): Ditto.
15925         (TARGET_ZIFENCEI): Ditto.
15926         (TARGET_ZIHINTNTL): Ditto.
15927         (TARGET_ZIHINTPAUSE): Ditto.
15928         (MASK_ZAWRS): Ditto.
15929         (TARGET_ZAWRS): Ditto.
15930         (MASK_ZBA): Ditto.
15931         (MASK_ZBB): Ditto.
15932         (MASK_ZBC): Ditto.
15933         (MASK_ZBS): Ditto.
15934         (TARGET_ZBA): Ditto.
15935         (TARGET_ZBB): Ditto.
15936         (TARGET_ZBC): Ditto.
15937         (TARGET_ZBS): Ditto.
15938         (MASK_ZFINX): Ditto.
15939         (MASK_ZDINX): Ditto.
15940         (MASK_ZHINX): Ditto.
15941         (MASK_ZHINXMIN): Ditto.
15942         (TARGET_ZFINX): Ditto.
15943         (TARGET_ZDINX): Ditto.
15944         (TARGET_ZHINX): Ditto.
15945         (TARGET_ZHINXMIN): Ditto.
15946         (MASK_ZBKB): Ditto.
15947         (MASK_ZBKC): Ditto.
15948         (MASK_ZBKX): Ditto.
15949         (MASK_ZKNE): Ditto.
15950         (MASK_ZKND): Ditto.
15951         (MASK_ZKNH): Ditto.
15952         (MASK_ZKR): Ditto.
15953         (MASK_ZKSED): Ditto.
15954         (MASK_ZKSH): Ditto.
15955         (MASK_ZKT): Ditto.
15956         (TARGET_ZBKB): Ditto.
15957         (TARGET_ZBKC): Ditto.
15958         (TARGET_ZBKX): Ditto.
15959         (TARGET_ZKNE): Ditto.
15960         (TARGET_ZKND): Ditto.
15961         (TARGET_ZKNH): Ditto.
15962         (TARGET_ZKR): Ditto.
15963         (TARGET_ZKSED): Ditto.
15964         (TARGET_ZKSH): Ditto.
15965         (TARGET_ZKT): Ditto.
15966         (MASK_ZTSO): Ditto.
15967         (TARGET_ZTSO): Ditto.
15968         (MASK_VECTOR_ELEN_32): Ditto.
15969         (MASK_VECTOR_ELEN_64): Ditto.
15970         (MASK_VECTOR_ELEN_FP_32): Ditto.
15971         (MASK_VECTOR_ELEN_FP_64): Ditto.
15972         (MASK_VECTOR_ELEN_FP_16): Ditto.
15973         (TARGET_VECTOR_ELEN_32): Ditto.
15974         (TARGET_VECTOR_ELEN_64): Ditto.
15975         (TARGET_VECTOR_ELEN_FP_32): Ditto.
15976         (TARGET_VECTOR_ELEN_FP_64): Ditto.
15977         (TARGET_VECTOR_ELEN_FP_16): Ditto.
15978         (MASK_ZVBB): Ditto.
15979         (MASK_ZVBC): Ditto.
15980         (TARGET_ZVBB): Ditto.
15981         (TARGET_ZVBC): Ditto.
15982         (MASK_ZVKG): Ditto.
15983         (MASK_ZVKNED): Ditto.
15984         (MASK_ZVKNHA): Ditto.
15985         (MASK_ZVKNHB): Ditto.
15986         (MASK_ZVKSED): Ditto.
15987         (MASK_ZVKSH): Ditto.
15988         (MASK_ZVKN): Ditto.
15989         (MASK_ZVKNC): Ditto.
15990         (MASK_ZVKNG): Ditto.
15991         (MASK_ZVKS): Ditto.
15992         (MASK_ZVKSC): Ditto.
15993         (MASK_ZVKSG): Ditto.
15994         (MASK_ZVKT): Ditto.
15995         (TARGET_ZVKG): Ditto.
15996         (TARGET_ZVKNED): Ditto.
15997         (TARGET_ZVKNHA): Ditto.
15998         (TARGET_ZVKNHB): Ditto.
15999         (TARGET_ZVKSED): Ditto.
16000         (TARGET_ZVKSH): Ditto.
16001         (TARGET_ZVKN): Ditto.
16002         (TARGET_ZVKNC): Ditto.
16003         (TARGET_ZVKNG): Ditto.
16004         (TARGET_ZVKS): Ditto.
16005         (TARGET_ZVKSC): Ditto.
16006         (TARGET_ZVKSG): Ditto.
16007         (TARGET_ZVKT): Ditto.
16008         (MASK_ZVL32B): Ditto.
16009         (MASK_ZVL64B): Ditto.
16010         (MASK_ZVL128B): Ditto.
16011         (MASK_ZVL256B): Ditto.
16012         (MASK_ZVL512B): Ditto.
16013         (MASK_ZVL1024B): Ditto.
16014         (MASK_ZVL2048B): Ditto.
16015         (MASK_ZVL4096B): Ditto.
16016         (MASK_ZVL8192B): Ditto.
16017         (MASK_ZVL16384B): Ditto.
16018         (MASK_ZVL32768B): Ditto.
16019         (MASK_ZVL65536B): Ditto.
16020         (TARGET_ZVL32B): Ditto.
16021         (TARGET_ZVL64B): Ditto.
16022         (TARGET_ZVL128B): Ditto.
16023         (TARGET_ZVL256B): Ditto.
16024         (TARGET_ZVL512B): Ditto.
16025         (TARGET_ZVL1024B): Ditto.
16026         (TARGET_ZVL2048B): Ditto.
16027         (TARGET_ZVL4096B): Ditto.
16028         (TARGET_ZVL8192B): Ditto.
16029         (TARGET_ZVL16384B): Ditto.
16030         (TARGET_ZVL32768B): Ditto.
16031         (TARGET_ZVL65536B): Ditto.
16032         (MASK_ZICBOZ): Ditto.
16033         (MASK_ZICBOM): Ditto.
16034         (MASK_ZICBOP): Ditto.
16035         (TARGET_ZICBOZ): Ditto.
16036         (TARGET_ZICBOM): Ditto.
16037         (TARGET_ZICBOP): Ditto.
16038         (MASK_ZICOND): Ditto.
16039         (TARGET_ZICOND): Ditto.
16040         (MASK_ZFA): Ditto.
16041         (TARGET_ZFA): Ditto.
16042         (MASK_ZFHMIN): Ditto.
16043         (MASK_ZFH): Ditto.
16044         (MASK_ZVFHMIN): Ditto.
16045         (MASK_ZVFH): Ditto.
16046         (TARGET_ZFHMIN): Ditto.
16047         (TARGET_ZFH): Ditto.
16048         (TARGET_ZVFHMIN): Ditto.
16049         (TARGET_ZVFH): Ditto.
16050         (MASK_ZMMUL): Ditto.
16051         (TARGET_ZMMUL): Ditto.
16052         (MASK_ZCA): Ditto.
16053         (MASK_ZCB): Ditto.
16054         (MASK_ZCE): Ditto.
16055         (MASK_ZCF): Ditto.
16056         (MASK_ZCD): Ditto.
16057         (MASK_ZCMP): Ditto.
16058         (MASK_ZCMT): Ditto.
16059         (TARGET_ZCA): Ditto.
16060         (TARGET_ZCB): Ditto.
16061         (TARGET_ZCE): Ditto.
16062         (TARGET_ZCF): Ditto.
16063         (TARGET_ZCD): Ditto.
16064         (TARGET_ZCMP): Ditto.
16065         (TARGET_ZCMT): Ditto.
16066         (MASK_SVINVAL): Ditto.
16067         (MASK_SVNAPOT): Ditto.
16068         (TARGET_SVINVAL): Ditto.
16069         (TARGET_SVNAPOT): Ditto.
16070         (MASK_XTHEADBA): Ditto.
16071         (MASK_XTHEADBB): Ditto.
16072         (MASK_XTHEADBS): Ditto.
16073         (MASK_XTHEADCMO): Ditto.
16074         (MASK_XTHEADCONDMOV): Ditto.
16075         (MASK_XTHEADFMEMIDX): Ditto.
16076         (MASK_XTHEADFMV): Ditto.
16077         (MASK_XTHEADINT): Ditto.
16078         (MASK_XTHEADMAC): Ditto.
16079         (MASK_XTHEADMEMIDX): Ditto.
16080         (MASK_XTHEADMEMPAIR): Ditto.
16081         (MASK_XTHEADSYNC): Ditto.
16082         (TARGET_XTHEADBA): Ditto.
16083         (TARGET_XTHEADBB): Ditto.
16084         (TARGET_XTHEADBS): Ditto.
16085         (TARGET_XTHEADCMO): Ditto.
16086         (TARGET_XTHEADCONDMOV): Ditto.
16087         (TARGET_XTHEADFMEMIDX): Ditto.
16088         (TARGET_XTHEADFMV): Ditto.
16089         (TARGET_XTHEADINT): Ditto.
16090         (TARGET_XTHEADMAC): Ditto.
16091         (TARGET_XTHEADMEMIDX): Ditto.
16092         (TARGET_XTHEADMEMPAIR): Ditto.
16093         (TARGET_XTHEADSYNC): Ditto.
16094         (MASK_XVENTANACONDOPS): Ditto.
16095         (TARGET_XVENTANACONDOPS): Ditto.
16096         * config/riscv/riscv.opt: Add new Mask defination.
16097         * doc/options.texi: Add explanation for this new usage.
16098         * opt-functions.awk: Add new function to find the index
16099         of target variable from extra_target_vars.
16100         * opt-read.awk: Add new function to store the Mask flags.
16101         * opth-gen.awk: Add new function to output the defination of
16102         Mask Macro and Target Macro.
16104 2023-10-01  Joern Rennecke  <joern.rennecke@embecosm.com>
16105             Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16106             Juzhe-Zhong   <juzhe.zhong@rivai.ai>
16108         PR target/111566
16109         * config/riscv/riscv-protos.h (riscv_vector::legitimize_move):
16110         Change second parameter to rtx *.
16111         * config/riscv/riscv-v.cc (risv_vector::legitimize_move): Likewise.
16112         * config/riscv/vector.md: Changed callers of
16113         riscv_vector::legitimize_move.
16114         (*mov<mode>_mem_to_mem): Remove.
16116 2023-09-30  Jakub Jelinek  <jakub@redhat.com>
16118         PR target/111649
16119         * config/riscv/riscv-vsetvl.cc (vector_infos_manager::vector_infos_manager):
16120         Replace safe_grow with safe_grow_cleared.
16122 2023-09-30  Jakub Jelinek  <jakub@redhat.com>
16124         * gimple-match-head.cc (gimple_bitwise_inverted_equal_p): Fix a pasto
16125         in function comment.
16127 2023-09-30  Jakub Jelinek  <jakub@redhat.com>
16129         PR middle-end/111625
16130         PR middle-end/111637
16131         * gimple-lower-bitint.cc (range_to_prec): Use prec or -prec if
16132         r.undefined_p ().
16133         (bitint_large_huge::handle_operand_addr): For uninitialized operands
16134         use limb_prec or -limb_prec precision.
16136 2023-09-30  Jakub Jelinek  <jakub@redhat.com>
16138         * vec.h (quick_grow): Uncomment static_assert.
16140 2023-09-30  Jivan Hakobyan  <jivanhakobyan9@gmail.com>
16142         * config/riscv/bitmanip.md (*<optab>_not_const<mode>): Added type attribute
16144 2023-09-29  Xiao Zeng  <zengxiao@eswincomputing.com>
16146         * config/riscv/riscv.cc (riscv_rtx_costs): Better handle costing
16147         SETs when the outer code is INSN.
16149 2023-09-29  Jivan Hakobyan  <jivanhakobyan9@gmail.com>
16151         * config/riscv/bitmanip.md (*<optab>_not_const<mode>): New split
16152         pattern.
16154 2023-09-29  Richard Sandiford  <richard.sandiford@arm.com>
16156         * poly-int.h (poly_int_pod): Delete.
16157         (poly_coeff_traits::init_cast): New type.
16158         (poly_int_full, poly_int_hungry, poly_int_fullness): New structures.
16159         (poly_int): Replace constructors that take 1 and 2 coefficients with
16160         a general one that takes an arbitrary number of coefficients.
16161         Delegate initialization to two new private constructors, one of
16162         which uses the coefficients as-is and one of which adds an extra
16163         zero of the appropriate type (and precision, where applicable).
16164         (gt_ggc_mx, gt_pch_nx): Operate on poly_ints rather than poly_int_pods.
16165         * poly-int-types.h (poly_uint16_pod, poly_int64_pod, poly_uint64_pod)
16166         (poly_offset_int_pod, poly_wide_int_pod, poly_widest_int_pod): Delete.
16167         * gengtype.cc (main): Don't register poly_int64_pod.
16168         * calls.cc (initialize_argument_information): Use poly_int rather
16169         than poly_int_pod.
16170         (combine_pending_stack_adjustment_and_call): Likewise.
16171         * config/aarch64/aarch64.cc (pure_scalable_type_info): Likewise.
16172         * data-streamer.h (bp_unpack_poly_value): Likewise.
16173         * dwarf2cfi.cc (struct dw_trace_info): Likewise.
16174         (struct queued_reg_save): Likewise.
16175         * dwarf2out.h (struct dw_cfa_location): Likewise.
16176         * emit-rtl.h (struct incoming_args): Likewise.
16177         (struct rtl_data): Likewise.
16178         * expr.cc (get_bit_range): Likewise.
16179         (get_inner_reference): Likewise.
16180         * expr.h (get_bit_range): Likewise.
16181         * fold-const.cc (split_address_to_core_and_offset): Likewise.
16182         (ptr_difference_const): Likewise.
16183         * fold-const.h (ptr_difference_const): Likewise.
16184         * function.cc (try_fit_stack_local): Likewise.
16185         (instantiate_new_reg): Likewise.
16186         * function.h (struct expr_status): Likewise.
16187         (struct args_size): Likewise.
16188         * genmodes.cc (ZERO_COEFFS): Likewise.
16189         (mode_size_inline): Likewise.
16190         (mode_nunits_inline): Likewise.
16191         (emit_mode_precision): Likewise.
16192         (emit_mode_size): Likewise.
16193         (emit_mode_nunits): Likewise.
16194         * gimple-fold.cc (get_base_constructor): Likewise.
16195         * gimple-ssa-store-merging.cc (struct symbolic_number): Likewise.
16196         * inchash.h (class hash): Likewise.
16197         * ipa-modref-tree.cc (modref_access_node::dump): Likewise.
16198         * ipa-modref.cc (modref_access_analysis::merge_call_side_effects):
16199         Likewise.
16200         * ira-int.h (ira_spilled_reg_stack_slot): Likewise.
16201         * lra-eliminations.cc (self_elim_offsets): Likewise.
16202         * machmode.h (mode_size, mode_precision, mode_nunits): Likewise.
16203         * omp-low.cc (omplow_simd_context): Likewise.
16204         * pretty-print.cc (pp_wide_integer): Likewise.
16205         * pretty-print.h (pp_wide_integer): Likewise.
16206         * reload.cc (struct decomposition): Likewise.
16207         * reload.h (struct reload): Likewise.
16208         * reload1.cc (spill_stack_slot_width): Likewise.
16209         (struct elim_table): Likewise.
16210         (offsets_at): Likewise.
16211         (init_eliminable_invariants): Likewise.
16212         * rtl.h (union rtunion): Likewise.
16213         (poly_int_rtx_p): Likewise.
16214         (strip_offset): Likewise.
16215         (strip_offset_and_add): Likewise.
16216         * rtlanal.cc (strip_offset): Likewise.
16217         * tree-dfa.cc (get_ref_base_and_extent): Likewise.
16218         (get_addr_base_and_unit_offset_1): Likewise.
16219         (get_addr_base_and_unit_offset): Likewise.
16220         * tree-dfa.h (get_ref_base_and_extent): Likewise.
16221         (get_addr_base_and_unit_offset_1): Likewise.
16222         (get_addr_base_and_unit_offset): Likewise.
16223         * tree-ssa-loop-ivopts.cc (struct iv_use): Likewise.
16224         (strip_offset): Likewise.
16225         * tree-ssa-sccvn.h (struct vn_reference_op_struct): Likewise.
16226         * tree.cc (ptrdiff_tree_p): Likewise.
16227         * tree.h (poly_int_tree_p): Likewise.
16228         (ptrdiff_tree_p): Likewise.
16229         (get_inner_reference): Likewise.
16231 2023-09-29  John David Anglin  <danglin@gcc.gnu.org>
16233         * config/pa/pa.md (memory_barrier): Revise comment.
16234         (memory_barrier_64, memory_barrier_32): Use ldcw,co on PA 2.0.
16235         * config/pa/pa.opt (coherent-ldcw): Change default to disabled.
16237 2023-09-29  Jakub Jelinek  <jakub@redhat.com>
16239         * vec.h (quick_insert, ordered_remove, unordered_remove,
16240         block_remove, qsort, sort, stablesort, quick_grow): Guard
16241         std::is_trivially_{copyable,default_constructible} and
16242         vec_detail::is_trivially_copyable_or_pair static assertions
16243         with GCC_VERSION >= 5000.
16244         (vec_detail::is_trivially_copyable_or_pair): Guard definition
16245         with GCC_VERSION >= 5000.
16247 2023-09-29  Manos Anagnostakis  <manos.anagnostakis@vrull.eu>
16249         * config/aarch64/aarch64-opts.h (enum aarch64_ldp_policy): Removed.
16250         (enum aarch64_ldp_stp_policy): Merged enums aarch64_ldp_policy
16251         and aarch64_stp_policy to aarch64_ldp_stp_policy.
16252         (enum aarch64_stp_policy): Removed.
16253         * config/aarch64/aarch64-protos.h (struct tune_params): Removed
16254         aarch64_ldp_policy_model and aarch64_stp_policy_model enum types
16255         and left only the definitions to the aarch64-opts one.
16256         * config/aarch64/aarch64.cc (aarch64_parse_ldp_policy): Removed.
16257         (aarch64_parse_stp_policy): Removed.
16258         (aarch64_override_options_internal): Removed calls to parsing
16259         functions and added obvious direct assignments.
16260         (aarch64_mem_ok_with_ldpstp_policy_model): Improved
16261         code quality based on the new changes.
16262         * config/aarch64/aarch64.opt: Use single enum type
16263         aarch64_ldp_stp_policy for both ldp and stp options.
16265 2023-09-29  Richard Biener  <rguenther@suse.de>
16267         PR tree-optimization/111583
16268         * tree-loop-distribution.cc (find_single_drs): Ensure the
16269         load/store are always executed.
16271 2023-09-29  Jakub Jelinek  <jakub@redhat.com>
16273         * tree-vect-patterns.cc (vect_recog_over_widening_pattern): Use
16274         quick_grow_cleared method on unprom rather than quick_grow.
16276 2023-09-29  Sergei Trofimovich  <siarheit@google.com>
16278         PR middle-end/111505
16279         * ggc-common.cc (ggc_zero_out_root_pointers, ggc_common_finalize):
16280         Add new helper. Use helper instead of memset() to wipe out pointers.
16282 2023-09-29  Richard Sandiford  <richard.sandiford@arm.com>
16284         * builtins.h (c_readstr): Take a fixed_size_mode rather than a
16285         scalar_int_mode.
16286         * builtins.cc (c_readstr): Likewise.  Build a local array of
16287         bytes and use native_decode_rtx to get the rtx image.
16288         (builtin_memcpy_read_str): Simplify accordingly.
16289         (builtin_strncpy_read_str): Likewise.
16290         (builtin_memset_read_str): Likewise.
16291         (builtin_memset_gen_str): Likewise.
16292         * expr.cc (string_cst_read_str): Likewise.
16294 2023-09-29  Jakub Jelinek  <jakub@redhat.com>
16296         * tree-ssa-loop-im.cc (tree_ssa_lim_initialize): Use quick_grow_cleared
16297         instead of quick_grow on vec<bitmap_head> members.
16298         * cfganal.cc (control_dependences::control_dependences): Likewise.
16299         * rtl-ssa/blocks.cc (function_info::build_info::build_info): Likewise.
16300         (function_info::place_phis): Use safe_grow_cleared instead of safe_grow
16301         on auto_vec<bitmap_head> vars.
16302         * tree-ssa-live.cc (compute_live_vars): Use quick_grow_cleared instead
16303         of quick_grow on vec<bitmap_head> var.
16305 2023-09-28  Vladimir N. Makarov  <vmakarov@redhat.com>
16307         Revert:
16308         2023-09-14  Vladimir N. Makarov  <vmakarov@redhat.com>
16310         * ira-costs.cc (find_costs_and_classes): Decrease memory cost
16311         by equiv savings.
16313 2023-09-28  Wilco Dijkstra  <wilco.dijkstra@arm.com>
16315         PR target/111121
16316         * config/aarch64/aarch64.md (aarch64_movmemdi): Add new expander.
16317         (movmemdi): Call aarch64_expand_cpymem_mops for correct expansion.
16318         * config/aarch64/aarch64.cc (aarch64_expand_cpymem_mops): Add support
16319         for memmove.
16320         * config/aarch64/aarch64-protos.h (aarch64_expand_cpymem_mops): Add new
16321         function.
16323 2023-09-28  Pan Li  <pan2.li@intel.com>
16325         PR target/111506
16326         * config/riscv/autovec.md (<float_cvt><mode><vnnconvert>2):
16327         New pattern.
16328         * config/riscv/vector-iterators.md: New iterator.
16330 2023-09-28  Vladimir N. Makarov  <vmakarov@redhat.com>
16332         * rtl.h (lra_in_progress): Change type to bool.
16333         (ira_in_progress): Add new extern.
16334         * ira.cc (ira_in_progress): New global.
16335         (pass_ira::execute): Set up ira_in_progress.
16336         * lra.cc: (lra_in_progress): Change type to bool and initialize.
16337         (lra): Use bool values for lra_in_progress.
16338         * lra-eliminations.cc (init_elim_table): Ditto.
16340 2023-09-28  Richard Biener  <rguenther@suse.de>
16342         PR target/111600
16343         * gimple-ssa-warn-access.cc (pass_waccess::check_dangling_stores):
16344         Use a heap allocated worklist for CFG traversal instead of
16345         recursion.
16347 2023-09-28  Jakub Jelinek  <jakub@redhat.com>
16348             Jonathan Wakely  <jwakely@redhat.com>
16350         * vec.h: Mention in file comment limited support for non-POD types
16351         in some operations.
16352         (vec_destruct): New function template.
16353         (release): Use it for non-trivially destructible T.
16354         (truncate): Likewise.
16355         (quick_push): Perform a placement new into slot
16356         instead of assignment.
16357         (pop): For non-trivially destructible T return void
16358         rather than T & and destruct the popped element.
16359         (quick_insert, ordered_remove): Note that they aren't suitable
16360         for non-trivially copyable types.  Add static_asserts for that.
16361         (block_remove): Assert T is trivially copyable.
16362         (vec_detail::is_trivially_copyable_or_pair): New trait.
16363         (qsort, sort, stablesort): Assert T is trivially copyable or
16364         std::pair with both trivally copyable types.
16365         (quick_grow): Add assert T is trivially default constructible,
16366         for now commented out.
16367         (quick_grow_cleared): Don't call quick_grow, instead inline it
16368         by hand except for the new static_assert.
16369         (gt_ggc_mx): Assert T is trivially destructable.
16370         (auto_vec::operator=): Formatting fixes.
16371         (auto_vec::auto_vec): Likewise.
16372         (vec_safe_grow_cleared): Don't call vec_safe_grow, instead inline
16373         it manually and call quick_grow_cleared method rather than quick_grow.
16374         (safe_grow_cleared): Likewise.
16375         * edit-context.cc (class line_event): Move definition earlier.
16376         * tree-ssa-loop-im.cc (seq_entry::seq_entry): Make default ctor
16377         defaulted.
16378         * ipa-fnsummary.cc (evaluate_properties_for_edge): Use
16379         safe_grow_cleared instead of safe_grow followed by placement new
16380         constructing the elements.
16382 2023-09-28  Richard Sandiford  <richard.sandiford@arm.com>
16384         * dwarf2out.cc (mem_loc_descriptor): Remove unused variables.
16385         * tree-affine.cc (expr_to_aff_combination): Likewise.
16387 2023-09-28  Richard Biener  <rguenther@suse.de>
16389         PR tree-optimization/111614
16390         * tree-ssa-reassoc.cc (undistribute_bitref_for_vector): Properly
16391         convert the first vector when required.
16393 2023-09-28  xuli  <xuli1@eswincomputing.com>
16395         PR target/111533
16396         * config/riscv/riscv-v.cc (expand_const_vector): Fix bug.
16397         * config/riscv/riscv-vsetvl.cc (anticipatable_occurrence_p): Fix bug.
16399 2023-09-27  Sandra Loosemore  <sandra@codesourcery.com>
16401         * gimple.cc (gimple_copy): Add case GIMPLE_OMP_STRUCTURED_BLOCK.
16403 2023-09-27  Iain Sandoe  <iain@sandoe.co.uk>
16405         PR target/111610
16406         * configure: Regenerate.
16407         * configure.ac: Rename the missing dsymutil case to "DET_UNKNOWN".
16409 2023-09-27  Manos Anagnostakis  <manos.anagnostakis@vrull.eu>
16410             Philipp Tomsich  <philipp.tomsich@vrull.eu>
16411             Manolis Tsamis  <manolis.tsamis@vrull.eu>
16413         * config/aarch64/aarch64-opts.h (enum aarch64_ldp_policy): New
16414         enum type.
16415         (enum aarch64_stp_policy): New enum type.
16416         * config/aarch64/aarch64-protos.h (struct tune_params): Add
16417         appropriate enums for the policies.
16418         (aarch64_mem_ok_with_ldpstp_policy_model): New declaration.
16419         * config/aarch64/aarch64-tuning-flags.def
16420         (AARCH64_EXTRA_TUNING_OPTION): Remove superseded tuning
16421         options.
16422         * config/aarch64/aarch64.cc (aarch64_parse_ldp_policy): New
16423         function to parse ldp-policy parameter.
16424         (aarch64_parse_stp_policy): New function to parse stp-policy parameter.
16425         (aarch64_override_options_internal): Call parsing functions.
16426         (aarch64_mem_ok_with_ldpstp_policy_model): New function.
16427         (aarch64_operands_ok_for_ldpstp): Add call to
16428         aarch64_mem_ok_with_ldpstp_policy_model for parameter-value
16429         check and alignment check and remove superseded ones.
16430         (aarch64_operands_adjust_ok_for_ldpstp): Add call to
16431         aarch64_mem_ok_with_ldpstp_policy_model for parameter-value
16432         check and alignment check and remove superseded ones.
16433         * config/aarch64/aarch64.opt (aarch64-ldp-policy): New param.
16434         (aarch64-stp-policy): New param.
16435         * doc/invoke.texi: Document the parameters accordingly.
16437 2023-09-27  Andre Vieira  <andre.simoesdiasvieira@arm.com>
16439         * tree-data-ref.cc (include calls.h): Add new include.
16440         (get_references_in_stmt): Correctly handle IFN_MASK_CALL.
16442 2023-09-27  Richard Biener  <rguenther@suse.de>
16444         * match.pd (abs (copysign (x, y)) -> abs (x)): New pattern.
16446 2023-09-27  Jakub Jelinek  <jakub@redhat.com>
16448         PR c++/105606
16449         * system.h (BROKEN_VALUE_INITIALIZATION): Don't define.
16450         * vec.h (vec_default_construct): Remove BROKEN_VALUE_INITIALIZATION
16451         workaround.
16452         * function.cc (assign_parm_find_data_types): Likewise.
16454 2023-09-27  Pan Li  <pan2.li@intel.com>
16456         * config/riscv/autovec.md (roundeven<mode>2): New pattern.
16457         * config/riscv/riscv-protos.h (enum insn_flags): New enum type.
16458         (enum insn_type): Ditto.
16459         (expand_vec_roundeven): New func decl.
16460         * config/riscv/riscv-v.cc (expand_vec_roundeven): New func impl.
16462 2023-09-27  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16464         PR target/111590
16465         * dse.cc (find_shift_sequence): Check the mode with access_size exist on the target.
16467 2023-09-27  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16469         * tree-if-conv.cc (is_cond_scalar_reduction): Fix comments.
16471 2023-09-27  Pan Li  <pan2.li@intel.com>
16473         * config/riscv/autovec.md (btrunc<mode>2): New pattern.
16474         * config/riscv/riscv-protos.h (expand_vec_trunc): New func decl.
16475         * config/riscv/riscv-v.cc (emit_vec_cvt_x_f_rtz): New func impl.
16476         (expand_vec_trunc): Ditto.
16478 2023-09-26  Hans-Peter Nilsson  <hp@axis.com>
16480         PR target/107567
16481         PR target/109166
16482         * builtins.cc (expand_builtin) <case BUILT_IN_ATOMIC_TEST_AND_SET>:
16483         Handle failure from expand_builtin_atomic_test_and_set.
16484         * optabs.cc (expand_atomic_test_and_set): When all attempts fail to
16485         generate atomic code through target support, return NULL
16486         instead of emitting non-atomic code.  Also, for code handling
16487         targetm.atomic_test_and_set_trueval != 1, gcc_assert result
16488         from calling emit_store_flag_force instead of returning NULL.
16490 2023-09-26  Andrew MacLeod  <amacleod@redhat.com>
16492         PR tree-optimization/111599
16493         * value-relation.cc (relation_oracle::valid_equivs): Ensure
16494         ssa_name is valid.
16496 2023-09-26  Andrew Pinski  <apinski@marvell.com>
16498         PR tree-optimization/106164
16499         PR tree-optimization/111456
16500         * match.pd (`(A ==/!= B) & (A CMP C)`):
16501         Support an optional cast on the second A.
16502         (`(A ==/!= B) | (A CMP C)`): Likewise.
16504 2023-09-26  Andrew Pinski  <apinski@marvell.com>
16506         PR tree-optimization/111469
16507         * tree-ssa-phiopt.cc (minmax_replacement): Fix
16508         the assumption for the `non-diamond` handling cases
16509         of diamond code.
16511 2023-09-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16513         * match.pd: Optimize COND_ADD reduction pattern.
16515 2023-09-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16517         PR tree-optimization/111594
16518         PR tree-optimization/110660
16519         * match.pd: Optimize COND_LEN_ADD reduction.
16521 2023-09-26  Pan Li  <pan2.li@intel.com>
16523         * config/riscv/autovec.md (round<mode>2): New pattern.
16524         * config/riscv/riscv-protos.h (enum insn_flags): New enum type.
16525         (enum insn_type): Ditto.
16526         (expand_vec_round): New function decl.
16527         * config/riscv/riscv-v.cc (expand_vec_round): New function impl.
16529 2023-09-26  Iain Sandoe  <iain@sandoe.co.uk>
16531         * config/darwin.h (DARWIN_CC1_SPEC): Remove -dynamiclib.
16533 2023-09-26  Tobias Burnus  <tobias@codesourcery.com>
16535         PR middle-end/111547
16536         * doc/invoke.texi (-fopenmp): Mention C++11 [[omp::decl(...)]] syntax.
16537         (-fopenmp-simd): Likewise. Clarify 'loop' directive semantic.
16539 2023-09-26  Pan Li  <pan2.li@intel.com>
16541         * config/riscv/autovec.md (rint<mode>2): New pattern.
16542         * config/riscv/riscv-protos.h (expand_vec_rint): New function decl.
16543         * config/riscv/riscv-v.cc (expand_vec_rint): New function impl.
16545 2023-09-26  Pan Li  <pan2.li@intel.com>
16547         * config/riscv/autovec.md (nearbyint<mode>2): New pattern.
16548         * config/riscv/riscv-protos.h (enum insn_type): New enum.
16549         (expand_vec_nearbyint): New function decl.
16550         * config/riscv/riscv-v.cc (expand_vec_nearbyint): New func impl.
16552 2023-09-26  Pan Li  <pan2.li@intel.com>
16554         * config/riscv/riscv-v.cc (gen_ceil_const_fp): Remove.
16555         (get_fp_rounding_coefficient): Rename.
16556         (gen_floor_const_fp): Remove.
16557         (expand_vec_ceil): Take renamed func.
16558         (expand_vec_floor): Ditto.
16560 2023-09-25  Vladimir N. Makarov  <vmakarov@redhat.com>
16562         PR middle-end/111497
16563         * lra-constraints.cc (lra_constraints): Copy substituted
16564         equivalence.
16565         * lra.cc (lra): Change comment for calling unshare_all_rtl_again.
16567 2023-09-25  Eric Botcazou  <ebotcazou@adacore.com>
16569         * gimple-range-gori.cc (gori_compute::logical_combine): Add missing
16570         return statement in the varying case.
16572 2023-09-25  Xi Ruoyao  <xry111@xry111.site>
16574         * doc/invoke.texi: Update -m[no-]explicit-relocs for r14-4160.
16576 2023-09-25  Andrew Pinski  <apinski@marvell.com>
16578         PR tree-optimization/110386
16579         * gimple-ssa-backprop.cc (strip_sign_op_1): Remove ABSU_EXPR.
16581 2023-09-25  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16583         PR target/111548
16584         * config/riscv/riscv-vsetvl.cc (earliest_pred_can_be_fused_p): Bugfix
16586 2023-09-25  Kewen Lin  <linkw@linux.ibm.com>
16588         PR target/111366
16589         * config/rs6000/rs6000.cc (rs6000_update_ipa_fn_target_info): Skip
16590         empty inline asm.
16592 2023-09-25  Kewen Lin  <linkw@linux.ibm.com>
16594         PR target/111380
16595         * config/rs6000/rs6000.cc (rs6000_can_inline_p): Adopt
16596         target_option_default_node when the callee has no option
16597         attributes, also simplify the existing code accordingly.
16599 2023-09-25  Guo Jie  <guojie@loongson.cn>
16601         * config/loongarch/lasx.md (lasx_vecinit_merge_<LASX:mode>): New
16602         pattern for vector construction.
16603         (vec_set<mode>_internal): Ditto.
16604         (lasx_xvinsgr2vr_<mode256_i_half>_internal): Ditto.
16605         (lasx_xvilvl_<lasxfmt_f>_internal): Ditto.
16606         * config/loongarch/loongarch.cc (loongarch_expand_vector_init):
16607         Optimized the implementation of vector construction.
16608         (loongarch_expand_vector_init_same): New function.
16609         * config/loongarch/lsx.md (lsx_vilvl_<lsxfmt_f>_internal): New
16610         pattern for vector construction.
16611         (lsx_vreplvei_mirror_<lsxfmt_f>): New pattern for vector
16612         construction.
16613         (vec_concatv2df): Ditto.
16614         (vec_concatv4sf): Ditto.
16616 2023-09-24  Pan Li  <pan2.li@intel.com>
16618         PR target/111546
16619         * config/riscv/riscv-v.cc
16620         (expand_vector_init_merge_repeating_sequence): Bugfix
16622 2023-09-24  Andrew Pinski  <apinski@marvell.com>
16624         PR tree-optimization/111543
16625         * match.pd (`(X & ~Y) & Y`, `(X | ~Y) | Y`): New patterns.
16627 2023-09-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16629         * config/riscv/autovec-opt.md: Extend VLS modes
16630         * config/riscv/vector-iterators.md: Ditto.
16632 2023-09-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16634         * config/riscv/autovec-opt.md: Add VLS modes for conditional ABS/SQRT.
16636 2023-09-23  Pan Li  <pan2.li@intel.com>
16638         * config/riscv/autovec.md (floor<mode>2): New pattern.
16639         * config/riscv/riscv-protos.h (enum insn_flags): New enum type.
16640         (enum insn_type): Ditto.
16641         (expand_vec_floor): New function decl.
16642         * config/riscv/riscv-v.cc (gen_floor_const_fp): New function impl.
16643         (expand_vec_floor): Ditto.
16645 2023-09-22  Pan Li  <pan2.li@intel.com>
16647         * config/riscv/riscv-v.cc (expand_vec_float_cmp_mask): Refactor.
16648         (emit_vec_float_cmp_mask): Rename.
16649         (expand_vec_copysign): Ditto.
16650         (emit_vec_copysign): Ditto.
16651         (emit_vec_abs): New function impl.
16652         (emit_vec_cvt_x_f): Ditto.
16653         (emit_vec_cvt_f_x): Ditto.
16654         (expand_vec_ceil): Ditto.
16656 2023-09-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16658         * config/riscv/vector-iterators.md: Extend VLS modes.
16660 2023-09-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16662         * config/riscv/riscv-v.cc (gen_const_vector_dup): Use global expand function.
16663         * config/riscv/vector.md (@vec_duplicate<mode>): Remove @.
16664         (vec_duplicate<mode>): Ditto.
16666 2023-09-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16668         * config/riscv/autovec.md: Add VLS conditional patterns.
16669         * config/riscv/riscv-protos.h (expand_cond_unop): Ditto.
16670         (expand_cond_binop): Ditto.
16671         (expand_cond_ternop): Ditto.
16672         * config/riscv/riscv-v.cc (expand_cond_unop): Ditto.
16673         (expand_cond_binop): Ditto.
16674         (expand_cond_ternop): Ditto.
16676 2023-09-22  xuli  <xuli1@eswincomputing.com>
16678         PR target/111451
16679         * config/riscv/riscv-v.cc (emit_vlmax_gather_insn): Optimization of vrgather.vv
16680                                                         into vrgatherei16.vv.
16682 2023-09-22  Lehua Ding  <lehua.ding@rivai.ai>
16684         * config/riscv/autovec-opt.md (*cond_widen_reduc_plus_scal_<mode>):
16685         New combine patterns.
16686         * config/riscv/riscv-protos.h (enum insn_type): New insn_type.
16688 2023-09-22  Lehua Ding  <lehua.ding@rivai.ai>
16690         * config/riscv/riscv-protos.h (enum avl_type): New VLS avl_type.
16691         * config/riscv/riscv-v.cc (autovec_use_vlmax_p): Move comments.
16693 2023-09-22  Pan Li  <pan2.li@intel.com>
16695         * config/riscv/autovec.md (ceil<mode>2): New pattern.
16696         * config/riscv/riscv-protos.h (enum insn_flags): New enum type.
16697         (enum insn_type): Ditto.
16698         (expand_vec_ceil): New function decl.
16699         * config/riscv/riscv-v.cc (gen_ceil_const_fp): New function impl.
16700         (expand_vec_float_cmp_mask): Ditto.
16701         (expand_vec_copysign): Ditto.
16702         (expand_vec_ceil): Ditto.
16703         * config/riscv/vector.md: Add VLS mode support.
16705 2023-09-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16707         * config/riscv/autovec.md: Extend VLS modes.
16709 2023-09-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16711         * config/riscv/vector-iterators.md: Extend VLS modes.
16713 2023-09-21  Lehua Ding  <lehua.ding@rivai.ai>
16714             Robin Dapp  <rdapp.gcc@gmail.com>
16716         * config/riscv/riscv-v.cc (emit_vlmax_insn): Adjust comments.
16717         (emit_nonvlmax_insn): Adjust comments.
16718         (emit_vlmax_insn_lra): Adjust comments.
16720 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16722         * config.gcc (*linux*): Set rust target_objs, and
16723         target_has_targetrustm,
16724         * config/t-linux (linux-rust.o): New rule.
16725         * config/linux-rust.cc: New file.
16727 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16729         * config.gcc (i[34567]86-*-mingw* | x86_64-*-mingw*): Set
16730         rust_target_objs and target_has_targetrustm.
16731         * config/t-winnt (winnt-rust.o): New rule.
16732         * config/winnt-rust.cc: New file.
16734 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16736         * config.gcc (*-*-fuchsia): Set tmake_rule, rust_target_objs,
16737         and target_has_targetrustm.
16738         * config/fuchsia-rust.cc: New file.
16739         * config/t-fuchsia: New file.
16741 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16743         * config.gcc (*-*-vxworks*): Set rust_target_objs and
16744         target_has_targetrustm.
16745         * config/t-vxworks (vxworks-rust.o): New rule.
16746         * config/vxworks-rust.cc: New file.
16748 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16750         * config.gcc (*-*-dragonfly*): Set rust_target_objs and
16751         target_has_targetrustm.
16752         * config/t-dragonfly (dragonfly-rust.o): New rule.
16753         * config/dragonfly-rust.cc: New file.
16755 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16757         * config.gcc (*-*-solaris2*): Set rust_target_objs and
16758         target_has_targetrustm.
16759         * config/t-sol2 (sol2-rust.o): New rule.
16760         * config/sol2-rust.cc: New file.
16762 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16764         * config.gcc (*-*-openbsd*): Set rust_target_objs and
16765         target_has_targetrustm.
16766         * config/t-openbsd (openbsd-rust.o): New rule.
16767         * config/openbsd-rust.cc: New file.
16769 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16771         * config.gcc (*-*-netbsd*): Set rust_target_objs and
16772         target_has_targetrustm.
16773         * config/t-netbsd (netbsd-rust.o): New rule.
16774         * config/netbsd-rust.cc: New file.
16776 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16778         * config.gcc (*-*-freebsd*): Set rust_target_objs and
16779         target_has_targetrustm.
16780         * config/t-freebsd (freebsd-rust.o): New rule.
16781         * config/freebsd-rust.cc: New file.
16783 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16785         * config.gcc (*-*-darwin*): Set rust_target_objs and
16786         target_has_targetrustm.
16787         * config/t-darwin (darwin-rust.o): New rule.
16788         * config/darwin-rust.cc: New file.
16790 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16792         * config/i386/t-i386 (i386-rust.o): New rule.
16793         * config/i386/i386-rust.cc: New file.
16794         * config/i386/i386-rust.h: New file.
16796 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16798         * doc/tm.texi: Regenerate.
16799         * doc/tm.texi.in: Document TARGET_RUST_OS_INFO.
16801 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16803         * doc/tm.texi: Regenerate.
16804         * doc/tm.texi.in: Add @node for Rust language and ABI, and document
16805         TARGET_RUST_CPU_INFO.
16807 2023-09-21  Iain Buclaw  <ibuclaw@gdcproject.org>
16809         * Makefile.in (tm_rust_file_list, tm_rust_include_list, TM_RUST_H,
16810         RUST_TARGET_DEF, RUST_TARGET_H, RUST_TARGET_OBJS): New variables.
16811         (tm_rust.h, cs-tm_rust.h, default-rust.o,
16812         rust/rust-target-hooks-def.h, s-rust-target-hooks-def-h): New rules.
16813         (s-tm-texi): Also check timestamp on rust-target.def.
16814         (generated_files): Add TM_RUST_H and rust-target-hooks-def.h.
16815         (build/genhooks.o): Also depend on RUST_TARGET_DEF.
16816         * config.gcc (tm_rust_file, rust_target_objs, target_has_targetrustm):
16817         New variables.
16818         * configure: Regenerate.
16819         * configure.ac (tm_rust_file_list, tm_rust_include_list,
16820         rust_target_objs): Add substitutes.
16821         * doc/tm.texi: Regenerate.
16822         * doc/tm.texi.in (targetrustm): Document.
16823         (target_has_targetrustm): Document.
16824         * genhooks.cc: Include rust/rust-target.def.
16825         * config/default-rust.cc: New file.
16827 2023-09-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16829         PR target/110751
16830         * config/riscv/autovec.md: Enable scratch rtx in ELSE operand.
16831         * config/riscv/predicates.md (autovec_else_operand): New predicate.
16832         * config/riscv/riscv-v.cc (get_else_operand): New function.
16833         (expand_cond_len_unop): Adapt ELSE value.
16834         (expand_cond_len_binop): Ditto.
16835         (expand_cond_len_ternop): Ditto.
16836         * config/riscv/riscv.cc (riscv_preferred_else_value): New function.
16837         (TARGET_PREFERRED_ELSE_VALUE): New targethook.
16839 2023-09-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16841         PR target/111486
16842         * config/riscv/riscv.cc (riscv_legitimize_move): Fix bug.
16844 2023-09-21  Jiufu Guo  <guojiufu@linux.ibm.com>
16846         PR tree-optimization/111355
16847         * match.pd ((X + C) / N): Update pattern.
16849 2023-09-21  Jiufu Guo  <guojiufu@linux.ibm.com>
16851         * match.pd ((t * 2) / 2): Update to use overflow_free_p.
16853 2023-09-21  xuli  <xuli1@eswincomputing.com>
16855         PR target/111450
16856         * config/riscv/constraints.md (c01): const_int 1.
16857         (c02): const_int 2.
16858         (c04): const_int 4.
16859         (c08): const_int 8.
16860         * config/riscv/predicates.md (vector_eew8_stride_operand): New predicate for stride operand.
16861         (vector_eew16_stride_operand): Ditto.
16862         (vector_eew32_stride_operand): Ditto.
16863         (vector_eew64_stride_operand): Ditto.
16864         * config/riscv/vector-iterators.md: New iterator for stride operand.
16865         * config/riscv/vector.md: Add stride = element width constraint.
16867 2023-09-21  Lehua Ding  <lehua.ding@rivai.ai>
16869         * config/riscv/predicates.md (const_1_or_2_operand): Rename.
16870         (const_1_or_4_operand): Ditto.
16871         (vector_gs_scale_operand_16): Ditto.
16872         (vector_gs_scale_operand_32): Ditto.
16873         * config/riscv/vector-iterators.md: Adjust.
16875 2023-09-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16877         * config/riscv/autovec.md: Extend VLS modes.
16878         * config/riscv/vector-iterators.md: Ditto.
16879         * config/riscv/vector.md: Ditto.
16881 2023-09-20  Andrew MacLeod  <amacleod@redhat.com>
16883         * gimple-range-cache.cc (ssa_cache::merge_range): Change meaning
16884         of the return value.
16885         (ssa_cache::dump): Don't print GLOBAL RANGE header.
16886         (ssa_lazy_cache::merge_range): Adjust return value meaning.
16887         (ranger_cache::dump): Print GLOBAL RANGE header.
16889 2023-09-20  Aldy Hernandez  <aldyh@redhat.com>
16891         * range-op-float.cc (foperator_unordered_ge::fold_range): Remove
16892         special casing.
16893         (foperator_unordered_gt::fold_range): Same.
16894         (foperator_unordered_lt::fold_range): Same.
16895         (foperator_unordered_le::fold_range): Same.
16897 2023-09-20  Jakub Jelinek  <jakub@redhat.com>
16899         * builtins.h (type_to_class): Declare.
16900         * builtins.cc (type_to_class): No longer static.  Return
16901         int rather than enum.
16902         * doc/extend.texi (__builtin_classify_type): Document.
16904 2023-09-20  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16906         PR target/110751
16907         * internal-fn.cc (expand_fn_using_insn): Support undefined rtx value.
16908         * optabs.cc (maybe_legitimize_operand): Ditto.
16909         (can_reuse_operands_p): Ditto.
16910         * optabs.h (enum expand_operand_type): Ditto.
16911         (create_undefined_input_operand): Ditto.
16913 2023-09-20  Tobias Burnus  <tobias@codesourcery.com>
16915         * gimplify.cc (gimplify_bind_expr): Call GOMP_alloc/free for
16916         'omp allocate' variables; move stack cleanup after other
16917         cleanup.
16918         (omp_notice_variable): Process original decl when decl
16919         of the value-expression for a 'omp allocate' variable is passed.
16920         * omp-low.cc (scan_omp_1_op): Handle 'omp allocate' variables
16922 2023-09-20  Yanzhang Wang  <yanzhang.wang@intel.com>
16924         * simplify-rtx.cc (simplify_context::simplify_binary_operation_1):
16925         support simplifying vector int not only scalar int.
16927 2023-09-20  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16929         * config/riscv/vector-iterators.md: Extend VLS floating-point.
16931 2023-09-20  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
16933         * config/riscv/riscv-vsetvl.cc (vector_insn_info::operator==): Fix bug.
16935 2023-09-20  Iain Sandoe  <iain@sandoe.co.uk>
16937         * config/darwin.h:
16938         (SUBTARGET_DRIVER_SELF_SPECS): Move handling of 'shared' into the same
16939         specs as 'dynamiclib'. (STARTFILE_SPEC): Handle 'shared'.
16941 2023-09-20  Richard Biener  <rguenther@suse.de>
16943         PR tree-optimization/111489
16944         * params.opt (-param uninit-max-chain-len=): Raise default to 8.
16946 2023-09-20  Richard Biener  <rguenther@suse.de>
16948         PR tree-optimization/111489
16949         * doc/invoke.texi (--param uninit-max-chain-len): Document.
16950         (--param uninit-max-num-chains): Likewise.
16951         * params.opt (-param=uninit-max-chain-len=): New.
16952         (-param=uninit-max-num-chains=): Likewise.
16953         * gimple-predicate-analysis.cc (MAX_NUM_CHAINS): Define to
16954         param_uninit_max_num_chains.
16955         (MAX_CHAIN_LEN): Define to param_uninit_max_chain_len.
16956         (uninit_analysis::init_use_preds): Avoid VLA.
16957         (uninit_analysis::init_from_phi_def): Likewise.
16958         (compute_control_dep_chain): Avoid using MAX_CHAIN_LEN in
16959         template parameter.
16961 2023-09-20  Jakub Jelinek  <jakub@redhat.com>
16963         * match.pd ((x << c) >> c): Use MAX_FIXED_MODE_SIZE instead of
16964         GET_MODE_PRECISION of TImode or DImode depending on whether
16965         TImode is supported scalar mode.
16966         * gimple-lower-bitint.cc (bitint_precision_kind): Likewise.
16967         * expr.cc (expand_expr_real_1): Likewise.
16968         * tree-ssa-sccvn.cc (eliminate_dom_walker::eliminate_stmt): Likewise.
16969         * ubsan.cc (ubsan_encode_value, ubsan_type_descriptor): Likewise.
16971 2023-09-20  Lehua Ding  <lehua.ding@rivai.ai>
16973         * config/riscv/autovec-opt.md (*<optab>not<mode>): Move and rename.
16974         (*n<optab><mode>): Ditto.
16975         (*v<any_shiftrt:optab><any_extend:optab>trunc<mode>): Ditto.
16976         (*<any_shiftrt:optab>trunc<mode>): Ditto.
16977         (*narrow_<any_shiftrt:optab><any_extend:optab><mode>): Ditto.
16978         (*narrow_<any_shiftrt:optab><mode>_scalar): Ditto.
16979         (*single_widen_mult<any_extend:su><mode>): Ditto.
16980         (*single_widen_mul<any_extend:su><mode>): Ditto.
16981         (*single_widen_mult<mode>): Ditto.
16982         (*single_widen_mul<mode>): Ditto.
16983         (*dual_widen_fma<mode>): Ditto.
16984         (*dual_widen_fma<su><mode>): Ditto.
16985         (*single_widen_fma<mode>): Ditto.
16986         (*single_widen_fma<su><mode>): Ditto.
16987         (*dual_fma<mode>): Ditto.
16988         (*single_fma<mode>): Ditto.
16989         (*dual_fnma<mode>): Ditto.
16990         (*dual_widen_fnma<mode>): Ditto.
16991         (*single_fnma<mode>): Ditto.
16992         (*single_widen_fnma<mode>): Ditto.
16993         (*dual_fms<mode>): Ditto.
16994         (*dual_widen_fms<mode>): Ditto.
16995         (*single_fms<mode>): Ditto.
16996         (*single_widen_fms<mode>): Ditto.
16997         (*dual_fnms<mode>): Ditto.
16998         (*dual_widen_fnms<mode>): Ditto.
16999         (*single_fnms<mode>): Ditto.
17000         (*single_widen_fnms<mode>): Ditto.
17002 2023-09-20  Jakub Jelinek  <jakub@redhat.com>
17004         PR c++/111392
17005         * attribs.cc (decl_attributes): Don't warn on omp::directive attribute
17006         on vars or function decls if -fopenmp or -fopenmp-simd.
17008 2023-09-20  Lehua Ding  <lehua.ding@rivai.ai>
17010         PR target/111488
17011         * config/riscv/autovec-opt.md: Add missed operand.
17013 2023-09-20  Omar Sandoval  <osandov@osandov.com>
17015         PR debug/111409
17016         * dwarf2out.cc (output_macinfo): Don't call optimize_macinfo_range if
17017         dwarf_split_debug_info.
17019 2023-09-20  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17021         * config/riscv/riscv-v.cc (can_find_related_mode_p): New function.
17022         (vectorize_related_mode): Add VLS related modes.
17023         * config/riscv/vector-iterators.md: Extend VLS modes.
17025 2023-09-20  Surya Kumari Jangala  <jskumari@linux.ibm.com>
17027         PR rtl-optimization/110071
17028         * ira-color.cc (improve_allocation): Consider cost of callee
17029         save registers.
17031 2023-09-20  mengqinggang  <mengqinggang@loongson.cn>
17032             Xi Ruoyao  <xry111@xry111.site>
17034         * configure: Regenerate.
17035         * configure.ac: Checking assembler for -mno-relax support.
17036         Disable relaxation when probing leb128 support.
17038 2023-09-20  Lulu Cheng  <chenglulu@loongson.cn>
17040         * config.in: Regenerate.
17041         * config/loongarch/genopts/loongarch.opt.in: Add compilation option
17042         mrelax. And set the initial value of explicit-relocs according to the
17043         detection status.
17044         * config/loongarch/gnu-user.h: When compiling with -mno-relax, pass the
17045         --no-relax option to the linker.
17046         * config/loongarch/loongarch-driver.h (ASM_SPEC): When compiling with
17047         -mno-relax, pass the -mno-relax option to the assembler.
17048         * config/loongarch/loongarch-opts.h (HAVE_AS_MRELAX_OPTION): Define macro.
17049         * config/loongarch/loongarch.opt: Regenerate.
17050         * configure: Regenerate.
17051         * configure.ac: Add detection of support for binutils relax function.
17053 2023-09-19  Ben Boeckel  <ben.boeckel@kitware.com>
17055         * doc/invoke.texi: Document -fdeps-format=, -fdeps-file=, and
17056         -fdeps-target= flags.
17057         * gcc.cc: add defaults for -fdeps-target= and -fdeps-file= when
17058         only -fdeps-format= is specified.
17059         * json.h: Add a TODO item to refactor out to share with
17060         `libcpp/mkdeps.cc`.
17062 2023-09-19  Ben Boeckel  <ben.boeckel@kitware.com>
17063             Jason Merrill  <jason@redhat.com>
17065         * gcc.cc (join_spec_func): Add a spec function to join all
17066         arguments.
17068 2023-09-19  Patrick O'Neill  <patrick@rivosinc.com>
17070         * config/riscv/riscv.cc (riscv_legitimize_const_move): Eliminate
17071         src_op_0 var to avoid rtl check error.
17073 2023-09-19  Aldy Hernandez  <aldyh@redhat.com>
17075         * range-op-float.cc (frelop_early_resolve): Clean-up and remove
17076         special casing.
17077         (operator_not_equal::fold_range): Handle VREL_EQ.
17078         (operator_lt::fold_range): Remove special casing for VREL_EQ.
17079         (operator_gt::fold_range): Same.
17080         (foperator_unordered_equal::fold_range): Same.
17082 2023-09-19  Javier Martinez  <javier.martinez.bugzilla@gmail.com>
17084         * doc/extend.texi: Document attributes hot, cold on C++ types.
17086 2023-09-19  Pat Haugen  <pthaugen@linux.ibm.com>
17088         * config/rs6000/rs6000.cc (rs6000_rtx_costs): Check whether the
17089         modulo instruction is disabled.
17090         * config/rs6000/rs6000.h (RS6000_DISABLE_SCALAR_MODULO): New.
17091         * config/rs6000/rs6000.md (mod<mode>3, *mod<mode>3): Check it.
17092         (define_expand umod<mode>3): New.
17093         (define_insn umod<mode>3): Rename to *umod<mode>3 and check if the modulo
17094         instruction is disabled.
17095         (umodti3, modti3): Check if the modulo instruction is disabled.
17097 2023-09-19  Gaius Mulley  <gaiusmod2@gmail.com>
17099         * doc/gm2.texi (fdebug-builtins): Correct description.
17101 2023-09-19  Jeff Law  <jlaw@ventanamicro.com>
17103         * config/iq2000/predicates.md (uns_arith_constant): New predicate.
17104         * config/iq2000/iq2000.md (rotrsi3): Use it.
17106 2023-09-19  Aldy Hernandez  <aldyh@redhat.com>
17108         * range-op-float.cc (operator_lt::op1_range): Remove known_isnan check.
17109         (operator_lt::op2_range): Same.
17110         (operator_le::op1_range): Same.
17111         (operator_le::op2_range): Same.
17112         (operator_gt::op1_range): Same.
17113         (operator_gt::op2_range): Same.
17114         (operator_ge::op1_range): Same.
17115         (operator_ge::op2_range): Same.
17116         (foperator_unordered_lt::op1_range): Same.
17117         (foperator_unordered_lt::op2_range): Same.
17118         (foperator_unordered_le::op1_range): Same.
17119         (foperator_unordered_le::op2_range): Same.
17120         (foperator_unordered_gt::op1_range): Same.
17121         (foperator_unordered_gt::op2_range): Same.
17122         (foperator_unordered_ge::op1_range): Same.
17123         (foperator_unordered_ge::op2_range): Same.
17125 2023-09-19  Aldy Hernandez  <aldyh@redhat.com>
17127         * value-range.h (frange::update_nan): New.
17129 2023-09-19  Aldy Hernandez  <aldyh@redhat.com>
17131         * range-op-float.cc (operator_not_equal::op2_range): New.
17132         * range-op-mixed.h: Add operator_not_equal::op2_range.
17134 2023-09-19  Andrew MacLeod  <amacleod@redhat.com>
17136         PR tree-optimization/110080
17137         PR tree-optimization/110249
17138         * tree-vrp.cc (remove_unreachable::final_p): New.
17139         (remove_unreachable::maybe_register): Rename from
17140         maybe_register_block and call early or final routine.
17141         (fully_replaceable): New.
17142         (remove_unreachable::handle_early): New.
17143         (remove_unreachable::remove_and_update_globals): Remove
17144         non-final processing.
17145         (rvrp_folder::rvrp_folder): Add final flag to constructor.
17146         (rvrp_folder::post_fold_bb): Remove unreachable registration.
17147         (rvrp_folder::pre_fold_stmt): Move unreachable processing to here.
17148         (execute_ranger_vrp): Adjust some call parameters.
17150 2023-09-19  Richard Biener  <rguenther@suse.de>
17152         PR c/111468
17153         * tree-pretty-print.h (op_symbol_code): Add defaulted flags
17154         argument.
17155         * tree-pretty-print.cc (op_symbol): Likewise.
17156         (op_symbol_code): Print TDF_GIMPLE variant if requested.
17157         * gimple-pretty-print.cc (dump_binary_rhs): Pass flags to
17158         op_symbol_code.
17159         (dump_gimple_cond): Likewise.
17161 2023-09-19  Thomas Schwinge  <thomas@codesourcery.com>
17162             Pan Li  <pan2.li@intel.com>
17164         * tree-streamer.h (bp_unpack_machine_mode): If
17165         'ib->file_data->mode_table' not available, apply 1-to-1 mapping.
17167 2023-09-19  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17169         * config/riscv/riscv.cc (riscv_can_change_mode_class): Block unordered VLA and VLS modes.
17171 2023-09-19  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17173         * config/riscv/autovec.md: Extend VLS modes.
17174         * config/riscv/vector.md: Ditto.
17176 2023-09-19  Richard Biener  <rguenther@suse.de>
17178         PR tree-optimization/111465
17179         * tree-ssa-threadupdate.cc (fwd_jt_path_registry::thread_block_1):
17180         Cancel the path when a EDGE_NO_COPY_SRC_BLOCK became non-empty.
17182 2023-09-19  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17184         * config/riscv/autovec.md: Extend VLS floating-point modes.
17185         * config/riscv/vector.md: Ditto.
17187 2023-09-19  Jakub Jelinek  <jakub@redhat.com>
17189         * match.pd ((x << c) >> c): Don't call build_nonstandard_integer_type
17190         nor check type_has_mode_precision_p for width larger than [TD]Imode
17191         precision.
17192         (a ? CST1 : CST2): Don't use build_nonstandard_type, just convert
17193         to type.  Use boolean_true_node instead of
17194         constant_boolean_node (true, boolean_type_node).  Formatting fixes.
17196 2023-09-19  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17198         * config/riscv/autovec.md: Add VLS modes.
17199         * config/riscv/vector.md: Ditto.
17201 2023-09-19  Jakub Jelinek  <jakub@redhat.com>
17203         * tree.cc (build_bitint_type): Assert precision is not 0, or
17204         for signed types 1.
17205         (signed_or_unsigned_type_for): Return INTEGER_TYPE for signed variant
17206         of unsigned _BitInt(1).
17208 2023-09-19  Lehua Ding  <lehua.ding@rivai.ai>
17210         * config/riscv/autovec-opt.md (*<optab>_fma<mode>):
17211         Removed old combine patterns.
17212         (*single_<optab>mult_plus<mode>): Ditto.
17213         (*double_<optab>mult_plus<mode>): Ditto.
17214         (*sign_zero_extend_fma): Ditto.
17215         (*zero_sign_extend_fma): Ditto.
17216         (*double_widen_fma<mode>): Ditto.
17217         (*single_widen_fma<mode>): Ditto.
17218         (*double_widen_fnma<mode>): Ditto.
17219         (*single_widen_fnma<mode>): Ditto.
17220         (*double_widen_fms<mode>): Ditto.
17221         (*single_widen_fms<mode>): Ditto.
17222         (*double_widen_fnms<mode>): Ditto.
17223         (*single_widen_fnms<mode>): Ditto.
17224         (*reduc_plus_scal_<mode>): Adjust name.
17225         (*widen_reduc_plus_scal_<mode>): Adjust name.
17226         (*dual_widen_fma<mode>): New combine pattern.
17227         (*dual_widen_fmasu<mode>): Ditto.
17228         (*dual_widen_fmaus<mode>): Ditto.
17229         (*dual_fma<mode>): Ditto.
17230         (*single_fma<mode>): Ditto.
17231         (*dual_fnma<mode>): Ditto.
17232         (*single_fnma<mode>): Ditto.
17233         (*dual_fms<mode>): Ditto.
17234         (*single_fms<mode>): Ditto.
17235         (*dual_fnms<mode>): Ditto.
17236         (*single_fnms<mode>): Ditto.
17237         * config/riscv/autovec.md (fma<mode>4):
17238         Reafctor fma pattern.
17239         (*fma<VI:mode><P:mode>): Removed.
17240         (fnma<mode>4): Reafctor.
17241         (*fnma<VI:mode><P:mode>): Removed.
17242         (*fma<VF:mode><P:mode>):  Removed.
17243         (*fnma<VF:mode><P:mode>):  Removed.
17244         (fms<mode>4):  Reafctor.
17245         (*fms<VF:mode><P:mode>):  Removed.
17246         (fnms<mode>4): Reafctor.
17247         (*fnms<VF:mode><P:mode>): Removed.
17248         * config/riscv/riscv-protos.h (prepare_ternary_operands):
17249         Adjust prototype.
17250         * config/riscv/riscv-v.cc (prepare_ternary_operands): Refactor.
17251         * config/riscv/vector.md (*pred_mul_plus<mode>_undef): New pattern.
17252         (*pred_mul_plus<mode>): Removed.
17253         (*pred_mul_plus<mode>_scalar): Removed.
17254         (*pred_mul_plus<mode>_extended_scalar): Removed.
17255         (*pred_minus_mul<mode>_undef):  New pattern.
17256         (*pred_minus_mul<mode>): Removed.
17257         (*pred_minus_mul<mode>_scalar): Removed.
17258         (*pred_minus_mul<mode>_extended_scalar): Removed.
17259         (*pred_mul_<optab><mode>_undef):  New pattern.
17260         (*pred_mul_<optab><mode>): Removed.
17261         (*pred_mul_<optab><mode>_scalar): Removed.
17262         (*pred_mul_neg_<optab><mode>_undef):  New pattern.
17263         (*pred_mul_neg_<optab><mode>): Removed.
17264         (*pred_mul_neg_<optab><mode>_scalar): Removed.
17266 2023-09-19  Tsukasa OI  <research_trasio@irq.a4lg.com>
17268         * config/riscv/riscv-vector-builtins.cc
17269         (builtin_decl, expand_builtin): Replace SVE with RVV.
17271 2023-09-19  Tsukasa OI  <research_trasio@irq.a4lg.com>
17273         * config/riscv/t-riscv: Add dependencies for riscv-builtins.cc,
17274         riscv-cmo.def and riscv-scalar-crypto.def.
17276 2023-09-18  Pan Li  <pan2.li@intel.com>
17278         * config/riscv/autovec.md: Extend to vls mode.
17280 2023-09-18  Pan Li  <pan2.li@intel.com>
17282         * config/riscv/autovec.md: Bugfix.
17283         * config/riscv/riscv-protos.h (SCALAR_MOVE_MERGED_OP): New enum.
17285 2023-09-18  Andrew Pinski  <apinski@marvell.com>
17287         PR tree-optimization/111442
17288         * match.pd (zero_one_valued_p): Have the bit_and match not be
17289         recursive.
17291 2023-09-18  Andrew Pinski  <apinski@marvell.com>
17293         PR tree-optimization/111435
17294         * match.pd (zero_one_valued_p): Don't do recursion
17295         on converts.
17297 2023-09-18  Iain Sandoe  <iain@sandoe.co.uk>
17299         * config/darwin-protos.h (enum darwin_external_toolchain): New.
17300         * config/darwin.cc (DSYMUTIL_VERSION): New.
17301         (darwin_override_options): Choose the default debug DWARF version
17302         depending on the configured dsymutil version.
17304 2023-09-18  Iain Sandoe  <iain@sandoe.co.uk>
17306         * configure: Regenerate.
17307         * configure.ac: Handle explict disable of stdlib option, set
17308         defaults for Darwin.
17310 2023-09-18  Andrew Pinski  <apinski@marvell.com>
17312         PR tree-optimization/111431
17313         * match.pd (`(a == CST) & a`): New pattern.
17315 2023-09-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17317         * config/riscv/riscv-selftests.cc (run_broadcast_selftests): Adapt selftests.
17318         * config/riscv/vector.md (@vec_duplicate<mode>): Remove.
17320 2023-09-18  Wilco Dijkstra  <wilco.dijkstra@arm.com>
17322         PR target/105928
17323         * config/aarch64/aarch64.cc (aarch64_internal_mov_immediate)
17324         Add support for immediates using shifted ORR/BIC.
17325         (aarch64_split_dimode_const_store): Apply if we save one instruction.
17326         * config/aarch64/aarch64.md (<LOGICAL:optab>_<SHIFT:optab><mode>3):
17327         Make pattern global.
17329 2023-09-18  Wilco Dijkstra  <wilco.dijkstra@arm.com>
17331         * config/aarch64/aarch64-cores.def (neoverse-n1): Place before ares.
17332         (neoverse-v1): Place before zeus.
17333         (neoverse-v2): Place before demeter.
17334         * config/aarch64/aarch64-tune.md: Regenerate.
17336 2023-09-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17338         * config/riscv/autovec.md: Add VLS modes.
17339         * config/riscv/vector-iterators.md: Ditto.
17340         * config/riscv/vector.md: Ditto.
17342 2023-09-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17344         * config/riscv/riscv-vsetvl.cc (vlmul_for_greatest_sew_second_ratio): New function.
17345         * config/riscv/riscv-vsetvl.def (DEF_SEW_LMUL_FUSE_RULE): Fix bug.
17347 2023-09-18  Richard Biener  <rguenther@suse.de>
17349         PR tree-optimization/111294
17350         * tree-ssa-threadbackward.cc (back_threader_profitability::m_name):
17351         Remove
17352         (back_threader::find_paths_to_names): Adjust.
17353         (back_threader::maybe_thread_block): Likewise.
17354         (back_threader_profitability::possibly_profitable_path_p): Remove
17355         code applying extra costs to copies PHIs.
17357 2023-09-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17359         * config/riscv/autovec.md: Extend VLS modes.
17360         * config/riscv/vector.md: Ditto.
17362 2023-09-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17364         * config/riscv/vector.md (mov<mode>): New pattern.
17365         (*mov<mode>_mem_to_mem): Ditto.
17366         (*mov<mode>): Ditto.
17367         (@mov<VLS_AVL_REG:mode><P:mode>_lra): Ditto.
17368         (*mov<VLS_AVL_REG:mode><P:mode>_lra): Ditto.
17369         (*mov<mode>_vls): Ditto.
17370         (movmisalign<mode>): Ditto.
17371         (@vec_duplicate<mode>): Ditto.
17372         * config/riscv/autovec-vls.md: Removed.
17374 2023-09-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17376         PR target/111153
17377         * config/riscv/autovec.md: Add VLS modes.
17379 2023-09-18  Jason Merrill  <jason@redhat.com>
17381         * doc/gty.texi: Add discussion of cache vs. deletable.
17383 2023-09-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17385         * config/riscv/autovec-vls.md (<optab><mode>3): Deleted.
17386         (copysign<mode>3): Ditto.
17387         (xorsign<mode>3): Ditto.
17388         (<optab><mode>2): Ditto.
17389         * config/riscv/autovec.md: Extend VLS modes.
17391 2023-09-18  Jiufu Guo  <guojiufu@linux.ibm.com>
17393         PR middle-end/111303
17394         * match.pd ((t * 2) / 2): Update pattern.
17396 2023-09-17  Ajit Kumar Agarwal  <aagarwa1@linux.ibm.com>
17398         * config/rs6000/vsx.md (*vctzlsbb_zext_<mode>): New define_insn.
17400 2023-09-16  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17402         PR target/111391
17403         * config/riscv/autovec.md (@vec_extract<mode><vel>): Remove @.
17404         (vec_extract<mode><vel>): Ditto.
17405         * config/riscv/riscv-vsetvl.cc (emit_vsetvl_insn): Fix bug.
17406         (pass_vsetvl::local_eliminate_vsetvl_insn): Fix bug.
17407         * config/riscv/riscv.cc (riscv_legitimize_move): Expand VLS mode to scalar mode move.
17409 2023-09-16  Tsukasa OI  <research_trasio@irq.a4lg.com>
17411         * config/riscv/crypto.md (riscv_sha256sig0_<mode>,
17412         riscv_sha256sig1_<mode>, riscv_sha256sum0_<mode>,
17413         riscv_sha256sum1_<mode>, riscv_sm3p0_<mode>, riscv_sm3p1_<mode>,
17414         riscv_sm4ed_<mode>, riscv_sm4ks_<mode>): Remove and replace with
17415         new insn/expansions.
17416         (SHA256_OP, SM3_OP, SM4_OP): New iterators.
17417         (sha256_op, sm3_op, sm4_op): New attributes for iteration.
17418         (*riscv_<sha256_op>_si): New raw instruction for RV32.
17419         (*riscv_<sm3_op>_si): Ditto.
17420         (*riscv_<sm4_op>_si): Ditto.
17421         (riscv_<sha256_op>_di_extended): New base instruction for RV64.
17422         (riscv_<sm3_op>_di_extended): Ditto.
17423         (riscv_<sm4_op>_di_extended): Ditto.
17424         (riscv_<sha256_op>_si): New common instruction expansion.
17425         (riscv_<sm3_op>_si): Ditto.
17426         (riscv_<sm4_op>_si): Ditto.
17427         * config/riscv/riscv-builtins.cc: Add availability "crypto_zknh",
17428         "crypto_zksh" and "crypto_zksed".  Remove availability
17429         "crypto_zksh{32,64}" and "crypto_zksed{32,64}".
17430         * config/riscv/riscv-ftypes.def: Remove unused function type.
17431         * config/riscv/riscv-scalar-crypto.def: Make SHA-256, SM3 and SM4
17432         intrinsics to operate on uint32_t.
17434 2023-09-16  Tsukasa OI  <research_trasio@irq.a4lg.com>
17436         * config/riscv/riscv-builtins.cc (RISCV_ATYPE_UQI): New for
17437         uint8_t.  (RISCV_ATYPE_UHI): New for uint16_t.
17438         (RISCV_ATYPE_QI, RISCV_ATYPE_HI, RISCV_ATYPE_SI, RISCV_ATYPE_DI):
17439         Removed as no longer used.
17440         (RISCV_ATYPE_UDI): New for uint64_t.
17441         * config/riscv/riscv-cmo.def: Make types unsigned for not working
17442         "zicbop_cbo_prefetchi" and working bit manipulation clmul builtin
17443         argument/return types.
17444         * config/riscv/riscv-ftypes.def: Make bit manipulation, round
17445         number and shift amount types unsigned.
17446         * config/riscv/riscv-scalar-crypto.def: Ditto.
17448 2023-09-16  Pan Li  <pan2.li@intel.com>
17450         * config/riscv/autovec-vls.md (xorsign<mode>3): New pattern.
17452 2023-09-15  Fei Gao  <gaofei@eswincomputing.com>
17454         * config/riscv/predicates.md: Restrict predicate
17455         to allow 'reg' only.
17457 2023-09-15  Andrew Pinski  <apinski@marvell.com>
17459         * match.pd (zero_one_valued_p): Match a cast from a zero_one_valued_p.
17460         Also match `a & zero_one_valued_p` too.
17462 2023-09-15  Andrew Pinski  <apinski@marvell.com>
17464         PR tree-optimization/111414
17465         * match.pd (`(1 >> X) != 0`): Check to see if
17466         the integer_onep was an integral type (not a vector type).
17468 2023-09-15  Andrew MacLeod  <amacleod@redhat.com>
17470         * gimple-range-fold.cc (fold_using_range::range_of_phi): Always
17471         run phi analysis, and do it before loop analysis.
17473 2023-09-15  Andrew MacLeod  <amacleod@redhat.com>
17475         * gimple-range-fold.cc (fold_using_range::range_of_phi): Fix
17476         indentation.
17478 2023-09-15  Qing Zhao  <qing.zhao@oracle.com>
17480         PR tree-optimization/111407
17481         * tree-ssa-math-opts.cc (convert_mult_to_widen): Avoid the transform
17482         when one of the operands is subject to abnormal coalescing.
17484 2023-09-15  Lehua Ding  <lehua.ding@rivai.ai>
17486         * config/riscv/riscv-protos.h (enum insn_flags): Change name.
17487         (enum insn_type): Ditto.
17488         * config/riscv/riscv-v.cc (get_mask_mode_from_insn_flags): Removed.
17489         (emit_vlmax_insn): Adjust.
17490         (emit_nonvlmax_insn): Adjust.
17491         (emit_vlmax_insn_lra): Adjust.
17493 2023-09-15  Lehua Ding  <lehua.ding@rivai.ai>
17495         * config/riscv/autovec-opt.md: Adjust.
17496         * config/riscv/autovec.md: Ditto.
17497         * config/riscv/riscv-protos.h (enum class): Delete enum reduction_type.
17498         (expand_reduction): Adjust expand_reduction prototype.
17499         * config/riscv/riscv-v.cc (need_mask_operand_p): New helper function.
17500         (expand_reduction): Refactor expand_reduction.
17502 2023-09-15  Richard Sandiford  <richard.sandiford@arm.com>
17504         PR target/111411
17505         * config/aarch64/aarch64.cc (aarch64_operands_ok_for_ldpstp): Require
17506         the lower memory access to a mem-pair operand.
17508 2023-09-15  Yang Yujie  <yangyujie@loongson.cn>
17510         * config.gcc: Pass the default ABI via TM_MULTILIB_CONFIG.
17511         * config/loongarch/loongarch-driver.h: Invoke MLIB_SELF_SPECS
17512         before the driver canonicalization routines.
17513         * config/loongarch/loongarch.h: Move definitions of CC1_SPEC etc.
17514         to loongarch-driver.h
17515         * config/loongarch/t-linux: Move multilib-related definitions to
17516         t-multilib.
17517         * config/loongarch/t-multilib: New file.  Inject library build
17518         options obtained from --with-multilib-list.
17519         * config/loongarch/t-loongarch: Same.
17521 2023-09-15  Lehua Ding  <lehua.ding@rivai.ai>
17523         PR target/111381
17524         * config/riscv/autovec-opt.md (*reduc_plus_scal_<mode>):
17525         New combine pattern.
17526         (*fold_left_widen_plus_<mode>): Ditto.
17527         (*mask_len_fold_left_widen_plus_<mode>): Ditto.
17528         * config/riscv/autovec.md (reduc_plus_scal_<mode>):
17529         Change from define_expand to define_insn_and_split.
17530         (fold_left_plus_<mode>): Ditto.
17531         (mask_len_fold_left_plus_<mode>): Ditto.
17532         * config/riscv/riscv-v.cc (expand_reduction):
17533         Support widen reduction.
17534         * config/riscv/vector-iterators.md (UNSPEC_WREDUC_SUM):
17535         Add new iterators and attrs.
17537 2023-09-14  David Malcolm  <dmalcolm@redhat.com>
17539         * diagnostic-event-id.h (diagnostic_thread_id_t): New typedef.
17540         * diagnostic-format-sarif.cc (class sarif_thread_flow): New.
17541         (sarif_thread_flow::sarif_thread_flow): New.
17542         (sarif_builder::make_code_flow_object): Reimplement, creating
17543         per-thread threadFlow objects, populating them with the relevant
17544         events.
17545         (sarif_builder::make_thread_flow_object): Delete, moving the
17546         code into sarif_builder::make_code_flow_object.
17547         (sarif_builder::make_thread_flow_location_object): Add
17548         "path_event_idx" param.  Use it to set "executionOrder"
17549         property.
17550         * diagnostic-path.h (diagnostic_event::get_thread_id): New
17551         pure-virtual vfunc.
17552         (class diagnostic_thread): New.
17553         (diagnostic_path::num_threads): New pure-virtual vfunc.
17554         (diagnostic_path::get_thread):  New pure-virtual vfunc.
17555         (diagnostic_path::multithreaded_p): New decl.
17556         (simple_diagnostic_event::simple_diagnostic_event): Add optional
17557         thread_id param.
17558         (simple_diagnostic_event::get_thread_id): New accessor.
17559         (simple_diagnostic_event::m_thread_id): New.
17560         (class simple_diagnostic_thread): New.
17561         (simple_diagnostic_path::simple_diagnostic_path): Move definition
17562         to diagnostic.cc.
17563         (simple_diagnostic_path::num_threads): New.
17564         (simple_diagnostic_path::get_thread): New.
17565         (simple_diagnostic_path::add_thread): New.
17566         (simple_diagnostic_path::add_thread_event): New.
17567         (simple_diagnostic_path::m_threads): New.
17568         * diagnostic-show-locus.cc (layout::layout): Add pretty_printer
17569         param for overriding the context's printer.
17570         (diagnostic_show_locus): Likwise.
17571         * diagnostic.cc (simple_diagnostic_path::simple_diagnostic_path):
17572         Move here from diagnostic-path.h.  Add main thread.
17573         (simple_diagnostic_path::num_threads): New.
17574         (simple_diagnostic_path::get_thread): New.
17575         (simple_diagnostic_path::add_thread): New.
17576         (simple_diagnostic_path::add_thread_event): New.
17577         (simple_diagnostic_event::simple_diagnostic_event): Add thread_id
17578         param and use it to initialize m_thread_id.  Reformat.
17579         * diagnostic.h: Add pretty_printer param for overriding the
17580         context's printer.
17581         * tree-diagnostic-path.cc: Add #define INCLUDE_VECTOR.
17582         (can_consolidate_events): Compare thread ids.
17583         (class per_thread_summary): New.
17584         (event_range::event_range): Add per_thread_summary arg.
17585         (event_range::print): Add "pp" param and use it rather than dc's
17586         printer.
17587         (event_range::m_thread_id): New field.
17588         (event_range::m_per_thread_summary): New field.
17589         (path_summary::multithreaded_p): New.
17590         (path_summary::get_events_for_thread_id): New.
17591         (path_summary::m_per_thread_summary): New field.
17592         (path_summary::m_thread_id_to_events): New field.
17593         (path_summary::get_or_create_events_for_thread_id): New.
17594         (path_summary::path_summary): Create per_thread_summary instances
17595         as needed and associate the event_range instances with them.
17596         (base_indent): Move here from print_path_summary_as_text.
17597         (per_frame_indent): Likewise.
17598         (class thread_event_printer): New, adapted from parts of
17599         print_path_summary_as_text.
17600         (print_path_summary_as_text): Make static.  Reimplement to
17601         moving most of existing code to class thread_event_printer,
17602         capturing state as per-thread as appropriate.
17603         (default_tree_diagnostic_path_printer): Add missing 'break' on
17604         final case.
17606 2023-09-14  David Malcolm  <dmalcolm@redhat.com>
17608         * dwarf2cfi.cc (dwarf2cfi_cc_finalize): New.
17609         * dwarf2out.h (dwarf2cfi_cc_finalize): New decl.
17610         * ggc-common.cc (ggc_mark_roots): Multiply by rti->nelt when
17611         clearing the deletable gcc_root_tab_t.
17612         (ggc_common_finalize): New.
17613         * ggc.h (ggc_common_finalize): New decl.
17614         * toplev.cc (toplev::finalize): Call dwarf2cfi_cc_finalize and
17615         ggc_common_finalize.
17617 2023-09-14  Max Filippov  <jcmvbkbc@gmail.com>
17619         * config/xtensa/predicates.md (xtensa_cstoresi_operator): Add
17620         unsigned comparisons.
17621         * config/xtensa/xtensa.cc (xtensa_expand_scc): Add code
17622         generation of salt/saltu instructions.
17623         * config/xtensa/xtensa.h (TARGET_SALT): New macro.
17624         * config/xtensa/xtensa.md (salt, saltu): New instruction
17625         patterns.
17627 2023-09-14  Vladimir N. Makarov  <vmakarov@redhat.com>
17629         * ira-costs.cc (find_costs_and_classes): Decrease memory cost
17630         by equiv savings.
17632 2023-09-14  Lehua Ding  <lehua.ding@rivai.ai>
17634         * config/riscv/autovec.md: Change rtx code to unspec.
17635         * config/riscv/riscv-protos.h (expand_reduction): Change prototype.
17636         * config/riscv/riscv-v.cc (expand_reduction): Change prototype.
17637         * config/riscv/riscv-vector-builtins-bases.cc (class widen_reducop):
17638         Removed.
17639         (class widen_freducop): Removed.
17640         * config/riscv/vector-iterators.md (minu): Add reduc unspec, iterators, attrs.
17641         * config/riscv/vector.md (@pred_reduc_<reduc><mode>): Change name.
17642         (@pred_<reduc_op><mode>): New name.
17643         (@pred_widen_reduc_plus<v_su><mode>): Change name.
17644         (@pred_reduc_plus<order><mode>): Change name.
17645         (@pred_widen_reduc_plus<order><mode>): Change name.
17647 2023-09-14  Lehua Ding  <lehua.ding@rivai.ai>
17649         * config/riscv/riscv-v.cc (expand_reduction): Adjust call.
17650         * config/riscv/riscv-vector-builtins-bases.cc: Adjust call.
17651         * config/riscv/vector-iterators.md: New iterators and attrs.
17652         * config/riscv/vector.md (@pred_reduc_<reduc><VQI:mode><VQI_LMUL1:mode>):
17653         Removed.
17654         (@pred_reduc_<reduc><VHI:mode><VHI_LMUL1:mode>): Removed.
17655         (@pred_reduc_<reduc><VSI:mode><VSI_LMUL1:mode>): Removed.
17656         (@pred_reduc_<reduc><VDI:mode><VDI_LMUL1:mode>): Removed.
17657         (@pred_reduc_<reduc><mode>): Added.
17658         (@pred_widen_reduc_plus<v_su><VQI:mode><VHI_LMUL1:mode>): Removed.
17659         (@pred_widen_reduc_plus<v_su><VHI:mode><VSI_LMUL1:mode>): Removed.
17660         (@pred_widen_reduc_plus<v_su><mode>): Added.
17661         (@pred_widen_reduc_plus<v_su><VSI:mode><VDI_LMUL1:mode>): Removed.
17662         (@pred_reduc_<reduc><VHF:mode><VHF_LMUL1:mode>): Removed.
17663         (@pred_reduc_<reduc><VSF:mode><VSF_LMUL1:mode>): Removed.
17664         (@pred_reduc_<reduc><VDF:mode><VDF_LMUL1:mode>): Removed.
17665         (@pred_reduc_plus<order><VHF:mode><VHF_LMUL1:mode>): Removed.
17666         (@pred_reduc_plus<order><VSF:mode><VSF_LMUL1:mode>): Removed.
17667         (@pred_reduc_plus<order><mode>): Added.
17668         (@pred_reduc_plus<order><VDF:mode><VDF_LMUL1:mode>): Removed.
17669         (@pred_widen_reduc_plus<order><VHF:mode><VSF_LMUL1:mode>): Removed.
17670         (@pred_widen_reduc_plus<order><VSF:mode><VDF_LMUL1:mode>): Removed.
17671         (@pred_widen_reduc_plus<order><mode>): Added.
17673 2023-09-14  Richard Sandiford  <richard.sandiford@arm.com>
17675         * config/aarch64/aarch64.cc (aarch64_vector_costs::analyze_loop_info):
17676         Move WHILELO handling to...
17677         (aarch64_vector_costs::finish_cost): ...here.  Check whether the
17678         vectorizer has decided to use a predicated loop.
17680 2023-09-14  Andrew Pinski  <apinski@marvell.com>
17682         PR tree-optimization/106164
17683         * match.pd (`(X CMP1 CST1) AND/IOR (X CMP2 CST2)`):
17684         Expand to support constants that are off by one.
17686 2023-09-14  Andrew Pinski  <apinski@marvell.com>
17688         * genmatch.cc (parser::parse_result): For an else clause
17689         of an if statement inside a switch, error out explictly.
17691 2023-09-14  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17693         * config/riscv/autovec-opt.md: Add VLS mask modes.
17694         * config/riscv/autovec.md (@vcond_mask_<mode><vm>): Remove @.
17695         (vcond_mask_<mode><vm>): Add VLS mask modes.
17696         * config/riscv/vector.md: Ditto.
17698 2023-09-14  Richard Biener  <rguenther@suse.de>
17700         PR tree-optimization/111294
17701         * tree-ssa-forwprop.cc (pass_forwprop::execute): Track
17702         operands that eventually become dead and use simple_dce_from_worklist
17703         to remove their definitions if they did so.
17705 2023-09-14  Richard Sandiford  <richard.sandiford@arm.com>
17707         * config/aarch64/aarch64-sve.md (@aarch64_vec_duplicate_vq<mode>_le):
17708         Accept all nonimmediate_operands, but keep the existing constraints.
17709         If the instruction is split before RA, load invalid addresses into
17710         a temporary register.
17711         * config/aarch64/predicates.md (aarch64_sve_dup_ld1rq_operand): Delete.
17713 2023-09-14  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17715         PR target/111395
17716         * config/riscv/riscv-vsetvl.cc (avl_info::operator==): Fix ICE.
17717         (vector_insn_info::global_merge): Ditto.
17718         (vector_insn_info::get_avl_or_vl_reg): Ditto.
17720 2023-09-14  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17722         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::global_eliminate_vsetvl_insn): Format it.
17724 2023-09-14  Lulu Cheng  <chenglulu@loongson.cn>
17726         * config/loongarch/loongarch-def.c: Modify the default value of
17727         branch_cost.
17729 2023-09-14  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
17731         * config/xtensa/xtensa.cc (xtensa_expand_scc):
17732         Revert the changes from the last patch, as the work in the RTL
17733         expansion pass is too far to determine the physical registers.
17734         * config/xtensa/xtensa.md (*eqne_INT_MIN): Ditto.
17735         (eq_zero_NSA, eqne_zero, *eqne_zero_masked_bits): New patterns.
17737 2023-09-14  Lulu Cheng  <chenglulu@loongson.cn>
17739         PR target/111334
17740         * config/loongarch/loongarch.md: Fix bug of '<optab>di3_fake'.
17742 2023-09-13  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17744         * config/riscv/autovec.md (vec_extract<mode><vel>): Add VLS modes.
17745         (@vec_extract<mode><vel>): Ditto.
17746         * config/riscv/vector.md: Ditto
17748 2023-09-13  Andrew Pinski  <apinski@marvell.com>
17750         * match.pd (`X <= MAX(X, Y)`):
17751         Move before `MIN (X, C1) < C2` pattern.
17753 2023-09-13  Andrew Pinski  <apinski@marvell.com>
17755         PR tree-optimization/111364
17756         * match.pd (`MIN (X, Y) == X`): Extend
17757         to min/lt, min/ge, max/gt, max/le.
17759 2023-09-13  Andrew Pinski  <apinski@marvell.com>
17761         PR tree-optimization/111345
17762         * match.pd (`Y > (X % Y)`): Merge
17763         into ...
17764         (`(X % Y) < Y`): Pattern by adding `:c`
17765         on the comparison.
17767 2023-09-13  Richard Biener  <rguenther@suse.de>
17769         PR tree-optimization/111387
17770         * tree-vect-slp.cc (vect_get_and_check_slp_defs): Check
17771         EDGE_DFS_BACK when doing BB vectorization.
17772         (vect_slp_function): Use rev_post_order_and_mark_dfs_back_seme
17773         to compute RPO and mark backedges.
17775 2023-09-13  Lehua Ding  <lehua.ding@rivai.ai>
17777         * config/riscv/autovec-opt.md (*cond_<mulh_table><mode>3_highpart):
17778         New combine pattern.
17779         * config/riscv/autovec.md (smul<mode>3_highpart): Mrege smul and umul.
17780         (<mulh_table><mode>3_highpart): Merged pattern.
17781         (umul<mode>3_highpart): Mrege smul and umul.
17782         * config/riscv/vector-iterators.md (umul): New iterators.
17783         (UNSPEC_VMULHU): New iterators.
17785 2023-09-13  Lehua Ding  <lehua.ding@rivai.ai>
17787         * config/riscv/autovec-opt.md (*cond_v<any_shiftrt:optab><any_extend:optab>trunc<mode>):
17788         New combine pattern.
17789         (*cond_<any_shiftrt:optab>trunc<mode>): Ditto.
17791 2023-09-13  Lehua Ding  <lehua.ding@rivai.ai>
17793         * config/riscv/autovec-opt.md (*copysign<mode>_neg): Move.
17794         (*cond_copysign<mode>): New combine pattern.
17795         * config/riscv/riscv-v.cc (needs_fp_rounding): Extend.
17797 2023-09-13  Richard Biener  <rguenther@suse.de>
17799         PR tree-optimization/111397
17800         * tree-ssa-propagate.cc (may_propagate_copy): Change optional
17801         argument to specify whether the PHI destination doesn't flow in
17802         from an abnormal PHI.
17803         (propagate_value): Adjust.
17804         * tree-ssa-forwprop.cc (pass_forwprop::execute): Indicate abnormal
17805         PHI dest.
17806         * tree-ssa-sccvn.cc (eliminate_dom_walker::before_dom_children):
17807         Likewise.
17808         (process_bb): Likewise.
17810 2023-09-13  Pan Li  <pan2.li@intel.com>
17812         PR target/111362
17813         * config/riscv/riscv.cc (riscv_emit_frm_mode_set): Bugfix.
17815 2023-09-13  Jiufu Guo  <guojiufu@linux.ibm.com>
17817         PR tree-optimization/111303
17818         * match.pd ((X - N * M) / N): Add undefined_p checking.
17819         ((X + N * M) / N): Likewise.
17820         ((X + C) div_rshift N): Likewise.
17822 2023-09-12  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17824         PR target/111337
17825         * config/riscv/autovec.md (vcond_mask_<mode><mode>): New pattern.
17827 2023-09-12  Martin Jambor  <mjambor@suse.cz>
17829         * dbgcnt.def (form_fma): New.
17830         * tree-ssa-math-opts.cc: Include dbgcnt.h.
17831         (convert_mult_to_fma): Bail out if the debug counter say so.
17833 2023-09-12  Edwin Lu  <ewlu@rivosinc.com>
17835         * config/riscv/autovec-opt.md: Update type
17836         * config/riscv/riscv.cc (riscv_sched_variable_issue): Enable assert
17838 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17840         * config/aarch64/aarch64.cc (aarch64_save_regs_above_locals_p):
17841         New function.
17842         (aarch64_layout_frame): Use it to decide whether locals should
17843         go above or below the saved registers.
17844         (aarch64_expand_prologue): Update stack layout comment.
17845         Emit a stack tie after the final adjustment.
17847 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17849         * config/aarch64/aarch64.h (aarch64_frame::saved_regs_size)
17850         (aarch64_frame::below_hard_fp_saved_regs_size): Delete.
17851         * config/aarch64/aarch64.cc (aarch64_layout_frame): Update accordingly.
17853 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17855         * config/aarch64/aarch64.h (aarch64_frame::sve_save_and_probe)
17856         (aarch64_frame::hard_fp_save_and_probe): New fields.
17857         * config/aarch64/aarch64.cc (aarch64_layout_frame): Initialize them.
17858         Rather than asserting that a leaf function saves LR, instead assert
17859         that a leaf function saves something.
17860         (aarch64_get_separate_components): Prevent the chosen probe
17861         registers from being individually shrink-wrapped.
17862         (aarch64_allocate_and_probe_stack_space): Remove workaround for
17863         probe registers that aren't at the bottom of the previous allocation.
17865 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17867         * config/aarch64/aarch64.cc (aarch64_allocate_and_probe_stack_space):
17868         Always probe the residual allocation at offset 1024, asserting
17869         that that is in range.
17871 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17873         * config/aarch64/aarch64.cc (aarch64_layout_frame): Ensure that
17874         the LR save slot is in the first 16 bytes of the register save area.
17875         Only form STP/LDP push/pop candidates if both registers are valid.
17876         (aarch64_allocate_and_probe_stack_space): Remove workaround for
17877         when LR was not in the first 16 bytes.
17879 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17881         * config/aarch64/aarch64.cc (aarch64_allocate_and_probe_stack_space):
17882         Don't probe final allocations that are exactly 1KiB in size (after
17883         unprobed space above the final allocation has been deducted).
17885 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17887         * config/aarch64/aarch64.cc (aarch64_layout_frame): Tweak
17888         calculation of initial_adjust for frames in which all saves
17889         are SVE saves.
17891 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17893         * config/aarch64/aarch64.cc (aarch64_layout_frame): Simplify
17894         the allocation of the top of the frame.
17896 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17898         * config/aarch64/aarch64.h (aarch64_frame): Add comment above
17899         reg_offset.
17900         * config/aarch64/aarch64.cc (aarch64_layout_frame): Walk offsets
17901         from the bottom of the frame, rather than the bottom of the saved
17902         register area.  Measure reg_offset from the bottom of the frame
17903         rather than the bottom of the saved register area.
17904         (aarch64_save_callee_saves): Update accordingly.
17905         (aarch64_restore_callee_saves): Likewise.
17906         (aarch64_get_separate_components): Likewise.
17907         (aarch64_process_components): Likewise.
17909 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17911         * config/aarch64/aarch64.h (aarch64_frame::frame_size): Tweak comment.
17913 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17915         * config/aarch64/aarch64.h (aarch64_frame::hard_fp_offset): Rename
17916         to...
17917         (aarch64_frame::bytes_above_hard_fp): ...this.
17918         * config/aarch64/aarch64.cc (aarch64_layout_frame)
17919         (aarch64_expand_prologue): Update accordingly.
17920         (aarch64_initial_elimination_offset): Likewise.
17922 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17924         * config/aarch64/aarch64.h (aarch64_frame::locals_offset): Rename to...
17925         (aarch64_frame::bytes_above_locals): ...this.
17926         * config/aarch64/aarch64.cc (aarch64_layout_frame)
17927         (aarch64_initial_elimination_offset): Update accordingly.
17929 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17931         * config/aarch64/aarch64.cc (aarch64_expand_prologue): Move the
17932         calculation of chain_offset into the emit_frame_chain block.
17934 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17936         * config/aarch64/aarch64.h (aarch64_frame::callee_offset): Delete.
17937         * config/aarch64/aarch64.cc (aarch64_layout_frame): Remove
17938         callee_offset handling.
17939         (aarch64_save_callee_saves): Replace the start_offset parameter
17940         with a bytes_below_sp parameter.
17941         (aarch64_restore_callee_saves): Likewise.
17942         (aarch64_expand_prologue): Update accordingly.
17943         (aarch64_expand_epilogue): Likewise.
17945 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17947         * config/aarch64/aarch64.h (aarch64_frame::bytes_below_hard_fp): New
17948         field.
17949         * config/aarch64/aarch64.cc (aarch64_layout_frame): Initialize it.
17950         (aarch64_expand_epilogue): Use it instead of
17951         below_hard_fp_saved_regs_size.
17953 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17955         * config/aarch64/aarch64.h (aarch64_frame::bytes_below_saved_regs): New
17956         field.
17957         * config/aarch64/aarch64.cc (aarch64_layout_frame): Initialize it,
17958         and use it instead of crtl->outgoing_args_size.
17959         (aarch64_get_separate_components): Use bytes_below_saved_regs instead
17960         of outgoing_args_size.
17961         (aarch64_process_components): Likewise.
17963 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17965         * config/aarch64/aarch64.cc (aarch64_layout_frame): Explicitly
17966         allocate the frame in one go if there are no saved registers.
17968 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17970         * config/aarch64/aarch64.cc (aarch64_expand_prologue): Use
17971         chain_offset rather than callee_offset.
17973 2023-09-12  Richard Sandiford  <richard.sandiford@arm.com>
17975         * config/aarch64/aarch64.cc (aarch64_save_callee_saves): Use
17976         a local shorthand for cfun->machine->frame.
17977         (aarch64_restore_callee_saves, aarch64_get_separate_components):
17978         (aarch64_process_components): Likewise.
17979         (aarch64_allocate_and_probe_stack_space): Likewise.
17980         (aarch64_expand_prologue, aarch64_expand_epilogue): Likewise.
17981         (aarch64_layout_frame): Use existing shorthand for one more case.
17983 2023-09-12  Andrew Pinski  <apinski@marvell.com>
17985         PR tree-optimization/107881
17986         * match.pd (`(a CMP1 b) ^ (a CMP2 b)`): New pattern.
17987         (`(a CMP1 b) == (a CMP2 b)`): New pattern.
17989 2023-09-12  Pan Li  <pan2.li@intel.com>
17991         * config/riscv/riscv-vector-costs.h (struct range): Removed.
17993 2023-09-12  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
17995         * config/riscv/riscv-vector-costs.cc (get_last_live_range): New function.
17996         (compute_nregs_for_mode): Ditto.
17997         (live_range_conflict_p): Ditto.
17998         (max_number_of_live_regs): Ditto.
17999         (compute_lmul): Ditto.
18000         (costs::prefer_new_lmul_p): Ditto.
18001         (costs::better_main_loop_than_p): Ditto.
18002         * config/riscv/riscv-vector-costs.h (struct stmt_point): New struct.
18003         (struct var_live_range): Ditto.
18004         (struct autovec_info): Ditto.
18005         * config/riscv/t-riscv: Update makefile for COST model.
18007 2023-09-12  Jakub Jelinek  <jakub@redhat.com>
18009         * fold-const.cc (range_check_type): Handle BITINT_TYPE like
18010         OFFSET_TYPE.
18012 2023-09-12  Jakub Jelinek  <jakub@redhat.com>
18014         PR middle-end/111338
18015         * tree-ssa-sccvn.cc (struct vn_walk_cb_data): Add bufsize non-static
18016         data member.
18017         (vn_walk_cb_data::push_partial_def): Remove bufsize variable.
18018         (visit_nary_op): Avoid the BIT_AND_EXPR with constant rhs2
18019         optimization if type's precision is too large for
18020         vn_walk_cb_data::bufsize.
18022 2023-09-12  Gaius Mulley  <gaiusmod2@gmail.com>
18024         * doc/gm2.texi (Compiler options): Document new option
18025         -Wcase-enum.
18027 2023-09-12  Thomas Schwinge  <thomas@codesourcery.com>
18029         * doc/sourcebuild.texi (stack_size): Update.
18031 2023-09-12  Christoph Müllner  <christoph.muellner@vrull.eu>
18033         * config/riscv/bitmanip.md (*<optab>_not<mode>): Export INSN name.
18034         (<optab>_not<mode>3): Likewise.
18035         * config/riscv/riscv-protos.h (riscv_expand_strcmp): New
18036         prototype.
18037         * config/riscv/riscv-string.cc (GEN_EMIT_HELPER3): New helper
18038         macros.
18039         (GEN_EMIT_HELPER2): Likewise.
18040         (emit_strcmp_scalar_compare_byte): New function.
18041         (emit_strcmp_scalar_compare_subword): Likewise.
18042         (emit_strcmp_scalar_compare_word): Likewise.
18043         (emit_strcmp_scalar_load_and_compare): Likewise.
18044         (emit_strcmp_scalar_call_to_libc): Likewise.
18045         (emit_strcmp_scalar_result_calculation_nonul): Likewise.
18046         (emit_strcmp_scalar_result_calculation): Likewise.
18047         (riscv_expand_strcmp_scalar): Likewise.
18048         (riscv_expand_strcmp): Likewise.
18049         * config/riscv/riscv.md (*slt<u>_<X:mode><GPR:mode>): Export
18050         INSN name.
18051         (@slt<u>_<X:mode><GPR:mode>3): Likewise.
18052         (cmpstrnsi): Invoke expansion function for str(n)cmp.
18053         (cmpstrsi): Likewise.
18054         * config/riscv/riscv.opt: Add new parameter
18055         '-mstring-compare-inline-limit'.
18056         * doc/invoke.texi: Document new parameter
18057         '-mstring-compare-inline-limit'.
18059 2023-09-12  Christoph Müllner  <christoph.muellner@vrull.eu>
18061         * config.gcc: Add new object riscv-string.o.
18062         riscv-string.cc.
18063         * config/riscv/riscv-protos.h (riscv_expand_strlen):
18064         New function.
18065         * config/riscv/riscv.md (strlen<mode>): New expand INSN.
18066         * config/riscv/riscv.opt: New flag 'minline-strlen'.
18067         * config/riscv/t-riscv: Add new object riscv-string.o.
18068         * config/riscv/thead.md (th_rev<mode>2): Export INSN name.
18069         (th_rev<mode>2): Likewise.
18070         (th_tstnbz<mode>2): New INSN.
18071         * doc/invoke.texi: Document '-minline-strlen'.
18072         * emit-rtl.cc (emit_likely_jump_insn): New helper function.
18073         (emit_unlikely_jump_insn): Likewise.
18074         * rtl.h (emit_likely_jump_insn): New prototype.
18075         (emit_unlikely_jump_insn): Likewise.
18076         * config/riscv/riscv-string.cc: New file.
18078 2023-09-12  Thomas Schwinge  <thomas@codesourcery.com>
18080         * config/nvptx/nvptx.h (TARGET_USE_LOCAL_THUNK_ALIAS_P)
18081         (TARGET_SUPPORTS_ALIASES): Define.
18083 2023-09-12  Thomas Schwinge  <thomas@codesourcery.com>
18085         * doc/sourcebuild.texi (check-function-bodies): Update.
18087 2023-09-12  Tobias Burnus  <tobias@codesourcery.com>
18089         * gimplify.cc (gimplify_bind_expr): Check for
18090         insertion after variable cleanup.  Convert 'omp allocate'
18091         var-decl attribute to GOMP_alloc/GOMP_free calls.
18093 2023-09-12  xuli  <xuli1@eswincomputing.com>
18095         * config/riscv/riscv-vector-builtins-bases.cc: remove unused
18096                 parameter e and replace NULL_RTX with gcc_unreachable.
18098 2023-09-12  xuli  <xuli1@eswincomputing.com>
18100         * config/riscv/riscv-vector-builtins-bases.cc (class vcreate): New class.
18101         (BASE): Ditto.
18102         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
18103         * config/riscv/riscv-vector-builtins-functions.def (vcreate): Add vcreate support.
18104         * config/riscv/riscv-vector-builtins-shapes.cc (struct vcreate_def): Ditto.
18105         (SHAPE): Ditto.
18106         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
18107         * config/riscv/riscv-vector-builtins.cc: Add args type.
18109 2023-09-12  Fei Gao  <gaofei@eswincomputing.com>
18111         * config/riscv/riscv.cc
18112         (riscv_avoid_shrink_wrapping_separate): wrap the condition check in
18113         riscv_avoid_shrink_wrapping_separate.
18114         (riscv_avoid_multi_push):avoid multi push if shrink_wrapping_separate
18115         is active.
18116         (riscv_get_separate_components):call riscv_avoid_shrink_wrapping_separate
18118 2023-09-12  Fei Gao  <gaofei@eswincomputing.com>
18120         * shrink-wrap.cc (try_shrink_wrapping_separate):call
18121         use_shrink_wrapping_separate.
18122         (use_shrink_wrapping_separate): wrap the condition
18123         check in use_shrink_wrapping_separate.
18124         * shrink-wrap.h (use_shrink_wrapping_separate): add to extern
18126 2023-09-11  Andrew Pinski  <apinski@marvell.com>
18128         PR tree-optimization/111348
18129         * match.pd (`(a CMP b) ? minmax<a, c> : minmax<b, c>`): Add :c on
18130         the cmp part of the pattern.
18132 2023-09-11  Uros Bizjak  <ubizjak@gmail.com>
18134         PR target/111340
18135         * config/i386/i386.cc (output_pic_addr_const): Handle CONST_WIDE_INT.
18136         Call output_addr_const for CASE_CONST_SCALAR_INT.
18138 2023-09-11  Edwin Lu  <ewlu@rivosinc.com>
18140         * config/riscv/thead.md: Update types
18142 2023-09-11  Edwin Lu  <ewlu@rivosinc.com>
18144         * config/riscv/riscv.md: Update types
18146 2023-09-11  Edwin Lu  <ewlu@rivosinc.com>
18148         * config/riscv/riscv.md: Add "zicond" type
18149         * config/riscv/zicond.md: Update types
18151 2023-09-11  Edwin Lu  <ewlu@rivosinc.com>
18153         * config/riscv/riscv.md: Add "pushpop" and "mvpair" types
18154         * config/riscv/zc.md: Update types
18156 2023-09-11  Edwin Lu  <ewlu@rivosinc.com>
18158         * config/riscv/autovec-opt.md: Update types
18159         * config/riscv/autovec.md: likewise
18161 2023-09-11  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
18163         * config/s390/s390-builtins.def (s390_vec_signed_flt): Fix
18164         builtin flag.
18165         (s390_vec_unsigned_flt): Ditto.
18166         (s390_vec_revb_flt): Ditto.
18167         (s390_vec_reve_flt): Ditto.
18168         (s390_vclfnhs): Fix operand flags.
18169         (s390_vclfnls): Ditto.
18170         (s390_vcrnfs): Ditto.
18171         (s390_vcfn): Ditto.
18172         (s390_vcnf): Ditto.
18174 2023-09-11  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
18176         * config/s390/s390-builtins.def (O_U64): New.
18177         (O1_U64): Ditto.
18178         (O2_U64): Ditto.
18179         (O3_U64): Ditto.
18180         (O4_U64): Ditto.
18181         (O_M12): Change bit position.
18182         (O_S2): Ditto.
18183         (O_S3): Ditto.
18184         (O_S4): Ditto.
18185         (O_S5): Ditto.
18186         (O_S8): Ditto.
18187         (O_S12): Ditto.
18188         (O_S16): Ditto.
18189         (O_S32): Ditto.
18190         (O_ELEM): Ditto.
18191         (O_LIT): Ditto.
18192         (OB_DEF_VAR): Add operand constraints.
18193         (B_DEF): Ditto.
18194         * config/s390/s390.cc (s390_const_operand_ok): Honour 64 bit
18195         operands.
18197 2023-09-11  Andrew Pinski  <apinski@marvell.com>
18199         PR tree-optimization/111349
18200         * match.pd (`(a CMP CST1) ? max<a,CST2> : a`): Add :c on
18201         the cmp part of the pattern.
18203 2023-09-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18205         PR target/111311
18206         * config/riscv/riscv.opt: Set default as scalable vectorization.
18208 2023-09-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18210         * config/riscv/riscv-protos.h (get_all_predecessors): Remove.
18211         (get_all_successors): Ditto.
18212         * config/riscv/riscv-v.cc (get_all_predecessors): Ditto.
18213         (get_all_successors): Ditto.
18215 2023-09-11  Jakub Jelinek  <jakub@redhat.com>
18217         PR middle-end/111329
18218         * pretty-print.h (pp_wide_int): Rewrite from macro into inline
18219         function.  For printing values which don't fit into digit_buffer
18220         use out-of-line function.
18221         * wide-int-print.h (pp_wide_int_large): Declare.
18222         * wide-int-print.cc: Include pretty-print.h.
18223         (pp_wide_int_large): Define.
18225 2023-09-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18227         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::global_eliminate_vsetvl_insn):
18228         Use dominance analysis.
18229         (pass_vsetvl::init): Ditto.
18230         (pass_vsetvl::done): Ditto.
18232 2023-09-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18234         PR target/111311
18235         * config/riscv/autovec.md: Add VLS modes.
18236         * config/riscv/riscv-protos.h (cmp_lmul_le_one): New function.
18237         (cmp_lmul_gt_one): Ditto.
18238         * config/riscv/riscv-v.cc (cmp_lmul_le_one): Ditto.
18239         (cmp_lmul_gt_one): Ditto.
18240         * config/riscv/riscv.cc (riscv_print_operand): Add VLS modes.
18241         (riscv_vectorize_vec_perm_const): Ditto.
18242         * config/riscv/vector-iterators.md: Ditto.
18243         * config/riscv/vector.md: Ditto.
18245 2023-09-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18247         * config/riscv/autovec-vls.md (*mov<mode>_vls): New pattern.
18248         * config/riscv/vector-iterators.md: New iterator
18250 2023-09-11  Andrew Pinski  <apinski@marvell.com>
18252         PR tree-optimization/111346
18253         * match.pd (`X CMP MINMAX`): Add `:c` on the cmp part
18254         of the pattern
18256 2023-09-11  liuhongt  <hongtao.liu@intel.com>
18258         PR target/111306
18259         PR target/111335
18260         * config/i386/sse.md (int_comm): New int_attr.
18261         (fma_<complexopname>_<mode><sdc_maskz_name><round_name>):
18262         Remove % for Complex conjugate operations since they're not
18263         commutative.
18264         (fma_<complexpairopname>_<mode>_pair): Ditto.
18265         (<avx512>_<complexopname>_<mode>_mask<round_name>): Ditto.
18266         (cmul<conj_op><mode>3): Ditto.
18268 2023-09-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18270         * config/riscv/riscv-v.cc (shuffle_generic_patterns): Expand
18271         fixed-vlmax/vls vector permutation.
18273 2023-09-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18275         * config/riscv/riscv-v.cc (shuffle_compress_patterns): Avoid unnecessary slideup.
18277 2023-09-10  Andrew Pinski  <apinski@marvell.com>
18279         PR tree-optimization/111331
18280         * match.pd (`(a CMP CST1) ? max<a,CST2> : a`):
18281         Fix the LE/GE comparison to the correct value.
18282         * tree-ssa-phiopt.cc (minmax_replacement):
18283         Fix the LE/GE comparison for the
18284         `(a CMP CST1) ? max<a,CST2> : a` optimization.
18286 2023-09-10  Iain Sandoe  <iain@sandoe.co.uk>
18288         * config/darwin.cc (darwin_function_section): Place unlikely
18289         executed global init code into the standard cold section.
18291 2023-09-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18293         PR target/111311
18294         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::vsetvl_fusion): Add TDF_DETAILS.
18295         (pass_vsetvl::pre_vsetvl): Ditto.
18296         (pass_vsetvl::init): Ditto.
18297         (pass_vsetvl::lazy_vsetvl): Ditto.
18299 2023-09-09  Lulu Cheng  <chenglulu@loongson.cn>
18301         * config/loongarch/loongarch.md (mulsidi3_64bit):
18302         Field unsigned extension support.
18303         (<u>muldi3_highpart): Modify template name.
18304         (<u>mulsi3_highpart): Likewise.
18305         (<u>mulsidi3_64bit): Field unsigned extension support.
18306         (<su>muldi3_highpart): Modify muldi3_highpart to
18307         smuldi3_highpart.
18308         (<su>mulsi3_highpart): Modify mulsi3_highpart to
18309         smulsi3_highpart.
18311 2023-09-09  Xi Ruoyao  <xry111@xry111.site>
18313         * config/loongarch/loongarch.cc (loongarch_block_move_straight):
18314         Check precondition (delta must be a power of 2) and use
18315         popcount_hwi instead of a homebrew loop.
18317 2023-09-09  Xi Ruoyao  <xry111@xry111.site>
18319         * config/loongarch/loongarch.h (LARCH_MAX_MOVE_PER_INSN):
18320         Define to the maximum amount of bytes able to be loaded or
18321         stored with one machine instruction.
18322         * config/loongarch/loongarch.cc (loongarch_mode_for_move_size):
18323         New static function.
18324         (loongarch_block_move_straight): Call
18325         loongarch_mode_for_move_size for machine_mode to be moved.
18326         (loongarch_expand_block_move): Use LARCH_MAX_MOVE_PER_INSN
18327         instead of UNITS_PER_WORD.
18329 2023-09-09  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18331         * config/riscv/vector-iterators.md: Fix floating-point operations predicate.
18333 2023-09-09  Lehua Ding  <lehua.ding@rivai.ai>
18335         * fold-const.cc (can_min_p): New function.
18336         (poly_int_binop): Try fold MIN_EXPR.
18338 2023-09-08  Aldy Hernandez  <aldyh@redhat.com>
18340         * range-op-float.cc (foperator_ltgt::fold_range): Do not special
18341         case VREL_EQ nor call frelop_early_resolve.
18343 2023-09-08  Christoph Müllner  <christoph.muellner@vrull.eu>
18345         * config/riscv/thead.md (*extend<SHORT:mode><SUPERQI:mode>2_th_ext):
18346         Remove broken INSN.
18347         (*extendhi<SUPERQI:mode>2_th_ext): New INSN.
18348         (*extendqi<SUPERQI:mode>2_th_ext): New INSN.
18350 2023-09-08  Christoph Müllner  <christoph.muellner@vrull.eu>
18352         * config/riscv/thead.md: Use more appropriate mode attributes
18353         for extensions.
18355 2023-09-08  Guo Jie  <guojie@loongson.cn>
18357         * common/config/loongarch/loongarch-common.cc:
18358         (default_options loongarch_option_optimization_table):
18359         Default to -fsched-pressure.
18361 2023-09-08  Yang Yujie  <yangyujie@loongson.cn>
18363         * config.gcc: remove non-POSIX syntax "<<<".
18365 2023-09-08  Christoph Müllner  <christoph.muellner@vrull.eu>
18367         * config/riscv/bitmanip.md (*extend<SHORT:mode><SUPERQI:mode>2_zbb):
18368         Rename postfix to _bitmanip.
18369         (*extend<SHORT:mode><SUPERQI:mode>2_bitmanip): Renamed pattern.
18370         (*zero_extendhi<GPR:mode>2_zbb): Remove duplicated pattern.
18372 2023-09-08  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18374         * config/riscv/riscv.cc (riscv_pass_in_vector_p): Only allow RVV type.
18376 2023-09-08  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18378         * config/riscv/riscv.cc (riscv_hard_regno_nregs): Fix bug.
18380 2023-09-07  liuhongt  <hongtao.liu@intel.com>
18382         * config/i386/sse.md
18383         (<avx512>_vpermt2var<mode>3<sd_maskz_name>): New define_insn.
18384         (VHFBF_AVX512VL): New mode iterator.
18385         (VI2HFBF_AVX512VL): New mode iterator.
18387 2023-09-07  Aldy Hernandez  <aldyh@redhat.com>
18389         * value-range.h (contains_zero_p): Return false for undefined ranges.
18390         * range-op-float.cc (operator_gt::op1_op2_relation): Adjust for
18391         contains_zero_p change above.
18392         (operator_ge::op1_op2_relation): Same.
18393         (operator_equal::op1_op2_relation): Same.
18394         (operator_not_equal::op1_op2_relation): Same.
18395         (operator_lt::op1_op2_relation): Same.
18396         (operator_le::op1_op2_relation): Same.
18397         (operator_ge::op1_op2_relation): Same.
18398         * range-op.cc (operator_equal::op1_op2_relation): Same.
18399         (operator_not_equal::op1_op2_relation): Same.
18400         (operator_lt::op1_op2_relation): Same.
18401         (operator_le::op1_op2_relation): Same.
18402         (operator_cast::op1_range): Same.
18403         (set_nonzero_range_from_mask): Same.
18404         (operator_bitwise_xor::op1_range): Same.
18405         (operator_addr_expr::fold_range): Same.
18406         (operator_addr_expr::op1_range): Same.
18408 2023-09-07  Andrew MacLeod  <amacleod@redhat.com>
18410         PR tree-optimization/110875
18411         * gimple-range.cc (gimple_ranger::prefill_name): Only invoke
18412         cache-prefilling routine when the ssa-name has no global value.
18414 2023-09-07  Vladimir N. Makarov  <vmakarov@redhat.com>
18416         PR target/111225
18417         * lra-constraints.cc (goal_reuse_alt_p): New global flag.
18418         (process_alt_operands): Set up the flag.  Clear flag for chosen
18419         alternative with special memory constraints.
18420         (process_alt_operands): Set up used insn alternative depending on the flag.
18422 2023-09-07  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18424         * config/riscv/autovec-vls.md: Add VLS mask modes mov patterns.
18425         * config/riscv/riscv.md: Ditto.
18426         * config/riscv/vector-iterators.md: Ditto.
18427         * config/riscv/vector.md: Ditto.
18429 2023-09-07  David Malcolm  <dmalcolm@redhat.com>
18431         * diagnostic-core.h (error_meta): New decl.
18432         * diagnostic.cc (error_meta): New.
18434 2023-09-07  Jakub Jelinek  <jakub@redhat.com>
18436         PR c/102989
18437         * expr.cc (expand_expr_real_1): Don't call targetm.c.bitint_type_info
18438         inside gcc_assert, as later code relies on it filling info variable.
18439         * gimple-fold.cc (clear_padding_bitint_needs_padding_p,
18440         clear_padding_type): Likewise.
18441         * varasm.cc (output_constant): Likewise.
18442         * fold-const.cc (native_encode_int, native_interpret_int): Likewise.
18443         * stor-layout.cc (finish_bitfield_representative, layout_type):
18444         Likewise.
18445         * gimple-lower-bitint.cc (bitint_precision_kind): Likewise.
18447 2023-09-07  Xi Ruoyao  <xry111@xry111.site>
18449         PR target/111252
18450         * config/loongarch/loongarch-protos.h
18451         (loongarch_pre_reload_split): Declare new function.
18452         (loongarch_use_bstrins_for_ior_with_mask): Likewise.
18453         * config/loongarch/loongarch.cc
18454         (loongarch_pre_reload_split): Implement.
18455         (loongarch_use_bstrins_for_ior_with_mask): Likewise.
18456         * config/loongarch/predicates.md (ins_zero_bitmask_operand):
18457         New predicate.
18458         * config/loongarch/loongarch.md (bstrins_<mode>_for_mask):
18459         New define_insn_and_split.
18460         (bstrins_<mode>_for_ior_mask): Likewise.
18461         (define_peephole2): Further optimize code sequence produced by
18462         bstrins_<mode>_for_ior_mask if possible.
18464 2023-09-07  Richard Sandiford  <richard.sandiford@arm.com>
18466         * lra-eliminations.cc (lra_eliminate_regs_1): Use simplify_gen_binary
18467         rather than gen_rtx_PLUS.
18469 2023-09-07  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18471         PR target/111313
18472         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::cleanup_earliest_vsetvls): Remove.
18473         (pass_vsetvl::df_post_optimization): Remove incorrect function.
18475 2023-09-07  Tsukasa OI  <research_trasio@irq.a4lg.com>
18477         * common/config/riscv/riscv-common.cc (riscv_ext_flag_table):
18478         Parse 'XVentanaCondOps' extension.
18479         * config/riscv/riscv-opts.h (MASK_XVENTANACONDOPS): New.
18480         (TARGET_XVENTANACONDOPS): Ditto.
18481         (TARGET_ZICOND_LIKE): New to represent targets with conditional
18482         moves like 'Zicond'.  It includes RV64 + 'XVentanaCondOps'.
18483         * config/riscv/riscv.cc (riscv_rtx_costs): Replace TARGET_ZICOND
18484         with TARGET_ZICOND_LIKE.
18485         (riscv_expand_conditional_move): Ditto.
18486         * config/riscv/riscv.md (mov<mode>cc): Replace TARGET_ZICOND with
18487         TARGET_ZICOND_LIKE.
18488         * config/riscv/riscv.opt: Add new riscv_xventana_subext.
18489         * config/riscv/zicond.md: Modify description.
18490         (eqz_ventana): New to match corresponding czero instructions.
18491         (nez_ventana): Ditto.
18492         (*czero.<eqz>.<GPR><X>): Emit a 'XVentanaCondOps' instruction if
18493         'Zicond' is not available but 'XVentanaCondOps' + RV64 is.
18494         (*czero.<eqz>.<GPR><X>): Ditto.
18495         (*czero.eqz.<GPR><X>.opt1): Ditto.
18496         (*czero.nez.<GPR><X>.opt2): Ditto.
18498 2023-09-06  Ian Lance Taylor  <iant@golang.org>
18500         PR go/111310
18501         * godump.cc (go_format_type): Handle BITINT_TYPE.
18503 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
18505         PR c/102989
18506         * tree.cc (build_one_cst, build_minus_one_cst): Handle BITINT_TYPE
18507         like INTEGER_TYPE.
18509 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
18511         PR c/102989
18512         * gimple-lower-bitint.cc (bitint_large_huge::if_then_else,
18513         bitint_large_huge::if_then_if_then_else): Use make_single_succ_edge
18514         rather than make_edge, initialize bb->count.
18516 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
18518         PR c/102989
18519         * doc/libgcc.texi (Bit-precise integer arithmetic functions):
18520         Document general rules for _BitInt support library functions
18521         and document __mulbitint3 and __divmodbitint4.
18522         (Conversion functions): Document __fix{s,d,x,t}fbitint,
18523         __floatbitint{s,d,x,t,h,b}f, __bid_fix{s,d,t}dbitint and
18524         __bid_floatbitint{s,d,t}d.
18526 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
18528         PR c/102989
18529         * glimits.h (BITINT_MAXWIDTH): Define if __BITINT_MAXWIDTH__ is
18530         predefined.
18532 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
18534         PR c/102989
18535         * internal-fn.cc (expand_ubsan_result_store): Add LHS, MODE and
18536         DO_ERROR arguments.  For non-mode precision BITINT_TYPE results
18537         check if all padding bits up to mode precision are zeros or sign
18538         bit copies and if not, jump to DO_ERROR.
18539         (expand_addsub_overflow, expand_neg_overflow, expand_mul_overflow):
18540         Adjust expand_ubsan_result_store callers.
18541         * ubsan.cc: Include target.h and langhooks.h.
18542         (ubsan_encode_value): Pass BITINT_TYPE values which fit into pointer
18543         size converted to pointer sized integer, pass BITINT_TYPE values
18544         which fit into TImode (if supported) or DImode as those integer types
18545         or otherwise for now punt (pass 0).
18546         (ubsan_type_descriptor): Handle BITINT_TYPE.  For pstyle of
18547         UBSAN_PRINT_FORCE_INT use TK_Integer (0x0000) mode with a
18548         TImode/DImode precision rather than TK_Unknown used otherwise for
18549         large/huge BITINT_TYPEs.
18550         (instrument_si_overflow): Instrument BITINT_TYPE operations even when
18551         they don't have mode precision.
18552         * ubsan.h (enum ubsan_print_style): New enumerator.
18554 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
18556         PR c/102989
18557         * config/i386/i386.cc (classify_argument): Handle BITINT_TYPE.
18558         (ix86_bitint_type_info): New function.
18559         (TARGET_C_BITINT_TYPE_INFO): Redefine.
18561 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
18563         PR c/102989
18564         * Makefile.in (OBJS): Add gimple-lower-bitint.o.
18565         * passes.def: Add pass_lower_bitint after pass_lower_complex and
18566         pass_lower_bitint_O0 after pass_lower_complex_O0.
18567         * tree-pass.h (PROP_gimple_lbitint): Define.
18568         (make_pass_lower_bitint_O0, make_pass_lower_bitint): Declare.
18569         * gimple-lower-bitint.h: New file.
18570         * tree-ssa-live.h (struct _var_map): Add bitint member.
18571         (init_var_map): Adjust declaration.
18572         (region_contains_p): Handle map->bitint like map->outofssa_p.
18573         * tree-ssa-live.cc (init_var_map): Add BITINT argument, initialize
18574         map->bitint and set map->outofssa_p to false if it is non-NULL.
18575         * tree-ssa-coalesce.cc: Include gimple-lower-bitint.h.
18576         (build_ssa_conflict_graph): Call build_bitint_stmt_ssa_conflicts if
18577         map->bitint.
18578         (create_coalesce_list_for_region): For map->bitint ignore SSA_NAMEs
18579         not in that bitmap, and allow res without default def.
18580         (compute_optimized_partition_bases): In map->bitint mode try hard to
18581         coalesce any SSA_NAMEs with the same size.
18582         (coalesce_bitint): New function.
18583         (coalesce_ssa_name): In map->bitint mode, or map->bitmap into
18584         used_in_copies and call coalesce_bitint.
18585         * gimple-lower-bitint.cc: New file.
18587 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
18589         PR c/102989
18590         * tree.def (BITINT_TYPE): New type.
18591         * tree.h (TREE_CHECK6, TREE_NOT_CHECK6): Define.
18592         (NUMERICAL_TYPE_CHECK, INTEGRAL_TYPE_P): Include
18593         BITINT_TYPE.
18594         (BITINT_TYPE_P): Define.
18595         (CONSTRUCTOR_BITFIELD_P): Return true even for BLKmode bit-fields if
18596         they have BITINT_TYPE type.
18597         (tree_check6, tree_not_check6): New inline functions.
18598         (any_integral_type_check): Include BITINT_TYPE.
18599         (build_bitint_type): Declare.
18600         * tree.cc (tree_code_size, wide_int_to_tree_1, cache_integer_cst,
18601         build_zero_cst, type_hash_canon_hash, type_cache_hasher::equal,
18602         type_hash_canon): Handle BITINT_TYPE.
18603         (bitint_type_cache): New variable.
18604         (build_bitint_type): New function.
18605         (signed_or_unsigned_type_for, verify_type_variant, verify_type):
18606         Handle BITINT_TYPE.
18607         (tree_cc_finalize): Free bitint_type_cache.
18608         * builtins.cc (type_to_class): Handle BITINT_TYPE.
18609         (fold_builtin_unordered_cmp): Handle BITINT_TYPE like INTEGER_TYPE.
18610         * cfgexpand.cc (expand_debug_expr): Punt on BLKmode BITINT_TYPE
18611         INTEGER_CSTs.
18612         * convert.cc (convert_to_pointer_1, convert_to_real_1,
18613         convert_to_complex_1): Handle BITINT_TYPE like INTEGER_TYPE.
18614         (convert_to_integer_1): Likewise.  For BITINT_TYPE don't check
18615         GET_MODE_PRECISION (TYPE_MODE (type)).
18616         * doc/generic.texi (BITINT_TYPE): Document.
18617         * doc/tm.texi.in (TARGET_C_BITINT_TYPE_INFO): New.
18618         * doc/tm.texi: Regenerated.
18619         * dwarf2out.cc (base_type_die, is_base_type, modified_type_die,
18620         gen_type_die_with_usage): Handle BITINT_TYPE.
18621         (rtl_for_decl_init): Punt on BLKmode BITINT_TYPE INTEGER_CSTs or
18622         handle those which fit into shwi.
18623         * expr.cc (expand_expr_real_1): Define EXTEND_BITINT macro, reduce
18624         to bitfield precision reads from BITINT_TYPE vars, parameters or
18625         memory locations.  Expand large/huge BITINT_TYPE INTEGER_CSTs into
18626         memory.
18627         * fold-const.cc (fold_convert_loc, make_range_step): Handle
18628         BITINT_TYPE.
18629         (extract_muldiv_1): For BITINT_TYPE use TYPE_PRECISION rather than
18630         GET_MODE_SIZE (SCALAR_INT_TYPE_MODE).
18631         (native_encode_int, native_interpret_int, native_interpret_expr):
18632         Handle BITINT_TYPE.
18633         * gimple-expr.cc (useless_type_conversion_p): Make BITINT_TYPE
18634         to some other integral type or vice versa conversions non-useless.
18635         * gimple-fold.cc (gimple_fold_builtin_memset): Punt for BITINT_TYPE.
18636         (clear_padding_unit): Mention in comment that _BitInt types don't need
18637         to fit either.
18638         (clear_padding_bitint_needs_padding_p): New function.
18639         (clear_padding_type_may_have_padding_p): Handle BITINT_TYPE.
18640         (clear_padding_type): Likewise.
18641         * internal-fn.cc (expand_mul_overflow): For unsigned non-mode
18642         precision operands force pos_neg? to 1.
18643         (expand_MULBITINT, expand_DIVMODBITINT, expand_FLOATTOBITINT,
18644         expand_BITINTTOFLOAT): New functions.
18645         * internal-fn.def (MULBITINT, DIVMODBITINT, FLOATTOBITINT,
18646         BITINTTOFLOAT): New internal functions.
18647         * internal-fn.h (expand_MULBITINT, expand_DIVMODBITINT,
18648         expand_FLOATTOBITINT, expand_BITINTTOFLOAT): Declare.
18649         * match.pd (non-equality compare simplifications from fold_binary):
18650         Punt if TYPE_MODE (arg1_type) is BLKmode.
18651         * pretty-print.h (pp_wide_int): Handle printing of large precision
18652         wide_ints which would buffer overflow digit_buffer.
18653         * stor-layout.cc (finish_bitfield_representative): For bit-fields
18654         with BITINT_TYPE, prefer representatives with precisions in
18655         multiple of limb precision.
18656         (layout_type): Handle BITINT_TYPE.  Handle COMPLEX_TYPE with BLKmode
18657         element type and assert it is BITINT_TYPE.
18658         * target.def (bitint_type_info): New C target hook.
18659         * target.h (struct bitint_info): New type.
18660         * targhooks.cc (default_bitint_type_info): New function.
18661         * targhooks.h (default_bitint_type_info): Declare.
18662         * tree-pretty-print.cc (dump_generic_node): Handle BITINT_TYPE.
18663         Handle printing large wide_ints which would buffer overflow
18664         digit_buffer.
18665         * tree-ssa-sccvn.cc: Include target.h.
18666         (eliminate_dom_walker::eliminate_stmt): Punt for large/huge
18667         BITINT_TYPE.
18668         * tree-switch-conversion.cc (jump_table_cluster::emit): For more than
18669         64-bit BITINT_TYPE subtract low bound from expression and cast to
18670         64-bit integer type both the controlling expression and case labels.
18671         * typeclass.h (enum type_class): Add bitint_type_class enumerator.
18672         * varasm.cc (output_constant): Handle BITINT_TYPE INTEGER_CSTs.
18673         * vr-values.cc (check_for_binary_op_overflow): Use widest2_int rather
18674         than widest_int.
18675         (simplify_using_ranges::simplify_internal_call_using_ranges): Use
18676         unsigned_type_for rather than build_nonstandard_integer_type.
18678 2023-09-06  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18680         PR target/111296
18681         * config/riscv/riscv.cc (riscv_modes_tieable_p): Fix incorrect mode
18682         tieable for RVV modes.
18684 2023-09-06  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18686         PR target/111295
18687         * config/riscv/riscv-vsetvl.cc (insert_vsetvl): Bug fix.
18689 2023-09-06  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
18691         * config/riscv/riscv-vector-switch.def (VLS_ENTRY): Remove TARGET_64BIT
18693 2023-09-06  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
18695         * config/xtensa/xtensa.cc (xtensa_expand_scc):
18696         Add code for particular constants (only 0 and INT_MIN for now)
18697         for EQ/NE boolean evaluation in SImode.
18698         * config/xtensa/xtensa.md (*eqne_INT_MIN): Remove because its
18699         implementation has been integrated into the above.
18701 2023-09-06  Lehua Ding  <lehua.ding@rivai.ai>
18703         PR target/111232
18704         * config/riscv/autovec-opt.md (@pred_single_widen_mul<any_extend:su><mode>):
18705         Delete.
18706         (*pred_widen_mulsu<mode>): Delete.
18707         (*pred_single_widen_mul<mode>): Delete.
18708         (*dual_widen_<any_widen_binop:optab><any_extend:su><mode>):
18709         Add new combine patterns.
18710         (*single_widen_sub<any_extend:su><mode>): Ditto.
18711         (*single_widen_add<any_extend:su><mode>): Ditto.
18712         (*single_widen_mult<any_extend:su><mode>): Ditto.
18713         (*dual_widen_mulsu<mode>): Ditto.
18714         (*dual_widen_mulus<mode>): Ditto.
18715         (*dual_widen_<optab><mode>): Ditto.
18716         (*single_widen_add<mode>): Ditto.
18717         (*single_widen_sub<mode>): Ditto.
18718         (*single_widen_mult<mode>): Ditto.
18719         * config/riscv/autovec.md (<optab><mode>3):
18720         Change define_expand to define_insn_and_split.
18721         (<optab><mode>2): Ditto.
18722         (abs<mode>2): Ditto.
18723         (smul<mode>3_highpart): Ditto.
18724         (umul<mode>3_highpart): Ditto.
18726 2023-09-06  Lehua Ding  <lehua.ding@rivai.ai>
18728         * config/riscv/riscv-protos.h (riscv_declare_function_name): Add protos.
18729         (riscv_asm_output_alias): Ditto.
18730         (riscv_asm_output_external): Ditto.
18731         * config/riscv/riscv.cc (riscv_asm_output_variant_cc):
18732         Output .variant_cc directive for vector function.
18733         (riscv_declare_function_name): Ditto.
18734         (riscv_asm_output_alias): Ditto.
18735         (riscv_asm_output_external): Ditto.
18736         * config/riscv/riscv.h (ASM_DECLARE_FUNCTION_NAME):
18737         Implement ASM_DECLARE_FUNCTION_NAME.
18738         (ASM_OUTPUT_DEF_FROM_DECLS): Implement ASM_OUTPUT_DEF_FROM_DECLS.
18739         (ASM_OUTPUT_EXTERNAL): Implement ASM_OUTPUT_EXTERNAL.
18741 2023-09-06  Lehua Ding  <lehua.ding@rivai.ai>
18743         * config/riscv/riscv-sr.cc (riscv_remove_unneeded_save_restore_calls): Pass riscv_cc.
18744         * config/riscv/riscv.cc (struct riscv_frame_info): Add new fileds.
18745         (riscv_frame_info::reset): Reset new fileds.
18746         (riscv_call_tls_get_addr): Pass riscv_cc.
18747         (riscv_function_arg): Return riscv_cc for call patterm.
18748         (get_riscv_cc): New function return riscv_cc from rtl call_insn.
18749         (riscv_insn_callee_abi): Implement TARGET_INSN_CALLEE_ABI.
18750         (riscv_save_reg_p): Add vector callee-saved check.
18751         (riscv_stack_align): Add vector save area comment.
18752         (riscv_compute_frame_info): Ditto.
18753         (riscv_restore_reg): Update for type change.
18754         (riscv_for_each_saved_v_reg): New function save vector registers.
18755         (riscv_first_stack_step): Handle funciton with vector callee-saved registers.
18756         (riscv_expand_prologue): Ditto.
18757         (riscv_expand_epilogue): Ditto.
18758         (riscv_output_mi_thunk): Pass riscv_cc.
18759         (TARGET_INSN_CALLEE_ABI): Implement TARGET_INSN_CALLEE_ABI.
18760         * config/riscv/riscv.h (get_riscv_cc): Export get_riscv_cc function.
18761         * config/riscv/riscv.md: Add CALLEE_CC operand for call pattern.
18763 2023-09-06  Lehua Ding  <lehua.ding@rivai.ai>
18765         * config/riscv/riscv-protos.h (builtin_type_p): New function for checking vector type.
18766         * config/riscv/riscv-vector-builtins.cc (builtin_type_p): Ditto.
18767         * config/riscv/riscv.cc (struct riscv_arg_info): New fields.
18768         (riscv_init_cumulative_args): Setup variant_cc field.
18769         (riscv_vector_type_p): New function for checking vector type.
18770         (riscv_hard_regno_nregs): Hoist declare.
18771         (riscv_get_vector_arg): Subroutine of riscv_get_arg_info.
18772         (riscv_get_arg_info): Support vector cc.
18773         (riscv_function_arg_advance): Update cum.
18774         (riscv_pass_by_reference): Handle vector args.
18775         (riscv_v_abi): New function return vector abi.
18776         (riscv_return_value_is_vector_type_p): New function for check vector arguments.
18777         (riscv_arguments_is_vector_type_p): New function for check vector returns.
18778         (riscv_fntype_abi): Implement TARGET_FNTYPE_ABI.
18779         (TARGET_FNTYPE_ABI): Implement TARGET_FNTYPE_ABI.
18780         * config/riscv/riscv.h (GCC_RISCV_H): Define macros for vector abi.
18781         (MAX_ARGS_IN_VECTOR_REGISTERS): Ditto.
18782         (MAX_ARGS_IN_MASK_REGISTERS): Ditto.
18783         (V_ARG_FIRST): Ditto.
18784         (V_ARG_LAST): Ditto.
18785         (enum riscv_cc): Define all RISCV_CC variants.
18786         * config/riscv/riscv.opt: Add --param=riscv-vector-abi.
18788 2023-09-06  Lehua Ding  <lehua.ding@rivai.ai>
18790         * config/riscv/autovec-opt.md (*cond_<optab><mode>):
18791         Add sqrt + vcond_mask combine pattern.
18792         * config/riscv/autovec.md (<optab><mode>2):
18793         Change define_expand to define_insn_and_split.
18795 2023-09-06  Jason Merrill  <jason@redhat.com>
18797         * common.opt: Update -fabi-version=19.
18799 2023-09-06  Tsukasa OI  <research_trasio@irq.a4lg.com>
18801         * config/riscv/zicond.md: Add closing parent to a comment.
18803 2023-09-06  Tsukasa OI  <research_trasio@irq.a4lg.com>
18805         * config/riscv/riscv.cc (riscv_expand_conditional_move): Force
18806         large constant cons/alt into a register.
18808 2023-09-05  Christoph Müllner  <christoph.muellner@vrull.eu>
18810         * config/riscv/riscv.cc (riscv_build_integer_1): Don't
18811         require one zero bit in the upper 32 bits for LI+RORI synthesis.
18813 2023-09-05  Jeff Law  <jlaw@ventanamicro.com>
18815         * config/riscv/bitmanip.md (bswapsi2): Expose for TARGET_64BIT.
18817 2023-09-05  Andrew Pinski  <apinski@marvell.com>
18819         PR tree-optimization/98710
18820         * match.pd (`(x | c) & ~(y | c)`, `(x & c) | ~(y & c)`): New pattern.
18821         (`x & ~(y | x)`, `x | ~(y & x)`): New patterns.
18823 2023-09-05  Andrew Pinski  <apinski@marvell.com>
18825         PR tree-optimization/103536
18826         * match.pd (`(x | y) & (x & z)`,
18827         `(x & y) | (x | z)`): New patterns.
18829 2023-09-05  Andrew Pinski  <apinski@marvell.com>
18831         PR tree-optimization/107137
18832         * match.pd (`(nop_convert)-(convert)a`): New pattern.
18834 2023-09-05  Andrew Pinski  <apinski@marvell.com>
18836         PR tree-optimization/96694
18837         * match.pd (`~MAX(~X, Y)`, `~MIN(~X, Y)`): New patterns.
18839 2023-09-05  Andrew Pinski  <apinski@marvell.com>
18841         PR tree-optimization/105832
18842         * match.pd (`(1 >> X) != 0`): New pattern
18844 2023-09-05  Edwin Lu  <ewlu@rivosinc.com>
18846         * config/riscv/riscv.md: Update/Add types
18848 2023-09-05  Edwin Lu  <ewlu@rivosinc.com>
18850         * config/riscv/pic.md: Update types
18852 2023-09-05  Christoph Müllner  <christoph.muellner@vrull.eu>
18854         * config/riscv/riscv.cc (riscv_build_integer_1): Enable constant
18855         synthesis with rotate-right for XTheadBb.
18857 2023-09-05  Vineet Gupta  <vineetg@rivosinc.com>
18859         * config/riscv/zicond.md: Fix op2 pattern.
18861 2023-09-05  Szabolcs Nagy  <szabolcs.nagy@arm.com>
18863         * config/aarch64/aarch64.h (AARCH64_ISA_RCPC): Remove dup.
18865 2023-09-05  Xi Ruoyao  <xry111@xry111.site>
18867         * config/loongarch/loongarch-opts.h (HAVE_AS_EXPLICIT_RELOCS):
18868         Define to 0 if not defined yet.
18870 2023-09-05  Kito Cheng  <kito.cheng@sifive.com>
18872         * config/riscv/linux.h (TARGET_ASM_FILE_END): Move ...
18873         * config/riscv/riscv.cc (TARGET_ASM_FILE_END): to here.
18875 2023-09-05  Pan Li  <pan2.li@intel.com>
18877         * config/riscv/autovec-vls.md (copysign<mode>3): New pattern.
18878         * config/riscv/vector.md: Extend iterator for VLS.
18880 2023-09-05  Lulu Cheng  <chenglulu@loongson.cn>
18882         * config.gcc: Export the header file lasxintrin.h.
18883         * config/loongarch/loongarch-builtins.cc (enum loongarch_builtin_type):
18884         Add Loongson ASX builtin functions support.
18885         (AVAIL_ALL): Ditto.
18886         (LASX_BUILTIN): Ditto.
18887         (LASX_NO_TARGET_BUILTIN): Ditto.
18888         (LASX_BUILTIN_TEST_BRANCH): Ditto.
18889         (CODE_FOR_lasx_xvsadd_b): Ditto.
18890         (CODE_FOR_lasx_xvsadd_h): Ditto.
18891         (CODE_FOR_lasx_xvsadd_w): Ditto.
18892         (CODE_FOR_lasx_xvsadd_d): Ditto.
18893         (CODE_FOR_lasx_xvsadd_bu): Ditto.
18894         (CODE_FOR_lasx_xvsadd_hu): Ditto.
18895         (CODE_FOR_lasx_xvsadd_wu): Ditto.
18896         (CODE_FOR_lasx_xvsadd_du): Ditto.
18897         (CODE_FOR_lasx_xvadd_b): Ditto.
18898         (CODE_FOR_lasx_xvadd_h): Ditto.
18899         (CODE_FOR_lasx_xvadd_w): Ditto.
18900         (CODE_FOR_lasx_xvadd_d): Ditto.
18901         (CODE_FOR_lasx_xvaddi_bu): Ditto.
18902         (CODE_FOR_lasx_xvaddi_hu): Ditto.
18903         (CODE_FOR_lasx_xvaddi_wu): Ditto.
18904         (CODE_FOR_lasx_xvaddi_du): Ditto.
18905         (CODE_FOR_lasx_xvand_v): Ditto.
18906         (CODE_FOR_lasx_xvandi_b): Ditto.
18907         (CODE_FOR_lasx_xvbitsel_v): Ditto.
18908         (CODE_FOR_lasx_xvseqi_b): Ditto.
18909         (CODE_FOR_lasx_xvseqi_h): Ditto.
18910         (CODE_FOR_lasx_xvseqi_w): Ditto.
18911         (CODE_FOR_lasx_xvseqi_d): Ditto.
18912         (CODE_FOR_lasx_xvslti_b): Ditto.
18913         (CODE_FOR_lasx_xvslti_h): Ditto.
18914         (CODE_FOR_lasx_xvslti_w): Ditto.
18915         (CODE_FOR_lasx_xvslti_d): Ditto.
18916         (CODE_FOR_lasx_xvslti_bu): Ditto.
18917         (CODE_FOR_lasx_xvslti_hu): Ditto.
18918         (CODE_FOR_lasx_xvslti_wu): Ditto.
18919         (CODE_FOR_lasx_xvslti_du): Ditto.
18920         (CODE_FOR_lasx_xvslei_b): Ditto.
18921         (CODE_FOR_lasx_xvslei_h): Ditto.
18922         (CODE_FOR_lasx_xvslei_w): Ditto.
18923         (CODE_FOR_lasx_xvslei_d): Ditto.
18924         (CODE_FOR_lasx_xvslei_bu): Ditto.
18925         (CODE_FOR_lasx_xvslei_hu): Ditto.
18926         (CODE_FOR_lasx_xvslei_wu): Ditto.
18927         (CODE_FOR_lasx_xvslei_du): Ditto.
18928         (CODE_FOR_lasx_xvdiv_b): Ditto.
18929         (CODE_FOR_lasx_xvdiv_h): Ditto.
18930         (CODE_FOR_lasx_xvdiv_w): Ditto.
18931         (CODE_FOR_lasx_xvdiv_d): Ditto.
18932         (CODE_FOR_lasx_xvdiv_bu): Ditto.
18933         (CODE_FOR_lasx_xvdiv_hu): Ditto.
18934         (CODE_FOR_lasx_xvdiv_wu): Ditto.
18935         (CODE_FOR_lasx_xvdiv_du): Ditto.
18936         (CODE_FOR_lasx_xvfadd_s): Ditto.
18937         (CODE_FOR_lasx_xvfadd_d): Ditto.
18938         (CODE_FOR_lasx_xvftintrz_w_s): Ditto.
18939         (CODE_FOR_lasx_xvftintrz_l_d): Ditto.
18940         (CODE_FOR_lasx_xvftintrz_wu_s): Ditto.
18941         (CODE_FOR_lasx_xvftintrz_lu_d): Ditto.
18942         (CODE_FOR_lasx_xvffint_s_w): Ditto.
18943         (CODE_FOR_lasx_xvffint_d_l): Ditto.
18944         (CODE_FOR_lasx_xvffint_s_wu): Ditto.
18945         (CODE_FOR_lasx_xvffint_d_lu): Ditto.
18946         (CODE_FOR_lasx_xvfsub_s): Ditto.
18947         (CODE_FOR_lasx_xvfsub_d): Ditto.
18948         (CODE_FOR_lasx_xvfmul_s): Ditto.
18949         (CODE_FOR_lasx_xvfmul_d): Ditto.
18950         (CODE_FOR_lasx_xvfdiv_s): Ditto.
18951         (CODE_FOR_lasx_xvfdiv_d): Ditto.
18952         (CODE_FOR_lasx_xvfmax_s): Ditto.
18953         (CODE_FOR_lasx_xvfmax_d): Ditto.
18954         (CODE_FOR_lasx_xvfmin_s): Ditto.
18955         (CODE_FOR_lasx_xvfmin_d): Ditto.
18956         (CODE_FOR_lasx_xvfsqrt_s): Ditto.
18957         (CODE_FOR_lasx_xvfsqrt_d): Ditto.
18958         (CODE_FOR_lasx_xvflogb_s): Ditto.
18959         (CODE_FOR_lasx_xvflogb_d): Ditto.
18960         (CODE_FOR_lasx_xvmax_b): Ditto.
18961         (CODE_FOR_lasx_xvmax_h): Ditto.
18962         (CODE_FOR_lasx_xvmax_w): Ditto.
18963         (CODE_FOR_lasx_xvmax_d): Ditto.
18964         (CODE_FOR_lasx_xvmaxi_b): Ditto.
18965         (CODE_FOR_lasx_xvmaxi_h): Ditto.
18966         (CODE_FOR_lasx_xvmaxi_w): Ditto.
18967         (CODE_FOR_lasx_xvmaxi_d): Ditto.
18968         (CODE_FOR_lasx_xvmax_bu): Ditto.
18969         (CODE_FOR_lasx_xvmax_hu): Ditto.
18970         (CODE_FOR_lasx_xvmax_wu): Ditto.
18971         (CODE_FOR_lasx_xvmax_du): Ditto.
18972         (CODE_FOR_lasx_xvmaxi_bu): Ditto.
18973         (CODE_FOR_lasx_xvmaxi_hu): Ditto.
18974         (CODE_FOR_lasx_xvmaxi_wu): Ditto.
18975         (CODE_FOR_lasx_xvmaxi_du): Ditto.
18976         (CODE_FOR_lasx_xvmin_b): Ditto.
18977         (CODE_FOR_lasx_xvmin_h): Ditto.
18978         (CODE_FOR_lasx_xvmin_w): Ditto.
18979         (CODE_FOR_lasx_xvmin_d): Ditto.
18980         (CODE_FOR_lasx_xvmini_b): Ditto.
18981         (CODE_FOR_lasx_xvmini_h): Ditto.
18982         (CODE_FOR_lasx_xvmini_w): Ditto.
18983         (CODE_FOR_lasx_xvmini_d): Ditto.
18984         (CODE_FOR_lasx_xvmin_bu): Ditto.
18985         (CODE_FOR_lasx_xvmin_hu): Ditto.
18986         (CODE_FOR_lasx_xvmin_wu): Ditto.
18987         (CODE_FOR_lasx_xvmin_du): Ditto.
18988         (CODE_FOR_lasx_xvmini_bu): Ditto.
18989         (CODE_FOR_lasx_xvmini_hu): Ditto.
18990         (CODE_FOR_lasx_xvmini_wu): Ditto.
18991         (CODE_FOR_lasx_xvmini_du): Ditto.
18992         (CODE_FOR_lasx_xvmod_b): Ditto.
18993         (CODE_FOR_lasx_xvmod_h): Ditto.
18994         (CODE_FOR_lasx_xvmod_w): Ditto.
18995         (CODE_FOR_lasx_xvmod_d): Ditto.
18996         (CODE_FOR_lasx_xvmod_bu): Ditto.
18997         (CODE_FOR_lasx_xvmod_hu): Ditto.
18998         (CODE_FOR_lasx_xvmod_wu): Ditto.
18999         (CODE_FOR_lasx_xvmod_du): Ditto.
19000         (CODE_FOR_lasx_xvmul_b): Ditto.
19001         (CODE_FOR_lasx_xvmul_h): Ditto.
19002         (CODE_FOR_lasx_xvmul_w): Ditto.
19003         (CODE_FOR_lasx_xvmul_d): Ditto.
19004         (CODE_FOR_lasx_xvclz_b): Ditto.
19005         (CODE_FOR_lasx_xvclz_h): Ditto.
19006         (CODE_FOR_lasx_xvclz_w): Ditto.
19007         (CODE_FOR_lasx_xvclz_d): Ditto.
19008         (CODE_FOR_lasx_xvnor_v): Ditto.
19009         (CODE_FOR_lasx_xvor_v): Ditto.
19010         (CODE_FOR_lasx_xvori_b): Ditto.
19011         (CODE_FOR_lasx_xvnori_b): Ditto.
19012         (CODE_FOR_lasx_xvpcnt_b): Ditto.
19013         (CODE_FOR_lasx_xvpcnt_h): Ditto.
19014         (CODE_FOR_lasx_xvpcnt_w): Ditto.
19015         (CODE_FOR_lasx_xvpcnt_d): Ditto.
19016         (CODE_FOR_lasx_xvxor_v): Ditto.
19017         (CODE_FOR_lasx_xvxori_b): Ditto.
19018         (CODE_FOR_lasx_xvsll_b): Ditto.
19019         (CODE_FOR_lasx_xvsll_h): Ditto.
19020         (CODE_FOR_lasx_xvsll_w): Ditto.
19021         (CODE_FOR_lasx_xvsll_d): Ditto.
19022         (CODE_FOR_lasx_xvslli_b): Ditto.
19023         (CODE_FOR_lasx_xvslli_h): Ditto.
19024         (CODE_FOR_lasx_xvslli_w): Ditto.
19025         (CODE_FOR_lasx_xvslli_d): Ditto.
19026         (CODE_FOR_lasx_xvsra_b): Ditto.
19027         (CODE_FOR_lasx_xvsra_h): Ditto.
19028         (CODE_FOR_lasx_xvsra_w): Ditto.
19029         (CODE_FOR_lasx_xvsra_d): Ditto.
19030         (CODE_FOR_lasx_xvsrai_b): Ditto.
19031         (CODE_FOR_lasx_xvsrai_h): Ditto.
19032         (CODE_FOR_lasx_xvsrai_w): Ditto.
19033         (CODE_FOR_lasx_xvsrai_d): Ditto.
19034         (CODE_FOR_lasx_xvsrl_b): Ditto.
19035         (CODE_FOR_lasx_xvsrl_h): Ditto.
19036         (CODE_FOR_lasx_xvsrl_w): Ditto.
19037         (CODE_FOR_lasx_xvsrl_d): Ditto.
19038         (CODE_FOR_lasx_xvsrli_b): Ditto.
19039         (CODE_FOR_lasx_xvsrli_h): Ditto.
19040         (CODE_FOR_lasx_xvsrli_w): Ditto.
19041         (CODE_FOR_lasx_xvsrli_d): Ditto.
19042         (CODE_FOR_lasx_xvsub_b): Ditto.
19043         (CODE_FOR_lasx_xvsub_h): Ditto.
19044         (CODE_FOR_lasx_xvsub_w): Ditto.
19045         (CODE_FOR_lasx_xvsub_d): Ditto.
19046         (CODE_FOR_lasx_xvsubi_bu): Ditto.
19047         (CODE_FOR_lasx_xvsubi_hu): Ditto.
19048         (CODE_FOR_lasx_xvsubi_wu): Ditto.
19049         (CODE_FOR_lasx_xvsubi_du): Ditto.
19050         (CODE_FOR_lasx_xvpackod_d): Ditto.
19051         (CODE_FOR_lasx_xvpackev_d): Ditto.
19052         (CODE_FOR_lasx_xvpickod_d): Ditto.
19053         (CODE_FOR_lasx_xvpickev_d): Ditto.
19054         (CODE_FOR_lasx_xvrepli_b): Ditto.
19055         (CODE_FOR_lasx_xvrepli_h): Ditto.
19056         (CODE_FOR_lasx_xvrepli_w): Ditto.
19057         (CODE_FOR_lasx_xvrepli_d): Ditto.
19058         (CODE_FOR_lasx_xvandn_v): Ditto.
19059         (CODE_FOR_lasx_xvorn_v): Ditto.
19060         (CODE_FOR_lasx_xvneg_b): Ditto.
19061         (CODE_FOR_lasx_xvneg_h): Ditto.
19062         (CODE_FOR_lasx_xvneg_w): Ditto.
19063         (CODE_FOR_lasx_xvneg_d): Ditto.
19064         (CODE_FOR_lasx_xvbsrl_v): Ditto.
19065         (CODE_FOR_lasx_xvbsll_v): Ditto.
19066         (CODE_FOR_lasx_xvfmadd_s): Ditto.
19067         (CODE_FOR_lasx_xvfmadd_d): Ditto.
19068         (CODE_FOR_lasx_xvfmsub_s): Ditto.
19069         (CODE_FOR_lasx_xvfmsub_d): Ditto.
19070         (CODE_FOR_lasx_xvfnmadd_s): Ditto.
19071         (CODE_FOR_lasx_xvfnmadd_d): Ditto.
19072         (CODE_FOR_lasx_xvfnmsub_s): Ditto.
19073         (CODE_FOR_lasx_xvfnmsub_d): Ditto.
19074         (CODE_FOR_lasx_xvpermi_q): Ditto.
19075         (CODE_FOR_lasx_xvpermi_d): Ditto.
19076         (CODE_FOR_lasx_xbnz_v): Ditto.
19077         (CODE_FOR_lasx_xbz_v): Ditto.
19078         (CODE_FOR_lasx_xvssub_b): Ditto.
19079         (CODE_FOR_lasx_xvssub_h): Ditto.
19080         (CODE_FOR_lasx_xvssub_w): Ditto.
19081         (CODE_FOR_lasx_xvssub_d): Ditto.
19082         (CODE_FOR_lasx_xvssub_bu): Ditto.
19083         (CODE_FOR_lasx_xvssub_hu): Ditto.
19084         (CODE_FOR_lasx_xvssub_wu): Ditto.
19085         (CODE_FOR_lasx_xvssub_du): Ditto.
19086         (CODE_FOR_lasx_xvabsd_b): Ditto.
19087         (CODE_FOR_lasx_xvabsd_h): Ditto.
19088         (CODE_FOR_lasx_xvabsd_w): Ditto.
19089         (CODE_FOR_lasx_xvabsd_d): Ditto.
19090         (CODE_FOR_lasx_xvabsd_bu): Ditto.
19091         (CODE_FOR_lasx_xvabsd_hu): Ditto.
19092         (CODE_FOR_lasx_xvabsd_wu): Ditto.
19093         (CODE_FOR_lasx_xvabsd_du): Ditto.
19094         (CODE_FOR_lasx_xvavg_b): Ditto.
19095         (CODE_FOR_lasx_xvavg_h): Ditto.
19096         (CODE_FOR_lasx_xvavg_w): Ditto.
19097         (CODE_FOR_lasx_xvavg_d): Ditto.
19098         (CODE_FOR_lasx_xvavg_bu): Ditto.
19099         (CODE_FOR_lasx_xvavg_hu): Ditto.
19100         (CODE_FOR_lasx_xvavg_wu): Ditto.
19101         (CODE_FOR_lasx_xvavg_du): Ditto.
19102         (CODE_FOR_lasx_xvavgr_b): Ditto.
19103         (CODE_FOR_lasx_xvavgr_h): Ditto.
19104         (CODE_FOR_lasx_xvavgr_w): Ditto.
19105         (CODE_FOR_lasx_xvavgr_d): Ditto.
19106         (CODE_FOR_lasx_xvavgr_bu): Ditto.
19107         (CODE_FOR_lasx_xvavgr_hu): Ditto.
19108         (CODE_FOR_lasx_xvavgr_wu): Ditto.
19109         (CODE_FOR_lasx_xvavgr_du): Ditto.
19110         (CODE_FOR_lasx_xvmuh_b): Ditto.
19111         (CODE_FOR_lasx_xvmuh_h): Ditto.
19112         (CODE_FOR_lasx_xvmuh_w): Ditto.
19113         (CODE_FOR_lasx_xvmuh_d): Ditto.
19114         (CODE_FOR_lasx_xvmuh_bu): Ditto.
19115         (CODE_FOR_lasx_xvmuh_hu): Ditto.
19116         (CODE_FOR_lasx_xvmuh_wu): Ditto.
19117         (CODE_FOR_lasx_xvmuh_du): Ditto.
19118         (CODE_FOR_lasx_xvssran_b_h): Ditto.
19119         (CODE_FOR_lasx_xvssran_h_w): Ditto.
19120         (CODE_FOR_lasx_xvssran_w_d): Ditto.
19121         (CODE_FOR_lasx_xvssran_bu_h): Ditto.
19122         (CODE_FOR_lasx_xvssran_hu_w): Ditto.
19123         (CODE_FOR_lasx_xvssran_wu_d): Ditto.
19124         (CODE_FOR_lasx_xvssrarn_b_h): Ditto.
19125         (CODE_FOR_lasx_xvssrarn_h_w): Ditto.
19126         (CODE_FOR_lasx_xvssrarn_w_d): Ditto.
19127         (CODE_FOR_lasx_xvssrarn_bu_h): Ditto.
19128         (CODE_FOR_lasx_xvssrarn_hu_w): Ditto.
19129         (CODE_FOR_lasx_xvssrarn_wu_d): Ditto.
19130         (CODE_FOR_lasx_xvssrln_bu_h): Ditto.
19131         (CODE_FOR_lasx_xvssrln_hu_w): Ditto.
19132         (CODE_FOR_lasx_xvssrln_wu_d): Ditto.
19133         (CODE_FOR_lasx_xvssrlrn_bu_h): Ditto.
19134         (CODE_FOR_lasx_xvssrlrn_hu_w): Ditto.
19135         (CODE_FOR_lasx_xvssrlrn_wu_d): Ditto.
19136         (CODE_FOR_lasx_xvftint_w_s): Ditto.
19137         (CODE_FOR_lasx_xvftint_l_d): Ditto.
19138         (CODE_FOR_lasx_xvftint_wu_s): Ditto.
19139         (CODE_FOR_lasx_xvftint_lu_d): Ditto.
19140         (CODE_FOR_lasx_xvsllwil_h_b): Ditto.
19141         (CODE_FOR_lasx_xvsllwil_w_h): Ditto.
19142         (CODE_FOR_lasx_xvsllwil_d_w): Ditto.
19143         (CODE_FOR_lasx_xvsllwil_hu_bu): Ditto.
19144         (CODE_FOR_lasx_xvsllwil_wu_hu): Ditto.
19145         (CODE_FOR_lasx_xvsllwil_du_wu): Ditto.
19146         (CODE_FOR_lasx_xvsat_b): Ditto.
19147         (CODE_FOR_lasx_xvsat_h): Ditto.
19148         (CODE_FOR_lasx_xvsat_w): Ditto.
19149         (CODE_FOR_lasx_xvsat_d): Ditto.
19150         (CODE_FOR_lasx_xvsat_bu): Ditto.
19151         (CODE_FOR_lasx_xvsat_hu): Ditto.
19152         (CODE_FOR_lasx_xvsat_wu): Ditto.
19153         (CODE_FOR_lasx_xvsat_du): Ditto.
19154         (loongarch_builtin_vectorized_function): Ditto.
19155         (loongarch_expand_builtin_insn): Ditto.
19156         (loongarch_expand_builtin): Ditto.
19157         * config/loongarch/loongarch-ftypes.def (1): Ditto.
19158         (2): Ditto.
19159         (3): Ditto.
19160         (4): Ditto.
19161         * config/loongarch/lasxintrin.h: New file.
19163 2023-09-05  Lulu Cheng  <chenglulu@loongson.cn>
19165         * config/loongarch/loongarch-modes.def
19166         (VECTOR_MODES): Add Loongson ASX instruction support.
19167         * config/loongarch/loongarch-protos.h (loongarch_split_256bit_move): Ditto.
19168         (loongarch_split_256bit_move_p): Ditto.
19169         (loongarch_expand_vector_group_init): Ditto.
19170         (loongarch_expand_vec_perm_1): Ditto.
19171         * config/loongarch/loongarch.cc (loongarch_symbol_insns): Ditto.
19172         (loongarch_valid_offset_p): Ditto.
19173         (loongarch_address_insns): Ditto.
19174         (loongarch_const_insns): Ditto.
19175         (loongarch_legitimize_move): Ditto.
19176         (loongarch_builtin_vectorization_cost): Ditto.
19177         (loongarch_split_move_p): Ditto.
19178         (loongarch_split_move): Ditto.
19179         (loongarch_output_move_index_float): Ditto.
19180         (loongarch_split_256bit_move_p): Ditto.
19181         (loongarch_split_256bit_move): Ditto.
19182         (loongarch_output_move): Ditto.
19183         (loongarch_print_operand_reloc): Ditto.
19184         (loongarch_print_operand): Ditto.
19185         (loongarch_hard_regno_mode_ok_uncached): Ditto.
19186         (loongarch_hard_regno_nregs): Ditto.
19187         (loongarch_class_max_nregs): Ditto.
19188         (loongarch_can_change_mode_class): Ditto.
19189         (loongarch_mode_ok_for_mov_fmt_p): Ditto.
19190         (loongarch_vector_mode_supported_p): Ditto.
19191         (loongarch_preferred_simd_mode): Ditto.
19192         (loongarch_autovectorize_vector_modes): Ditto.
19193         (loongarch_lsx_output_division): Ditto.
19194         (loongarch_expand_lsx_shuffle): Ditto.
19195         (loongarch_expand_vec_perm): Ditto.
19196         (loongarch_expand_vec_perm_interleave): Ditto.
19197         (loongarch_try_expand_lsx_vshuf_const): Ditto.
19198         (loongarch_expand_vec_perm_even_odd_1): Ditto.
19199         (loongarch_expand_vec_perm_even_odd): Ditto.
19200         (loongarch_expand_vec_perm_1): Ditto.
19201         (loongarch_expand_vec_perm_const_2): Ditto.
19202         (loongarch_is_quad_duplicate): Ditto.
19203         (loongarch_is_double_duplicate): Ditto.
19204         (loongarch_is_odd_extraction): Ditto.
19205         (loongarch_is_even_extraction): Ditto.
19206         (loongarch_is_extraction_permutation): Ditto.
19207         (loongarch_is_center_extraction): Ditto.
19208         (loongarch_is_reversing_permutation): Ditto.
19209         (loongarch_is_di_misalign_extract): Ditto.
19210         (loongarch_is_si_misalign_extract): Ditto.
19211         (loongarch_is_lasx_lowpart_interleave): Ditto.
19212         (loongarch_is_lasx_lowpart_interleave_2): Ditto.
19213         (COMPARE_SELECTOR): Ditto.
19214         (loongarch_is_lasx_lowpart_extract): Ditto.
19215         (loongarch_is_lasx_highpart_interleave): Ditto.
19216         (loongarch_is_lasx_highpart_interleave_2): Ditto.
19217         (loongarch_is_elem_duplicate): Ditto.
19218         (loongarch_is_op_reverse_perm): Ditto.
19219         (loongarch_is_single_op_perm): Ditto.
19220         (loongarch_is_divisible_perm): Ditto.
19221         (loongarch_is_triple_stride_extract): Ditto.
19222         (loongarch_vectorize_vec_perm_const): Ditto.
19223         (loongarch_cpu_sched_reassociation_width): Ditto.
19224         (loongarch_expand_vector_extract): Ditto.
19225         (emit_reduc_half): Ditto.
19226         (loongarch_expand_vec_unpack): Ditto.
19227         (loongarch_expand_vector_group_init): Ditto.
19228         (loongarch_expand_vector_init): Ditto.
19229         (loongarch_expand_lsx_cmp): Ditto.
19230         (loongarch_builtin_support_vector_misalignment): Ditto.
19231         * config/loongarch/loongarch.h (UNITS_PER_LASX_REG): Ditto.
19232         (BITS_PER_LASX_REG): Ditto.
19233         (STRUCTURE_SIZE_BOUNDARY): Ditto.
19234         (LASX_REG_FIRST): Ditto.
19235         (LASX_REG_LAST): Ditto.
19236         (LASX_REG_NUM): Ditto.
19237         (LASX_REG_P): Ditto.
19238         (LASX_REG_RTX_P): Ditto.
19239         (LASX_SUPPORTED_MODE_P): Ditto.
19240         * config/loongarch/loongarch.md: Ditto.
19241         * config/loongarch/lasx.md: New file.
19243 2023-09-05  Lulu Cheng  <chenglulu@loongson.cn>
19245         * config.gcc: Export the header file lsxintrin.h.
19246         * config/loongarch/loongarch-builtins.cc (LARCH_FTYPE_NAME4): Add builtin function support.
19247         (enum loongarch_builtin_type): Ditto.
19248         (AVAIL_ALL): Ditto.
19249         (LARCH_BUILTIN): Ditto.
19250         (LSX_BUILTIN): Ditto.
19251         (LSX_BUILTIN_TEST_BRANCH): Ditto.
19252         (LSX_NO_TARGET_BUILTIN): Ditto.
19253         (CODE_FOR_lsx_vsadd_b): Ditto.
19254         (CODE_FOR_lsx_vsadd_h): Ditto.
19255         (CODE_FOR_lsx_vsadd_w): Ditto.
19256         (CODE_FOR_lsx_vsadd_d): Ditto.
19257         (CODE_FOR_lsx_vsadd_bu): Ditto.
19258         (CODE_FOR_lsx_vsadd_hu): Ditto.
19259         (CODE_FOR_lsx_vsadd_wu): Ditto.
19260         (CODE_FOR_lsx_vsadd_du): Ditto.
19261         (CODE_FOR_lsx_vadd_b): Ditto.
19262         (CODE_FOR_lsx_vadd_h): Ditto.
19263         (CODE_FOR_lsx_vadd_w): Ditto.
19264         (CODE_FOR_lsx_vadd_d): Ditto.
19265         (CODE_FOR_lsx_vaddi_bu): Ditto.
19266         (CODE_FOR_lsx_vaddi_hu): Ditto.
19267         (CODE_FOR_lsx_vaddi_wu): Ditto.
19268         (CODE_FOR_lsx_vaddi_du): Ditto.
19269         (CODE_FOR_lsx_vand_v): Ditto.
19270         (CODE_FOR_lsx_vandi_b): Ditto.
19271         (CODE_FOR_lsx_bnz_v): Ditto.
19272         (CODE_FOR_lsx_bz_v): Ditto.
19273         (CODE_FOR_lsx_vbitsel_v): Ditto.
19274         (CODE_FOR_lsx_vseqi_b): Ditto.
19275         (CODE_FOR_lsx_vseqi_h): Ditto.
19276         (CODE_FOR_lsx_vseqi_w): Ditto.
19277         (CODE_FOR_lsx_vseqi_d): Ditto.
19278         (CODE_FOR_lsx_vslti_b): Ditto.
19279         (CODE_FOR_lsx_vslti_h): Ditto.
19280         (CODE_FOR_lsx_vslti_w): Ditto.
19281         (CODE_FOR_lsx_vslti_d): Ditto.
19282         (CODE_FOR_lsx_vslti_bu): Ditto.
19283         (CODE_FOR_lsx_vslti_hu): Ditto.
19284         (CODE_FOR_lsx_vslti_wu): Ditto.
19285         (CODE_FOR_lsx_vslti_du): Ditto.
19286         (CODE_FOR_lsx_vslei_b): Ditto.
19287         (CODE_FOR_lsx_vslei_h): Ditto.
19288         (CODE_FOR_lsx_vslei_w): Ditto.
19289         (CODE_FOR_lsx_vslei_d): Ditto.
19290         (CODE_FOR_lsx_vslei_bu): Ditto.
19291         (CODE_FOR_lsx_vslei_hu): Ditto.
19292         (CODE_FOR_lsx_vslei_wu): Ditto.
19293         (CODE_FOR_lsx_vslei_du): Ditto.
19294         (CODE_FOR_lsx_vdiv_b): Ditto.
19295         (CODE_FOR_lsx_vdiv_h): Ditto.
19296         (CODE_FOR_lsx_vdiv_w): Ditto.
19297         (CODE_FOR_lsx_vdiv_d): Ditto.
19298         (CODE_FOR_lsx_vdiv_bu): Ditto.
19299         (CODE_FOR_lsx_vdiv_hu): Ditto.
19300         (CODE_FOR_lsx_vdiv_wu): Ditto.
19301         (CODE_FOR_lsx_vdiv_du): Ditto.
19302         (CODE_FOR_lsx_vfadd_s): Ditto.
19303         (CODE_FOR_lsx_vfadd_d): Ditto.
19304         (CODE_FOR_lsx_vftintrz_w_s): Ditto.
19305         (CODE_FOR_lsx_vftintrz_l_d): Ditto.
19306         (CODE_FOR_lsx_vftintrz_wu_s): Ditto.
19307         (CODE_FOR_lsx_vftintrz_lu_d): Ditto.
19308         (CODE_FOR_lsx_vffint_s_w): Ditto.
19309         (CODE_FOR_lsx_vffint_d_l): Ditto.
19310         (CODE_FOR_lsx_vffint_s_wu): Ditto.
19311         (CODE_FOR_lsx_vffint_d_lu): Ditto.
19312         (CODE_FOR_lsx_vfsub_s): Ditto.
19313         (CODE_FOR_lsx_vfsub_d): Ditto.
19314         (CODE_FOR_lsx_vfmul_s): Ditto.
19315         (CODE_FOR_lsx_vfmul_d): Ditto.
19316         (CODE_FOR_lsx_vfdiv_s): Ditto.
19317         (CODE_FOR_lsx_vfdiv_d): Ditto.
19318         (CODE_FOR_lsx_vfmax_s): Ditto.
19319         (CODE_FOR_lsx_vfmax_d): Ditto.
19320         (CODE_FOR_lsx_vfmin_s): Ditto.
19321         (CODE_FOR_lsx_vfmin_d): Ditto.
19322         (CODE_FOR_lsx_vfsqrt_s): Ditto.
19323         (CODE_FOR_lsx_vfsqrt_d): Ditto.
19324         (CODE_FOR_lsx_vflogb_s): Ditto.
19325         (CODE_FOR_lsx_vflogb_d): Ditto.
19326         (CODE_FOR_lsx_vmax_b): Ditto.
19327         (CODE_FOR_lsx_vmax_h): Ditto.
19328         (CODE_FOR_lsx_vmax_w): Ditto.
19329         (CODE_FOR_lsx_vmax_d): Ditto.
19330         (CODE_FOR_lsx_vmaxi_b): Ditto.
19331         (CODE_FOR_lsx_vmaxi_h): Ditto.
19332         (CODE_FOR_lsx_vmaxi_w): Ditto.
19333         (CODE_FOR_lsx_vmaxi_d): Ditto.
19334         (CODE_FOR_lsx_vmax_bu): Ditto.
19335         (CODE_FOR_lsx_vmax_hu): Ditto.
19336         (CODE_FOR_lsx_vmax_wu): Ditto.
19337         (CODE_FOR_lsx_vmax_du): Ditto.
19338         (CODE_FOR_lsx_vmaxi_bu): Ditto.
19339         (CODE_FOR_lsx_vmaxi_hu): Ditto.
19340         (CODE_FOR_lsx_vmaxi_wu): Ditto.
19341         (CODE_FOR_lsx_vmaxi_du): Ditto.
19342         (CODE_FOR_lsx_vmin_b): Ditto.
19343         (CODE_FOR_lsx_vmin_h): Ditto.
19344         (CODE_FOR_lsx_vmin_w): Ditto.
19345         (CODE_FOR_lsx_vmin_d): Ditto.
19346         (CODE_FOR_lsx_vmini_b): Ditto.
19347         (CODE_FOR_lsx_vmini_h): Ditto.
19348         (CODE_FOR_lsx_vmini_w): Ditto.
19349         (CODE_FOR_lsx_vmini_d): Ditto.
19350         (CODE_FOR_lsx_vmin_bu): Ditto.
19351         (CODE_FOR_lsx_vmin_hu): Ditto.
19352         (CODE_FOR_lsx_vmin_wu): Ditto.
19353         (CODE_FOR_lsx_vmin_du): Ditto.
19354         (CODE_FOR_lsx_vmini_bu): Ditto.
19355         (CODE_FOR_lsx_vmini_hu): Ditto.
19356         (CODE_FOR_lsx_vmini_wu): Ditto.
19357         (CODE_FOR_lsx_vmini_du): Ditto.
19358         (CODE_FOR_lsx_vmod_b): Ditto.
19359         (CODE_FOR_lsx_vmod_h): Ditto.
19360         (CODE_FOR_lsx_vmod_w): Ditto.
19361         (CODE_FOR_lsx_vmod_d): Ditto.
19362         (CODE_FOR_lsx_vmod_bu): Ditto.
19363         (CODE_FOR_lsx_vmod_hu): Ditto.
19364         (CODE_FOR_lsx_vmod_wu): Ditto.
19365         (CODE_FOR_lsx_vmod_du): Ditto.
19366         (CODE_FOR_lsx_vmul_b): Ditto.
19367         (CODE_FOR_lsx_vmul_h): Ditto.
19368         (CODE_FOR_lsx_vmul_w): Ditto.
19369         (CODE_FOR_lsx_vmul_d): Ditto.
19370         (CODE_FOR_lsx_vclz_b): Ditto.
19371         (CODE_FOR_lsx_vclz_h): Ditto.
19372         (CODE_FOR_lsx_vclz_w): Ditto.
19373         (CODE_FOR_lsx_vclz_d): Ditto.
19374         (CODE_FOR_lsx_vnor_v): Ditto.
19375         (CODE_FOR_lsx_vor_v): Ditto.
19376         (CODE_FOR_lsx_vori_b): Ditto.
19377         (CODE_FOR_lsx_vnori_b): Ditto.
19378         (CODE_FOR_lsx_vpcnt_b): Ditto.
19379         (CODE_FOR_lsx_vpcnt_h): Ditto.
19380         (CODE_FOR_lsx_vpcnt_w): Ditto.
19381         (CODE_FOR_lsx_vpcnt_d): Ditto.
19382         (CODE_FOR_lsx_vxor_v): Ditto.
19383         (CODE_FOR_lsx_vxori_b): Ditto.
19384         (CODE_FOR_lsx_vsll_b): Ditto.
19385         (CODE_FOR_lsx_vsll_h): Ditto.
19386         (CODE_FOR_lsx_vsll_w): Ditto.
19387         (CODE_FOR_lsx_vsll_d): Ditto.
19388         (CODE_FOR_lsx_vslli_b): Ditto.
19389         (CODE_FOR_lsx_vslli_h): Ditto.
19390         (CODE_FOR_lsx_vslli_w): Ditto.
19391         (CODE_FOR_lsx_vslli_d): Ditto.
19392         (CODE_FOR_lsx_vsra_b): Ditto.
19393         (CODE_FOR_lsx_vsra_h): Ditto.
19394         (CODE_FOR_lsx_vsra_w): Ditto.
19395         (CODE_FOR_lsx_vsra_d): Ditto.
19396         (CODE_FOR_lsx_vsrai_b): Ditto.
19397         (CODE_FOR_lsx_vsrai_h): Ditto.
19398         (CODE_FOR_lsx_vsrai_w): Ditto.
19399         (CODE_FOR_lsx_vsrai_d): Ditto.
19400         (CODE_FOR_lsx_vsrl_b): Ditto.
19401         (CODE_FOR_lsx_vsrl_h): Ditto.
19402         (CODE_FOR_lsx_vsrl_w): Ditto.
19403         (CODE_FOR_lsx_vsrl_d): Ditto.
19404         (CODE_FOR_lsx_vsrli_b): Ditto.
19405         (CODE_FOR_lsx_vsrli_h): Ditto.
19406         (CODE_FOR_lsx_vsrli_w): Ditto.
19407         (CODE_FOR_lsx_vsrli_d): Ditto.
19408         (CODE_FOR_lsx_vsub_b): Ditto.
19409         (CODE_FOR_lsx_vsub_h): Ditto.
19410         (CODE_FOR_lsx_vsub_w): Ditto.
19411         (CODE_FOR_lsx_vsub_d): Ditto.
19412         (CODE_FOR_lsx_vsubi_bu): Ditto.
19413         (CODE_FOR_lsx_vsubi_hu): Ditto.
19414         (CODE_FOR_lsx_vsubi_wu): Ditto.
19415         (CODE_FOR_lsx_vsubi_du): Ditto.
19416         (CODE_FOR_lsx_vpackod_d): Ditto.
19417         (CODE_FOR_lsx_vpackev_d): Ditto.
19418         (CODE_FOR_lsx_vpickod_d): Ditto.
19419         (CODE_FOR_lsx_vpickev_d): Ditto.
19420         (CODE_FOR_lsx_vrepli_b): Ditto.
19421         (CODE_FOR_lsx_vrepli_h): Ditto.
19422         (CODE_FOR_lsx_vrepli_w): Ditto.
19423         (CODE_FOR_lsx_vrepli_d): Ditto.
19424         (CODE_FOR_lsx_vsat_b): Ditto.
19425         (CODE_FOR_lsx_vsat_h): Ditto.
19426         (CODE_FOR_lsx_vsat_w): Ditto.
19427         (CODE_FOR_lsx_vsat_d): Ditto.
19428         (CODE_FOR_lsx_vsat_bu): Ditto.
19429         (CODE_FOR_lsx_vsat_hu): Ditto.
19430         (CODE_FOR_lsx_vsat_wu): Ditto.
19431         (CODE_FOR_lsx_vsat_du): Ditto.
19432         (CODE_FOR_lsx_vavg_b): Ditto.
19433         (CODE_FOR_lsx_vavg_h): Ditto.
19434         (CODE_FOR_lsx_vavg_w): Ditto.
19435         (CODE_FOR_lsx_vavg_d): Ditto.
19436         (CODE_FOR_lsx_vavg_bu): Ditto.
19437         (CODE_FOR_lsx_vavg_hu): Ditto.
19438         (CODE_FOR_lsx_vavg_wu): Ditto.
19439         (CODE_FOR_lsx_vavg_du): Ditto.
19440         (CODE_FOR_lsx_vavgr_b): Ditto.
19441         (CODE_FOR_lsx_vavgr_h): Ditto.
19442         (CODE_FOR_lsx_vavgr_w): Ditto.
19443         (CODE_FOR_lsx_vavgr_d): Ditto.
19444         (CODE_FOR_lsx_vavgr_bu): Ditto.
19445         (CODE_FOR_lsx_vavgr_hu): Ditto.
19446         (CODE_FOR_lsx_vavgr_wu): Ditto.
19447         (CODE_FOR_lsx_vavgr_du): Ditto.
19448         (CODE_FOR_lsx_vssub_b): Ditto.
19449         (CODE_FOR_lsx_vssub_h): Ditto.
19450         (CODE_FOR_lsx_vssub_w): Ditto.
19451         (CODE_FOR_lsx_vssub_d): Ditto.
19452         (CODE_FOR_lsx_vssub_bu): Ditto.
19453         (CODE_FOR_lsx_vssub_hu): Ditto.
19454         (CODE_FOR_lsx_vssub_wu): Ditto.
19455         (CODE_FOR_lsx_vssub_du): Ditto.
19456         (CODE_FOR_lsx_vabsd_b): Ditto.
19457         (CODE_FOR_lsx_vabsd_h): Ditto.
19458         (CODE_FOR_lsx_vabsd_w): Ditto.
19459         (CODE_FOR_lsx_vabsd_d): Ditto.
19460         (CODE_FOR_lsx_vabsd_bu): Ditto.
19461         (CODE_FOR_lsx_vabsd_hu): Ditto.
19462         (CODE_FOR_lsx_vabsd_wu): Ditto.
19463         (CODE_FOR_lsx_vabsd_du): Ditto.
19464         (CODE_FOR_lsx_vftint_w_s): Ditto.
19465         (CODE_FOR_lsx_vftint_l_d): Ditto.
19466         (CODE_FOR_lsx_vftint_wu_s): Ditto.
19467         (CODE_FOR_lsx_vftint_lu_d): Ditto.
19468         (CODE_FOR_lsx_vandn_v): Ditto.
19469         (CODE_FOR_lsx_vorn_v): Ditto.
19470         (CODE_FOR_lsx_vneg_b): Ditto.
19471         (CODE_FOR_lsx_vneg_h): Ditto.
19472         (CODE_FOR_lsx_vneg_w): Ditto.
19473         (CODE_FOR_lsx_vneg_d): Ditto.
19474         (CODE_FOR_lsx_vshuf4i_d): Ditto.
19475         (CODE_FOR_lsx_vbsrl_v): Ditto.
19476         (CODE_FOR_lsx_vbsll_v): Ditto.
19477         (CODE_FOR_lsx_vfmadd_s): Ditto.
19478         (CODE_FOR_lsx_vfmadd_d): Ditto.
19479         (CODE_FOR_lsx_vfmsub_s): Ditto.
19480         (CODE_FOR_lsx_vfmsub_d): Ditto.
19481         (CODE_FOR_lsx_vfnmadd_s): Ditto.
19482         (CODE_FOR_lsx_vfnmadd_d): Ditto.
19483         (CODE_FOR_lsx_vfnmsub_s): Ditto.
19484         (CODE_FOR_lsx_vfnmsub_d): Ditto.
19485         (CODE_FOR_lsx_vmuh_b): Ditto.
19486         (CODE_FOR_lsx_vmuh_h): Ditto.
19487         (CODE_FOR_lsx_vmuh_w): Ditto.
19488         (CODE_FOR_lsx_vmuh_d): Ditto.
19489         (CODE_FOR_lsx_vmuh_bu): Ditto.
19490         (CODE_FOR_lsx_vmuh_hu): Ditto.
19491         (CODE_FOR_lsx_vmuh_wu): Ditto.
19492         (CODE_FOR_lsx_vmuh_du): Ditto.
19493         (CODE_FOR_lsx_vsllwil_h_b): Ditto.
19494         (CODE_FOR_lsx_vsllwil_w_h): Ditto.
19495         (CODE_FOR_lsx_vsllwil_d_w): Ditto.
19496         (CODE_FOR_lsx_vsllwil_hu_bu): Ditto.
19497         (CODE_FOR_lsx_vsllwil_wu_hu): Ditto.
19498         (CODE_FOR_lsx_vsllwil_du_wu): Ditto.
19499         (CODE_FOR_lsx_vssran_b_h): Ditto.
19500         (CODE_FOR_lsx_vssran_h_w): Ditto.
19501         (CODE_FOR_lsx_vssran_w_d): Ditto.
19502         (CODE_FOR_lsx_vssran_bu_h): Ditto.
19503         (CODE_FOR_lsx_vssran_hu_w): Ditto.
19504         (CODE_FOR_lsx_vssran_wu_d): Ditto.
19505         (CODE_FOR_lsx_vssrarn_b_h): Ditto.
19506         (CODE_FOR_lsx_vssrarn_h_w): Ditto.
19507         (CODE_FOR_lsx_vssrarn_w_d): Ditto.
19508         (CODE_FOR_lsx_vssrarn_bu_h): Ditto.
19509         (CODE_FOR_lsx_vssrarn_hu_w): Ditto.
19510         (CODE_FOR_lsx_vssrarn_wu_d): Ditto.
19511         (CODE_FOR_lsx_vssrln_bu_h): Ditto.
19512         (CODE_FOR_lsx_vssrln_hu_w): Ditto.
19513         (CODE_FOR_lsx_vssrln_wu_d): Ditto.
19514         (CODE_FOR_lsx_vssrlrn_bu_h): Ditto.
19515         (CODE_FOR_lsx_vssrlrn_hu_w): Ditto.
19516         (CODE_FOR_lsx_vssrlrn_wu_d): Ditto.
19517         (loongarch_builtin_vector_type): Ditto.
19518         (loongarch_build_cvpointer_type): Ditto.
19519         (LARCH_ATYPE_CVPOINTER): Ditto.
19520         (LARCH_ATYPE_BOOLEAN): Ditto.
19521         (LARCH_ATYPE_V2SF): Ditto.
19522         (LARCH_ATYPE_V2HI): Ditto.
19523         (LARCH_ATYPE_V2SI): Ditto.
19524         (LARCH_ATYPE_V4QI): Ditto.
19525         (LARCH_ATYPE_V4HI): Ditto.
19526         (LARCH_ATYPE_V8QI): Ditto.
19527         (LARCH_ATYPE_V2DI): Ditto.
19528         (LARCH_ATYPE_V4SI): Ditto.
19529         (LARCH_ATYPE_V8HI): Ditto.
19530         (LARCH_ATYPE_V16QI): Ditto.
19531         (LARCH_ATYPE_V2DF): Ditto.
19532         (LARCH_ATYPE_V4SF): Ditto.
19533         (LARCH_ATYPE_V4DI): Ditto.
19534         (LARCH_ATYPE_V8SI): Ditto.
19535         (LARCH_ATYPE_V16HI): Ditto.
19536         (LARCH_ATYPE_V32QI): Ditto.
19537         (LARCH_ATYPE_V4DF): Ditto.
19538         (LARCH_ATYPE_V8SF): Ditto.
19539         (LARCH_ATYPE_UV2DI): Ditto.
19540         (LARCH_ATYPE_UV4SI): Ditto.
19541         (LARCH_ATYPE_UV8HI): Ditto.
19542         (LARCH_ATYPE_UV16QI): Ditto.
19543         (LARCH_ATYPE_UV4DI): Ditto.
19544         (LARCH_ATYPE_UV8SI): Ditto.
19545         (LARCH_ATYPE_UV16HI): Ditto.
19546         (LARCH_ATYPE_UV32QI): Ditto.
19547         (LARCH_ATYPE_UV2SI): Ditto.
19548         (LARCH_ATYPE_UV4HI): Ditto.
19549         (LARCH_ATYPE_UV8QI): Ditto.
19550         (loongarch_builtin_vectorized_function): Ditto.
19551         (LARCH_GET_BUILTIN): Ditto.
19552         (loongarch_expand_builtin_insn): Ditto.
19553         (loongarch_expand_builtin_lsx_test_branch): Ditto.
19554         (loongarch_expand_builtin): Ditto.
19555         * config/loongarch/loongarch-ftypes.def (1): Ditto.
19556         (2): Ditto.
19557         (3): Ditto.
19558         (4): Ditto.
19559         * config/loongarch/lsxintrin.h: New file.
19561 2023-09-05  Lulu Cheng  <chenglulu@loongson.cn>
19563         * config/loongarch/constraints.md (M): Add Loongson LSX base instruction support.
19564         (N): Ditto.
19565         (O): Ditto.
19566         (P): Ditto.
19567         (R): Ditto.
19568         (S): Ditto.
19569         (YG): Ditto.
19570         (YA): Ditto.
19571         (YB): Ditto.
19572         (Yb): Ditto.
19573         (Yh): Ditto.
19574         (Yw): Ditto.
19575         (YI): Ditto.
19576         (YC): Ditto.
19577         (YZ): Ditto.
19578         (Unv5): Ditto.
19579         (Uuv5): Ditto.
19580         (Usv5): Ditto.
19581         (Uuv6): Ditto.
19582         (Urv8): Ditto.
19583         * config/loongarch/genopts/loongarch.opt.in: Ditto.
19584         * config/loongarch/loongarch-builtins.cc (loongarch_gen_const_int_vector): Ditto.
19585         * config/loongarch/loongarch-modes.def (VECTOR_MODES): Ditto.
19586         (VECTOR_MODE): Ditto.
19587         (INT_MODE): Ditto.
19588         * config/loongarch/loongarch-protos.h (loongarch_split_move_insn_p): Ditto.
19589         (loongarch_split_move_insn): Ditto.
19590         (loongarch_split_128bit_move): Ditto.
19591         (loongarch_split_128bit_move_p): Ditto.
19592         (loongarch_split_lsx_copy_d): Ditto.
19593         (loongarch_split_lsx_insert_d): Ditto.
19594         (loongarch_split_lsx_fill_d): Ditto.
19595         (loongarch_expand_vec_cmp): Ditto.
19596         (loongarch_const_vector_same_val_p): Ditto.
19597         (loongarch_const_vector_same_bytes_p): Ditto.
19598         (loongarch_const_vector_same_int_p): Ditto.
19599         (loongarch_const_vector_shuffle_set_p): Ditto.
19600         (loongarch_const_vector_bitimm_set_p): Ditto.
19601         (loongarch_const_vector_bitimm_clr_p): Ditto.
19602         (loongarch_lsx_vec_parallel_const_half): Ditto.
19603         (loongarch_gen_const_int_vector): Ditto.
19604         (loongarch_lsx_output_division): Ditto.
19605         (loongarch_expand_vector_init): Ditto.
19606         (loongarch_expand_vec_unpack): Ditto.
19607         (loongarch_expand_vec_perm): Ditto.
19608         (loongarch_expand_vector_extract): Ditto.
19609         (loongarch_expand_vector_reduc): Ditto.
19610         (loongarch_ldst_scaled_shift): Ditto.
19611         (loongarch_expand_vec_cond_expr): Ditto.
19612         (loongarch_expand_vec_cond_mask_expr): Ditto.
19613         (loongarch_builtin_vectorized_function): Ditto.
19614         (loongarch_gen_const_int_vector_shuffle): Ditto.
19615         (loongarch_build_signbit_mask): Ditto.
19616         * config/loongarch/loongarch.cc (loongarch_pass_aggregate_num_fpr): Ditto.
19617         (loongarch_setup_incoming_varargs): Ditto.
19618         (loongarch_emit_move): Ditto.
19619         (loongarch_const_vector_bitimm_set_p): Ditto.
19620         (loongarch_const_vector_bitimm_clr_p): Ditto.
19621         (loongarch_const_vector_same_val_p): Ditto.
19622         (loongarch_const_vector_same_bytes_p): Ditto.
19623         (loongarch_const_vector_same_int_p): Ditto.
19624         (loongarch_const_vector_shuffle_set_p): Ditto.
19625         (loongarch_symbol_insns): Ditto.
19626         (loongarch_cannot_force_const_mem): Ditto.
19627         (loongarch_valid_offset_p): Ditto.
19628         (loongarch_valid_index_p): Ditto.
19629         (loongarch_classify_address): Ditto.
19630         (loongarch_address_insns): Ditto.
19631         (loongarch_ldst_scaled_shift): Ditto.
19632         (loongarch_const_insns): Ditto.
19633         (loongarch_split_move_insn_p): Ditto.
19634         (loongarch_subword_at_byte): Ditto.
19635         (loongarch_legitimize_move): Ditto.
19636         (loongarch_builtin_vectorization_cost): Ditto.
19637         (loongarch_split_move_p): Ditto.
19638         (loongarch_split_move): Ditto.
19639         (loongarch_split_move_insn): Ditto.
19640         (loongarch_output_move_index_float): Ditto.
19641         (loongarch_split_128bit_move_p): Ditto.
19642         (loongarch_split_128bit_move): Ditto.
19643         (loongarch_split_lsx_copy_d): Ditto.
19644         (loongarch_split_lsx_insert_d): Ditto.
19645         (loongarch_split_lsx_fill_d): Ditto.
19646         (loongarch_output_move): Ditto.
19647         (loongarch_extend_comparands): Ditto.
19648         (loongarch_print_operand_reloc): Ditto.
19649         (loongarch_print_operand): Ditto.
19650         (loongarch_hard_regno_mode_ok_uncached): Ditto.
19651         (loongarch_hard_regno_call_part_clobbered): Ditto.
19652         (loongarch_hard_regno_nregs): Ditto.
19653         (loongarch_class_max_nregs): Ditto.
19654         (loongarch_can_change_mode_class): Ditto.
19655         (loongarch_mode_ok_for_mov_fmt_p): Ditto.
19656         (loongarch_secondary_reload): Ditto.
19657         (loongarch_vector_mode_supported_p): Ditto.
19658         (loongarch_preferred_simd_mode): Ditto.
19659         (loongarch_autovectorize_vector_modes): Ditto.
19660         (loongarch_lsx_output_division): Ditto.
19661         (loongarch_option_override_internal): Ditto.
19662         (loongarch_hard_regno_caller_save_mode): Ditto.
19663         (MAX_VECT_LEN): Ditto.
19664         (loongarch_spill_class): Ditto.
19665         (struct expand_vec_perm_d): Ditto.
19666         (loongarch_promote_function_mode): Ditto.
19667         (loongarch_expand_vselect): Ditto.
19668         (loongarch_starting_frame_offset): Ditto.
19669         (loongarch_expand_vselect_vconcat): Ditto.
19670         (TARGET_ASM_ALIGNED_DI_OP): Ditto.
19671         (TARGET_OPTION_OVERRIDE): Ditto.
19672         (TARGET_LEGITIMIZE_ADDRESS): Ditto.
19673         (TARGET_ASM_SELECT_RTX_SECTION): Ditto.
19674         (TARGET_ASM_FUNCTION_RODATA_SECTION): Ditto.
19675         (loongarch_expand_lsx_shuffle): Ditto.
19676         (TARGET_SCHED_INIT): Ditto.
19677         (TARGET_SCHED_REORDER): Ditto.
19678         (TARGET_SCHED_REORDER2): Ditto.
19679         (TARGET_SCHED_VARIABLE_ISSUE): Ditto.
19680         (TARGET_SCHED_ADJUST_COST): Ditto.
19681         (TARGET_SCHED_ISSUE_RATE): Ditto.
19682         (TARGET_SCHED_FIRST_CYCLE_MULTIPASS_DFA_LOOKAHEAD): Ditto.
19683         (TARGET_FUNCTION_OK_FOR_SIBCALL): Ditto.
19684         (TARGET_VALID_POINTER_MODE): Ditto.
19685         (TARGET_REGISTER_MOVE_COST): Ditto.
19686         (TARGET_MEMORY_MOVE_COST): Ditto.
19687         (TARGET_RTX_COSTS): Ditto.
19688         (TARGET_ADDRESS_COST): Ditto.
19689         (TARGET_IN_SMALL_DATA_P): Ditto.
19690         (TARGET_PREFERRED_RELOAD_CLASS): Ditto.
19691         (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Ditto.
19692         (TARGET_EXPAND_BUILTIN_VA_START): Ditto.
19693         (loongarch_expand_vec_perm): Ditto.
19694         (TARGET_PROMOTE_FUNCTION_MODE): Ditto.
19695         (TARGET_RETURN_IN_MEMORY): Ditto.
19696         (TARGET_FUNCTION_VALUE): Ditto.
19697         (TARGET_LIBCALL_VALUE): Ditto.
19698         (loongarch_try_expand_lsx_vshuf_const): Ditto.
19699         (TARGET_ASM_OUTPUT_MI_THUNK): Ditto.
19700         (TARGET_ASM_CAN_OUTPUT_MI_THUNK): Ditto.
19701         (TARGET_PRINT_OPERAND): Ditto.
19702         (TARGET_PRINT_OPERAND_ADDRESS): Ditto.
19703         (TARGET_PRINT_OPERAND_PUNCT_VALID_P): Ditto.
19704         (TARGET_SETUP_INCOMING_VARARGS): Ditto.
19705         (TARGET_STRICT_ARGUMENT_NAMING): Ditto.
19706         (TARGET_MUST_PASS_IN_STACK): Ditto.
19707         (TARGET_PASS_BY_REFERENCE): Ditto.
19708         (TARGET_ARG_PARTIAL_BYTES): Ditto.
19709         (TARGET_FUNCTION_ARG): Ditto.
19710         (TARGET_FUNCTION_ARG_ADVANCE): Ditto.
19711         (TARGET_FUNCTION_ARG_BOUNDARY): Ditto.
19712         (TARGET_SCALAR_MODE_SUPPORTED_P): Ditto.
19713         (TARGET_INIT_BUILTINS): Ditto.
19714         (loongarch_expand_vec_perm_const_1): Ditto.
19715         (loongarch_expand_vec_perm_const_2): Ditto.
19716         (loongarch_vectorize_vec_perm_const): Ditto.
19717         (loongarch_cpu_sched_reassociation_width): Ditto.
19718         (loongarch_sched_reassociation_width): Ditto.
19719         (loongarch_expand_vector_extract): Ditto.
19720         (emit_reduc_half): Ditto.
19721         (loongarch_expand_vector_reduc): Ditto.
19722         (loongarch_expand_vec_unpack): Ditto.
19723         (loongarch_lsx_vec_parallel_const_half): Ditto.
19724         (loongarch_constant_elt_p): Ditto.
19725         (loongarch_gen_const_int_vector_shuffle): Ditto.
19726         (loongarch_expand_vector_init): Ditto.
19727         (loongarch_expand_lsx_cmp): Ditto.
19728         (loongarch_expand_vec_cond_expr): Ditto.
19729         (loongarch_expand_vec_cond_mask_expr): Ditto.
19730         (loongarch_expand_vec_cmp): Ditto.
19731         (loongarch_case_values_threshold): Ditto.
19732         (loongarch_build_const_vector): Ditto.
19733         (loongarch_build_signbit_mask): Ditto.
19734         (loongarch_builtin_support_vector_misalignment): Ditto.
19735         (TARGET_ASM_ALIGNED_HI_OP): Ditto.
19736         (TARGET_ASM_ALIGNED_SI_OP): Ditto.
19737         (TARGET_VECTORIZE_BUILTIN_VECTORIZATION_COST): Ditto.
19738         (TARGET_VECTOR_MODE_SUPPORTED_P): Ditto.
19739         (TARGET_VECTORIZE_PREFERRED_SIMD_MODE): Ditto.
19740         (TARGET_VECTORIZE_AUTOVECTORIZE_VECTOR_MODES): Ditto.
19741         (TARGET_VECTORIZE_VEC_PERM_CONST): Ditto.
19742         (TARGET_SCHED_REASSOCIATION_WIDTH): Ditto.
19743         (TARGET_CASE_VALUES_THRESHOLD): Ditto.
19744         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Ditto.
19745         (TARGET_VECTORIZE_SUPPORT_VECTOR_MISALIGNMENT): Ditto.
19746         * config/loongarch/loongarch.h (TARGET_SUPPORTS_WIDE_INT): Ditto.
19747         (UNITS_PER_LSX_REG): Ditto.
19748         (BITS_PER_LSX_REG): Ditto.
19749         (BIGGEST_ALIGNMENT): Ditto.
19750         (LSX_REG_FIRST): Ditto.
19751         (LSX_REG_LAST): Ditto.
19752         (LSX_REG_NUM): Ditto.
19753         (LSX_REG_P): Ditto.
19754         (LSX_REG_RTX_P): Ditto.
19755         (IMM13_OPERAND): Ditto.
19756         (LSX_SUPPORTED_MODE_P): Ditto.
19757         * config/loongarch/loongarch.md (unknown,add,sub,not,nor,and,or,xor): Ditto.
19758         (unknown,add,sub,not,nor,and,or,xor,simd_add): Ditto.
19759         (unknown,none,QI,HI,SI,DI,TI,SF,DF,TF,FCC): Ditto.
19760         (mode" ): Ditto.
19761         (DF): Ditto.
19762         (SF): Ditto.
19763         (sf): Ditto.
19764         (DI): Ditto.
19765         (SI): Ditto.
19766         * config/loongarch/loongarch.opt: Ditto.
19767         * config/loongarch/predicates.md (const_lsx_branch_operand): Ditto.
19768         (const_uimm3_operand): Ditto.
19769         (const_8_to_11_operand): Ditto.
19770         (const_12_to_15_operand): Ditto.
19771         (const_uimm4_operand): Ditto.
19772         (const_uimm6_operand): Ditto.
19773         (const_uimm7_operand): Ditto.
19774         (const_uimm8_operand): Ditto.
19775         (const_imm5_operand): Ditto.
19776         (const_imm10_operand): Ditto.
19777         (const_imm13_operand): Ditto.
19778         (reg_imm10_operand): Ditto.
19779         (aq8b_operand): Ditto.
19780         (aq8h_operand): Ditto.
19781         (aq8w_operand): Ditto.
19782         (aq8d_operand): Ditto.
19783         (aq10b_operand): Ditto.
19784         (aq10h_operand): Ditto.
19785         (aq10w_operand): Ditto.
19786         (aq10d_operand): Ditto.
19787         (aq12b_operand): Ditto.
19788         (aq12h_operand): Ditto.
19789         (aq12w_operand): Ditto.
19790         (aq12d_operand): Ditto.
19791         (const_m1_operand): Ditto.
19792         (reg_or_m1_operand): Ditto.
19793         (const_exp_2_operand): Ditto.
19794         (const_exp_4_operand): Ditto.
19795         (const_exp_8_operand): Ditto.
19796         (const_exp_16_operand): Ditto.
19797         (const_exp_32_operand): Ditto.
19798         (const_0_or_1_operand): Ditto.
19799         (const_0_to_3_operand): Ditto.
19800         (const_0_to_7_operand): Ditto.
19801         (const_2_or_3_operand): Ditto.
19802         (const_4_to_7_operand): Ditto.
19803         (const_8_to_15_operand): Ditto.
19804         (const_16_to_31_operand): Ditto.
19805         (qi_mask_operand): Ditto.
19806         (hi_mask_operand): Ditto.
19807         (si_mask_operand): Ditto.
19808         (d_operand): Ditto.
19809         (db4_operand): Ditto.
19810         (db7_operand): Ditto.
19811         (db8_operand): Ditto.
19812         (ib3_operand): Ditto.
19813         (sb4_operand): Ditto.
19814         (sb5_operand): Ditto.
19815         (sb8_operand): Ditto.
19816         (sd8_operand): Ditto.
19817         (ub4_operand): Ditto.
19818         (ub8_operand): Ditto.
19819         (uh4_operand): Ditto.
19820         (uw4_operand): Ditto.
19821         (uw5_operand): Ditto.
19822         (uw6_operand): Ditto.
19823         (uw8_operand): Ditto.
19824         (addiur2_operand): Ditto.
19825         (addiusp_operand): Ditto.
19826         (andi16_operand): Ditto.
19827         (movep_src_register): Ditto.
19828         (movep_src_operand): Ditto.
19829         (fcc_reload_operand): Ditto.
19830         (muldiv_target_operand): Ditto.
19831         (const_vector_same_val_operand): Ditto.
19832         (const_vector_same_simm5_operand): Ditto.
19833         (const_vector_same_uimm5_operand): Ditto.
19834         (const_vector_same_ximm5_operand): Ditto.
19835         (const_vector_same_uimm6_operand): Ditto.
19836         (par_const_vector_shf_set_operand): Ditto.
19837         (reg_or_vector_same_val_operand): Ditto.
19838         (reg_or_vector_same_simm5_operand): Ditto.
19839         (reg_or_vector_same_uimm5_operand): Ditto.
19840         (reg_or_vector_same_ximm5_operand): Ditto.
19841         (reg_or_vector_same_uimm6_operand): Ditto.
19842         * doc/md.texi: Ditto.
19843         * config/loongarch/lsx.md: New file.
19845 2023-09-05  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
19847         * config/riscv/riscv-protos.h (lookup_vector_type_attribute): Export global.
19848         (get_all_predecessors): New function.
19849         (get_all_successors): Ditto.
19850         * config/riscv/riscv-v.cc (get_all_predecessors): Ditto.
19851         (get_all_successors): Ditto.
19852         * config/riscv/riscv-vector-builtins.cc (sizeless_type_p): Export global.
19853         * config/riscv/riscv-vsetvl.cc (get_all_predecessors): Remove it.
19855 2023-09-05  Claudiu Zissulescu  <claziss@gmail.com>
19857         * config/arc/arc-protos.h (arc_output_addsi): Remove declaration.
19858         (split_addsi): Likewise.
19859         * config/arc/arc.cc (arc_print_operand): Add/repurpose 's', 'S',
19860         'N', 'x', and 'J' code letters.
19861         (arc_output_addsi): Make it static.
19862         (split_addsi): Remove it.
19863         * config/arc/arc.h (UNSIGNED_INT*): New defines.
19864         (SINNED_INT*): Likewise.
19865         * config/arc/arc.md (type): Add add, sub, bxor types.
19866         (tst_movb): Change code letter from 's' to 'x'.
19867         (andsi3_i): Likewise.
19868         (addsi3_mixed): Refurbish the pattern.
19869         (call_i): Change code letter from 'S' to 'J'.
19870         * config/arc/arc700.md: Add newly introduced types.
19871         * config/arc/arcHS.md: Likewsie.
19872         * config/arc/arcHS4x.md: Likewise.
19873         * config/arc/constraints.md (Cca, CL2, Csp, C2a): Remove it.
19874         (CM4): Update description.
19875         (CP4, C6u, C6n, CIs, C4p): New constraint.
19877 2023-09-05  Claudiu Zissulescu  <claziss@gmail.com>
19879         * common/config/arc/arc-common.cc (arc_option_optimization_table):
19880         Remove mbbit_peephole.
19881         * config/arc/arc.md (UNSPEC_ARC_DIRECT): Remove.
19882         (store_direct): Likewise.
19883         (BBIT peephole2): Likewise.
19884         * config/arc/arc.opt (mbbit-peephole): Ignore option.
19885         * doc/invoke.texi (mbbit-peephole): Update document.
19887 2023-09-05  Jakub Jelinek  <jakub@redhat.com>
19889         * tree-ssa-tail-merge.cc (replace_block_by): Fix a comment typo:
19890         avreage -> average.
19892 2023-09-05  Yang Yujie  <yangyujie@loongson.cn>
19894         * config/loongarch/loongarch.h (CC1_SPEC): Mark normalized
19895         options passed from driver to gnat1 as explicit for multilib.
19897 2023-09-05  Yang Yujie  <yangyujie@loongson.cn>
19899         * config.gcc: add loongarch*-elf target.
19900         * config/loongarch/elf.h: New file.
19901         Link against newlib by default.
19903 2023-09-05  Yang Yujie  <yangyujie@loongson.cn>
19905         * config.gcc: use -mstrict-align for building libraries
19906         if --with-strict-align-lib is given.
19907         * doc/install.texi: likewise.
19909 2023-09-05  Yang Yujie  <yangyujie@loongson.cn>
19911         * config/loongarch/loongarch-c.cc: Export macros
19912         "__loongarch_{arch,tune}" in the preprocessor.
19914 2023-09-05  Yang Yujie  <yangyujie@loongson.cn>
19916         * config.gcc: Make --with-abi= obsolete, decide the default ABI
19917         with target triplet.  Allow specifying multilib library build
19918         options with --with-multilib-list and --with-multilib-default.
19919         * config/loongarch/t-linux: Likewise.
19920         * config/loongarch/genopts/loongarch-strings: Likewise.
19921         * config/loongarch/loongarch-str.h: Likewise.
19922         * doc/install.texi: Likewise.
19923         * config/loongarch/genopts/loongarch.opt.in: Introduce
19924         -m[no-]l[a]sx options.  Only process -m*-float and
19925         -m[no-]l[a]sx in the GCC driver.
19926         * config/loongarch/loongarch.opt: Likewise.
19927         * config/loongarch/la464.md: Likewise.
19928         * config/loongarch/loongarch-c.cc: Likewise.
19929         * config/loongarch/loongarch-cpu.cc: Likewise.
19930         * config/loongarch/loongarch-cpu.h: Likewise.
19931         * config/loongarch/loongarch-def.c: Likewise.
19932         * config/loongarch/loongarch-def.h: Likewise.
19933         * config/loongarch/loongarch-driver.cc: Likewise.
19934         * config/loongarch/loongarch-driver.h: Likewise.
19935         * config/loongarch/loongarch-opts.cc: Likewise.
19936         * config/loongarch/loongarch-opts.h: Likewise.
19937         * config/loongarch/loongarch.cc: Likewise.
19938         * doc/invoke.texi: Likewise.
19940 2023-09-05  liuhongt  <hongtao.liu@intel.com>
19942         * config/i386/sse.md: (V8BFH_128): Renamed to ..
19943         (VHFBF_128): .. this.
19944         (V16BFH_256): Renamed to ..
19945         (VHFBF_256): .. this.
19946         (avx512f_mov<mode>): Extend to V_128.
19947         (vcvtnee<bf16_ph>2ps_<mode>): Changed to VHFBF_128.
19948         (vcvtneo<bf16_ph>2ps_<mode>): Ditto.
19949         (vcvtnee<bf16_ph>2ps_<mode>): Changed to VHFBF_256.
19950         (vcvtneo<bf16_ph>2ps_<mode>): Ditto.
19951         * config/i386/i386-expand.cc (expand_vec_perm_blend):
19952         Canonicalize vec_merge.
19954 2023-09-05  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
19956         * config/riscv/riscv-opts.h (enum riscv_autovec_lmul_enum): Fix Dynamic status.
19957         * config/riscv/riscv-v.cc (preferred_simd_mode): Ditto.
19958         (autovectorize_vector_modes): Ditto.
19959         (vectorize_related_mode): Ditto.
19961 2023-09-04  Iain Sandoe  <iain@sandoe.co.uk>
19963         * config/rs6000/darwin.h (LIB_SPEC): Include libSystemStubs for
19964         all 32b Darwin PowerPC cases.
19966 2023-09-04  Iain Sandoe  <iain@sandoe.co.uk>
19968         * config/darwin-sections.def (static_init_section): Add the
19969         __TEXT,__StaticInit section.
19970         * config/darwin.cc (darwin_function_section): Use the static init
19971         section for global initializers, to match other platform toolchains.
19973 2023-09-04  Iain Sandoe  <iain@sandoe.co.uk>
19975         * config/darwin-sections.def (darwin_exception_section): Move to
19976         the __TEXT segment.
19977         * config/darwin.cc (darwin_emit_except_table_label): Align before
19978         the exception table label.
19979         * config/darwin.h (ASM_PREFERRED_EH_DATA_FORMAT): Use indirect PC-
19980         relative 4byte relocs.
19982 2023-09-04  Iain Sandoe  <iain@sandoe.co.uk>
19984         * config/darwin.cc (dump_machopic_symref_flags): New.
19985         (debug_machopic_symref_flags): New.
19987 2023-09-04  Pan Li  <pan2.li@intel.com>
19989         * config/riscv/riscv-vector-builtins-types.def
19990         (vfloat16mf4_t): Add FP16 intrinsic def.
19991         (vfloat16mf2_t): Ditto.
19992         (vfloat16m1_t): Ditto.
19993         (vfloat16m2_t): Ditto.
19994         (vfloat16m4_t): Ditto.
19995         (vfloat16m8_t): Ditto.
19997 2023-09-04  Jiufu Guo  <guojiufu@linux.ibm.com>
19999         PR tree-optimization/108757
20000         * match.pd ((X - N * M) / N): New pattern.
20001         ((X + N * M) / N): New pattern.
20002         ((X + C) div_rshift N): New pattern.
20004 2023-09-04  Guo Jie  <guojie@loongson.cn>
20006         * config/loongarch/loongarch.md: Support 'G' -> 'k' in
20007         movsf_hardfloat and movdf_hardfloat.
20009 2023-09-04  Lulu Cheng  <chenglulu@loongson.cn>
20011         * config/loongarch/loongarch.cc (loongarch_extend_comparands):
20012         In unsigned QImode test, check for sign extended subreg and/or
20013         constant operands, and do a sign extension in that case.
20014         * config/loongarch/loongarch.md (TARGET_64BIT): Define
20015         template cbranchqi4.
20017 2023-09-04  Lulu Cheng  <chenglulu@loongson.cn>
20019         * config/loongarch/loongarch.md: Allows fixed-point values to be loaded
20020         from memory into floating-point registers.
20022 2023-09-03  Pan Li  <pan2.li@intel.com>
20024         * config/riscv/autovec-vls.md (<optab><mode>3): New pattern for
20025         fmax/fmin
20026         * config/riscv/vector.md: Add VLS modes to vfmax/vfmin.
20028 2023-09-02  Mikael Morin  <mikael@gcc.gnu.org>
20030         * tree-diagnostic.cc (tree_diagnostics_defaults): Delete allocated
20031         pointer before overwriting it.
20033 2023-09-02  chenxiaolong  <chenxiaolong@loongson.cn>
20035         * config/loongarch/loongarch-builtins.cc (loongarch_init_builtins):
20036         Associate the __float128 type to float128_type_node so that it can
20037         be recognized by the compiler.
20038         * config/loongarch/loongarch-c.cc (loongarch_cpu_cpp_builtins):
20039         Add the flag "FLOAT128_TYPE" to gcc and associate a function
20040         with the suffix "q" to "f128".
20041         * doc/extend.texi:Added support for 128-bit floating-point functions on
20042         the LoongArch architecture.
20044 2023-09-01  Jakub Jelinek  <jakub@redhat.com>
20046         PR c++/111069
20047         * common.opt (fabi-version=): Document version 19.
20048         * doc/invoke.texi (-fabi-version=): Likewise.
20050 2023-09-01  Lehua Ding  <lehua.ding@rivai.ai>
20052         * config/riscv/autovec-opt.md (*cond_<optab><mode><vconvert>):
20053         New combine pattern.
20054         (*cond_<float_cvt><vconvert><mode>): Ditto.
20055         (*cond_<optab><vnconvert><mode>): Ditto.
20056         (*cond_<float_cvt><vnconvert><mode>): Ditto.
20057         (*cond_<optab><mode><vnconvert>): Ditto.
20058         (*cond_<float_cvt><mode><vnconvert>2): Ditto.
20059         * config/riscv/autovec.md (<optab><mode><vconvert>2): Adjust.
20060         (<float_cvt><vconvert><mode>2): Adjust.
20061         (<optab><vnconvert><mode>2): Adjust.
20062         (<float_cvt><vnconvert><mode>2): Adjust.
20063         (<optab><mode><vnconvert>2): Adjust.
20064         (<float_cvt><mode><vnconvert>2): Adjust.
20065         * config/riscv/riscv-v.cc (needs_fp_rounding): Add INT->FP extend.
20067 2023-09-01  Lehua Ding  <lehua.ding@rivai.ai>
20069         * config/riscv/autovec-opt.md (*cond_extend<v_double_trunc><mode>):
20070         New combine pattern.
20071         (*cond_trunc<mode><v_double_trunc>): Ditto.
20072         * config/riscv/autovec.md: Adjust.
20073         * config/riscv/riscv-v.cc (needs_fp_rounding): Add FP extend.
20075 2023-09-01  Lehua Ding  <lehua.ding@rivai.ai>
20077         * config/riscv/autovec-opt.md (*cond_<optab><v_double_trunc><mode>):
20078         New combine pattern.
20079         (*cond_<optab><v_quad_trunc><mode>): Ditto.
20080         (*cond_<optab><v_oct_trunc><mode>): Ditto.
20081         (*cond_trunc<mode><v_double_trunc>): Ditto.
20082         * config/riscv/autovec.md (<optab><v_quad_trunc><mode>2): Adjust.
20083         (<optab><v_oct_trunc><mode>2): Ditto.
20085 2023-09-01  Lehua Ding  <lehua.ding@rivai.ai>
20087         * config/riscv/autovec.md: Adjust.
20088         * config/riscv/riscv-protos.h (expand_cond_len_unop): Ditto.
20089         (expand_cond_len_binop): Ditto.
20090         * config/riscv/riscv-v.cc (needs_fp_rounding): Ditto.
20091         (expand_cond_len_op): Ditto.
20092         (expand_cond_len_unop): Ditto.
20093         (expand_cond_len_binop): Ditto.
20094         (expand_cond_len_ternop): Ditto.
20096 2023-09-01  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20098         * config/riscv/riscv-v.cc (autovectorize_vector_modes): Enable
20099         VECT_COMPARE_COSTS by default.
20101 2023-09-01  Robin Dapp  <rdapp@ventanamicro.com>
20103         * config/riscv/autovec.md (vec_extract<mode>qi): New expander.
20105 2023-09-01  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20107         * config/riscv/riscv-opts.h (enum riscv_autovec_lmul_enum): Add
20108         dynamic enum.
20109         * config/riscv/riscv.opt: Add dynamic compile option.
20111 2023-09-01  Pan Li  <pan2.li@intel.com>
20113         * config/riscv/autovec-vls.md (<optab><mode>3): New pattern for
20114         vls floating-point autovec.
20115         * config/riscv/vector-iterators.md: New iterator for
20116         floating-point V and VLS.
20117         * config/riscv/vector.md: Add VLS to floating-point binop.
20119 2023-09-01  Andrew Pinski  <apinski@marvell.com>
20121         PR tree-optimization/19832
20122         * match.pd: Add pattern to optimize
20123         `(a != b) ? a OP b : c`.
20125 2023-09-01  Lulu Cheng  <chenglulu@loongson.cn>
20126             Guo Jie  <guojie@loongson.cn>
20128         PR target/110484
20129         * config/loongarch/loongarch.cc (loongarch_emit_stack_tie): Use the
20130         frame_pointer_needed to determine whether to use the $fp register.
20132 2023-08-31  Andrew Pinski  <apinski@marvell.com>
20134         PR tree-optimization/110915
20135         * match.pd (min_value, max_value): Extend to vector constants.
20137 2023-08-31  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
20139         * config.in: Regenerate.
20140         * config/darwin-c.cc: Change spelling to macOS.
20141         * config/darwin-driver.cc: Likewise.
20142         * config/darwin.h: Likewise.
20143         * configure.ac: Likewise.
20144         * doc/contrib.texi: Likewise.
20145         * doc/extend.texi: Likewise.
20146         * doc/invoke.texi: Likewise.
20147         * doc/plugins.texi: Likewise.
20148         * doc/tm.texi: Regenerate.
20149         * doc/tm.texi.in: Change spelling to macOS.
20150         * plugin.cc: Likewise.
20152 2023-08-31  Pan Li  <pan2.li@intel.com>
20154         * config/riscv/autovec-opt.md: Add FRM_REGNUM to vfnmadd/vfnmacc.
20155         * config/riscv/autovec.md: Ditto.
20157 2023-08-31  Pan Li  <pan2.li@intel.com>
20159         * config/riscv/autovec-opt.md: Add FRM_REGNUM to vfnmsac/vfnmsub
20160         * config/riscv/autovec.md: Ditto.
20162 2023-08-31  Richard Sandiford  <richard.sandiford@arm.com>
20164         * config/aarch64/aarch64.md (untyped_call): Emit a call_value
20165         rather than a call.  List each possible destination register
20166         in the call pattern.
20168 2023-08-31  Pan Li  <pan2.li@intel.com>
20170         * config/riscv/autovec-opt.md: Add FRM_REGNUM to vfmsac/vfmsub
20171         * config/riscv/autovec.md: Ditto.
20173 2023-08-31  Pan Li  <pan2.li@intel.com>
20174             Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
20176         * config/riscv/autovec-opt.md: Add FRM_REGNUM to vfmadd/vfmacc.
20177         * config/riscv/autovec.md: Ditto.
20178         * config/riscv/vector-iterators.md: Add UNSPEC_VFFMA.
20180 2023-08-31  Palmer Dabbelt  <palmer@rivosinc.com>
20182         * config/riscv/autovec.md (shifts): Use
20183         vector_scalar_shift_operand.
20184         * config/riscv/predicates.md (vector_scalar_shift_operand): New
20185         predicate.
20187 2023-08-31  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20189         * config.gcc: Add vector cost model framework for RVV.
20190         * config/riscv/riscv.cc (riscv_vectorize_create_costs): Ditto.
20191         (TARGET_VECTORIZE_CREATE_COSTS): Ditto.
20192         * config/riscv/t-riscv: Ditto.
20193         * config/riscv/riscv-vector-costs.cc: New file.
20194         * config/riscv/riscv-vector-costs.h: New file.
20196 2023-08-31  Jeevitha Palanisamy  <jeevitha@linux.ibm.com>
20198         PR target/110411
20199         * config/rs6000/mma.md (define_insn_and_split movoo): Disallow
20200         AltiVec address operands.
20201         (define_insn_and_split movxo): Likewise.
20202         * config/rs6000/predicates.md (vsx_quad_dform_memory_operand): Remove
20203         redundant mode size check.
20205 2023-08-31  Lehua Ding  <lehua.ding@rivai.ai>
20207         * config/riscv/riscv-protos.h (IS_AGNOSTIC): Move to here.
20208         * config/riscv/riscv-v.cc (gen_no_side_effects_vsetvl_rtx):
20209         Change to default policy.
20210         * config/riscv/riscv-vector-builtins-bases.cc: Change to default policy.
20211         * config/riscv/riscv-vsetvl.h (IS_AGNOSTIC): Delete.
20212         * config/riscv/riscv.cc (riscv_print_operand): Use IS_AGNOSTIC to test.
20214 2023-08-31  Lehua Ding  <lehua.ding@rivai.ai>
20216         * config/riscv/autovec-opt.md: Adjust.
20217         * config/riscv/autovec-vls.md: Ditto.
20218         * config/riscv/autovec.md: Ditto.
20219         * config/riscv/riscv-protos.h (enum insn_type): Add insn_type.
20220         (enum insn_flags): Add insn flags.
20221         (emit_vlmax_insn): Adjust.
20222         (emit_vlmax_fp_insn): Delete.
20223         (emit_vlmax_ternary_insn): Delete.
20224         (emit_vlmax_fp_ternary_insn): Delete.
20225         (emit_nonvlmax_insn): Adjust.
20226         (emit_vlmax_slide_insn): Delete.
20227         (emit_nonvlmax_slide_tu_insn): Delete.
20228         (emit_vlmax_merge_insn): Delete.
20229         (emit_vlmax_cmp_insn): Delete.
20230         (emit_vlmax_cmp_mu_insn): Delete.
20231         (emit_vlmax_masked_mu_insn): Delete.
20232         (emit_scalar_move_insn): Delete.
20233         (emit_nonvlmax_integer_move_insn): Delete.
20234         (emit_vlmax_insn_lra): Add.
20235         * config/riscv/riscv-v.cc (get_mask_mode_from_insn_flags): New.
20236         (emit_vlmax_insn): Adjust.
20237         (emit_nonvlmax_insn): Adjust.
20238         (emit_vlmax_insn_lra): Add.
20239         (emit_vlmax_fp_insn): Delete.
20240         (emit_vlmax_ternary_insn): Delete.
20241         (emit_vlmax_fp_ternary_insn): Delete.
20242         (emit_vlmax_slide_insn): Delete.
20243         (emit_nonvlmax_slide_tu_insn): Delete.
20244         (emit_nonvlmax_slide_insn): Delete.
20245         (emit_vlmax_merge_insn): Delete.
20246         (emit_vlmax_cmp_insn): Delete.
20247         (emit_vlmax_cmp_mu_insn): Delete.
20248         (emit_vlmax_masked_insn): Delete.
20249         (emit_nonvlmax_masked_insn): Delete.
20250         (emit_vlmax_masked_store_insn): Delete.
20251         (emit_nonvlmax_masked_store_insn): Delete.
20252         (emit_vlmax_masked_mu_insn): Delete.
20253         (emit_vlmax_masked_fp_mu_insn): Delete.
20254         (emit_nonvlmax_tu_insn): Delete.
20255         (emit_nonvlmax_fp_tu_insn): Delete.
20256         (emit_nonvlmax_tumu_insn): Delete.
20257         (emit_nonvlmax_fp_tumu_insn): Delete.
20258         (emit_scalar_move_insn): Delete.
20259         (emit_cpop_insn): Delete.
20260         (emit_vlmax_integer_move_insn): Delete.
20261         (emit_nonvlmax_integer_move_insn): Delete.
20262         (emit_vlmax_gather_insn): Delete.
20263         (emit_vlmax_masked_gather_mu_insn): Delete.
20264         (emit_vlmax_compress_insn): Delete.
20265         (emit_nonvlmax_compress_insn): Delete.
20266         (emit_vlmax_reduction_insn): Delete.
20267         (emit_vlmax_fp_reduction_insn): Delete.
20268         (emit_nonvlmax_fp_reduction_insn): Delete.
20269         (expand_vec_series): Adjust.
20270         (expand_const_vector): Adjust.
20271         (legitimize_move): Adjust.
20272         (sew64_scalar_helper): Adjust.
20273         (expand_tuple_move): Adjust.
20274         (expand_vector_init_insert_elems): Adjust.
20275         (expand_vector_init_merge_repeating_sequence): Adjust.
20276         (expand_vec_cmp): Adjust.
20277         (expand_vec_cmp_float): Adjust.
20278         (expand_vec_perm): Adjust.
20279         (shuffle_merge_patterns): Adjust.
20280         (shuffle_compress_patterns): Adjust.
20281         (shuffle_decompress_patterns): Adjust.
20282         (expand_load_store): Adjust.
20283         (expand_cond_len_op): Adjust.
20284         (expand_cond_len_unop): Adjust.
20285         (expand_cond_len_binop): Adjust.
20286         (expand_gather_scatter): Adjust.
20287         (expand_cond_len_ternop): Adjust.
20288         (expand_reduction): Adjust.
20289         (expand_lanes_load_store): Adjust.
20290         (expand_fold_extract_last): Adjust.
20291         * config/riscv/riscv.cc (vector_zero_call_used_regs): Adjust.
20292         * config/riscv/vector.md: Adjust.
20294 2023-08-31  Haochen Gui  <guihaoc@gcc.gnu.org>
20296         PR target/96762
20297         * config/rs6000/rs6000-string.cc (expand_block_move): Call vector
20298         load/store with length only on 64-bit Power10.
20300 2023-08-31  Claudiu Zissulescu  <claziss@gmail.com>
20302         * config/arc/arc.cc (arc_split_mov_const): Use LSL16 only when
20303         SWAP option is enabled.
20304         * config/arc/arc.md (ashlsi2_cnt16): Likewise.
20306 2023-08-31  Stamatis Markianos-Wright  <stam.markianos-wright@arm.com>
20308         * config/arm/arm-mve-builtins-base.cc (vcaddq_rot90, vcaddq_rot270):
20309         Use common insn for signed and unsigned front-end definitions.
20310         * config/arm/arm_mve_builtins.def
20311         (vcaddq_rot90_m_u, vcaddq_rot270_m_u): Make common.
20312         (vcaddq_rot90_m_s, vcaddq_rot270_m_s): Remove.
20313         * config/arm/iterators.md (mve_insn): Merge signed and unsigned defs.
20314         (isu): Likewise.
20315         (rot): Likewise.
20316         (mve_rot): Likewise.
20317         (supf): Likewise.
20318         (VxCADDQ_M): Likewise.
20319         * config/arm/unspecs.md (unspec): Likewise.
20320         * config/arm/mve.md: Fix minor typo.
20322 2023-08-31  liuhongt  <hongtao.liu@intel.com>
20324         * config/i386/sse.md (<avx512>_blendm<mode>): Merge
20325         VF_AVX512HFBFVL into VI12HFBF_AVX512VL.
20326         (VF_AVX512HFBF16): Renamed to VHFBF.
20327         (VF_AVX512FP16VL): Renamed to VHF_AVX512VL.
20328         (VF_AVX512FP16): Removed.
20329         (div<mode>3): Adjust VF_AVX512FP16VL to VHF_AVX512VL.
20330         (avx512fp16_rcp<mode>2<mask_name>): Ditto.
20331         (rsqrt<mode>2): Ditto.
20332         (<sse>_rsqrt<mode>2<mask_name>): Ditto.
20333         (vcond<mode><code>): Ditto.
20334         (vcond<sseintvecmodelower><mode>): Ditto.
20335         (<avx512>_fmaddc_<mode>_mask1<round_expand_name>): Ditto.
20336         (<avx512>_fmaddc_<mode>_maskz<round_expand_name>): Ditto.
20337         (<avx512>_fcmaddc_<mode>_mask1<round_expand_name>): Ditto.
20338         (<avx512>_fcmaddc_<mode>_maskz<round_expand_name>): Ditto.
20339         (cmla<conj_op><mode>4): Ditto.
20340         (fma_<mode>_fadd_fmul): Ditto.
20341         (fma_<mode>_fadd_fcmul): Ditto.
20342         (fma_<complexopname>_<mode>_fma_zero): Ditto.
20343         (fma_<mode>_fmaddc_bcst): Ditto.
20344         (fma_<mode>_fcmaddc_bcst): Ditto.
20345         (<avx512>_<complexopname>_<mode>_mask<round_name>): Ditto.
20346         (cmul<conj_op><mode>3): Ditto.
20347         (<avx512>_<complexopname>_<mode><maskc_name><round_name>):
20348         Ditto.
20349         (vec_unpacks_lo_<mode>): Ditto.
20350         (vec_unpacks_hi_<mode>): Ditto.
20351         (vec_unpack_<fixprefix>fix_trunc_lo_<mode>): Ditto.
20352         (vec_unpack_<fixprefix>fix_trunc_lo_<mode>): Ditto.
20353         (*vec_extract<mode>_0): Ditto.
20354         (*<avx512>_cmp<mode>3): Extend to V48H_AVX512VL.
20356 2023-08-31  Lehua Ding  <lehua.ding@rivai.ai>
20358         PR target/111234
20359         * config/riscv/riscv-vsetvl.cc (gen_vsetvl_pat): Remove condition.
20361 2023-08-31  Jiufu Guo  <guojiufu@linux.ibm.com>
20363         * range-op-mixed.h (operator_plus::overflow_free_p): New declare.
20364         (operator_minus::overflow_free_p): New declare.
20365         (operator_mult::overflow_free_p): New declare.
20366         * range-op.cc (range_op_handler::overflow_free_p): New function.
20367         (range_operator::overflow_free_p): New default function.
20368         (operator_plus::overflow_free_p): New function.
20369         (operator_minus::overflow_free_p): New function.
20370         (operator_mult::overflow_free_p): New function.
20371         * range-op.h (range_op_handler::overflow_free_p): New declare.
20372         (range_operator::overflow_free_p): New declare.
20373         * value-range.cc (irange::nonnegative_p): New function.
20374         (irange::nonpositive_p): New function.
20375         * value-range.h (irange::nonnegative_p): New declare.
20376         (irange::nonpositive_p): New declare.
20378 2023-08-30  Dimitar Dimitrov  <dimitar@dinux.eu>
20380         PR target/106562
20381         * config/pru/predicates.md (const_0_operand): New predicate.
20382         (pru_cstore_comparison_operator): Ditto.
20383         * config/pru/pru.md (cstore<mode>4): New pattern.
20384         (cstoredi4): Ditto.
20386 2023-08-30  Richard Biener  <rguenther@suse.de>
20388         PR tree-optimization/111228
20389         * match.pd ((vec_perm (vec_perm ..) @5 ..) -> (vec_perm @x @5 ..)):
20390         New simplifications.
20392 2023-08-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20394         * config/riscv/autovec.md (movmisalign<mode>): Delete.
20396 2023-08-30  Die Li  <lidie@eswincomputing.com>
20397             Fei Gao  <gaofei@eswincomputing.com>
20399         * config/riscv/peephole.md: New pattern.
20400         * config/riscv/predicates.md (a0a1_reg_operand): New predicate.
20401         (zcmp_mv_sreg_operand): New predicate.
20402         * config/riscv/riscv.md: New predicate.
20403         * config/riscv/zc.md (*mva01s<X:mode>): New pattern.
20404         (*mvsa01<X:mode>): New pattern.
20406 2023-08-30  Fei Gao  <gaofei@eswincomputing.com>
20408         * config/riscv/riscv.cc
20409         (riscv_zcmp_can_use_popretz): true if popretz can be used
20410         (riscv_gen_multi_pop_insn): interface to generate cm.pop[ret][z]
20411         (riscv_expand_epilogue): expand cm.pop[ret][z] in epilogue
20412         * config/riscv/riscv.md: define A0_REGNUM
20413         * config/riscv/zc.md
20414         (@gpr_multi_popretz_up_to_ra_<mode>): md for popretz ra
20415         (@gpr_multi_popretz_up_to_s0_<mode>): md for popretz ra, s0
20416         (@gpr_multi_popretz_up_to_s1_<mode>): likewise
20417         (@gpr_multi_popretz_up_to_s2_<mode>): likewise
20418         (@gpr_multi_popretz_up_to_s3_<mode>): likewise
20419         (@gpr_multi_popretz_up_to_s4_<mode>): likewise
20420         (@gpr_multi_popretz_up_to_s5_<mode>): likewise
20421         (@gpr_multi_popretz_up_to_s6_<mode>): likewise
20422         (@gpr_multi_popretz_up_to_s7_<mode>): likewise
20423         (@gpr_multi_popretz_up_to_s8_<mode>): likewise
20424         (@gpr_multi_popretz_up_to_s9_<mode>): likewise
20425         (@gpr_multi_popretz_up_to_s11_<mode>): likewise
20427 2023-08-30  Fei Gao  <gaofei@eswincomputing.com>
20429         * config/riscv/iterators.md
20430         (slot0_offset): slot 0 offset in stack GPRs area in bytes
20431         (slot1_offset): slot 1 offset in stack GPRs area in bytes
20432         (slot2_offset): likewise
20433         (slot3_offset): likewise
20434         (slot4_offset): likewise
20435         (slot5_offset): likewise
20436         (slot6_offset): likewise
20437         (slot7_offset): likewise
20438         (slot8_offset): likewise
20439         (slot9_offset): likewise
20440         (slot10_offset): likewise
20441         (slot11_offset): likewise
20442         (slot12_offset): likewise
20443         * config/riscv/predicates.md
20444         (stack_push_up_to_ra_operand): predicates of stack adjust pushing ra
20445         (stack_push_up_to_s0_operand): predicates of stack adjust pushing ra, s0
20446         (stack_push_up_to_s1_operand): likewise
20447         (stack_push_up_to_s2_operand): likewise
20448         (stack_push_up_to_s3_operand): likewise
20449         (stack_push_up_to_s4_operand): likewise
20450         (stack_push_up_to_s5_operand): likewise
20451         (stack_push_up_to_s6_operand): likewise
20452         (stack_push_up_to_s7_operand): likewise
20453         (stack_push_up_to_s8_operand): likewise
20454         (stack_push_up_to_s9_operand): likewise
20455         (stack_push_up_to_s11_operand): likewise
20456         (stack_pop_up_to_ra_operand): predicates of stack adjust poping ra
20457         (stack_pop_up_to_s0_operand): predicates of stack adjust poping ra, s0
20458         (stack_pop_up_to_s1_operand): likewise
20459         (stack_pop_up_to_s2_operand): likewise
20460         (stack_pop_up_to_s3_operand): likewise
20461         (stack_pop_up_to_s4_operand): likewise
20462         (stack_pop_up_to_s5_operand): likewise
20463         (stack_pop_up_to_s6_operand): likewise
20464         (stack_pop_up_to_s7_operand): likewise
20465         (stack_pop_up_to_s8_operand): likewise
20466         (stack_pop_up_to_s9_operand): likewise
20467         (stack_pop_up_to_s11_operand): likewise
20468         * config/riscv/riscv-protos.h
20469         (riscv_zcmp_valid_stack_adj_bytes_p):declaration
20470         * config/riscv/riscv.cc (struct riscv_frame_info): comment change
20471         (riscv_avoid_multi_push): helper function of riscv_use_multi_push
20472         (riscv_use_multi_push): true if multi push is used
20473         (riscv_multi_push_sregs_count): num of sregs in multi-push
20474         (riscv_multi_push_regs_count): num of regs in multi-push
20475         (riscv_16bytes_align): align to 16 bytes
20476         (riscv_stack_align): moved to a better place
20477         (riscv_save_libcall_count): no functional change
20478         (riscv_compute_frame_info): add zcmp frame info
20479         (riscv_for_each_saved_reg): save or restore fprs in specified slot for zcmp
20480         (riscv_adjust_multi_push_cfi_prologue): adjust cfi for cm.push
20481         (riscv_gen_multi_push_pop_insn): gen function for multi push and pop
20482         (get_multi_push_fpr_mask): get mask for the fprs pushed by cm.push
20483         (riscv_expand_prologue): allocate stack by cm.push
20484         (riscv_adjust_multi_pop_cfi_epilogue): adjust cfi for cm.pop[ret]
20485         (riscv_expand_epilogue): allocate stack by cm.pop[ret]
20486         (zcmp_base_adj): calculate stack adjustment base size
20487         (zcmp_additional_adj): calculate stack adjustment additional size
20488         (riscv_zcmp_valid_stack_adj_bytes_p): check if stack adjustment valid
20489         * config/riscv/riscv.h (RETURN_ADDR_MASK): mask of ra
20490         (S0_MASK): likewise
20491         (S1_MASK): likewise
20492         (S2_MASK): likewise
20493         (S3_MASK): likewise
20494         (S4_MASK): likewise
20495         (S5_MASK): likewise
20496         (S6_MASK): likewise
20497         (S7_MASK): likewise
20498         (S8_MASK): likewise
20499         (S9_MASK): likewise
20500         (S10_MASK): likewise
20501         (S11_MASK): likewise
20502         (MULTI_PUSH_GPR_MASK): GPR_MASK that cm.push can cover at most
20503         (ZCMP_MAX_SPIMM): max spimm value
20504         (ZCMP_SP_INC_STEP): zcmp sp increment step
20505         (ZCMP_INVALID_S0S10_SREGS_COUNTS): num of s0-s10
20506         (ZCMP_S0S11_SREGS_COUNTS): num of s0-s11
20507         (ZCMP_MAX_GRP_SLOTS): max slots of pushing and poping in zcmp
20508         (CALLEE_SAVED_FREG_NUMBER): get x of fsx(fs0 ~ fs11)
20509         * config/riscv/riscv.md: include zc.md
20510         * config/riscv/zc.md: New file. machine description for zcmp
20512 2023-08-30  Jakub Jelinek  <jakub@redhat.com>
20514         PR tree-optimization/110914
20515         * tree-ssa-strlen.cc (strlen_pass::handle_builtin_memcpy): Don't call
20516         adjust_last_stmt unless len is known constant.
20518 2023-08-30  Jakub Jelinek  <jakub@redhat.com>
20520         PR tree-optimization/111015
20521         * gimple-ssa-store-merging.cc
20522         (imm_store_chain_info::output_merged_store): Use wi::mask and
20523         wide_int_to_tree instead of unsigned HOST_WIDE_INT shift and
20524         build_int_cst to build BIT_AND_EXPR mask.
20526 2023-08-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20528         * tree-ssa-alias.cc (ref_maybe_used_by_call_p_1): Add MASK_LEN_ variant.
20529         (call_may_clobber_ref_p_1): Ditto.
20530         * tree-ssa-loop-ivopts.cc (get_mem_type_for_internal_fn): Ditto.
20531         (get_alias_ptr_type_for_ptr_address): Ditto.
20533 2023-08-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20535         * config/riscv/riscv-vsetvl.cc
20536         (vector_insn_info::get_avl_or_vl_reg): Fix bug.
20538 2023-08-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20540         * config/riscv/autovec-vls.md (movmisalign<mode>): New pattern.
20541         * config/riscv/riscv.cc (riscv_support_vector_misalignment): Support
20542         VLS misalign.
20544 2023-08-29  Philipp Tomsich  <philipp.tomsich@vrull.eu>
20546         * config/riscv/zicond.md: New splitters to rewrite single bit
20547         sign extension as the condition to a czero in the desired form.
20549 2023-08-29  David Malcolm  <dmalcolm@redhat.com>
20551         PR analyzer/99860
20552         * doc/invoke.texi: Add -Wanalyzer-overlapping-buffers.
20554 2023-08-29  David Malcolm  <dmalcolm@redhat.com>
20556         PR analyzer/99860
20557         * Makefile.in (ANALYZER_OBJS): Add analyzer/ranges.o.
20559 2023-08-29  Jin Ma  <jinma@linux.alibaba.com>
20561         * config/riscv/riscv.cc (riscv_float_const_rtx_index_for_fli):
20562         zvfh can generate zfa extended instruction fli.h, just like zfh.
20564 2023-08-29  Edwin Lu  <ewlu@rivosinc.com>
20565             Vineet Gupta  <vineetg@rivosinc.com>
20567         * config/riscv/riscv-c.cc (riscv_cpu_cpp_builtins): Generate
20568         __riscv_unaligned_avoid with value 1 or
20569         __riscv_unaligned_slow with value 1 or
20570         __riscv_unaligned_fast with value 1
20571         * config/riscv/riscv.cc (riscv_option_override): Define
20572         riscv_user_wants_strict_align. Set
20573         riscv_user_wants_strict_align to TARGET_STRICT_ALIGN
20574         * config/riscv/riscv.h: Declare riscv_user_wants_strict_align
20576 2023-08-29  Edwin Lu  <ewlu@rivosinc.com>
20578         * config/riscv/autovec-vls.md: Update types
20579         * config/riscv/riscv.md: Add vector placeholder type
20580         * config/riscv/vector.md: Update types
20582 2023-08-29  Carl Love  <cel@us.ibm.com>
20584         * config/rs6000/dfp.md (UNSPEC_DQUAN): New unspec.
20585         (dfp_dqua_<mode>, dfp_dquai_<mode>): New define_insn.
20586         * config/rs6000/rs6000-builtins.def (__builtin_dfp_dqua,
20587         __builtin_dfp_dquai, __builtin_dfp_dquaq, __builtin_dfp_dquaqi):
20588         New buit-in definitions.
20589         * config/rs6000/rs6000-overload.def (__builtin_dfp_quantize): New
20590         overloaded definition.
20591         * doc/extend.texi: Add documentation for __builtin_dfp_quantize.
20593 2023-08-29  Pan Li  <pan2.li@intel.com>
20594             Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
20596         * config/riscv/riscv.cc (riscv_legitimize_poly_move): New declaration.
20597         (riscv_legitimize_const_move): Handle ref plus const poly.
20599 2023-08-29  Tsukasa OI  <research_trasio@irq.a4lg.com>
20601         * common/config/riscv/riscv-common.cc
20602         (riscv_implied_info): Add implications from unprivileged extensions.
20603         (riscv_ext_version_table): Add stub support for all unprivileged
20604         extensions supported by Binutils as well as 'Zce', 'Zcmp', 'Zcmt'.
20606 2023-08-29  Tsukasa OI  <research_trasio@irq.a4lg.com>
20608         * common/config/riscv/riscv-common.cc (riscv_ext_version_table):
20609         Add stub support for all vendor extensions supported by Binutils.
20611 2023-08-29  Tsukasa OI  <research_trasio@irq.a4lg.com>
20613         * common/config/riscv/riscv-common.cc
20614         (riscv_implied_info): Add implications from privileged extensions.
20615         (riscv_ext_version_table): Add stub support for all privileged
20616         extensions supported by Binutils.
20618 2023-08-29  Lehua Ding  <lehua.ding@rivai.ai>
20620         * config/riscv/autovec.md: Adjust
20621         * config/riscv/riscv-protos.h (RVV_VUNDEF): Clean.
20622         (get_vlmax_rtx): Exported.
20623         * config/riscv/riscv-v.cc (emit_nonvlmax_fp_ternary_tu_insn): Deleted.
20624         (emit_vlmax_masked_gather_mu_insn): Adjust.
20625         (get_vlmax_rtx): New func.
20626         (expand_load_store): Adjust.
20627         (expand_cond_len_unop): Call expand_cond_len_op.
20628         (expand_cond_len_op): New subroutine.
20629         (expand_cond_len_binop): Call expand_cond_len_op.
20630         (expand_cond_len_ternop): Call expand_cond_len_op.
20631         (expand_lanes_load_store): Adjust.
20633 2023-08-29  Jakub Jelinek  <jakub@redhat.com>
20635         PR middle-end/79173
20636         PR middle-end/111209
20637         * tree-ssa-math-opts.cc (match_uaddc_usubc): Match also
20638         just 2 limb uaddc/usubc with 0 carry-in on lower limb and ignored
20639         carry-out on higher limb.  Don't match it though if it could be
20640         matched later on 4 argument addition/subtraction.
20642 2023-08-29  Andrew Pinski  <apinski@marvell.com>
20644         PR tree-optimization/111147
20645         * match.pd (`(x | y) & (~x ^ y)`) Use bitwise_inverted_equal_p
20646         instead of matching bit_not.
20648 2023-08-29  Christophe Lyon  <christophe.lyon@linaro.org>
20650         * config/arm/arm-mve-builtins.cc (type_suffixes): Add missing
20651         initializer.
20653 2023-08-29  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20655         * config/riscv/riscv-vsetvl.cc (vector_insn_info::get_avl_or_vl_reg): New function.
20656         (pass_vsetvl::compute_local_properties): Fix bug.
20657         (pass_vsetvl::commit_vsetvls): Ditto.
20658         * config/riscv/riscv-vsetvl.h: New function.
20660 2023-08-29  Lehua Ding  <lehua.ding@rivai.ai>
20662         PR target/110943
20663         * config/riscv/predicates.md (vector_const_int_or_double_0_operand):
20664         New predicate.
20665         * config/riscv/riscv-vector-builtins.cc (function_expander::function_expander):
20666         force_reg mem target operand.
20667         * config/riscv/vector.md (@pred_mov<mode>): Wrapper.
20668         (*pred_mov<mode>): Remove imm -> reg pattern.
20669         (*pred_broadcast<mode>_imm): Add imm -> reg pattern.
20671 2023-08-29  Lulu Cheng  <chenglulu@loongson.cn>
20673         * common/config/loongarch/loongarch-common.cc:
20674         Enable '-free' on O2 and above.
20675         * doc/invoke.texi: Modify the description information
20676         of the '-free' compilation option and add the LoongArch
20677         description.
20679 2023-08-28  Tsukasa OI  <research_trasio@irq.a4lg.com>
20681         * doc/extend.texi: Fix the description of __builtin_riscv_pause.
20683 2023-08-28  Tsukasa OI  <research_trasio@irq.a4lg.com>
20685         * common/config/riscv/riscv-common.cc (riscv_ext_version_table):
20686         Implement the 'Zihintpause' extension, version 2.0.
20687         (riscv_ext_flag_table) Add 'Zihintpause' handling.
20688         * config/riscv/riscv-builtins.cc: Remove availability predicate
20689         "always" and add "hint_pause".
20690         (riscv_builtins) : Add "pause" extension.
20691         * config/riscv/riscv-opts.h (MASK_ZIHINTPAUSE, TARGET_ZIHINTPAUSE): New.
20692         * config/riscv/riscv.md (riscv_pause): Adjust output based on
20693         TARGET_ZIHINTPAUSE.
20695 2023-08-28  Andrew Pinski  <apinski@marvell.com>
20697         * match.pd (`(X & ~Y) | (~X & Y)`): Use bitwise_inverted_equal_p
20698         instead of specifically checking for ~X.
20700 2023-08-28  Andrew Pinski  <apinski@marvell.com>
20702         PR tree-optimization/111146
20703         * match.pd (`(x | y) & ~x`, `(x & y) | ~x`): Remove
20704         redundant pattern.
20706 2023-08-28  Andrew Pinski  <apinski@marvell.com>
20708         * tree-ssa-phiopt.cc (gimple_simplify_phiopt): Add dump information
20709         when resimplify returns true.
20710         (match_simplify_replacement): Print only if accepted the match-and-simplify
20711         result rather than the full sequence.
20713 2023-08-28  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20715         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::earliest_fusion): Skip
20716         never probability.
20717         (pass_vsetvl::compute_probabilities): Fix unitialized probability.
20719 2023-08-28  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20721         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::earliest_fusion): Fix bug.
20723 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20725         * config/arm/arm-mve-builtins-base.cc (vmullbq_poly)
20726         (vmulltq_poly): New.
20727         * config/arm/arm-mve-builtins-base.def (vmullbq_poly)
20728         (vmulltq_poly): New.
20729         * config/arm/arm-mve-builtins-base.h (vmullbq_poly)
20730         (vmulltq_poly): New.
20731         * config/arm/arm_mve.h (vmulltq_poly): Remove.
20732         (vmullbq_poly): Remove.
20733         (vmullbq_poly_m): Remove.
20734         (vmulltq_poly_m): Remove.
20735         (vmullbq_poly_x): Remove.
20736         (vmulltq_poly_x): Remove.
20737         (vmulltq_poly_p8): Remove.
20738         (vmullbq_poly_p8): Remove.
20739         (vmulltq_poly_p16): Remove.
20740         (vmullbq_poly_p16): Remove.
20741         (vmullbq_poly_m_p8): Remove.
20742         (vmullbq_poly_m_p16): Remove.
20743         (vmulltq_poly_m_p8): Remove.
20744         (vmulltq_poly_m_p16): Remove.
20745         (vmullbq_poly_x_p8): Remove.
20746         (vmullbq_poly_x_p16): Remove.
20747         (vmulltq_poly_x_p8): Remove.
20748         (vmulltq_poly_x_p16): Remove.
20749         (__arm_vmulltq_poly_p8): Remove.
20750         (__arm_vmullbq_poly_p8): Remove.
20751         (__arm_vmulltq_poly_p16): Remove.
20752         (__arm_vmullbq_poly_p16): Remove.
20753         (__arm_vmullbq_poly_m_p8): Remove.
20754         (__arm_vmullbq_poly_m_p16): Remove.
20755         (__arm_vmulltq_poly_m_p8): Remove.
20756         (__arm_vmulltq_poly_m_p16): Remove.
20757         (__arm_vmullbq_poly_x_p8): Remove.
20758         (__arm_vmullbq_poly_x_p16): Remove.
20759         (__arm_vmulltq_poly_x_p8): Remove.
20760         (__arm_vmulltq_poly_x_p16): Remove.
20761         (__arm_vmulltq_poly): Remove.
20762         (__arm_vmullbq_poly): Remove.
20763         (__arm_vmullbq_poly_m): Remove.
20764         (__arm_vmulltq_poly_m): Remove.
20765         (__arm_vmullbq_poly_x): Remove.
20766         (__arm_vmulltq_poly_x): Remove.
20768 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20770         * config/arm/arm-mve-builtins-functions.h (class
20771         unspec_mve_function_exact_insn_vmull_poly): New.
20773 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20775         * config/arm/arm-mve-builtins-shapes.cc (binary_widen_poly): New.
20776         * config/arm/arm-mve-builtins-shapes.h (binary_widen_poly): New.
20778 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20780         * config/arm/arm-mve-builtins-shapes.cc (parse_element_type): Add
20781         support for 'U' and 'p' format specifiers.
20783 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20785         * config/arm/arm-mve-builtins.cc (type_suffixes): Handle poly_p
20786         field..
20787         (TYPES_poly_8_16): New.
20788         (poly_8_16): New.
20789         * config/arm/arm-mve-builtins.def (p8): New type suffix.
20790         (p16): Likewise.
20791         * config/arm/arm-mve-builtins.h (enum type_class_index): Add
20792         TYPE_poly.
20793         (struct type_suffix_info): Add poly_p field.
20795 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20797         * config/arm/arm-mve-builtins-base.cc (vmullbq_int, vmulltq_int):
20798         New.
20799         * config/arm/arm-mve-builtins-base.def (vmullbq_int, vmulltq_int):
20800         New.
20801         * config/arm/arm-mve-builtins-base.h (vmullbq_int, vmulltq_int):
20802         New.
20803         * config/arm/arm_mve.h (vmulltq_int): Remove.
20804         (vmullbq_int): Remove.
20805         (vmullbq_int_m): Remove.
20806         (vmulltq_int_m): Remove.
20807         (vmullbq_int_x): Remove.
20808         (vmulltq_int_x): Remove.
20809         (vmulltq_int_u8): Remove.
20810         (vmullbq_int_u8): Remove.
20811         (vmulltq_int_s8): Remove.
20812         (vmullbq_int_s8): Remove.
20813         (vmulltq_int_u16): Remove.
20814         (vmullbq_int_u16): Remove.
20815         (vmulltq_int_s16): Remove.
20816         (vmullbq_int_s16): Remove.
20817         (vmulltq_int_u32): Remove.
20818         (vmullbq_int_u32): Remove.
20819         (vmulltq_int_s32): Remove.
20820         (vmullbq_int_s32): Remove.
20821         (vmullbq_int_m_s8): Remove.
20822         (vmullbq_int_m_s32): Remove.
20823         (vmullbq_int_m_s16): Remove.
20824         (vmullbq_int_m_u8): Remove.
20825         (vmullbq_int_m_u32): Remove.
20826         (vmullbq_int_m_u16): Remove.
20827         (vmulltq_int_m_s8): Remove.
20828         (vmulltq_int_m_s32): Remove.
20829         (vmulltq_int_m_s16): Remove.
20830         (vmulltq_int_m_u8): Remove.
20831         (vmulltq_int_m_u32): Remove.
20832         (vmulltq_int_m_u16): Remove.
20833         (vmullbq_int_x_s8): Remove.
20834         (vmullbq_int_x_s16): Remove.
20835         (vmullbq_int_x_s32): Remove.
20836         (vmullbq_int_x_u8): Remove.
20837         (vmullbq_int_x_u16): Remove.
20838         (vmullbq_int_x_u32): Remove.
20839         (vmulltq_int_x_s8): Remove.
20840         (vmulltq_int_x_s16): Remove.
20841         (vmulltq_int_x_s32): Remove.
20842         (vmulltq_int_x_u8): Remove.
20843         (vmulltq_int_x_u16): Remove.
20844         (vmulltq_int_x_u32): Remove.
20845         (__arm_vmulltq_int_u8): Remove.
20846         (__arm_vmullbq_int_u8): Remove.
20847         (__arm_vmulltq_int_s8): Remove.
20848         (__arm_vmullbq_int_s8): Remove.
20849         (__arm_vmulltq_int_u16): Remove.
20850         (__arm_vmullbq_int_u16): Remove.
20851         (__arm_vmulltq_int_s16): Remove.
20852         (__arm_vmullbq_int_s16): Remove.
20853         (__arm_vmulltq_int_u32): Remove.
20854         (__arm_vmullbq_int_u32): Remove.
20855         (__arm_vmulltq_int_s32): Remove.
20856         (__arm_vmullbq_int_s32): Remove.
20857         (__arm_vmullbq_int_m_s8): Remove.
20858         (__arm_vmullbq_int_m_s32): Remove.
20859         (__arm_vmullbq_int_m_s16): Remove.
20860         (__arm_vmullbq_int_m_u8): Remove.
20861         (__arm_vmullbq_int_m_u32): Remove.
20862         (__arm_vmullbq_int_m_u16): Remove.
20863         (__arm_vmulltq_int_m_s8): Remove.
20864         (__arm_vmulltq_int_m_s32): Remove.
20865         (__arm_vmulltq_int_m_s16): Remove.
20866         (__arm_vmulltq_int_m_u8): Remove.
20867         (__arm_vmulltq_int_m_u32): Remove.
20868         (__arm_vmulltq_int_m_u16): Remove.
20869         (__arm_vmullbq_int_x_s8): Remove.
20870         (__arm_vmullbq_int_x_s16): Remove.
20871         (__arm_vmullbq_int_x_s32): Remove.
20872         (__arm_vmullbq_int_x_u8): Remove.
20873         (__arm_vmullbq_int_x_u16): Remove.
20874         (__arm_vmullbq_int_x_u32): Remove.
20875         (__arm_vmulltq_int_x_s8): Remove.
20876         (__arm_vmulltq_int_x_s16): Remove.
20877         (__arm_vmulltq_int_x_s32): Remove.
20878         (__arm_vmulltq_int_x_u8): Remove.
20879         (__arm_vmulltq_int_x_u16): Remove.
20880         (__arm_vmulltq_int_x_u32): Remove.
20881         (__arm_vmulltq_int): Remove.
20882         (__arm_vmullbq_int): Remove.
20883         (__arm_vmullbq_int_m): Remove.
20884         (__arm_vmulltq_int_m): Remove.
20885         (__arm_vmullbq_int_x): Remove.
20886         (__arm_vmulltq_int_x): Remove.
20888 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20890         * config/arm/arm-mve-builtins-shapes.cc (binary_widen): New.
20891         * config/arm/arm-mve-builtins-shapes.h (binary_widen): New.
20893 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20895         * config/arm/arm-mve-builtins-functions.h (class
20896         unspec_mve_function_exact_insn_vmull): New.
20898 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20900         * config/arm/iterators.md (mve_insn): Add vmullb, vmullt.
20901         (isu): Add VMULLBQ_INT_S, VMULLBQ_INT_U, VMULLTQ_INT_S,
20902         VMULLTQ_INT_U.
20903         (supf): Add VMULLBQ_POLY_P, VMULLTQ_POLY_P, VMULLBQ_POLY_M_P,
20904         VMULLTQ_POLY_M_P.
20905         (VMULLBQ_INT, VMULLTQ_INT, VMULLBQ_INT_M, VMULLTQ_INT_M): Delete.
20906         (VMULLxQ_INT, VMULLxQ_POLY, VMULLxQ_INT_M, VMULLxQ_POLY_M): New.
20907         * config/arm/mve.md (mve_vmullbq_int_<supf><mode>)
20908         (mve_vmulltq_int_<supf><mode>): Merge into ...
20909         (@mve_<mve_insn>q_int_<supf><mode>) ... this.
20910         (mve_vmulltq_poly_p<mode>, mve_vmullbq_poly_p<mode>): Merge into ...
20911         (@mve_<mve_insn>q_poly_<supf><mode>): ... this.
20912         (mve_vmullbq_int_m_<supf><mode>, mve_vmulltq_int_m_<supf><mode>): Merge into ...
20913         (@mve_<mve_insn>q_int_m_<supf><mode>): ... this.
20914         (mve_vmullbq_poly_m_p<mode>, mve_vmulltq_poly_m_p<mode>): Merge into ...
20915         (@mve_<mve_insn>q_poly_m_<supf><mode>): ... this.
20917 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20919         * config/arm/arm-mve-builtins-shapes.cc (parse_element_type):
20920         Remove dead check.
20922 2023-08-28  Christophe Lyon  <christophe.lyon@linaro.org>
20924         * config/arm/arm-mve-builtins-shapes.cc (binary_acca_int32): Fix loop bound.
20925         (binary_acca_int64): Likewise.
20927 2023-08-28  Aldy Hernandez  <aldyh@redhat.com>
20929         * range-op-float.cc (fold_range): Handle relations.
20931 2023-08-28  Lulu Cheng  <chenglulu@loongson.cn>
20933         * config/loongarch/loongarch.cc (loongarch_expand_conditional_move):
20934         Optimize the function implementation.
20936 2023-08-28  liuhongt  <hongtao.liu@intel.com>
20938         PR target/111119
20939         * config/i386/sse.md (V48_AVX2): Rename to ..
20940         (V48_128_256): .. this.
20941         (ssefltmodesuffix): Extend to V4SF/V8SF/V2DF/V4DF.
20942         (<avx_avx2>_maskload<ssemodesuffix><avxsizesuffix>): Change
20943         V48_AVX2 to V48_128_256, also generate vmaskmov{ps,pd} for
20944         integral modes when TARGET_AVX2 is not available.
20945         (<avx_avx2>_maskstore<ssemodesuffix><avxsizesuffix>): Ditto.
20946         (maskload<mode><sseintvecmodelower>): Change V48_AVX2 to
20947         V48_128_256.
20948         (maskstore<mode><sseintvecmodelower>): Ditto.
20950 2023-08-28  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20952         * config/riscv/riscv-vsetvl.cc (vsetvl_vtype_change_only_p):
20953         New function.
20954         (after_or_same_p): Ditto.
20955         (find_reg_killed_by): Delete.
20956         (has_vsetvl_killed_avl_p): Ditto.
20957         (anticipatable_occurrence_p): Refactor.
20958         (any_set_in_bb_p): Delete.
20959         (count_regno_occurrences): Ditto.
20960         (backward_propagate_worthwhile_p): Ditto.
20961         (demands_can_be_fused_p): Ditto.
20962         (earliest_pred_can_be_fused_p): New function.
20963         (vsetvl_dominated_by_p): Ditto.
20964         (vector_insn_info::parse_insn): Refactor.
20965         (vector_insn_info::merge): Refactor.
20966         (vector_insn_info::dump): Refactor.
20967         (vector_infos_manager::vector_infos_manager): Refactor.
20968         (vector_infos_manager::all_empty_predecessor_p): Delete.
20969         (vector_infos_manager::all_same_avl_p): Ditto.
20970         (vector_infos_manager::create_bitmap_vectors): Refactor.
20971         (vector_infos_manager::free_bitmap_vectors): Refactor.
20972         (vector_infos_manager::dump): Refactor.
20973         (pass_vsetvl::update_block_info): New function.
20974         (enum fusion_type): Ditto.
20975         (pass_vsetvl::get_backward_fusion_type): Delete.
20976         (pass_vsetvl::hard_empty_block_p): Ditto.
20977         (pass_vsetvl::backward_demand_fusion): Ditto.
20978         (pass_vsetvl::forward_demand_fusion): Ditto.
20979         (pass_vsetvl::demand_fusion): Ditto.
20980         (pass_vsetvl::cleanup_illegal_dirty_blocks): Ditto.
20981         (pass_vsetvl::compute_local_properties): Ditto.
20982         (pass_vsetvl::earliest_fusion): New function.
20983         (pass_vsetvl::vsetvl_fusion): Ditto.
20984         (pass_vsetvl::commit_vsetvls): Refactor.
20985         (get_first_vsetvl_before_rvv_insns): Ditto.
20986         (pass_vsetvl::global_eliminate_vsetvl_insn): Ditto.
20987         (pass_vsetvl::cleanup_earliest_vsetvls): New function.
20988         (pass_vsetvl::df_post_optimization): Refactor.
20989         (pass_vsetvl::lazy_vsetvl): Ditto.
20990         * config/riscv/riscv-vsetvl.h: Ditto.
20992 2023-08-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
20994         * config/riscv/autovec.md (len_fold_extract_last_<mode>): New pattern.
20995         * config/riscv/riscv-protos.h (enum insn_type): New enum.
20996         (expand_fold_extract_last): New function.
20997         * config/riscv/riscv-v.cc (emit_nonvlmax_slide_insn): Ditto.
20998         (emit_cpop_insn): Ditto.
20999         (emit_nonvlmax_compress_insn): Ditto.
21000         (expand_fold_extract_last): Ditto.
21001         * config/riscv/vector.md: Fix vcpop.m ratio demand.
21003 2023-08-25  Edwin Lu  <ewlu@rivosinc.com>
21005         * config/riscv/sync-rvwmo.md: updated types to "multi" or
21006                 "atomic" based on number of assembly lines generated
21007         * config/riscv/sync-ztso.md: likewise
21008         * config/riscv/sync.md: likewise
21010 2023-08-25  Jin Ma  <jinma@linux.alibaba.com>
21012         * common/config/riscv/riscv-common.cc: Add zfa extension version, which depends on
21013         the F extension.
21014         * config/riscv/constraints.md (zfli): Constrain the floating point number that the
21015         instructions FLI.H/S/D can load.
21016         * config/riscv/iterators.md (ceil): New.
21017         * config/riscv/riscv-opts.h (MASK_ZFA): New.
21018         (TARGET_ZFA): New.
21019         * config/riscv/riscv-protos.h (riscv_float_const_rtx_index_for_fli): New.
21020         * config/riscv/riscv.cc (riscv_float_const_rtx_index_for_fli): New.
21021         (riscv_cannot_force_const_mem): If instruction FLI.H/S/D can be used, memory is
21022         not applicable.
21023         (riscv_const_insns): Likewise.
21024         (riscv_legitimize_const_move): Likewise.
21025         (riscv_split_64bit_move_p): If instruction FLI.H/S/D can be used, no split is
21026         required.
21027         (riscv_split_doubleword_move): Likewise.
21028         (riscv_output_move): Output the mov instructions in zfa extension.
21029         (riscv_print_operand): Output the floating-point value of the FLI.H/S/D immediate
21030         in assembly.
21031         (riscv_secondary_memory_needed): Likewise.
21032         * config/riscv/riscv.md (fminm<mode>3): New.
21033         (fmaxm<mode>3): New.
21034         (movsidf2_low_rv32): New.
21035         (movsidf2_high_rv32): New.
21036         (movdfsisi3_rv32): New.
21037         (f<quiet_pattern>_quiet<ANYF:mode><X:mode>4_zfa): New.
21038         * config/riscv/riscv.opt: New.
21040 2023-08-25  Sandra Loosemore  <sandra@codesourcery.com>
21042         * omp-api.h: New.
21043         * omp-general.cc (omp_runtime_api_procname): New.
21044         (omp_runtime_api_call): Moved here from omp-low.cc, and make
21045         non-static.
21046         * omp-general.h: Include omp-api.h.
21047         * omp-low.cc (omp_runtime_api_call): Delete this copy.
21049 2023-08-25  Sandra Loosemore  <sandra@codesourcery.com>
21051         * doc/generic.texi (OpenMP): Document OMP_STRUCTURED_BLOCK.
21052         * doc/gimple.texi (GIMPLE instruction set): Add
21053         GIMPLE_OMP_STRUCTURED_BLOCK.
21054         (GIMPLE_OMP_STRUCTURED_BLOCK): New subsection.
21055         * gimple-low.cc (lower_stmt): Error on GIMPLE_OMP_STRUCTURED_BLOCK.
21056         * gimple-pretty-print.cc (dump_gimple_omp_block): Handle
21057         GIMPLE_OMP_STRUCTURED_BLOCK.
21058         (pp_gimple_stmt_1): Likewise.
21059         * gimple-walk.cc (walk_gimple_stmt): Likewise.
21060         * gimple.cc (gimple_build_omp_structured_block): New.
21061         * gimple.def (GIMPLE_OMP_STRUCTURED_BLOCK): New.
21062         * gimple.h (gimple_build_omp_structured_block): Declare.
21063         (gimple_has_substatements): Handle GIMPLE_OMP_STRUCTURED_BLOCK.
21064         (CASE_GIMPLE_OMP): Likewise.
21065         * gimplify.cc (is_gimple_stmt): Handle OMP_STRUCTURED_BLOCK.
21066         (gimplify_expr): Likewise.
21067         * omp-expand.cc (GIMPLE_OMP_STRUCTURED_BLOCK): Error on
21068         GIMPLE_OMP_STRUCTURED_BLOCK.
21069         * omp-low.cc (scan_omp_1_stmt): Handle GIMPLE_OMP_STRUCTURED_BLOCK.
21070         (lower_omp_1): Likewise.
21071         (diagnose_sb_1): Likewise.
21072         (diagnose_sb_2): Likewise.
21073         * tree-inline.cc (remap_gimple_stmt): Handle
21074         GIMPLE_OMP_STRUCTURED_BLOCK.
21075         (estimate_num_insns): Likewise.
21076         * tree-nested.cc (convert_nonlocal_reference_stmt): Likewise.
21077         (convert_local_reference_stmt): Likewise.
21078         (convert_gimple_call): Likewise.
21079         * tree-pretty-print.cc (dump_generic_node): Handle
21080         OMP_STRUCTURED_BLOCK.
21081         * tree.def (OMP_STRUCTURED_BLOCK): New.
21082         * tree.h (OMP_STRUCTURED_BLOCK_BODY): New.
21084 2023-08-25  Vineet Gupta  <vineetg@rivosinc.com>
21086         * config/riscv/riscv.cc (riscv_rtx_costs): Adjust const_int
21087         cost. Add some comments about different constants handling.
21089 2023-08-25  Andrew Pinski  <apinski@marvell.com>
21091         * match.pd (`a ? one_zero : one_zero`): Move
21092         below detection of minmax.
21094 2023-08-25  Andrew Pinski  <apinski@marvell.com>
21096         * match.pd (`a | C -> C`): New pattern.
21098 2023-08-25  Uros Bizjak  <ubizjak@gmail.com>
21100         * caller-save.cc (new_saved_hard_reg):
21101         Rename TRUE/FALSE to true/false.
21102         (setup_save_areas): Ditto.
21103         * gcc.cc (set_collect_gcc_options): Ditto.
21104         (driver::build_multilib_strings): Ditto.
21105         (print_multilib_info): Ditto.
21106         * genautomata.cc (gen_cpu_unit): Ditto.
21107         (gen_query_cpu_unit): Ditto.
21108         (gen_bypass): Ditto.
21109         (gen_excl_set): Ditto.
21110         (gen_presence_absence_set): Ditto.
21111         (gen_presence_set): Ditto.
21112         (gen_final_presence_set): Ditto.
21113         (gen_absence_set): Ditto.
21114         (gen_final_absence_set): Ditto.
21115         (gen_automaton): Ditto.
21116         (gen_regexp_repeat): Ditto.
21117         (gen_regexp_allof): Ditto.
21118         (gen_regexp_oneof): Ditto.
21119         (gen_regexp_sequence): Ditto.
21120         (process_decls): Ditto.
21121         (reserv_sets_are_intersected): Ditto.
21122         (initiate_excl_sets): Ditto.
21123         (form_reserv_sets_list): Ditto.
21124         (check_presence_pattern_sets): Ditto.
21125         (check_absence_pattern_sets): Ditto.
21126         (check_regexp_units_distribution): Ditto.
21127         (check_unit_distributions_to_automata): Ditto.
21128         (create_ainsns): Ditto.
21129         (output_insn_code_cases): Ditto.
21130         (output_internal_dead_lock_func): Ditto.
21131         (form_important_insn_automata_lists): Ditto.
21132         * gengtype-state.cc (read_state_files_list): Ditto.
21133         * gengtype.cc (main): Ditto.
21134         * gimple-array-bounds.cc (array_bounds_checker::check_array_bounds):
21135         Ditto.
21136         * gimple.cc (gimple_build_call_from_tree): Ditto.
21137         (preprocess_case_label_vec_for_gimple): Ditto.
21138         * gimplify.cc (gimplify_call_expr): Ditto.
21139         * ordered-hash-map-tests.cc (test_map_of_int_to_strings): Ditto.
21141 2023-08-25  Richard Biener  <rguenther@suse.de>
21143         PR tree-optimization/111137
21144         * tree-vect-data-refs.cc (vect_slp_analyze_load_dependences):
21145         Properly handle grouped stores from other SLP instances.
21147 2023-08-25  Richard Biener  <rguenther@suse.de>
21149         * tree-vect-data-refs.cc (vect_slp_analyze_store_dependences):
21150         Split out from vect_slp_analyze_node_dependences, remove
21151         dead code.
21152         (vect_slp_analyze_load_dependences): Split out from
21153         vect_slp_analyze_node_dependences, adjust comments.  Process
21154         queued stores before any disambiguation.
21155         (vect_slp_analyze_node_dependences): Remove.
21156         (vect_slp_analyze_instance_dependence): Adjust.
21158 2023-08-25  Aldy Hernandez  <aldyh@redhat.com>
21160         * range-op-float.cc (frelop_early_resolve): Rewrite for better NAN
21161         handling.
21162         (operator_not_equal::fold_range): Adjust for relations.
21163         (operator_lt::fold_range): Same.
21164         (operator_gt::fold_range): Same.
21165         (foperator_unordered_equal::fold_range): Same.
21166         (foperator_unordered_lt::fold_range): Same.
21167         (foperator_unordered_le::fold_range): Same.
21168         (foperator_unordered_gt::fold_range): Same.
21169         (foperator_unordered_ge::fold_range): Same.
21171 2023-08-25  Richard Biener  <rguenther@suse.de>
21173         PR tree-optimization/111136
21174         * tree-vect-loop.cc (vect_dissolve_slp_only_groups): For
21175         stores force STMT_VINFO_STRIDED_P and also duplicate that
21176         to all elements.
21178 2023-08-25  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21180         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::compute_local_properties):
21181         Add early continue.
21183 2023-08-25  liuhongt  <hongtao.liu@intel.com>
21185         * config/i386/sse.md (vec_set<mode>): Removed.
21186         (V_128H): Merge into ..
21187         (V_128): .. this.
21188         (V_256H): Merge into ..
21189         (V_256): .. this.
21190         (V_512): Add V32HF, V32BF.
21191         (*ssse3_palignr<mode>_perm): Adjust mode iterator from V_128H
21192         to V_128.
21193         (vcond<mode><sseintvecmodelower>): Removed
21194         (vcondu<mode><sseintvecmodelower>): Removed.
21195         (avx_vbroadcastf128_<mode>): Refator from V_256H to V_256.
21197 2023-08-25  Hongyu Wang  <hongyu.wang@intel.com>
21199         PR target/111127
21200         * config/i386/sse.md (avx512f_cvtne2ps2bf16_<mode>_maskz):
21201         Adjust paramter order.
21203 2023-08-24  Uros Bizjak  <ubizjak@gmail.com>
21205         PR target/94866
21206         * config/i386/sse.md (*sse2_movq128_<mode>_1): New insn pattern.
21208 2023-08-24  David Malcolm  <dmalcolm@redhat.com>
21210         PR analyzer/105899
21211         * doc/invoke.texi (Static Analyzer Options): Add "strcat" to the
21212         list of functions known to the analyzer.
21214 2023-08-24  Richard Biener  <rguenther@suse.de>
21216         PR tree-optimization/111123
21217         * tree-ssa-ccp.cc (pass_fold_builtins::execute): Do not
21218         remove indirect clobbers here ...
21219         * tree-outof-ssa.cc (rewrite_out_of_ssa): ... but here.
21220         (remove_indirect_clobbers): New function.
21222 2023-08-24  Jan Hubicka  <jh@suse.cz>
21224         * cfg.h (struct control_flow_graph): New field full_profile.
21225         * auto-profile.cc (afdo_annotate_cfg): Set full_profile to true.
21226         * cfg.cc (init_flow): Set full_profile to false.
21227         * graphite.cc (graphite_transform_loops): Set full_profile to false.
21228         * lto-streamer-in.cc (input_cfg): Initialize full_profile flag.
21229         * predict.cc (pass_profile::execute): Set full_profile to true.
21230         * symtab-thunks.cc (expand_thunk): Set full_profile to true.
21231         * tree-cfg.cc (gimple_verify_flow_info): Verify that profile is full
21232         if full_profile is set.
21233         * tree-inline.cc (initialize_cfun): Initialize full_profile.
21234         (expand_call_inline): Combine full_profile.
21236 2023-08-24  Richard Biener  <rguenther@suse.de>
21238         * tree-vect-slp.cc (vect_build_slp_tree_1): Rename
21239         load_p to ldst_p, fix mistakes and rely on
21240         STMT_VINFO_DATA_REF.
21242 2023-08-24  Jan Hubicka  <jh@suse.cz>
21244         * gimple-harden-conditionals.cc (insert_check_and_trap): Set count
21245         of newly build trap bb.
21247 2023-08-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21249         * config/riscv/riscv.cc (riscv_preferred_else_value): Remove it since
21250         it forbid COND_LEN_FMS/COND_LEN_FNMS STMT fold.
21251         (TARGET_PREFERRED_ELSE_VALUE): Ditto.
21253 2023-08-24  Robin Dapp  <rdapp.gcc@gmail.com>
21255         * common/config/riscv/riscv-common.cc: Add -fsched-pressure.
21256         * config/riscv/riscv.cc (riscv_option_override): Set sched
21257         pressure algorithm.
21259 2023-08-24  Robin Dapp  <rdapp@ventanamicro.com>
21261         * config/riscv/riscv.cc (riscv_print_operand): Allow vk operand.
21263 2023-08-24  Richard Biener  <rguenther@suse.de>
21265         PR tree-optimization/111125
21266         * tree-vect-slp.cc (vect_slp_function): Split at novector
21267         loop entry, do not push blocks in novector loops.
21269 2023-08-24  Richard Sandiford  <richard.sandiford@arm.com>
21271         * doc/extend.texi: Document the C [[__extension__ ...]] construct.
21273 2023-08-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21275         * genmatch.cc (decision_tree::gen): Support
21276         COND_LEN_FNMA/COND_LEN_FMS/COND_LEN_FNMS gimple fold.
21277         * gimple-match-exports.cc (gimple_simplify): Ditto.
21278         (gimple_resimplify6): New function.
21279         (gimple_resimplify7): New function.
21280         (gimple_match_op::resimplify): Support
21281         COND_LEN_FNMA/COND_LEN_FMS/COND_LEN_FNMS gimple fold.
21282         (convert_conditional_op): Ditto.
21283         (build_call_internal): Ditto.
21284         (try_conditional_simplification): Ditto.
21285         (gimple_extract): Ditto.
21286         * gimple-match.h (gimple_match_cond::gimple_match_cond): Ditto.
21287         * internal-fn.cc (CASE): Ditto.
21289 2023-08-24  Richard Biener  <rguenther@suse.de>
21291         PR tree-optimization/111115
21292         * tree-vectorizer.h (vect_slp_child_index_for_operand): New.
21293         * tree-vect-data-refs.cc (can_group_stmts_p): Also group
21294         .MASK_STORE.
21295         * tree-vect-slp.cc (arg3_arg2_map): New.
21296         (vect_get_operand_map): Handle IFN_MASK_STORE.
21297         (vect_slp_child_index_for_operand): New function.
21298         (vect_build_slp_tree_1): Handle statements with no LHS,
21299         masked store ifns.
21300         (vect_remove_slp_scalar_calls): Likewise.
21301         * tree-vect-stmts.cc (vect_check_store_rhs): Lookup the
21302         SLP child corresponding to the ifn value index.
21303         (vectorizable_store): Likewise for the mask index.  Support
21304         masked stores.
21305         (vectorizable_load): Lookup the SLP child corresponding to the
21306         ifn mask index.
21308 2023-08-24  Richard Biener  <rguenther@suse.de>
21310         PR tree-optimization/111125
21311         * tree-vect-slp.cc (vectorizable_bb_reduc_epilogue): Account
21312         for the remain_defs processing.
21314 2023-08-24  Richard Sandiford  <richard.sandiford@arm.com>
21316         * config/aarch64/aarch64.cc: Include ssa.h.
21317         (aarch64_multiply_add_p): Require the second operand of an
21318         Advanced SIMD subtraction to be a multiplication.  Assume that
21319         such an operation won't be fused if the second operand is used
21320         multiple times and if the first operand is also a multiplication.
21322 2023-08-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21324         * tree-vect-loop.cc (vectorizable_reduction): Apply
21325         LEN_FOLD_EXTRACT_LAST.
21326         * tree-vect-stmts.cc (vectorizable_condition): Ditto.
21328 2023-08-24  Richard Biener  <rguenther@suse.de>
21330         PR tree-optimization/111128
21331         * tree-vect-patterns.cc (vect_recog_over_widening_pattern):
21332         Emit external shift operand inline if we promoted it with
21333         another pattern stmt.
21335 2023-08-24  Pan Li  <pan2.li@intel.com>
21337         * config/riscv/autovec.md: Fix typo.
21339 2023-08-24  Pan Li  <pan2.li@intel.com>
21341         * config/riscv/riscv-vector-builtins-bases.cc
21342         (class binop_frm): Removed.
21343         (class reverse_binop_frm): Ditto.
21344         (class widen_binop_frm): Ditto.
21345         (class vfmacc_frm): Ditto.
21346         (class vfnmacc_frm): Ditto.
21347         (class vfmsac_frm): Ditto.
21348         (class vfnmsac_frm): Ditto.
21349         (class vfmadd_frm): Ditto.
21350         (class vfnmadd_frm): Ditto.
21351         (class vfmsub_frm): Ditto.
21352         (class vfnmsub_frm): Ditto.
21353         (class vfwmacc_frm): Ditto.
21354         (class vfwnmacc_frm): Ditto.
21355         (class vfwmsac_frm): Ditto.
21356         (class vfwnmsac_frm): Ditto.
21357         (class unop_frm): Ditto.
21358         (class vfrec7_frm): Ditto.
21359         (class binop): Add frm_op_type template arg.
21360         (class unop): Ditto.
21361         (class widen_binop): Ditto.
21362         (class widen_binop_fp): Ditto.
21363         (class reverse_binop): Ditto.
21364         (class vfmacc): Ditto.
21365         (class vfnmsac): Ditto.
21366         (class vfmadd): Ditto.
21367         (class vfnmsub): Ditto.
21368         (class vfnmacc): Ditto.
21369         (class vfmsac): Ditto.
21370         (class vfnmadd): Ditto.
21371         (class vfmsub): Ditto.
21372         (class vfwmacc): Ditto.
21373         (class vfwnmacc): Ditto.
21374         (class vfwmsac): Ditto.
21375         (class vfwnmsac): Ditto.
21376         (class float_misc): Ditto.
21378 2023-08-24  Andrew Pinski  <apinski@marvell.com>
21380         PR tree-optimization/111109
21381         * match.pd (ior(cond,cond), ior(vec_cond,vec_cond)):
21382         Add check to make sure cmp and icmp are inverse.
21384 2023-08-24  Andrew Pinski  <apinski@marvell.com>
21386         PR tree-optimization/95929
21387         * match.pd (convert?(-a)): New pattern
21388         for 1bit integer types.
21390 2023-08-24  Haochen Jiang  <haochen.jiang@intel.com>
21392         Revert:
21393         2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
21395         * common/config/i386/cpuinfo.h (get_available_features):
21396         Add avx10_set and version and detect avx10.1.
21397         (cpu_indicator_init): Handle avx10.1-512.
21398         * common/config/i386/i386-common.cc
21399         (OPTION_MASK_ISA2_AVX10_512BIT_SET): New.
21400         (OPTION_MASK_ISA2_AVX10_1_SET): Ditto.
21401         (OPTION_MASK_ISA2_AVX10_512BIT_UNSET): Ditto.
21402         (OPTION_MASK_ISA2_AVX10_1_UNSET): Ditto.
21403         (OPTION_MASK_ISA2_AVX2_UNSET): Modify for AVX10_1.
21404         (ix86_handle_option): Handle -mavx10.1, -mavx10.1-256 and
21405         -mavx10.1-512.
21406         * common/config/i386/i386-cpuinfo.h (enum processor_features):
21407         Add FEATURE_AVX10_512BIT, FEATURE_AVX10_1 and
21408         FEATURE_AVX10_512BIT.
21409         * common/config/i386/i386-isas.h: Add ISA_NAME_TABLE_ENTRY for
21410         AVX10_512BIT, AVX10_1 and AVX10_1_512.
21411         * config/i386/constraints.md (Yk): Add AVX10_1.
21412         (Yv): Ditto.
21413         (k): Ditto.
21414         * config/i386/cpuid.h (bit_AVX10): New.
21415         (bit_AVX10_256): Ditto.
21416         (bit_AVX10_512): Ditto.
21417         * config/i386/i386-c.cc (ix86_target_macros_internal):
21418         Define AVX10_512BIT and AVX10_1.
21419         * config/i386/i386-isa.def
21420         (AVX10_512BIT): Add DEF_PTA(AVX10_512BIT).
21421         (AVX10_1): Add DEF_PTA(AVX10_1).
21422         * config/i386/i386-options.cc (isa2_opts): Add -mavx10.1.
21423         (ix86_valid_target_attribute_inner_p): Handle avx10-512bit, avx10.1
21424         and avx10.1-512.
21425         (ix86_option_override_internal): Enable AVX512{F,VL,BW,DQ,CD,BF16,
21426         FP16,VBMI,VBMI2,VNNI,IFMA,BITALG,VPOPCNTDQ} features for avx10.1-512.
21427         (ix86_valid_target_attribute_inner_p): Handle AVX10_1.
21428         * config/i386/i386.cc (ix86_get_ssemov): Add AVX10_1.
21429         (ix86_conditional_register_usage): Ditto.
21430         (ix86_hard_regno_mode_ok): Ditto.
21431         (ix86_rtx_costs): Ditto.
21432         * config/i386/i386.h (VALID_MASK_AVX10_MODE): New macro.
21433         * config/i386/i386.opt: Add option -mavx10.1, -mavx10.1-256 and
21434         -mavx10.1-512.
21435         * doc/extend.texi: Document avx10.1, avx10.1-256 and avx10.1-512.
21436         * doc/invoke.texi: Document -mavx10.1, -mavx10.1-256 and -mavx10.1-512.
21437         * doc/sourcebuild.texi: Document target avx10.1, avx10.1-256
21438         and avx10.1-512.
21440 2023-08-24  Haochen Jiang  <haochen.jiang@intel.com>
21442         Revert:
21443         2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
21445         * common/config/i386/i386-common.cc
21446         (ix86_check_avx10): New function to check isa_flags and
21447         isa_flags_explicit to emit warning when AVX10 is enabled
21448         by "-m" option.
21449         (ix86_check_avx512):  New function to check isa_flags and
21450         isa_flags_explicit to emit warning when AVX512 is enabled
21451         by "-m" option.
21452         (ix86_handle_option): Do not change the flags when warning
21453         is emitted.
21454         * config/i386/driver-i386.cc (host_detect_local_cpu):
21455         Do not append -mno-avx10.1 for -march=native.
21457 2023-08-24  Haochen Jiang  <haochen.jiang@intel.com>
21459         Revert:
21460         2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
21462         * common/config/i386/i386-common.cc
21463         (ix86_check_avx10_vector_width): New function to check isa_flags
21464         to emit a warning when there is a conflict in AVX10 options for
21465         vector width.
21466         (ix86_handle_option): Add check for avx10.1-256 and avx10.1-512.
21467         * config/i386/driver-i386.cc (host_detect_local_cpu):
21468         Do not append -mno-avx10-max-512bit for -march=native.
21470 2023-08-24  Haochen Jiang  <haochen.jiang@intel.com>
21472         Revert:
21473         2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
21475         * config/i386/avx512vldqintrin.h: Remove target attribute.
21476         * config/i386/i386-builtin.def (BDESC):
21477         Add OPTION_MASK_ISA2_AVX10_1.
21478         * config/i386/i386-builtins.cc (def_builtin): Handle AVX10_1.
21479         * config/i386/i386-expand.cc
21480         (ix86_check_builtin_isa_match): Ditto.
21481         (ix86_expand_sse2_mulvxdi3): Add TARGET_AVX10_1.
21482         * config/i386/i386.md: Add new isa attribute avx10_1_or_avx512dq
21483         and avx10_1_or_avx512vl.
21484         * config/i386/sse.md: (VF2_AVX512VLDQ_AVX10_1): New.
21485         (VF1_128_256VLDQ_AVX10_1): Ditto.
21486         (VI8_AVX512VLDQ_AVX10_1): Ditto.
21487         (<sse>_andnot<mode>3<mask_name>):
21488         Add TARGET_AVX10_1 and change isa attr from avx512dq to
21489         avx10_1_or_avx512dq.
21490         (*andnot<mode>3): Add TARGET_AVX10_1 and change isa attr from
21491         avx512vl to avx10_1_or_avx512vl.
21492         (fix<fixunssuffix>_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
21493         Change iterator to VF2_AVX512VLDQ_AVX10_1. Remove target check.
21494         (fix_notrunc<mode><sseintvecmodelower>2<mask_name><round_name>):
21495         Ditto.
21496         (ufix_notrunc<mode><sseintvecmodelower>2<mask_name><round_name>):
21497         Ditto.
21498         (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
21499         Change iterator to VF1_128_256VLDQ_AVX10_1. Remove target check.
21500         (avx512dq_fix<fixunssuffix>_truncv2sfv2di2<mask_name>):
21501         Add TARGET_AVX10_1.
21502         (fix<fixunssuffix>_truncv2sfv2di2): Ditto.
21503         (cond_mul<mode>): Change iterator to VI8_AVX10_1_AVX512DQVL.
21504         Remove target check.
21505         (avx512dq_mul<mode>3<mask_name>): Ditto.
21506         (*avx512dq_mul<mode>3<mask_name>): Ditto.
21507         (VI4F_BRCST32x2): Add TARGET_AVX512DQ and TARGET_AVX10_1.
21508         (<mask_codefor>avx512dq_broadcast<mode><mask_name>):
21509         Remove target check.
21510         (VI8F_BRCST64x2): Add TARGET_AVX512DQ and TARGET_AVX10_1.
21511         (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1):
21512         Remove target check.
21513         * config/i386/subst.md (mask_mode512bit_condition): Add TARGET_AVX10_1.
21514         (mask_avx512vl_condition): Ditto.
21515         (mask): Ditto.
21517 2023-08-24  Haochen Jiang  <haochen.jiang@intel.com>
21519         Revert:
21520         2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
21522         * config/i386/avx512vldqintrin.h: Remove target attribute.
21523         * config/i386/i386-builtin.def (BDESC):
21524         Add OPTION_MASK_ISA2_AVX10_1.
21525         * config/i386/i386.cc (standard_sse_constant_opcode): Add TARGET_AVX10_1.
21526         * config/i386/sse.md: (VI48_AVX512VL_AVX10_1): New.
21527         (VI48_AVX512VLDQ_AVX10_1): Ditto.
21528         (VF2_AVX512VL): Remove.
21529         (VI8_256_512VLDQ_AVX10_1): Rename from VI8_256_512.
21530         Add TARGET_AVX10_1.
21531         (*<code><mode>3<mask_name>): Change isa attribute to
21532         avx10_1_or_avx512dq. Add TARGET_AVX10_1.
21533         (<code><mode>3): Add TARGET_AVX10_1. Change isa attr
21534         to avx10_1_or_avx512vl.
21535         (<mask_codefor>avx512dq_cvtps2qq<mode><mask_name><round_name>):
21536         Change iterator to VI8_256_512VLDQ_AVX10_1. Remove target check.
21537         (<mask_codefor>avx512dq_cvtps2qqv2di<mask_name>):
21538         Add TARGET_AVX10_1.
21539         (<mask_codefor>avx512dq_cvtps2uqq<mode><mask_name><round_name>):
21540         Change iterator to VI8_256_512VLDQ_AVX10_1. Remove target check.
21541         (<mask_codefor>avx512dq_cvtps2uqqv2di<mask_name>):
21542         Add TARGET_AVX10_1.
21543         (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
21544         Change iterator to VF2_AVX512VLDQ_AVX10_1. Remove target check.
21545         (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
21546         Change iterator to VF1_128_256VLDQ_AVX10_1. Remove target check.
21547         (float<floatunssuffix>v4div4sf2<mask_name>):
21548         Add TARGET_AVX10_1.
21549         (avx512dq_float<floatunssuffix>v2div2sf2): Ditto.
21550         (*avx512dq_float<floatunssuffix>v2div2sf2): Ditto.
21551         (float<floatunssuffix>v2div2sf2): Ditto.
21552         (float<floatunssuffix>v2div2sf2_mask): Ditto.
21553         (*float<floatunssuffix>v2div2sf2_mask): Ditto.
21554         (*float<floatunssuffix>v2div2sf2_mask_1): Ditto.
21555         (<avx512>_cvt<ssemodesuffix>2mask<mode>):
21556         Change iterator to VI48_AVX512VLDQ_AVX10_1. Remove target check.
21557         (<avx512>_cvtmask2<ssemodesuffix><mode>): Ditto.
21558         (*<avx512>_cvtmask2<ssemodesuffix><mode>):
21559         Change iterator to VI48_AVX512VL_AVX10_1. Remove target check.
21560         Change when constraint is enabled.
21562 2023-08-24  Haochen Jiang  <haochen.jiang@intel.com>
21564         Revert:
21565         2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
21567         * config/i386/avx512vldqintrin.h: Remove target attribute.
21568         * config/i386/i386-builtin.def (BDESC):
21569         Add OPTION_MASK_ISA2_AVX10_1.
21570         * config/i386/sse.md (VF_AVX512VLDQ_AVX10_1): New.
21571         (VFH_AVX512VLDQ_AVX10_1): Ditto.
21572         (VF1_AVX512VLDQ_AVX10_1): Ditto.
21573         (<mask_codefor>reducep<mode><mask_name><round_saeonly_name>):
21574         Change iterator to VFH_AVX512VLDQ_AVX10_1. Remove target check.
21575         (vec_pack<floatprefix>_float_<mode>): Change iterator to
21576         VI8_AVX512VLDQ_AVX10_1. Remove target check.
21577         (vec_unpack_<fixprefix>fix_trunc_lo_<mode>): Change iterator to
21578         VF1_AVX512VLDQ_AVX10_1. Remove target check.
21579         (vec_unpack_<fixprefix>fix_trunc_hi_<mode>): Ditto.
21580         (VI48F_256_DQVL_AVX10_1): Rename from VI48F_256_DQ.
21581         (avx512vl_vextractf128<mode>): Change iterator to
21582         VI48F_256_DQVL_AVX10_1. Remove target check.
21583         (vec_extract_hi_<mode>_mask): Add TARGET_AVX10_1.
21584         (vec_extract_hi_<mode>): Ditto.
21585         (avx512vl_vinsert<mode>): Ditto.
21586         (vec_set_lo_<mode><mask_name>): Ditto.
21587         (vec_set_hi_<mode><mask_name>): Ditto.
21588         (avx512dq_rangep<mode><mask_name><round_saeonly_name>): Change
21589         iterator to VF_AVX512VLDQ_AVX10_1. Remove target check.
21590         (avx512dq_fpclass<mode><mask_scalar_merge_name>): Change
21591         iterator to VFH_AVX512VLDQ_AVX10_1. Remove target check.
21592         * config/i386/subst.md (mask_avx512dq_condition): Add
21593         TARGET_AVX10_1.
21594         (mask_scalar_merge): Ditto.
21596 2023-08-24  Haochen Jiang  <haochen.jiang@intel.com>
21598         Revert:
21599         2023-08-18  Haochen Jiang  <haochen.jiang@intel.com>
21601         PR target/111051
21602         * config/i386/avx512vldqintrin.h: Push AVX2 when AVX2 is
21603         disabled.
21605 2023-08-24  Richard Biener  <rguenther@suse.de>
21607         PR debug/111080
21608         * dwarf2out.cc (prune_unused_types_walk): Handle
21609         DW_TAG_restrict_type, DW_TAG_shared_type, DW_TAG_atomic_type,
21610         DW_TAG_immutable_type, DW_TAG_coarray_type, DW_TAG_unspecified_type
21611         and DW_TAG_dynamic_type as to only output them when referenced.
21613 2023-08-24  liuhongt  <hongtao.liu@intel.com>
21615         * config/i386/i386.cc (ix86_invalid_conversion): Adjust GCC
21616         V13 to GCC 13.1.
21618 2023-08-24  liuhongt  <hongtao.liu@intel.com>
21620         * common/config/i386/i386-common.cc (processor_names): Add new
21621         member graniterapids-s and arrowlake-s.
21622         * config/i386/i386-options.cc (processor_alias_table): Update
21623         table with PROCESSOR_ARROWLAKE_S and
21624         PROCESSOR_GRANITERAPIDS_D.
21625         (m_GRANITERAPID_D): New macro.
21626         (m_ARROWLAKE_S): Ditto.
21627         (m_CORE_AVX512): Add m_GRANITERAPIDS_D.
21628         (processor_cost_table): Add icelake_cost for
21629         PROCESSOR_GRANITERAPIDS_D and alderlake_cost for
21630         PROCESSOR_ARROWLAKE_S.
21631         * config/i386/x86-tune.def: Hanlde m_ARROWLAKE_S same as
21632         m_ARROWLAKE.
21633         * config/i386/i386.h (enum processor_type): Add new member
21634         PROCESSOR_GRANITERAPIDS_D and PROCESSOR_ARROWLAKE_S.
21635         * config/i386/i386-c.cc (ix86_target_macros_internal): Handle
21636         PROCESSOR_GRANITERAPIDS_D and PROCESSOR_ARROWLAKE_S
21638 2023-08-23  Jivan Hakobyan  <jivanhakobyan9@gmail.com>
21640         * lra-eliminations.cc (eliminate_regs_in_insn): Use equivalences to
21641         to help simplify code further.
21643 2023-08-23  Andrew MacLeod  <amacleod@redhat.com>
21645         * gimple-range-fold.cc (fold_using_range::range_of_phi): Tweak output.
21646         * gimple-range-phi.cc (phi_group::phi_group): Remove unused members.
21647         Initialize using a range instead of value and edge.
21648         (phi_group::calculate_using_modifier): Use initializer value and
21649         process for relations after trying for iteration convergence.
21650         (phi_group::refine_using_relation): Use initializer range.
21651         (phi_group::dump): Rework the dump output.
21652         (phi_analyzer::process_phi): Allow multiple constant initilizers.
21653         Dump groups immediately as created.
21654         (phi_analyzer::dump): Tweak output.
21655         * gimple-range-phi.h (phi_group::phi_group): Adjust prototype.
21656         (phi_group::initial_value): Delete.
21657         (phi_group::refine_using_relation): Adjust prototype.
21658         (phi_group::m_initial_value): Delete.
21659         (phi_group::m_initial_edge): Delete.
21660         (phi_group::m_vr): Use int_range_max.
21661         * tree-vrp.cc (execute_ranger_vrp): Don't dump phi groups.
21663 2023-08-23  Andrew MacLeod  <amacleod@redhat.com>
21665         * gimple-range-phi.cc (phi_analyzer::operator[]): Return NULL if
21666         no group was created.
21667         (phi_analyzer::process_phi): Do not create groups of one phi node.
21669 2023-08-23  Richard Earnshaw  <rearnsha@arm.com>
21671         * target.def (gen_ccmp_first, gen_ccmp_next): Use rtx_code for
21672         CODE, CMP_CODE and BIT_CODE arguments.
21673         * config/aarch64/aarch64.cc (aarch64_gen_ccmp_first): Likewise.
21674         (aarch64_gen_ccmp_next): Likewise.
21675         * doc/tm.texi: Regenerated.
21677 2023-08-23  Richard Earnshaw  <rearnsha@arm.com>
21679         * coretypes.h (rtx_code): Add forward declaration.
21680         * rtl.h (rtx_code): Make compatible with forward declaration.
21682 2023-08-23  Uros Bizjak  <ubizjak@gmail.com>
21684         PR target/111010
21685         * config/i386/i386.md (*concat<any_or_plus:mode><dwi>3_3):
21686         Merge pattern from *concatditi3_3 and *concatsidi3_3 using
21687         DWIH mode iterator.  Disable (=&r,m,m) alternative for
21688         32-bit targets.
21689         (*concat<any_or_plus:mode><dwi>3_3): Disable (=&r,m,m)
21690         alternative for 32-bit targets.
21692 2023-08-23  Zhangjin Liao  <liaozhangjin@eswincomputing.com>
21694         * config/riscv/bitmanip.md (*<bitmanip_optab>disi2_sext): Add a more
21695         appropriate type attribute.
21697 2023-08-23  Lehua Ding  <lehua.ding@rivai.ai>
21699         * config/riscv/autovec-opt.md (*cond_abs<mode>): New combine pattern.
21700         (*copysign<mode>_neg): Ditto.
21701         * config/riscv/autovec.md (@vcond_mask_<mode><vm>): Adjust.
21702         (<optab><mode>2): Ditto.
21703         (cond_<optab><mode>): New.
21704         (cond_len_<optab><mode>): Ditto.
21705         * config/riscv/riscv-protos.h (enum insn_type): New.
21706         (expand_cond_len_unop): New helper func.
21707         * config/riscv/riscv-v.cc (shuffle_merge_patterns): Adjust.
21708         (expand_cond_len_unop): New helper func.
21710 2023-08-23  Jan Hubicka  <jh@suse.cz>
21712         * tree-ssa-loop-ch.cc (enum ch_decision): Fix comment.
21713         (should_duplicate_loop_header_p): Fix return value for static exits.
21714         (ch_base::copy_headers): Improve handling of ch_possible_zero_cost.
21716 2023-08-23  Kewen Lin  <linkw@linux.ibm.com>
21718         * tree-vect-stmts.cc (vectorizable_store): Move the handlings on
21719         VMAT_GATHER_SCATTER in the final loop nest to its own loop,
21720         and update the final nest accordingly.
21722 2023-08-23  Kewen Lin  <linkw@linux.ibm.com>
21724         * tree-vect-stmts.cc (vectorizable_store): Move the handlings on
21725         VMAT_LOAD_STORE_LANES in the final loop nest to its own loop,
21726         and update the final nest accordingly.
21728 2023-08-23  Kewen Lin  <linkw@linux.ibm.com>
21730         * tree-vect-stmts.cc (vectorizable_store): Remove vec oprnds,
21731         adjust vec result_chain, vec_oprnd with auto_vec, and adjust
21732         gvec_oprnds with auto_delete_vec.
21734 2023-08-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21736         * config/riscv/riscv-vsetvl.cc
21737         (pass_vsetvl::global_eliminate_vsetvl_insn): Fix potential ICE.
21739 2023-08-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21741         * config/riscv/riscv-vsetvl.cc (ge_sew_ratio_unavailable_p):
21742         Fix fuse rule bug.
21743         * config/riscv/riscv-vsetvl.def (DEF_SEW_LMUL_FUSE_RULE): Ditto.
21745 2023-08-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21747         * config/riscv/vector.md: Add attribute.
21749 2023-08-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21751         * config/riscv/riscv-vsetvl.cc (change_insn): Clang format.
21752         (vector_infos_manager::all_same_ratio_p): Ditto.
21753         (vector_infos_manager::all_same_avl_p): Ditto.
21754         (pass_vsetvl::refine_vsetvls): Ditto.
21755         (pass_vsetvl::cleanup_vsetvls): Ditto.
21756         (pass_vsetvl::commit_vsetvls): Ditto.
21757         (pass_vsetvl::local_eliminate_vsetvl_insn): Ditto.
21758         (pass_vsetvl::global_eliminate_vsetvl_insn): Ditto.
21759         (pass_vsetvl::compute_probabilities): Ditto.
21761 2023-08-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21763         * config/riscv/t-riscv: Add riscv-vsetvl.def
21765 2023-08-22  Vineet Gupta  <vineetg@rivosinc.com>
21767         * config/riscv/riscv.opt: Add --param names
21768         riscv-autovec-preference and riscv-autovec-lmul
21770 2023-08-22  Raphael Moreira Zinsly  <rzinsly@ventanamicro.com>
21772         * config/riscv/t-linux: Add MULTIARCH_DIRNAME.
21774 2023-08-22  Tobias Burnus  <tobias@codesourcery.com>
21776         * tree-core.h (enum omp_clause_defaultmap_kind): Add
21777         OMP_CLAUSE_DEFAULTMAP_CATEGORY_ALL.
21778         * gimplify.cc (gimplify_scan_omp_clauses): Handle it.
21779         * tree-pretty-print.cc (dump_omp_clause): Likewise.
21781 2023-08-22  Jakub Jelinek  <jakub@redhat.com>
21783         PR c++/106652
21784         * doc/extend.texi (_Float<n>): Drop obsolete sentence that the
21785         types aren't supported in C++.
21787 2023-08-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21789         * doc/md.texi: Add LEN_FOLD_EXTRACT_LAST pattern.
21790         * internal-fn.cc (fold_len_extract_direct): Ditto.
21791         (expand_fold_len_extract_optab_fn): Ditto.
21792         (direct_fold_len_extract_optab_supported_p): Ditto.
21793         * internal-fn.def (LEN_FOLD_EXTRACT_LAST): Ditto.
21794         * optabs.def (OPTAB_D): Ditto.
21796 2023-08-22  Richard Biener  <rguenther@suse.de>
21798         * tree-vect-stmts.cc (vectorizable_store): Do not bump
21799         DR_GROUP_STORE_COUNT here.  Remove early out.
21800         (vect_transform_stmt): Only call vectorizable_store on
21801         the last element of an interleaving chain.
21803 2023-08-22  Richard Biener  <rguenther@suse.de>
21805         PR tree-optimization/94864
21806         PR tree-optimization/94865
21807         PR tree-optimization/93080
21808         * match.pd (bit_insert @0 (BIT_FIELD_REF @1 ..) ..): New pattern
21809         for vector insertion from vector extraction.
21811 2023-08-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21812             Kewen.Lin  <linkw@linux.ibm.com>
21814         * tree-vect-loop.cc (vect_verify_loop_lens): Add exists check.
21815         (vectorizable_live_operation): Add live vectorization for length loop
21816         control.
21818 2023-08-22  David Malcolm  <dmalcolm@redhat.com>
21820         PR analyzer/105899
21821         * doc/invoke.texi: Remove -Wanalyzer-unterminated-string.
21823 2023-08-22  Pan Li  <pan2.li@intel.com>
21825         * config/riscv/riscv-vector-builtins-bases.cc
21826         (vfwredusum_frm_obj): New declaration.
21827         (BASE): Ditto.
21828         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
21829         * config/riscv/riscv-vector-builtins-functions.def
21830         (vfwredusum_frm): New intrinsic function def.
21832 2023-08-21  David Faust  <david.faust@oracle.com>
21834         * config/bpf/bpf.md (neg): Second operand must be a register.
21836 2023-08-21  Edwin Lu  <ewlu@rivosinc.com>
21838         * config/riscv/bitmanip.md: Added bitmanip type to insns
21839         that are missing types.
21841 2023-08-21  Jeff Law  <jlaw@ventanamicro.com>
21843         * config/riscv/sync-ztso.md (atomic_load_ztso<mode>): Avoid extraenous
21844         newline.
21846 2023-08-21  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
21848         * config/aarch64/falkor-tag-collision-avoidance.cc (dump_insn_list):
21849         Fix format specifier.
21851 2023-08-21  Aldy Hernandez  <aldyh@redhat.com>
21853         * value-range.cc (frange::union_nans): Return false if nothing
21854         changed.
21855         (range_tests_floats): New test.
21857 2023-08-21  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
21859         PR tree-optimization/111048
21860         * fold-const.cc (valid_mask_for_fold_vec_perm_cst_p): Set arg_npatterns
21861         correctly.
21862         (fold_vec_perm_cst): Remove workaround and again call
21863         valid_mask_fold_vec_perm_cst_p for both VLS and VLA vectors.
21864         (test_fold_vec_perm_cst::test_nunits_min_4): Add test-case.
21866 2023-08-21  Richard Biener  <rguenther@suse.de>
21868         PR tree-optimization/111082
21869         * tree-vect-slp.cc (vectorize_slp_instance_root_stmt): Only
21870         pun operations that can overflow.
21872 2023-08-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
21874         * lcm.cc (compute_antinout_edge): Export as global use.
21875         (compute_earliest): Ditto.
21876         (compute_rev_insert_delete): Ditto.
21877         * lcm.h (compute_antinout_edge): Ditto.
21878         (compute_earliest): Ditto.
21880 2023-08-21  Richard Biener  <rguenther@suse.de>
21882         PR tree-optimization/111070
21883         * tree-ssa-ifcombine.cc (ifcombine_ifandif): Check we have
21884         an SSA name before checking SSA_NAME_OCCURS_IN_ABNORMAL_PHI.
21886 2023-08-21  Andrew Pinski  <apinski@marvell.com>
21888         PR tree-optimization/111002
21889         * match.pd (view_convert(vec_cond(a,b,c))): New pattern.
21891 2023-08-21  liuhongt  <hongtao.liu@intel.com>
21893         * common/config/i386/cpuinfo.h (get_intel_cpu): Detect
21894         Alderlake-N.
21895         * common/config/i386/i386-common.cc (alias_table): Support
21896         -march=gracemont as an alias of -march=alderlake.
21898 2023-08-20  Uros Bizjak  <ubizjak@gmail.com>
21900         * config/i386/i386-expand.cc (ix86_expand_sse_extend): Use ops[1]
21901         instead of src in the call to ix86_expand_sse_cmp.
21902         * config/i386/sse.md (<any_extend:insn>v8qiv8hi2): Do not
21903         force operands[1] to a register.
21904         (<any_extend:insn>v4hiv4si2): Ditto.
21905         (<any_extend:insn>v2siv2di2): Ditto.
21907 2023-08-20  Andrew Pinski  <apinski@marvell.com>
21909         PR tree-optimization/111006
21910         PR tree-optimization/110986
21911         * match.pd: (op(vec_cond(a,b,c))): Handle convert for op.
21913 2023-08-20  Eric Gallager  <egallager@gcc.gnu.org>
21915         PR target/90835
21916         * Makefile.in: improve error message when /usr/include is
21917         missing
21919 2023-08-19  Tobias Burnus  <tobias@codesourcery.com>
21921         PR middle-end/111017
21922         * omp-expand.cc (expand_omp_for_init_vars): Pass after=true
21923         to expand_omp_build_cond for 'factor != 0' condition, resulting
21924         in pre-r12-5295-g47de0b56ee455e code for the gimple insert.
21926 2023-08-19  Guo Jie  <guojie@loongson.cn>
21927             Lulu Cheng  <chenglulu@loongson.cn>
21929         * config/loongarch/t-loongarch: Add loongarch-driver.h into
21930         TM_H. Add loongarch-def.h and loongarch-tune.h into
21931         OPTIONS_H_EXTRA.
21933 2023-08-18  Uros Bizjak  <ubizjak@gmail.com>
21935         PR target/111023
21936         * config/i386/i386-expand.cc (ix86_split_mmx_punpck):
21937         Also handle V2QImode.
21938         (ix86_expand_sse_extend): New function.
21939         * config/i386/i386-protos.h (ix86_expand_sse_extend): New prototype.
21940         * config/i386/mmx.md (<any_extend:insn>v4qiv4hi2): Enable for
21941         TARGET_SSE2.  Expand through ix86_expand_sse_extend for !TARGET_SSE4_1.
21942         (<any_extend:insn>v2hiv2si2): Ditto.
21943         (<any_extend:insn>v2qiv2hi2): Ditto.
21944         * config/i386/sse.md (<any_extend:insn>v8qiv8hi2): Ditto.
21945         (<any_extend:insn>v4hiv4si2): Ditto.
21946         (<any_extend:insn>v2siv2di2): Ditto.
21948 2023-08-18  Aldy Hernandez  <aldyh@redhat.com>
21950         PR ipa/110753
21951         * value-range.cc (irange::union_bitmask): Return FALSE if updated
21952         bitmask is semantically equivalent to the original mask.
21953         (irange::intersect_bitmask): Same.
21954         (irange::get_bitmask): Add comment.
21956 2023-08-18  Richard Biener  <rguenther@suse.de>
21958         PR tree-optimization/111019
21959         * tree-ssa-loop-im.cc (gather_mem_refs_stmt): When canonicalizing
21960         also scrap base and offset in case the ref is indirect.
21962 2023-08-18  Jose E. Marchesi  <jose.marchesi@oracle.com>
21964         * config/bpf/bpf.opt (mframe-limit): Set default to 32767.
21966 2023-08-18  Kewen Lin  <linkw@linux.ibm.com>
21968         PR bootstrap/111021
21969         * Makefile.in (TM_P_H): Add $(TREE_H) as dependence.
21971 2023-08-18  Kewen Lin  <linkw@linux.ibm.com>
21973         * tree-vect-stmts.cc (vect_build_scatter_store_calls): New, factor
21974         out from ...
21975         (vectorizable_store): ... here.
21977 2023-08-18  Richard Biener  <rguenther@suse.de>
21979         PR tree-optimization/111048
21980         * fold-const.cc (fold_vec_perm_cst): Check for non-VLA
21981         vectors first.
21983 2023-08-18  Haochen Jiang  <haochen.jiang@intel.com>
21985         PR target/111051
21986         * config/i386/avx512vldqintrin.h: Push AVX2 when AVX2 is
21987         disabled.
21989 2023-08-18  Kewen Lin  <linkw@linux.ibm.com>
21991         * tree-vect-stmts.cc (vectorizable_load): Move the handlings on
21992         VMAT_GATHER_SCATTER in the final loop nest to its own loop,
21993         and update the final nest accordingly.
21995 2023-08-18  Andrew Pinski  <apinski@marvell.com>
21997         * doc/md.texi (Standard patterns): Document cond_neg, cond_one_cmpl,
21998         cond_len_neg and cond_len_one_cmpl.
22000 2023-08-18  Lehua Ding  <lehua.ding@rivai.ai>
22002         * config/riscv/iterators.md (TARGET_HARD_FLOAT || TARGET_ZFINX): New.
22003         * config/riscv/pic.md (*local_pic_load<ANYF:mode>): Change ANYF.
22004         (*local_pic_load<ANYLSF:mode>): To ANYLSF.
22005         (*local_pic_load_32d<ANYF:mode>): Ditto.
22006         (*local_pic_load_32d<ANYLSF:mode>): Ditto.
22007         (*local_pic_store<ANYF:mode>): Ditto.
22008         (*local_pic_store<ANYLSF:mode>): Ditto.
22009         (*local_pic_store_32d<ANYF:mode>): Ditto.
22010         (*local_pic_store_32d<ANYLSF:mode>): Ditto.
22012 2023-08-18  Lehua Ding  <lehua.ding@rivai.ai>
22013             Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
22015         * config/riscv/predicates.md (vector_const_0_operand): New.
22016         * config/riscv/vector.md (*pred_broadcast<mode>_zero): Ditto.
22018 2023-08-18  Lehua Ding  <lehua.ding@rivai.ai>
22020         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::backward_demand_fusion):
22021         Forbidden.
22023 2023-08-17  Andrew MacLeod  <amacleod@redhat.com>
22025         PR tree-optimization/111009
22026         * range-op.cc (operator_addr_expr::op1_range): Be more restrictive.
22028 2023-08-17  Vladimir N. Makarov  <vmakarov@redhat.com>
22030         * lra-spills.cc (assign_stack_slot_num_and_sort_pseudos): Moving
22031         slots_num initialization from here ...
22032         (lra_spill): ... to here before the 1st call of
22033         assign_stack_slot_num_and_sort_pseudos.  Add the 2nd call after
22034         fp->sp elimination.
22036 2023-08-17  Jose E. Marchesi  <jose.marchesi@oracle.com>
22038         PR c/106537
22039         * doc/invoke.texi (Option Summary): Mention
22040         -Wcompare-distinct-pointer-types under `Warning Options'.
22041         (Warning Options): Document -Wcompare-distinct-pointer-types.
22043 2023-08-17  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
22045         * recog.cc (memory_address_addr_space_p): Mark possibly unused
22046         argument as unused.
22048 2023-08-17  Richard Biener  <rguenther@suse.de>
22050         PR tree-optimization/111039
22051         * tree-ssa-ifcombine.cc (ifcombine_ifandif): Check for
22052         SSA_NAME_OCCURS_IN_ABNORMAL_PHI.
22054 2023-08-17  Alex Coplan  <alex.coplan@arm.com>
22056         * doc/rtl.texi: Fix up sample code for RTL-SSA insn changes.
22058 2023-08-17  Jose E. Marchesi  <jose.marchesi@oracle.com>
22060         PR target/111046
22061         * config/bpf/bpf.cc (bpf_attribute_table): Add entry for the
22062         `naked' function attribute.
22063         (bpf_warn_func_return): New function.
22064         (TARGET_WARN_FUNC_RETURN): Define.
22065         (bpf_expand_prologue): Add preventive comment.
22066         (bpf_expand_epilogue): Likewise.
22067         * doc/extend.texi (BPF Function Attributes): Document the `naked'
22068         function attribute.
22070 2023-08-17  Richard Biener  <rguenther@suse.de>
22072         * tree-vect-slp.cc (vect_slp_check_for_roots): Use
22073         !needs_fold_left_reduction_p to decide whether we can
22074         handle the reduction with association.
22075         (vectorize_slp_instance_root_stmt): For TYPE_OVERFLOW_UNDEFINED
22076         reductions perform all arithmetic in an unsigned type.
22078 2023-08-17  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
22080         * configure.ac (gcc_cv_ld64_version): Allow for dyld in ld -v
22081         output.
22082         * configure: Regenerate.
22084 2023-08-17  Pan Li  <pan2.li@intel.com>
22086         * config/riscv/riscv-vector-builtins-bases.cc
22087         (widen_freducop): Add frm_opt_type template arg.
22088         (vfwredosum_frm_obj): New declaration.
22089         (BASE): Ditto.
22090         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22091         * config/riscv/riscv-vector-builtins-functions.def
22092         (vfwredosum_frm): New intrinsic function def.
22094 2023-08-17  Pan Li  <pan2.li@intel.com>
22096         * config/riscv/riscv-vector-builtins-bases.cc
22097         (vfredosum_frm_obj): New declaration.
22098         (BASE): Ditto.
22099         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22100         * config/riscv/riscv-vector-builtins-functions.def
22101         (vfredosum_frm): New intrinsic function def.
22103 2023-08-17  Pan Li  <pan2.li@intel.com>
22105         * config/riscv/riscv-vector-builtins-bases.cc
22106         (class freducop): Add frm_op_type template arg.
22107         (vfredusum_frm_obj): New declaration.
22108         (BASE): Ditto.
22109         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22110         * config/riscv/riscv-vector-builtins-functions.def
22111         (vfredusum_frm): New intrinsic function def.
22112         * config/riscv/riscv-vector-builtins-shapes.cc
22113         (struct reduc_alu_frm_def): New class for frm shape.
22114         (SHAPE): New declaration.
22115         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
22117 2023-08-17  Pan Li  <pan2.li@intel.com>
22119         * config/riscv/riscv-vector-builtins-bases.cc
22120         (class vfncvt_f): Add frm_op_type template arg.
22121         (vfncvt_f_frm_obj): New declaration.
22122         (BASE): Ditto.
22123         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22124         * config/riscv/riscv-vector-builtins-functions.def
22125         (vfncvt_f_frm): New intrinsic function def.
22127 2023-08-17  Pan Li  <pan2.li@intel.com>
22129         * config/riscv/riscv-vector-builtins-bases.cc
22130         (vfncvt_xu_frm_obj): New declaration.
22131         (BASE): Ditto.
22132         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22133         * config/riscv/riscv-vector-builtins-functions.def
22134         (vfncvt_xu_frm): New intrinsic function def.
22136 2023-08-17  Pan Li  <pan2.li@intel.com>
22138         * config/riscv/riscv-vector-builtins-bases.cc
22139         (class vfncvt_x): Add frm_op_type template arg.
22140         (BASE): New declaration.
22141         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22142         * config/riscv/riscv-vector-builtins-functions.def
22143         (vfncvt_x_frm): New intrinsic function def.
22144         * config/riscv/riscv-vector-builtins-shapes.cc
22145         (struct narrow_alu_frm_def): New shape function for frm.
22146         (SHAPE): New declaration.
22147         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
22149 2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
22151         * config/i386/avx512vldqintrin.h: Remove target attribute.
22152         * config/i386/i386-builtin.def (BDESC):
22153         Add OPTION_MASK_ISA2_AVX10_1.
22154         * config/i386/sse.md (VF_AVX512VLDQ_AVX10_1): New.
22155         (VFH_AVX512VLDQ_AVX10_1): Ditto.
22156         (VF1_AVX512VLDQ_AVX10_1): Ditto.
22157         (<mask_codefor>reducep<mode><mask_name><round_saeonly_name>):
22158         Change iterator to VFH_AVX512VLDQ_AVX10_1. Remove target check.
22159         (vec_pack<floatprefix>_float_<mode>): Change iterator to
22160         VI8_AVX512VLDQ_AVX10_1. Remove target check.
22161         (vec_unpack_<fixprefix>fix_trunc_lo_<mode>): Change iterator to
22162         VF1_AVX512VLDQ_AVX10_1. Remove target check.
22163         (vec_unpack_<fixprefix>fix_trunc_hi_<mode>): Ditto.
22164         (VI48F_256_DQVL_AVX10_1): Rename from VI48F_256_DQ.
22165         (avx512vl_vextractf128<mode>): Change iterator to
22166         VI48F_256_DQVL_AVX10_1. Remove target check.
22167         (vec_extract_hi_<mode>_mask): Add TARGET_AVX10_1.
22168         (vec_extract_hi_<mode>): Ditto.
22169         (avx512vl_vinsert<mode>): Ditto.
22170         (vec_set_lo_<mode><mask_name>): Ditto.
22171         (vec_set_hi_<mode><mask_name>): Ditto.
22172         (avx512dq_rangep<mode><mask_name><round_saeonly_name>): Change
22173         iterator to VF_AVX512VLDQ_AVX10_1. Remove target check.
22174         (avx512dq_fpclass<mode><mask_scalar_merge_name>): Change
22175         iterator to VFH_AVX512VLDQ_AVX10_1. Remove target check.
22176         * config/i386/subst.md (mask_avx512dq_condition): Add
22177         TARGET_AVX10_1.
22178         (mask_scalar_merge): Ditto.
22180 2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
22182         * config/i386/avx512vldqintrin.h: Remove target attribute.
22183         * config/i386/i386-builtin.def (BDESC):
22184         Add OPTION_MASK_ISA2_AVX10_1.
22185         * config/i386/i386.cc (standard_sse_constant_opcode): Add TARGET_AVX10_1.
22186         * config/i386/sse.md: (VI48_AVX512VL_AVX10_1): New.
22187         (VI48_AVX512VLDQ_AVX10_1): Ditto.
22188         (VF2_AVX512VL): Remove.
22189         (VI8_256_512VLDQ_AVX10_1): Rename from VI8_256_512.
22190         Add TARGET_AVX10_1.
22191         (*<code><mode>3<mask_name>): Change isa attribute to
22192         avx10_1_or_avx512dq. Add TARGET_AVX10_1.
22193         (<code><mode>3): Add TARGET_AVX10_1. Change isa attr
22194         to avx10_1_or_avx512vl.
22195         (<mask_codefor>avx512dq_cvtps2qq<mode><mask_name><round_name>):
22196         Change iterator to VI8_256_512VLDQ_AVX10_1. Remove target check.
22197         (<mask_codefor>avx512dq_cvtps2qqv2di<mask_name>):
22198         Add TARGET_AVX10_1.
22199         (<mask_codefor>avx512dq_cvtps2uqq<mode><mask_name><round_name>):
22200         Change iterator to VI8_256_512VLDQ_AVX10_1. Remove target check.
22201         (<mask_codefor>avx512dq_cvtps2uqqv2di<mask_name>):
22202         Add TARGET_AVX10_1.
22203         (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
22204         Change iterator to VF2_AVX512VLDQ_AVX10_1. Remove target check.
22205         (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
22206         Change iterator to VF1_128_256VLDQ_AVX10_1. Remove target check.
22207         (float<floatunssuffix>v4div4sf2<mask_name>):
22208         Add TARGET_AVX10_1.
22209         (avx512dq_float<floatunssuffix>v2div2sf2): Ditto.
22210         (*avx512dq_float<floatunssuffix>v2div2sf2): Ditto.
22211         (float<floatunssuffix>v2div2sf2): Ditto.
22212         (float<floatunssuffix>v2div2sf2_mask): Ditto.
22213         (*float<floatunssuffix>v2div2sf2_mask): Ditto.
22214         (*float<floatunssuffix>v2div2sf2_mask_1): Ditto.
22215         (<avx512>_cvt<ssemodesuffix>2mask<mode>):
22216         Change iterator to VI48_AVX512VLDQ_AVX10_1. Remove target check.
22217         (<avx512>_cvtmask2<ssemodesuffix><mode>): Ditto.
22218         (*<avx512>_cvtmask2<ssemodesuffix><mode>):
22219         Change iterator to VI48_AVX512VL_AVX10_1. Remove target check.
22220         Change when constraint is enabled.
22222 2023-08-17  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
22224         PR target/111037
22225         * config/riscv/riscv-vsetvl.cc (float_insn_valid_sew_p): New function.
22226         (second_sew_less_than_first_sew_p): Fix bug.
22227         (first_sew_less_than_second_sew_p): Ditto.
22229 2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
22231         * config/i386/avx512vldqintrin.h: Remove target attribute.
22232         * config/i386/i386-builtin.def (BDESC):
22233         Add OPTION_MASK_ISA2_AVX10_1.
22234         * config/i386/i386-builtins.cc (def_builtin): Handle AVX10_1.
22235         * config/i386/i386-expand.cc
22236         (ix86_check_builtin_isa_match): Ditto.
22237         (ix86_expand_sse2_mulvxdi3): Add TARGET_AVX10_1.
22238         * config/i386/i386.md: Add new isa attribute avx10_1_or_avx512dq
22239         and avx10_1_or_avx512vl.
22240         * config/i386/sse.md: (VF2_AVX512VLDQ_AVX10_1): New.
22241         (VF1_128_256VLDQ_AVX10_1): Ditto.
22242         (VI8_AVX512VLDQ_AVX10_1): Ditto.
22243         (<sse>_andnot<mode>3<mask_name>):
22244         Add TARGET_AVX10_1 and change isa attr from avx512dq to
22245         avx10_1_or_avx512dq.
22246         (*andnot<mode>3): Add TARGET_AVX10_1 and change isa attr from
22247         avx512vl to avx10_1_or_avx512vl.
22248         (fix<fixunssuffix>_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
22249         Change iterator to VF2_AVX512VLDQ_AVX10_1. Remove target check.
22250         (fix_notrunc<mode><sseintvecmodelower>2<mask_name><round_name>):
22251         Ditto.
22252         (ufix_notrunc<mode><sseintvecmodelower>2<mask_name><round_name>):
22253         Ditto.
22254         (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
22255         Change iterator to VF1_128_256VLDQ_AVX10_1. Remove target check.
22256         (avx512dq_fix<fixunssuffix>_truncv2sfv2di2<mask_name>):
22257         Add TARGET_AVX10_1.
22258         (fix<fixunssuffix>_truncv2sfv2di2): Ditto.
22259         (cond_mul<mode>): Change iterator to VI8_AVX10_1_AVX512DQVL.
22260         Remove target check.
22261         (avx512dq_mul<mode>3<mask_name>): Ditto.
22262         (*avx512dq_mul<mode>3<mask_name>): Ditto.
22263         (VI4F_BRCST32x2): Add TARGET_AVX512DQ and TARGET_AVX10_1.
22264         (<mask_codefor>avx512dq_broadcast<mode><mask_name>):
22265         Remove target check.
22266         (VI8F_BRCST64x2): Add TARGET_AVX512DQ and TARGET_AVX10_1.
22267         (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1):
22268         Remove target check.
22269         * config/i386/subst.md (mask_mode512bit_condition): Add TARGET_AVX10_1.
22270         (mask_avx512vl_condition): Ditto.
22271         (mask): Ditto.
22273 2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
22275         * common/config/i386/i386-common.cc
22276         (ix86_check_avx10_vector_width): New function to check isa_flags
22277         to emit a warning when there is a conflict in AVX10 options for
22278         vector width.
22279         (ix86_handle_option): Add check for avx10.1-256 and avx10.1-512.
22280         * config/i386/driver-i386.cc (host_detect_local_cpu):
22281         Do not append -mno-avx10-max-512bit for -march=native.
22283 2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
22285         * common/config/i386/i386-common.cc
22286         (ix86_check_avx10): New function to check isa_flags and
22287         isa_flags_explicit to emit warning when AVX10 is enabled
22288         by "-m" option.
22289         (ix86_check_avx512):  New function to check isa_flags and
22290         isa_flags_explicit to emit warning when AVX512 is enabled
22291         by "-m" option.
22292         (ix86_handle_option): Do not change the flags when warning
22293         is emitted.
22294         * config/i386/driver-i386.cc (host_detect_local_cpu):
22295         Do not append -mno-avx10.1 for -march=native.
22297 2023-08-17  Haochen Jiang  <haochen.jiang@intel.com>
22299         * common/config/i386/cpuinfo.h (get_available_features):
22300         Add avx10_set and version and detect avx10.1.
22301         (cpu_indicator_init): Handle avx10.1-512.
22302         * common/config/i386/i386-common.cc
22303         (OPTION_MASK_ISA2_AVX10_512BIT_SET): New.
22304         (OPTION_MASK_ISA2_AVX10_1_SET): Ditto.
22305         (OPTION_MASK_ISA2_AVX10_512BIT_UNSET): Ditto.
22306         (OPTION_MASK_ISA2_AVX10_1_UNSET): Ditto.
22307         (OPTION_MASK_ISA2_AVX2_UNSET): Modify for AVX10_1.
22308         (ix86_handle_option): Handle -mavx10.1, -mavx10.1-256 and
22309         -mavx10.1-512.
22310         * common/config/i386/i386-cpuinfo.h (enum processor_features):
22311         Add FEATURE_AVX10_512BIT, FEATURE_AVX10_1 and
22312         FEATURE_AVX10_512BIT.
22313         * common/config/i386/i386-isas.h: Add ISA_NAME_TABLE_ENTRY for
22314         AVX10_512BIT, AVX10_1 and AVX10_1_512.
22315         * config/i386/constraints.md (Yk): Add AVX10_1.
22316         (Yv): Ditto.
22317         (k): Ditto.
22318         * config/i386/cpuid.h (bit_AVX10): New.
22319         (bit_AVX10_256): Ditto.
22320         (bit_AVX10_512): Ditto.
22321         * config/i386/i386-c.cc (ix86_target_macros_internal):
22322         Define AVX10_512BIT and AVX10_1.
22323         * config/i386/i386-isa.def
22324         (AVX10_512BIT): Add DEF_PTA(AVX10_512BIT).
22325         (AVX10_1): Add DEF_PTA(AVX10_1).
22326         * config/i386/i386-options.cc (isa2_opts): Add -mavx10.1.
22327         (ix86_valid_target_attribute_inner_p): Handle avx10-512bit, avx10.1
22328         and avx10.1-512.
22329         (ix86_option_override_internal): Enable AVX512{F,VL,BW,DQ,CD,BF16,
22330         FP16,VBMI,VBMI2,VNNI,IFMA,BITALG,VPOPCNTDQ} features for avx10.1-512.
22331         (ix86_valid_target_attribute_inner_p): Handle AVX10_1.
22332         * config/i386/i386.cc (ix86_get_ssemov): Add AVX10_1.
22333         (ix86_conditional_register_usage): Ditto.
22334         (ix86_hard_regno_mode_ok): Ditto.
22335         (ix86_rtx_costs): Ditto.
22336         * config/i386/i386.h (VALID_MASK_AVX10_MODE): New macro.
22337         * config/i386/i386.opt: Add option -mavx10.1, -mavx10.1-256 and
22338         -mavx10.1-512.
22339         * doc/extend.texi: Document avx10.1, avx10.1-256 and avx10.1-512.
22340         * doc/invoke.texi: Document -mavx10.1, -mavx10.1-256 and -mavx10.1-512.
22341         * doc/sourcebuild.texi: Document target avx10.1, avx10.1-256
22342         and avx10.1-512.
22344 2023-08-17  Sergei Trofimovich  <siarheit@google.com>
22346         * flag-types.h (vrp_mode): Remove unused.
22348 2023-08-17  Yanzhang Wang  <yanzhang.wang@intel.com>
22350         * simplify-rtx.cc (simplify_context::simplify_binary_operation_1): Use
22351         CONSTM1_RTX.
22353 2023-08-17  Andrew Pinski  <apinski@marvell.com>
22355         * internal-fn.def (COND_NOT): New internal function.
22356         * match.pd (UNCOND_UNARY, COND_UNARY): Add bit_not/not
22357         to the lists.
22358         (`vec (a ? -1 : 0) ^ b`): New pattern to convert
22359         into conditional not.
22360         * optabs.def (cond_one_cmpl): New optab.
22361         (cond_len_one_cmpl): Likewise.
22363 2023-08-16  Surya Kumari Jangala  <jskumari@linux.ibm.com>
22365         PR rtl-optimization/110254
22366         * ira-color.cc (improve_allocation): Update array
22367         allocated_hard_reg_p.
22369 2023-08-16  Vladimir N. Makarov  <vmakarov@redhat.com>
22371         * lra-int.h (lra_update_fp2sp_elimination): Change the prototype.
22372         * lra-eliminations.cc (spill_pseudos): Record spilled pseudos.
22373         (lra_update_fp2sp_elimination): Ditto.
22374         (update_reg_eliminate): Adjust spill_pseudos call.
22375         * lra-spills.cc (lra_spill): Assign stack slots to pseudos spilled
22376         in lra_update_fp2sp_elimination.
22378 2023-08-16  Richard Ball  <richard.ball@arm.com>
22380         * config/aarch64/aarch64-cores.def (AARCH64_CORE): Add Cortex-A720 CPU.
22381         * config/aarch64/aarch64-tune.md: Regenerate.
22382         * doc/invoke.texi: Document Cortex-A720 CPU.
22384 2023-08-16  Robin Dapp  <rdapp@ventanamicro.com>
22386         * config/riscv/autovec.md (<u>avg<v_double_trunc>3_floor):
22387         Implement expander.
22388         (<u>avg<v_double_trunc>3_ceil): Ditto.
22389         * config/riscv/vector-iterators.md (ashiftrt): New iterator.
22390         (ASHIFTRT): Ditto.
22392 2023-08-16  Robin Dapp  <rdapp@ventanamicro.com>
22394         * internal-fn.cc (vec_extract_direct): Change type argument
22395         numbers.
22396         (expand_vec_extract_optab_fn): Call convert_optab_fn.
22397         (direct_vec_extract_optab_supported_p): Use
22398         convert_optab_supported_p.
22400 2023-08-16  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
22401             Richard Sandiford  <richard.sandiford@arm.com>
22403         * fold-const.cc (INCLUDE_ALGORITHM): Add Include.
22404         (valid_mask_for_fold_vec_perm_cst_p): New function.
22405         (fold_vec_perm_cst): Likewise.
22406         (fold_vec_perm): Adjust assert and call fold_vec_perm_cst.
22407         (test_fold_vec_perm_cst): New namespace.
22408         (test_fold_vec_perm_cst::build_vec_cst_rand): New function.
22409         (test_fold_vec_perm_cst::validate_res): Likewise.
22410         (test_fold_vec_perm_cst::validate_res_vls): Likewise.
22411         (test_fold_vec_perm_cst::builder_push_elems): Likewise.
22412         (test_fold_vec_perm_cst::test_vnx4si_v4si): Likewise.
22413         (test_fold_vec_perm_cst::test_v4si_vnx4si): Likewise.
22414         (test_fold_vec_perm_cst::test_all_nunits): Likewise.
22415         (test_fold_vec_perm_cst::test_nunits_min_2): Likewise.
22416         (test_fold_vec_perm_cst::test_nunits_min_4): Likewise.
22417         (test_fold_vec_perm_cst::test_nunits_min_8): Likewise.
22418         (test_fold_vec_perm_cst::test_nunits_max_4): Likewise.
22419         (test_fold_vec_perm_cst::is_simple_vla_size): Likewise.
22420         (test_fold_vec_perm_cst::test): Likewise.
22421         (fold_const_cc_tests): Call test_fold_vec_perm_cst::test.
22423 2023-08-16  Pan Li  <pan2.li@intel.com>
22425         * config/riscv/riscv-vector-builtins-bases.cc
22426         (BASE): New declaration.
22427         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22428         * config/riscv/riscv-vector-builtins-functions.def
22429         (vfwcvt_xu_frm): New intrinsic function def.
22431 2023-08-16  Pan Li  <pan2.li@intel.com>
22433         * config/riscv/riscv-vector-builtins-bases.cc: Use explicit argument.
22435 2023-08-16  Pan Li  <pan2.li@intel.com>
22437         * config/riscv/riscv-vector-builtins-bases.cc
22438         (BASE): New declaration.
22439         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22440         * config/riscv/riscv-vector-builtins-functions.def
22441         (vfwcvt_x_frm): New intrinsic function def.
22443 2023-08-16  Pan Li  <pan2.li@intel.com>
22445         * config/riscv/riscv-vector-builtins-bases.cc (BASE): New declaration.
22446         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22447         * config/riscv/riscv-vector-builtins-functions.def
22448         (vfcvt_f_frm): New intrinsic function def.
22450 2023-08-16  Pan Li  <pan2.li@intel.com>
22452         * config/riscv/riscv-vector-builtins-bases.cc
22453         (BASE): New declaration.
22454         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22455         * config/riscv/riscv-vector-builtins-functions.def
22456         (vfcvt_xu_frm): New intrinsic function def..
22458 2023-08-16  Haochen Gui  <guihaoc@gcc.gnu.org>
22460         PR target/110429
22461         * config/rs6000/vsx.md (*vsx_extract_<mode>_store_p9): Skip vector
22462         extract when the element is 7 on BE while 8 on LE for byte or 3 on
22463         BE while 4 on LE for halfword.
22465 2023-08-16  Haochen Gui  <guihaoc@gcc.gnu.org>
22467         PR target/106769
22468         * config/rs6000/vsx.md (expand vsx_extract_<mode>): Set it only
22469         for V8HI and V16QI.
22470         (vsx_extract_v4si): New expand for V4SI extraction.
22471         (vsx_extract_v4si_w1): New insn pattern for V4SI extraction on
22472         word 1 from BE order.
22473         (*mfvsrwz): New insn pattern for mfvsrwz.
22474         (*vsx_extract_<mode>_di_p9): Assert that it won't be generated on
22475         word 1 from BE order.
22476         (*vsx_extract_si): Remove.
22477         (*vsx_extract_v4si_w023): New insn and split pattern on word 0, 2,
22478         3 from BE order.
22480 2023-08-16  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
22482         * config/riscv/autovec.md (vec_mask_len_load_lanes<mode><vsingle>):
22483         New pattern.
22484         (vec_mask_len_store_lanes<mode><vsingle>): Ditto.
22485         * config/riscv/riscv-protos.h (expand_lanes_load_store): New function.
22486         * config/riscv/riscv-v.cc (get_mask_mode): Add tuple mask mode.
22487         (expand_lanes_load_store): New function.
22488         * config/riscv/vector-iterators.md: New iterator.
22490 2023-08-16  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
22492         * internal-fn.cc (internal_load_fn_p): Apply
22493         MASK_LEN_{LOAD_LANES,STORE_LANES} into vectorizer.
22494         (internal_store_fn_p): Ditto.
22495         (internal_fn_len_index): Ditto.
22496         (internal_fn_mask_index): Ditto.
22497         (internal_fn_stored_value_index): Ditto.
22498         * tree-vect-data-refs.cc (vect_store_lanes_supported): Ditto.
22499         (vect_load_lanes_supported): Ditto.
22500         * tree-vect-loop.cc: Ditto.
22501         * tree-vect-slp.cc (vect_slp_prefer_store_lanes_p): Ditto.
22502         * tree-vect-stmts.cc (check_load_store_for_partial_vectors): Ditto.
22503         (get_group_load_store_type): Ditto.
22504         (vectorizable_store): Ditto.
22505         (vectorizable_load): Ditto.
22506         * tree-vectorizer.h (vect_store_lanes_supported): Ditto.
22507         (vect_load_lanes_supported): Ditto.
22509 2023-08-16  Pan Li  <pan2.li@intel.com>
22511         * config/riscv/riscv-vector-builtins-bases.cc
22512         (enum frm_op_type): New type for frm.
22513         (BASE): New declaration.
22514         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22515         * config/riscv/riscv-vector-builtins-functions.def
22516         (vfcvt_x_frm): New intrinsic function def.
22518 2023-08-16  liuhongt  <hongtao.liu@intel.com>
22520         * config/i386/i386-builtins.cc
22521         (ix86_vectorize_builtin_gather): Adjust for use_gather_8parts.
22522         * config/i386/i386-options.cc (parse_mtune_ctrl_str):
22523         Set/Clear tune features use_{gather,scatter}_{2parts, 4parts,
22524         8parts} for -mtune-crtl={,^}{use_gather,use_scatter}.
22525         * config/i386/i386.cc (ix86_vectorize_builtin_scatter): Adjust
22526         for use_scatter_8parts
22527         * config/i386/i386.h (TARGET_USE_GATHER): Rename to ..
22528         (TARGET_USE_GATHER_8PARTS): .. this.
22529         (TARGET_USE_SCATTER): Rename to ..
22530         (TARGET_USE_SCATTER_8PARTS): .. this.
22531         * config/i386/x86-tune.def (X86_TUNE_USE_GATHER): Rename to
22532         (X86_TUNE_USE_GATHER_8PARTS): .. this.
22533         (X86_TUNE_USE_SCATTER): Rename to
22534         (X86_TUNE_USE_SCATTER_8PARTS): .. this.
22535         * config/i386/i386.opt: Add new options mgather, mscatter.
22537 2023-08-16  liuhongt  <hongtao.liu@intel.com>
22539         * config/i386/i386-options.cc (m_GDS): New macro.
22540         * config/i386/x86-tune.def (X86_TUNE_USE_GATHER_2PARTS): Don't
22541         enable for m_GDS.
22542         (X86_TUNE_USE_GATHER_4PARTS): Ditto.
22543         (X86_TUNE_USE_GATHER): Ditto.
22545 2023-08-16  liuhongt  <hongtao.liu@intel.com>
22547         * config/i386/i386.md (movdf_internal): Generate vmovapd instead of
22548         vmovsd when moving DFmode between SSE_REGS.
22549         (movhi_internal): Generate vmovdqa instead of vmovsh when
22550         moving HImode between SSE_REGS.
22551         (mov<mode>_internal): Use vmovaps instead of vmovsh when
22552         moving HF/BFmode between SSE_REGS.
22554 2023-08-15  David Faust  <david.faust@oracle.com>
22556         * config/bpf/bpf.md (extendsisi2): Delete useless define_insn.
22558 2023-08-15  David Faust  <david.faust@oracle.com>
22560         PR target/111029
22561         * config/bpf/bpf.cc (bpf_print_register): Print 'w' registers
22562         for any mode 32-bits or smaller, not just SImode.
22564 2023-08-15  Martin Jambor  <mjambor@suse.cz>
22566         PR ipa/68930
22567         PR ipa/92497
22568         * ipa-prop.h (ipcp_get_aggregate_const): Declare.
22569         * ipa-prop.cc (ipcp_get_aggregate_const): New function.
22570         (ipcp_transform_function): Do not deallocate transformation info.
22571         * tree-ssa-sccvn.cc: Include alloc-pool.h, symbol-summary.h and
22572         ipa-prop.h.
22573         (vn_reference_lookup_2): When hitting default-def vuse, query
22574         IPA-CP transformation info for any known constants.
22576 2023-08-15  Chung-Lin Tang  <cltang@codesourcery.com>
22577             Thomas Schwinge  <thomas@codesourcery.com>
22579         * gimplify.cc (oacc_region_type_name): New function.
22580         (oacc_default_clause): If no 'default' clause appears on this
22581         compute construct, see if one appears on a lexically containing
22582         'data' construct.
22583         (gimplify_scan_omp_clauses): Upon OMP_CLAUSE_DEFAULT case, set
22584         ctx->oacc_default_clause_ctx to current context.
22586 2023-08-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
22588         PR target/110989
22589         * config/riscv/predicates.md: Fix predicate.
22591 2023-08-15  Richard Biener  <rguenther@suse.de>
22593         * tree-vect-slp.cc (vect_analyze_slp_instance): Remove
22594         slp_inst_kind_ctor handling.
22595         (vect_analyze_slp): Simplify.
22596         (vect_build_slp_instance): Dump when we analyze a CTOR.
22597         (vect_slp_check_for_constructors): Rename to ...
22598         (vect_slp_check_for_roots): ... this.  Register a
22599         slp_root for CONSTRUCTORs instead of shoving them to
22600         the set of grouped stores.
22601         (vect_slp_analyze_bb_1): Adjust.
22603 2023-08-15  Richard Biener  <rguenther@suse.de>
22605         * tree-vectorizer.h (_slp_instance::remain_stmts): Change
22606         to ...
22607         (_slp_instance::remain_defs): ... this.
22608         (SLP_INSTANCE_REMAIN_STMTS): Rename to ...
22609         (SLP_INSTANCE_REMAIN_DEFS): ... this.
22610         (slp_root::remain): New.
22611         (slp_root::slp_root): Adjust.
22612         * tree-vect-slp.cc (vect_free_slp_instance): Adjust.
22613         (vect_build_slp_instance): Get extra remain parameter,
22614         adjust former handling of a cut off stmt.
22615         (vect_analyze_slp_instance): Adjust.
22616         (vect_analyze_slp): Likewise.
22617         (_bb_vec_info::~_bb_vec_info): Likewise.
22618         (vectorizable_bb_reduc_epilogue): Dump something if we fail.
22619         (vect_slp_check_for_constructors): Handle non-internal
22620         defs as remain defs of a reduction.
22621         (vectorize_slp_instance_root_stmt): Adjust.
22623 2023-08-15  Richard Biener  <rguenther@suse.de>
22625         * tree-ssa-loop-ivcanon.cc: Include tree-vectorizer.h
22626         (canonicalize_loop_induction_variables): Use find_loop_location.
22628 2023-08-15  Hans-Peter Nilsson  <hp@axis.com>
22630         PR bootstrap/111021
22631         * config/cris/cris-protos.h: Revert recent change.
22632         * config/cris/cris.cc (cris_legitimate_address_p): Remove
22633         code_helper unused parameter.
22634         (cris_legitimate_address_p_hook): New wrapper function.
22635         (TARGET_LEGITIMATE_ADDRESS_P): Change to
22636         cris_legitimate_address_p_hook.
22638 2023-08-15  Richard Biener  <rguenther@suse.de>
22640         PR tree-optimization/110963
22641         * tree-ssa-pre.cc (do_pre_regular_insertion): Also insert
22642         a PHI node when the expression is available on all edges
22643         and we insert at most one copy from a constant.
22645 2023-08-15  Richard Biener  <rguenther@suse.de>
22647         PR tree-optimization/110991
22648         * tree-ssa-loop-ivcanon.cc (constant_after_peeling): Handle
22649         VIEW_CONVERT_EXPR <op>, handle more simple IV-like SSA cycles
22650         that will end up constant.
22652 2023-08-15  Kewen Lin  <linkw@linux.ibm.com>
22654         PR bootstrap/111021
22655         * Makefile.in (RECOG_H): Add $(TREE_H) as dependence.
22657 2023-08-15  Kewen Lin  <linkw@linux.ibm.com>
22659         * tree-vect-stmts.cc (vectorizable_load): Move the handlings on
22660         VMAT_LOAD_STORE_LANES in the final loop nest to its own loop,
22661         and update the final nest accordingly.
22663 2023-08-15  Kewen Lin  <linkw@linux.ibm.com>
22665         * tree-vect-stmts.cc (vectorizable_load): Remove some useless checks
22666         on VMAT_INVARIANT.
22668 2023-08-15  Pan Li  <pan2.li@intel.com>
22670         * mode-switching.cc (create_pre_exit): Add SET insn check.
22672 2023-08-15  Pan Li  <pan2.li@intel.com>
22674         * config/riscv/riscv-vector-builtins-bases.cc
22675         (class vfrec7_frm): New class for frm.
22676         (vfrec7_frm_obj): New declaration.
22677         (BASE): Ditto.
22678         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22679         * config/riscv/riscv-vector-builtins-functions.def
22680         (vfrec7_frm): New intrinsic function definition.
22681         * config/riscv/vector-iterators.md
22682         (VFMISC): Remove VFREC7.
22683         (misc_op): Ditto.
22684         (float_insn_type): Ditto.
22685         (VFMISC_FRM): New int iterator.
22686         (misc_frm_op): New op for frm.
22687         (float_frm_insn_type): New type for frm.
22688         * config/riscv/vector.md (@pred_<misc_frm_op><mode>):
22689         New pattern for misc frm.
22691 2023-08-14  Vladimir N. Makarov  <vmakarov@redhat.com>
22693         * lra-constraints.cc (curr_insn_transform): Process output stack
22694         pointer reloads before emitting reload insns.
22696 2023-08-14  benjamin priour  <vultkayn@gcc.gnu.org>
22698         PR analyzer/110543
22699         * doc/invoke.texi: Add documentation of
22700         fanalyzer-show-events-in-system-headers
22702 2023-08-14  Jan Hubicka  <jh@suse.cz>
22704         PR gcov-profile/110988
22705         * tree-cfg.cc (fold_loop_internal_call): Avoid division by zero.
22707 2023-08-14  Jiawei  <jiawei@iscas.ac.cn>
22709         * config/riscv/riscv-c.cc (riscv_cpu_cpp_builtins):
22710         Enable compressed builtins when ZC* extensions enabled.
22711         * config/riscv/riscv-shorten-memrefs.cc:
22712         Enable shorten_memrefs pass when ZC* extensions enabled.
22713         * config/riscv/riscv.cc (riscv_compressed_reg_p):
22714         Enable compressible registers when ZC* extensions enabled.
22715         (riscv_rtx_costs): Allow adjusting rtx costs when ZC* extensions enabled.
22716         (riscv_address_cost): Allow adjusting address cost when ZC* extensions enabled.
22717         (riscv_first_stack_step): Allow compression of the register saves
22718         without adding extra instructions.
22719         * config/riscv/riscv.h (FUNCTION_BOUNDARY): Adjusts function boundary
22720         to 16 bits when ZC* extensions enabled.
22722 2023-08-14  Jiawei  <jiawei@iscas.ac.cn>
22724         * common/config/riscv/riscv-common.cc (riscv_subset_list::parse): New extensions.
22725         * config/riscv/riscv-opts.h (MASK_ZCA): New mask.
22726         (MASK_ZCB): Ditto.
22727         (MASK_ZCE): Ditto.
22728         (MASK_ZCF): Ditto.
22729         (MASK_ZCD): Ditto.
22730         (MASK_ZCMP): Ditto.
22731         (MASK_ZCMT): Ditto.
22732         (TARGET_ZCA): New target.
22733         (TARGET_ZCB): Ditto.
22734         (TARGET_ZCE): Ditto.
22735         (TARGET_ZCF): Ditto.
22736         (TARGET_ZCD): Ditto.
22737         (TARGET_ZCMP): Ditto.
22738         (TARGET_ZCMT): Ditto.
22739         * config/riscv/riscv.opt: New target variable.
22741 2023-08-14  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
22743         Revert:
22744         2023-05-17  Jin Ma  <jinma@linux.alibaba.com>
22746         * genrecog.cc (print_nonbool_test): Fix type error of
22747         switch (SUBREG_BYTE (op))'.
22749 2023-08-14  Richard Biener  <rguenther@suse.de>
22751         * tree-cfg.cc (print_loop_info): Dump to 'file', not 'dump_file'.
22753 2023-08-14  Pan Li  <pan2.li@intel.com>
22755         * config/riscv/riscv-vector-builtins-bases.cc
22756         (class unop_frm): New class for frm.
22757         (vfsqrt_frm_obj): New declaration.
22758         (BASE): Ditto.
22759         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22760         * config/riscv/riscv-vector-builtins-functions.def
22761         (vfsqrt_frm): New intrinsic function definition.
22763 2023-08-14  Pan Li  <pan2.li@intel.com>
22765         * config/riscv/riscv-vector-builtins-bases.cc
22766         (class vfwnmsac_frm): New class for frm.
22767         (vfwnmsac_frm_obj): New declaration.
22768         (BASE): Ditto.
22769         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22770         * config/riscv/riscv-vector-builtins-functions.def
22771         (vfwnmsac_frm): New intrinsic function definition.
22773 2023-08-14  Pan Li  <pan2.li@intel.com>
22775         * config/riscv/riscv-vector-builtins-bases.cc
22776         (class vfwmsac_frm): New class for frm.
22777         (vfwmsac_frm_obj): New declaration.
22778         (BASE): Ditto.
22779         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22780         * config/riscv/riscv-vector-builtins-functions.def
22781         (vfwmsac_frm): New intrinsic function definition.
22783 2023-08-14  Pan Li  <pan2.li@intel.com>
22785         * config/riscv/riscv-vector-builtins-bases.cc
22786         (class vfwnmacc_frm): New class for frm.
22787         (vfwnmacc_frm_obj): New declaration.
22788         (BASE): Ditto.
22789         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22790         * config/riscv/riscv-vector-builtins-functions.def
22791         (vfwnmacc_frm): New intrinsic function definition.
22793 2023-08-14  Cui, Lili  <lili.cui@intel.com>
22795         * common/config/i386/cpuinfo.h (get_intel_cpu): Add model value 0xba
22796         to Raptorlake.
22798 2023-08-14  Hans-Peter Nilsson  <hp@axis.com>
22800         * config/mmix/predicates.md (mmix_address_operand): Use
22801         lra_in_progress, not reload_in_progress.
22803 2023-08-14  Hans-Peter Nilsson  <hp@axis.com>
22805         * config/mmix/mmix.cc: Re-enable LRA.
22807 2023-08-14  Hans-Peter Nilsson  <hp@axis.com>
22809         * config/mmix/predicates.md (frame_pointer_operand): Handle FP+offset
22810         when lra_in_progress.
22812 2023-08-14  Hans-Peter Nilsson  <hp@axis.com>
22814         * config/mmix/mmix.cc: Disable LRA for MMIX.
22816 2023-08-14  Pan Li  <pan2.li@intel.com>
22818         * config/riscv/riscv-vector-builtins-bases.cc
22819         (class vfwmacc_frm): New class for vfwmacc frm.
22820         (vfwmacc_frm_obj): New declaration.
22821         (BASE): Ditto.
22822         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22823         * config/riscv/riscv-vector-builtins-functions.def
22824         (vfwmacc_frm): Function definition for vfwmacc.
22825         * config/riscv/riscv-vector-builtins.cc
22826         (function_expander::use_widen_ternop_insn): Add frm support.
22828 2023-08-14  Pan Li  <pan2.li@intel.com>
22830         * config/riscv/riscv-vector-builtins-bases.cc
22831         (class vfnmsub_frm): New class for vfnmsub frm.
22832         (vfnmsub_frm): New declaration.
22833         (BASE): Ditto.
22834         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22835         * config/riscv/riscv-vector-builtins-functions.def
22836         (vfnmsub_frm): New function declaration.
22838 2023-08-14  Vladimir N. Makarov  <vmakarov@redhat.com>
22840         * lra-constraints.cc (curr_insn_transform): Set done_p up and
22841         check it on true after processing output stack pointer reload.
22843 2023-08-12  Jakub Jelinek  <jakub@redhat.com>
22845         * Makefile.in (USER_H): Add stdckdint.h.
22846         * ginclude/stdckdint.h: New file.
22848 2023-08-12  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
22850         PR target/110994
22851         * config/riscv/riscv-opts.h (TARGET_VECTOR_VLS): Add TARGET_VETOR.
22853 2023-08-12  Patrick Palka  <ppalka@redhat.com>
22855         * tree-pretty-print.cc (dump_generic_node) <case TREE_VEC>:
22856         Delimit output with braces.
22858 2023-08-12  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
22860         PR target/110985
22861         * config/riscv/riscv-v.cc (expand_vec_series): Refactor the expander.
22863 2023-08-12  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
22865         * config/riscv/autovec.md: Add VLS CONST_VECTOR.
22866         * config/riscv/riscv.cc (riscv_const_insns): Ditto.
22867         * config/riscv/vector.md: Ditto.
22869 2023-08-11  David Malcolm  <dmalcolm@redhat.com>
22871         PR analyzer/105899
22872         * doc/analyzer.texi (__analyzer_get_strlen): New.
22873         * doc/invoke.texi: Add -Wanalyzer-unterminated-string.
22875 2023-08-11  Jeff Law  <jlaw@ventanamicro.com>
22877         * config/rx/rx.md (subdi3): Fix test for borrow.
22879 2023-08-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
22881         PR middle-end/110989
22882         * tree-vect-stmts.cc (vectorizable_store): Replace iv_type with sizetype.
22883         (vectorizable_load): Ditto.
22885 2023-08-11  Jose E. Marchesi  <jose.marchesi@oracle.com>
22887         * config/bpf/bpf.md (allocate_stack): Define.
22888         * config/bpf/bpf.h (FIRST_PSEUDO_REGISTER): Make room for fake
22889         stack pointer register.
22890         (FIXED_REGISTERS): Adjust accordingly.
22891         (CALL_USED_REGISTERS): Likewise.
22892         (REG_CLASS_CONTENTS): Likewise.
22893         (REGISTER_NAMES): Likewise.
22894         * config/bpf/bpf.cc (bpf_compute_frame_layout): Do not reserve
22895         space for callee-saved registers.
22896         (bpf_expand_prologue): Do not save callee-saved registers in xbpf.
22897         (bpf_expand_epilogue): Do not restore callee-saved registers in
22898         xbpf.
22900 2023-08-11  Jose E. Marchesi  <jose.marchesi@oracle.com>
22902         * config/bpf/bpf.cc (bpf_function_arg_advance): Do not complain
22903         about too many arguments if function is always inlined.
22905 2023-08-11  Patrick Palka  <ppalka@redhat.com>
22907         * tree-pretty-print.cc (dump_generic_node) <case COMPONENT_REF>:
22908         Don't call component_ref_field_offset if the RHS isn't a decl.
22910 2023-08-11  John David Anglin  <danglin@gcc.gnu.org>
22912         PR bootstrap/110646
22913         * gensupport.cc(class conlist): Use strtol instead of std::stoi.
22915 2023-08-11  Vladimir N. Makarov  <vmakarov@redhat.com>
22917         * lra-constraints.cc (goal_alt_out_sp_reload_p): New flag.
22918         (process_alt_operands): Set the flag.
22919         (curr_insn_transform): Modify stack pointer offsets if output
22920         stack pointer reload is generated.
22922 2023-08-11  Joseph Myers  <joseph@codesourcery.com>
22924         * configure: Regenerate.
22926 2023-08-11  Richard Biener  <rguenther@suse.de>
22928         PR tree-optimization/110979
22929         * tree-vect-loop.cc (vectorizable_reduction): For
22930         FOLD_LEFT_REDUCTION without target support make sure
22931         we don't need to honor signed zeros and sign dependent rounding.
22933 2023-08-11  Richard Biener  <rguenther@suse.de>
22935         * tree-vect-slp.cc (vect_slp_region): Provide opt-info for all SLP
22936         subgraph entries.  Dump the used vector size based on the
22937         SLP subgraph entry root vector type.
22939 2023-08-11  Pan Li  <pan2.li@intel.com>
22941         * config/riscv/riscv-vector-builtins-bases.cc
22942         (class vfmsub_frm): New class for vfmsub frm.
22943         (vfmsub_frm): New declaration.
22944         (BASE): Ditto.
22945         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22946         * config/riscv/riscv-vector-builtins-functions.def
22947         (vfmsub_frm): New function declaration.
22949 2023-08-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
22951         * doc/md.texi: Add vec_mask_len_{load_lanes,store_lanes} patterns.
22952         * internal-fn.cc (expand_partial_load_optab_fn): Ditto.
22953         (expand_partial_store_optab_fn): Ditto.
22954         * internal-fn.def (MASK_LEN_LOAD_LANES): Ditto.
22955         (MASK_LEN_STORE_LANES): Ditto.
22956         * optabs.def (OPTAB_CD): Ditto.
22958 2023-08-11  Pan Li  <pan2.li@intel.com>
22960         * config/riscv/riscv-vector-builtins-bases.cc
22961         (class vfnmadd_frm): New class for vfnmadd frm.
22962         (vfnmadd_frm): New declaration.
22963         (BASE): Ditto.
22964         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22965         * config/riscv/riscv-vector-builtins-functions.def
22966         (vfnmadd_frm): New function declaration.
22968 2023-08-11  Drew Ross  <drross@redhat.com>
22969             Jakub Jelinek  <jakub@redhat.com>
22971         PR tree-optimization/109938
22972         * match.pd (((x ^ y) & z) | x -> (z & y) | x): New simplification.
22974 2023-08-11  Pan Li  <pan2.li@intel.com>
22976         * config/riscv/riscv-vector-builtins-bases.cc
22977         (class vfmadd_frm): New class for vfmadd frm.
22978         (vfmadd_frm_obj): New declaration.
22979         (BASE): Ditto.
22980         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22981         * config/riscv/riscv-vector-builtins-functions.def
22982         (vfmadd_frm): New function definition.
22984 2023-08-11  Pan Li  <pan2.li@intel.com>
22986         * config/riscv/riscv-vector-builtins-bases.cc
22987         (class vfnmsac_frm): New class for vfnmsac frm.
22988         (vfnmsac_frm_obj): New declaration.
22989         (BASE): Ditto.
22990         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
22991         * config/riscv/riscv-vector-builtins-functions.def
22992         (vfnmsac_frm): New function definition.
22994 2023-08-11  Jakub Jelinek  <jakub@redhat.com>
22996         * doc/extend.texi (Typeof): Document typeof_unqual
22997         and __typeof_unqual__.
22999 2023-08-11  Andrew Pinski  <apinski@marvell.com>
23001         PR tree-optimization/110954
23002         * generic-match-head.cc (bitwise_inverted_equal_p): Add
23003         wascmp argument and set it accordingly.
23004         * gimple-match-head.cc (bitwise_inverted_equal_p): Add
23005         wascmp argument to the macro.
23006         (gimple_bitwise_inverted_equal_p): Add
23007         wascmp argument and set it accordingly.
23008         * match.pd (`a & ~a`, `a ^| ~a`): Update call
23009         to bitwise_inverted_equal_p and handle wascmp case.
23010         (`(~x | y) & x`, `(~x | y) & x`, `a?~t:t`): Update
23011         call to bitwise_inverted_equal_p and check to see
23012         if was !wascmp or if precision was 1.
23014 2023-08-11  Martin Uecker  <uecker@tugraz.at>
23016         PR c/84510
23017         * doc/invoke.texi: Update.
23019 2023-08-11  Pan Li  <pan2.li@intel.com>
23021         * config/riscv/riscv-vector-builtins-bases.cc
23022         (class vfmsac_frm): New class for vfmsac frm.
23023         (vfmsac_frm_obj): New declaration.
23024         (BASE): Ditto.
23025         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
23026         * config/riscv/riscv-vector-builtins-functions.def
23027         (vfmsac_frm): New function definition
23029 2023-08-10  Jan Hubicka  <jh@suse.cz>
23031         PR middle-end/110923
23032         * tree-ssa-loop-split.cc (split_loop): Watch for division by zero.
23034 2023-08-10  Patrick O'Neill  <patrick@rivosinc.com>
23036         * common/config/riscv/riscv-common.cc: Add Ztso and mark Ztso as
23037         dependent on 'a' extension.
23038         * config/riscv/riscv-opts.h (MASK_ZTSO): New mask.
23039         (TARGET_ZTSO): New target.
23040         * config/riscv/riscv.cc (riscv_memmodel_needs_amo_acquire): Add
23041         Ztso case.
23042         (riscv_memmodel_needs_amo_release): Add Ztso case.
23043         (riscv_print_operand): Add Ztso case for LR/SC annotations.
23044         * config/riscv/riscv.md: Import sync-rvwmo.md and sync-ztso.md.
23045         * config/riscv/riscv.opt: Add Ztso target variable.
23046         * config/riscv/sync.md (mem_thread_fence_1): Expand to RVWMO or
23047         Ztso specific insn.
23048         (atomic_load<mode>): Expand to RVWMO or Ztso specific insn.
23049         (atomic_store<mode>): Expand to RVWMO or Ztso specific insn.
23050         * config/riscv/sync-rvwmo.md: New file. Seperate out RVWMO
23051         specific load/store/fence mappings.
23052         * config/riscv/sync-ztso.md: New file. Seperate out Ztso
23053         specific load/store/fence mappings.
23055 2023-08-10  Jan Hubicka  <jh@suse.cz>
23057         * cfgloopmanip.cc (duplicate_loop_body_to_header_edge): Special case loops with
23058         0 iteration count.
23060 2023-08-10  Jan Hubicka  <jh@suse.cz>
23062         * tree-ssa-threadupdate.cc (ssa_fix_duplicate_block_edges): Fix profile update.
23064 2023-08-10  Jan Hubicka  <jh@suse.cz>
23066         * profile-count.cc (profile_count::differs_from_p): Fix overflow and
23067         handling of undefined values.
23069 2023-08-10  Jakub Jelinek  <jakub@redhat.com>
23071         PR c/102989
23072         * tree-ssa-phiopt.cc (single_non_singleton_phi_for_edges): Never
23073         return virtual phis and return NULL if there is a virtual phi
23074         where the arguments from E0 and E1 edges aren't equal.
23076 2023-08-10  Richard Biener  <rguenther@suse.de>
23078         * internal-fn.def (VCOND, VCONDU, VCONDEQ, VCOND_MASK,
23079         VEC_SET, VEC_EXTRACT): Make ECF_CONST | ECF_NOTHROW.
23081 2023-08-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
23083         PR target/110962
23084         * config/riscv/autovec.md (vec_duplicate<mode>): New pattern.
23086 2023-08-10  Pan Li  <pan2.li@intel.com>
23088         * config/riscv/riscv-vector-builtins-bases.cc
23089         (class vfnmacc_frm): New class for vfnmacc.
23090         (vfnmacc_frm_obj): New declaration.
23091         (BASE): Ditto.
23092         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
23093         * config/riscv/riscv-vector-builtins-functions.def
23094         (vfnmacc_frm): New function definition.
23096 2023-08-10  Pan Li  <pan2.li@intel.com>
23098         * config/riscv/riscv-vector-builtins-bases.cc
23099         (class vfmacc_frm): New class for vfmacc frm.
23100         (vfmacc_frm_obj): New declaration.
23101         (BASE): Ditto.
23102         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
23103         * config/riscv/riscv-vector-builtins-functions.def
23104         (vfmacc_frm): New function definition.
23106 2023-08-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
23108         PR target/110964
23109         * config/riscv/riscv-v.cc (expand_cond_len_ternop): Add integer ternary.
23111 2023-08-10  Richard Biener  <rguenther@suse.de>
23113         * tree-vectorizer.h (vectorizable_live_operation): Remove
23114         gimple_stmt_iterator * argument.
23115         * tree-vect-loop.cc (vectorizable_live_operation): Likewise.
23116         Adjust plumbing around vect_get_loop_mask.
23117         (vect_analyze_loop_operations): Adjust.
23118         * tree-vect-slp.cc (vect_slp_analyze_node_operations_1): Likewise.
23119         (vect_bb_slp_mark_live_stmts): Likewise.
23120         (vect_schedule_slp_node): Likewise.
23121         * tree-vect-stmts.cc (can_vectorize_live_stmts): Likewise.
23122         Remove gimple_stmt_iterator * argument.
23123         (vect_transform_stmt): Adjust.
23125 2023-08-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
23127         * config/riscv/vector-iterators.md: Add missing modes.
23129 2023-08-10  Jakub Jelinek  <jakub@redhat.com>
23131         PR c/102989
23132         * lto-streamer-in.cc (lto_input_tree_1): Assert TYPE_PRECISION
23133         is up to WIDE_INT_MAX_PRECISION rather than MAX_BITSIZE_MODE_ANY_INT.
23135 2023-08-10  Jakub Jelinek  <jakub@redhat.com>
23137         PR c/102989
23138         * expr.cc (expand_expr_real_1) <case MEM_REF>: Add an early return for
23139         EXPAND_WRITE or EXPAND_MEMORY modifiers to avoid testing it multiple
23140         times.
23142 2023-08-10  liuhongt  <hongtao.liu@intel.com>
23144         PR target/110832
23145         * config/i386/mmx.md: (movq_<mode>_to_sse): Also do not
23146         sanitize upper part of V4HFmode register with
23147         -fno-trapping-math.
23148         (<insn>v4hf3): Enable for ix86_partial_vec_fp_math.
23149         (<divv4hf3): Ditto.
23150         (<insn>v2hf3): Ditto.
23151         (divv2hf3): Ditto.
23152         (movd_v2hf_to_sse): Do not sanitize upper part of V2HFmode
23153         register with -fno-trapping-math.
23155 2023-08-10  Pan Li  <pan2.li@intel.com>
23156             Kito Cheng  <kito.cheng@sifive.com>
23158         * config/riscv/riscv-protos.h
23159         (enum floating_point_rounding_mode): Add NONE, DYN_EXIT and DYN_CALL.
23160         (get_frm_mode): New declaration.
23161         * config/riscv/riscv-v.cc (get_frm_mode): New function to get frm mode.
23162         * config/riscv/riscv-vector-builtins.cc
23163         (function_expander::use_ternop_insn): Take care of frm reg.
23164         * config/riscv/riscv.cc (riscv_static_frm_mode_p): Migrate to FRM_XXX.
23165         (riscv_emit_frm_mode_set): Ditto.
23166         (riscv_emit_mode_set): Ditto.
23167         (riscv_frm_adjust_mode_after_call): Ditto.
23168         (riscv_frm_mode_needed): Ditto.
23169         (riscv_frm_mode_after): Ditto.
23170         (riscv_mode_entry): Ditto.
23171         (riscv_mode_exit): Ditto.
23172         * config/riscv/riscv.h (NUM_MODES_FOR_MODE_SWITCHING): Ditto.
23173         * config/riscv/vector.md
23174         (rne,rtz,rdn,rup,rmm,dyn,dyn_exit,dyn_call,none): Removed
23175         (symbol_ref): * config/riscv/vector.md: Set frm_mode attr explicitly.
23177 2023-08-09  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
23179         * config/riscv/riscv-vsetvl.cc (anticipatable_occurrence_p): Fix
23180         incorrect anticipate info.
23182 2023-08-09  Tsukasa OI  <research_trasio@irq.a4lg.com>
23184         * common/config/riscv/riscv-common.cc (riscv_ext_version_table):
23185         Remove 'Zve32d' from the version list.
23187 2023-08-09  Jin Ma  <jinma@linux.alibaba.com>
23189         * config/riscv/riscv.cc (riscv_sched_variable_issue): New function.
23190         (TARGET_SCHED_VARIABLE_ISSUE): New macro.
23191         Co-authored-by: Philipp Tomsich <philipp.tomsich@vrull.eu>
23192         Co-authored-by: Jeff Law <jlaw@ventanamicro.com>
23194 2023-08-09  Jivan Hakobyan  <jivanhakobyan9@gmail.com>
23196         * config/riscv/riscv.cc (riscv_legitimize_address): Handle folding.
23197         (mem_shadd_or_shadd_rtx_p): New function.
23199 2023-08-09  Andrew Pinski  <apinski@marvell.com>
23201         PR tree-optimization/110937
23202         PR tree-optimization/100798
23203         * match.pd (`a ? ~b : b`): Handle this
23204         case.
23206 2023-08-09  Uros Bizjak  <ubizjak@gmail.com>
23208         * config/i386/i386.opt (mpartial-vector-fp-math): Add dot.
23210 2023-08-09  Richard Ball  <richard.ball@arm.com>
23212         * config/aarch64/aarch64-cores.def (AARCH64_CORE): Add Cortex-A520 CPU.
23213         * config/aarch64/aarch64-tune.md: Regenerate.
23214         * doc/invoke.texi: Document Cortex-A520 CPU.
23216 2023-08-09  Carl Love  <cel@us.ibm.com>
23218         * config/rs6000/rs6000-builtins.def (vcmpneb, vcmpneh, vcmpnew):
23219         Move definitions to Altivec stanza.
23220         * config/rs6000/altivec.md (vcmpneb, vcmpneh, vcmpnew): New
23221         define_expand.
23223 2023-08-09  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
23225         PR target/110950
23226         * config/riscv/riscv-v.cc (expand_const_vector): Add NPATTERNS = 1
23227         stepped vector support.
23229 2023-08-09  liuhongt  <hongtao.liu@intel.com>
23231         * common/config/i386/cpuinfo.h (get_available_features):
23232         Rename local variable subleaf_level to max_subleaf_level.
23234 2023-08-09  Richard Biener  <rguenther@suse.de>
23236         PR rtl-optimization/110587
23237         * lra-assigns.cc (find_hard_regno_for_1): Re-order checks.
23239 2023-08-09  Kewen Lin  <linkw@linux.ibm.com>
23241         PR tree-optimization/110248
23242         * config/rs6000/rs6000.cc (rs6000_legitimate_address_p): Check if
23243         the given code is for ifn LEN_{LOAD,STORE}, if yes then make it not
23244         legitimate when outer code is PLUS.
23246 2023-08-09  Kewen Lin  <linkw@linux.ibm.com>
23248         PR tree-optimization/110248
23249         * recog.cc (memory_address_addr_space_p): Add one more argument ch of
23250         type code_helper and pass it to targetm.addr_space.legitimate_address_p
23251         instead of ERROR_MARK.
23252         (offsettable_address_addr_space_p): Update one function pointer with
23253         one more argument of type code_helper as its assignees
23254         memory_address_addr_space_p and strict_memory_address_addr_space_p
23255         have been adjusted, and adjust some call sites with ERROR_MARK.
23256         * recog.h (tree.h): New include header file for tree_code ERROR_MARK.
23257         (memory_address_addr_space_p): Adjust with one more unnamed argument
23258         of type code_helper with default ERROR_MARK.
23259         (strict_memory_address_addr_space_p): Likewise.
23260         * reload.cc (strict_memory_address_addr_space_p): Add one unnamed
23261         argument of type code_helper.
23262         * tree-ssa-address.cc (valid_mem_ref_p): Add one more argument ch of
23263         type code_helper and pass it to memory_address_addr_space_p.
23264         * tree-ssa-address.h (valid_mem_ref_p): Adjust the declaration with
23265         one more unnamed argument of type code_helper with default value
23266         ERROR_MARK.
23267         * tree-ssa-loop-ivopts.cc (get_address_cost): Use ERROR_MARK as code
23268         by default, change it with ifn code for USE_PTR_ADDRESS type use, and
23269         pass it to all valid_mem_ref_p calls.
23271 2023-08-09  Kewen Lin  <linkw@linux.ibm.com>
23273         PR tree-optimization/110248
23274         * coretypes.h (class code_helper): Add forward declaration.
23275         * doc/tm.texi: Regenerate.
23276         * lra-constraints.cc (valid_address_p): Call target hook
23277         targetm.addr_space.legitimate_address_p with an extra parameter
23278         ERROR_MARK as its prototype changes.
23279         * recog.cc (memory_address_addr_space_p): Likewise.
23280         * reload.cc (strict_memory_address_addr_space_p): Likewise.
23281         * target.def (legitimate_address_p, addr_space.legitimate_address_p):
23282         Extend with one more argument of type code_helper, update the
23283         documentation accordingly.
23284         * targhooks.cc (default_legitimate_address_p): Adjust for the
23285         new code_helper argument.
23286         (default_addr_space_legitimate_address_p): Likewise.
23287         * targhooks.h (default_legitimate_address_p): Likewise.
23288         (default_addr_space_legitimate_address_p): Likewise.
23289         * config/aarch64/aarch64.cc (aarch64_legitimate_address_hook_p): Adjust
23290         with extra unnamed code_helper argument with default ERROR_MARK.
23291         * config/alpha/alpha.cc (alpha_legitimate_address_p): Likewise.
23292         * config/arc/arc.cc (arc_legitimate_address_p): Likewise.
23293         * config/arm/arm-protos.h (arm_legitimate_address_p): Likewise.
23294         (tree.h): New include for tree_code ERROR_MARK.
23295         * config/arm/arm.cc (arm_legitimate_address_p): Adjust with extra
23296         unnamed code_helper argument with default ERROR_MARK.
23297         * config/avr/avr.cc (avr_addr_space_legitimate_address_p): Likewise.
23298         * config/bfin/bfin.cc (bfin_legitimate_address_p): Likewise.
23299         * config/bpf/bpf.cc (bpf_legitimate_address_p): Likewise.
23300         * config/c6x/c6x.cc (c6x_legitimate_address_p): Likewise.
23301         * config/cris/cris-protos.h (cris_legitimate_address_p): Likewise.
23302         (tree.h): New include for tree_code ERROR_MARK.
23303         * config/cris/cris.cc (cris_legitimate_address_p): Adjust with extra
23304         unnamed code_helper argument with default ERROR_MARK.
23305         * config/csky/csky.cc (csky_legitimate_address_p): Likewise.
23306         * config/epiphany/epiphany.cc (epiphany_legitimate_address_p):
23307         Likewise.
23308         * config/frv/frv.cc (frv_legitimate_address_p): Likewise.
23309         * config/ft32/ft32.cc (ft32_addr_space_legitimate_address_p): Likewise.
23310         * config/gcn/gcn.cc (gcn_addr_space_legitimate_address_p): Likewise.
23311         * config/h8300/h8300.cc (h8300_legitimate_address_p): Likewise.
23312         * config/i386/i386.cc (ix86_legitimate_address_p): Likewise.
23313         * config/ia64/ia64.cc (ia64_legitimate_address_p): Likewise.
23314         * config/iq2000/iq2000.cc (iq2000_legitimate_address_p): Likewise.
23315         * config/lm32/lm32.cc (lm32_legitimate_address_p): Likewise.
23316         * config/loongarch/loongarch.cc (loongarch_legitimate_address_p):
23317         Likewise.
23318         * config/m32c/m32c.cc (m32c_legitimate_address_p): Likewise.
23319         (m32c_addr_space_legitimate_address_p): Likewise.
23320         * config/m32r/m32r.cc (m32r_legitimate_address_p): Likewise.
23321         * config/m68k/m68k.cc (m68k_legitimate_address_p): Likewise.
23322         * config/mcore/mcore.cc (mcore_legitimate_address_p): Likewise.
23323         * config/microblaze/microblaze-protos.h (tree.h): New include for
23324         tree_code ERROR_MARK.
23325         (microblaze_legitimate_address_p): Adjust with extra unnamed
23326         code_helper argument with default ERROR_MARK.
23327         * config/microblaze/microblaze.cc (microblaze_legitimate_address_p):
23328         Likewise.
23329         * config/mips/mips.cc (mips_legitimate_address_p): Likewise.
23330         * config/mmix/mmix.cc (mmix_legitimate_address_p): Likewise.
23331         * config/mn10300/mn10300.cc (mn10300_legitimate_address_p): Likewise.
23332         * config/moxie/moxie.cc (moxie_legitimate_address_p): Likewise.
23333         * config/msp430/msp430.cc (msp430_legitimate_address_p): Likewise.
23334         (msp430_addr_space_legitimate_address_p): Adjust with extra code_helper
23335         argument with default ERROR_MARK and adjust the call to function
23336         msp430_legitimate_address_p.
23337         * config/nds32/nds32.cc (nds32_legitimate_address_p): Adjust with extra
23338         unnamed code_helper argument with default ERROR_MARK.
23339         * config/nios2/nios2.cc (nios2_legitimate_address_p): Likewise.
23340         * config/nvptx/nvptx.cc (nvptx_legitimate_address_p): Likewise.
23341         * config/or1k/or1k.cc (or1k_legitimate_address_p): Likewise.
23342         * config/pa/pa.cc (pa_legitimate_address_p): Likewise.
23343         * config/pdp11/pdp11.cc (pdp11_legitimate_address_p): Likewise.
23344         * config/pru/pru.cc (pru_addr_space_legitimate_address_p): Likewise.
23345         * config/riscv/riscv.cc (riscv_legitimate_address_p): Likewise.
23346         * config/rl78/rl78-protos.h (rl78_as_legitimate_address): Likewise.
23347         (tree.h): New include for tree_code ERROR_MARK.
23348         * config/rl78/rl78.cc (rl78_as_legitimate_address): Adjust with
23349         extra unnamed code_helper argument with default ERROR_MARK.
23350         * config/rs6000/rs6000.cc (rs6000_legitimate_address_p): Likewise.
23351         (rs6000_debug_legitimate_address_p): Adjust with extra code_helper
23352         argument and adjust the call to function rs6000_legitimate_address_p.
23353         * config/rx/rx.cc (rx_is_legitimate_address): Adjust with extra
23354         unnamed code_helper argument with default ERROR_MARK.
23355         * config/s390/s390.cc (s390_legitimate_address_p): Likewise.
23356         * config/sh/sh.cc (sh_legitimate_address_p): Likewise.
23357         * config/sparc/sparc.cc (sparc_legitimate_address_p): Likewise.
23358         * config/v850/v850.cc (v850_legitimate_address_p): Likewise.
23359         * config/vax/vax.cc (vax_legitimate_address_p): Likewise.
23360         * config/visium/visium.cc (visium_legitimate_address_p): Likewise.
23361         * config/xtensa/xtensa.cc (xtensa_legitimate_address_p): Likewise.
23362         * config/stormy16/stormy16-protos.h (xstormy16_legitimate_address_p):
23363         Likewise.
23364         (tree.h): New include for tree_code ERROR_MARK.
23365         * config/stormy16/stormy16.cc (xstormy16_legitimate_address_p):
23366         Adjust with extra unnamed code_helper argument with default
23367         ERROR_MARK.
23369 2023-08-09  liuhongt  <hongtao.liu@intel.com>
23371         * common/config/i386/cpuinfo.h (get_available_features): Check
23372         EAX for valid subleaf before use CPUID.
23374 2023-08-08  Jeff Law  <jlaw@ventanamicro.com>
23376         * config/riscv/riscv.cc (riscv_expand_conditional_move): Use word_mode
23377         for the temporary when canonicalizing the condition.
23379 2023-08-08  Cupertino Miranda  <cupertino.miranda@oracle.com>
23381         * config/bpf/core-builtins.cc: Cleaned include headers.
23382         (struct cr_builtins): Added GTY.
23383         (cr_builtins_ref): Created.
23384         (builtins_data) Changed to GC root.
23385         (allocate_builtin_data): Changed.
23386         Included gt-core-builtins.h.
23387         * config/bpf/coreout.cc: (bpf_core_extra) Added GTY.
23388         (bpf_core_extra_ref): Created.
23389         (bpf_comment_info): Changed to GC root.
23390         (bpf_core_reloc_add, output_btfext_header, btf_ext_init): Changed.
23392 2023-08-08  Uros Bizjak  <ubizjak@gmail.com>
23394         PR target/110832
23395         * config/i386/i386.opt (mpartial-vector-fp-math): New option.
23396         * config/i386/mmx.md (movq_<mode>_to_sse): Do not sanitize
23397         upper part of V2SFmode register with -fno-trapping-math.
23398         (<plusminusmult:insn>v2sf3): Enable for ix86_partial_vec_fp_math.
23399         (divv2sf3): Ditto.
23400         (<smaxmin:code>v2sf3): Ditto.
23401         (sqrtv2sf2): Ditto.
23402         (*mmx_haddv2sf3_low): Ditto.
23403         (*mmx_hsubv2sf3_low): Ditto.
23404         (vec_addsubv2sf3): Ditto.
23405         (vec_cmpv2sfv2si): Ditto.
23406         (vcond<V2FI:mode>v2sf): Ditto.
23407         (fmav2sf4): Ditto.
23408         (fmsv2sf4): Ditto.
23409         (fnmav2sf4): Ditto.
23410         (fnmsv2sf4): Ditto.
23411         (fix_truncv2sfv2si2): Ditto.
23412         (fixuns_truncv2sfv2si2): Ditto.
23413         (floatv2siv2sf2): Ditto.
23414         (floatunsv2siv2sf2): Ditto.
23415         (nearbyintv2sf2): Ditto.
23416         (rintv2sf2): Ditto.
23417         (lrintv2sfv2si2): Ditto.
23418         (ceilv2sf2): Ditto.
23419         (lceilv2sfv2si2): Ditto.
23420         (floorv2sf2): Ditto.
23421         (lfloorv2sfv2si2): Ditto.
23422         (btruncv2sf2): Ditto.
23423         (roundv2sf2): Ditto.
23424         (lroundv2sfv2si2): Ditto.
23425         * doc/invoke.texi (x86 Options): Document
23426         -mpartial-vector-fp-math option.
23428 2023-08-08  Andrew Pinski  <apinski@marvell.com>
23430         PR tree-optimization/103281
23431         PR tree-optimization/28794
23432         * vr-values.cc (simplify_using_ranges::simplify_cond_using_ranges_1): Split out
23433         majority to ...
23434         (simplify_using_ranges::simplify_compare_using_ranges_1): Here.
23435         (simplify_using_ranges::simplify_casted_cond): Rename to ...
23436         (simplify_using_ranges::simplify_casted_compare): This
23437         and change arguments to take op0 and op1.
23438         (simplify_using_ranges::simplify_compare_assign_using_ranges_1): New method.
23439         (simplify_using_ranges::simplify): For tcc_comparison assignments call
23440         simplify_compare_assign_using_ranges_1.
23441         * vr-values.h (simplify_using_ranges): Add
23442         new methods, simplify_compare_using_ranges_1 and simplify_compare_assign_using_ranges_1.
23443         Rename simplify_casted_cond and simplify_casted_compare and
23444         update argument types.
23446 2023-08-08  Andrzej Turko  <andrzej.turko@gmail.com>
23448         * genmatch.cc: Log line numbers indirectly.
23450 2023-08-08  Andrzej Turko  <andrzej.turko@gmail.com>
23452         * genmatch.cc: Make sinfo map ordered.
23453         * Makefile.in: Require the ordered map header for genmatch.o.
23455 2023-08-08  Andrzej Turko  <andrzej.turko@gmail.com>
23457         * ordered-hash-map.h: Add get_or_insert.
23458         * ordered-hash-map-tests.cc: Use get_or_insert in tests.
23460 2023-08-08  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
23462         * config/riscv/autovec.md (cond_<optab><mode>): New pattern.
23463         (cond_len_<optab><mode>): Ditto.
23464         (cond_fma<mode>): Ditto.
23465         (cond_len_fma<mode>): Ditto.
23466         (cond_fnma<mode>): Ditto.
23467         (cond_len_fnma<mode>): Ditto.
23468         (cond_fms<mode>): Ditto.
23469         (cond_len_fms<mode>): Ditto.
23470         (cond_fnms<mode>): Ditto.
23471         (cond_len_fnms<mode>): Ditto.
23472         * config/riscv/riscv-protos.h (riscv_get_v_regno_alignment): Export
23473         global.
23474         (enum insn_type): Add new enum type.
23475         (prepare_ternary_operands): New function.
23476         * config/riscv/riscv-v.cc (emit_vlmax_masked_fp_mu_insn): Ditto.
23477         (emit_nonvlmax_tumu_insn): Ditto.
23478         (emit_nonvlmax_fp_tumu_insn): Ditto.
23479         (expand_cond_len_binop): Add condtional operations.
23480         (expand_cond_len_ternop): Ditto.
23481         (prepare_ternary_operands): New function.
23482         * config/riscv/riscv.cc (riscv_memmodel_needs_amo_release): Export
23483         riscv_get_v_regno_alignment as global scope.
23484         * config/riscv/vector.md: Fix ternary bugs.
23486 2023-08-08  Richard Biener  <rguenther@suse.de>
23488         PR tree-optimization/49955
23489         * tree-vectorizer.h (_slp_instance::remain_stmts): New.
23490         (SLP_INSTANCE_REMAIN_STMTS): Likewise.
23491         * tree-vect-slp.cc (vect_free_slp_instance): Release
23492         SLP_INSTANCE_REMAIN_STMTS.
23493         (vect_build_slp_instance): Make the number of lanes of
23494         a BB reduction even.
23495         (vectorize_slp_instance_root_stmt): Handle unvectorized
23496         defs of a BB reduction.
23498 2023-08-08  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
23500         * internal-fn.cc (get_len_internal_fn): New function.
23501         (DEF_INTERNAL_COND_FN): Ditto.
23502         (DEF_INTERNAL_SIGNED_COND_FN): Ditto.
23503         * internal-fn.h (get_len_internal_fn): Ditto.
23504         * tree-vect-stmts.cc (vectorizable_call): Add CALL auto-vectorization.
23506 2023-08-08  Richard Biener  <rguenther@suse.de>
23508         PR tree-optimization/110924
23509         * tree-ssa-live.h (virtual_operand_live): Update comment.
23510         * tree-ssa-live.cc (virtual_operand_live::get_live_in): Remove
23511         optimization, look at each predecessor.
23512         * tree-ssa-sink.cc (pass_sink_code::execute): Mark backedges.
23514 2023-08-08  yulong  <shiyulong@iscas.ac.cn>
23516         * config/riscv/riscv-v.cc (slide1_sew64_helper): Modify.
23518 2023-08-08  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
23520         * config/riscv/autovec-vls.md (<optab><mode>2): Add VLS neg.
23521         * config/riscv/vector.md: Ditto.
23523 2023-08-08  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
23525         * config/riscv/autovec.md: Add VLS shift.
23527 2023-08-07  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
23529         * config/riscv/autovec-vls.md (<optab><mode>3): Add VLS modes.
23530         * config/riscv/vector-iterators.md: Ditto.
23531         * config/riscv/vector.md: Ditto.
23533 2023-08-07  Jonathan Wakely  <jwakely@redhat.com>
23535         * config/i386/i386.cc (ix86_invalid_conversion): Fix grammar.
23537 2023-08-07  Nick Alcock  <nick.alcock@oracle.com>
23539         * configure: Regenerate.
23541 2023-08-07  John Ericson  <git@JohnEricson.me>
23543         * configure: Regenerate.
23545 2023-08-07  Alan Modra  <amodra@gmail.com>
23547         * configure: Regenerate.
23549 2023-08-07  Alexander von Gluck IV  <kallisti5@unixzen.com>
23551         * configure: Regenerate.
23553 2023-08-07  Nick Alcock  <nick.alcock@oracle.com>
23555         * configure: Regenerate.
23557 2023-08-07  Nick Alcock  <nick.alcock@oracle.com>
23559         * configure: Regenerate.
23561 2023-08-07  H.J. Lu  <hjl.tools@gmail.com>
23563         * configure: Regenerate.
23565 2023-08-07  H.J. Lu  <hjl.tools@gmail.com>
23567         * configure: Regenerate.
23569 2023-08-07  Jeff Law  <jlaw@ventanamicro.com>
23571         * config/riscv/riscv.cc (riscv_expand_conditional_move): Allow
23572         VOIDmode operands to conditional before canonicalization.
23574 2023-08-07  Manolis Tsamis  <manolis.tsamis@vrull.eu>
23576         * regcprop.cc (maybe_copy_reg_attrs): Remove unnecessary function.
23577         (find_oldest_value_reg): Inline stack_pointer_rtx check.
23578         (copyprop_hardreg_forward_1): Inline stack_pointer_rtx check.
23580 2023-08-07  Martin Jambor  <mjambor@suse.cz>
23582         PR ipa/110378
23583         * ipa-param-manipulation.h (class ipa_param_body_adjustments): New
23584         members get_ddef_if_exists_and_is_used and mark_clobbers_dead.
23585         * ipa-sra.cc (isra_track_scalar_value_uses): Ignore clobbers.
23586         (ptr_parm_has_nonarg_uses): Likewise.
23587         * ipa-param-manipulation.cc
23588         (ipa_param_body_adjustments::get_ddef_if_exists_and_is_used): New.
23589         (ipa_param_body_adjustments::mark_dead_statements): Move initial
23590         checks to get_ddef_if_exists_and_is_used.
23591         (ipa_param_body_adjustments::mark_clobbers_dead): New.
23592         (ipa_param_body_adjustments::common_initialization): Call
23593         mark_clobbers_dead when splitting.
23595 2023-08-07  Raphael Zinsly  <rzinsly@ventanamicro.com>
23597         * config/riscv/riscv.cc (riscv_expand_int_scc): Add invert_ptr
23598         as an argument and pass it to riscv_emit_int_order_test.
23599         (riscv_expand_conditional_move): Handle cases where the condition
23600         is not EQ/NE or the second argument to the conditional is not
23601         (const_int 0).
23602         * config/riscv/riscv-protos.h (riscv_expand_int_scc): Update prototype.
23603         Co-authored-by: Jeff Law <jlaw@ventanamicro.com>
23605 2023-08-07  Andrew Pinski  <apinski@marvell.com>
23607         PR tree-optimization/109959
23608         * match.pd (`(a > 1) ? 0 : (cast)a`, `(a <= 1) & (cast)a`):
23609         New patterns.
23611 2023-08-07  Richard Biener  <rguenther@suse.de>
23613         * tree-ssa-sink.cc (pass_sink_code::execute): Do not
23614         calculate post-dominators.  Calculate RPO on the inverted
23615         graph and process blocks in that order.
23617 2023-08-07  liuhongt  <hongtao.liu@intel.com>
23619         PR target/110926
23620         * config/i386/i386-protos.h
23621         (vpternlog_redundant_operand_mask): Adjust parameter type.
23622         * config/i386/i386.cc (vpternlog_redundant_operand_mask): Use
23623         INTVAL instead of XINT, also adjust parameter type from rtx*
23624         to rtx since the function only needs operands[4] in vpternlog
23625         pattern.
23626         (substitute_vpternlog_operands): Pass operands[4] instead of
23627         operands to vpternlog_redundant_operand_mask.
23628         * config/i386/sse.md: Ditto.
23630 2023-08-07  Richard Biener  <rguenther@suse.de>
23632         * tree-vect-slp.cc (vect_slp_region): Save/restore vect_location
23633         around dumping code.
23635 2023-08-07  liuhongt  <hongtao.liu@intel.com>
23637         PR target/110762
23638         * config/i386/mmx.md (<insn><mode>3): Changed from define_insn
23639         to define_expand and break into ..
23640         (<insn>v4hf3): .. this.
23641         (divv4hf3): .. this.
23642         (<insn>v2hf3): .. this.
23643         (divv2hf3): .. this.
23644         (movd_v2hf_to_sse): New define_expand.
23645         (movq_<mode>_to_sse): Extend to V4HFmode.
23646         (mmxdoublevecmode): Ditto.
23647         (V2FI_V4HF): New mode iterator.
23648         * config/i386/sse.md (*vec_concatv4sf): Extend to hanlde V8HF
23649         by using mode iterator V4SF_V8HF, renamed to ..
23650         (*vec_concat<mode>): .. this.
23651         (*vec_concatv4sf_0): Extend to handle V8HF by using mode
23652         iterator V4SF_V8HF, renamed to ..
23653         (*vec_concat<mode>_0): .. this.
23654         (*vec_concatv8hf_movss): New define_insn.
23655         (V4SF_V8HF): New mode iterator.
23657 2023-08-07  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
23659         * tree-vect-patterns.cc (vect_recog_over_widening_pattern): Add op vectype.
23661 2023-08-07  Jan Beulich  <jbeulich@suse.com>
23663         * config/i386/mmx.md (*mmx_pinsrd): Drop "prefix_data16".
23664         (*mmx_pinsrb): Likewise.
23665         (*mmx_pextrb): Likewise.
23666         (*mmx_pextrb_zext): Likewise.
23667         (mmx_pshufbv8qi3): Likewise.
23668         (mmx_pshufbv4qi3): Likewise.
23669         (mmx_pswapdv2si2): Likewise.
23670         (*pinsrb): Likewise.
23671         (*pextrb): Likewise.
23672         (*pextrb_zext): Likewise.
23673         * config/i386/sse.md (*sse4_1_mulv2siv2di3<mask_name>): Likewise.
23674         (*sse2_eq<mode>3): Likewise.
23675         (*sse2_gt<mode>3): Likewise.
23676         (<sse2p4_1>_pinsr<ssemodesuffix>): Likewise.
23677         (*vec_extract<mode>): Likewise.
23678         (*vec_extract<PEXTR_MODE12:mode>_zext): Likewise.
23679         (*vec_extractv16qi_zext): Likewise.
23680         (ssse3_ph<plusminus_mnemonic>wv8hi3): Likewise.
23681         (ssse3_pmaddubsw128): Likewise.
23682         (*<ssse3_avx2>_pmulhrsw<mode>3<mask_name>): Likewise.
23683         (<ssse3_avx2>_pshufb<mode>3<mask_name>): Likewise.
23684         (<ssse3_avx2>_psign<mode>3): Likewise.
23685         (<ssse3_avx2>_palignr<mode>): Likewise.
23686         (*abs<mode>2): Likewise.
23687         (sse4_2_pcmpestr): Likewise.
23688         (sse4_2_pcmpestri): Likewise.
23689         (sse4_2_pcmpestrm): Likewise.
23690         (sse4_2_pcmpestr_cconly): Likewise.
23691         (sse4_2_pcmpistr): Likewise.
23692         (sse4_2_pcmpistri): Likewise.
23693         (sse4_2_pcmpistrm): Likewise.
23694         (sse4_2_pcmpistr_cconly): Likewise.
23695         (vgf2p8affineinvqb_<mode><mask_name>): Likewise.
23696         (vgf2p8affineqb_<mode><mask_name>): Likewise.
23697         (vgf2p8mulb_<mode><mask_name>): Likewise.
23698         (*<code>v8hi3 [smaxmin]): Drop "prefix_data16" and
23699         "prefix_extra".
23700         (*<code>v16qi3 [umaxmin]): Likewise.
23702 2023-08-07  Jan Beulich  <jbeulich@suse.com>
23704         * config/i386/i386.md (sse4_1_round<mode>2): Make
23705         "length_immediate" uniformly 1.
23706         * config/i386/mmx.md (mmx_pblendvb_v8qi): Likewise.
23707         (mmx_pblendvb_<mode>): Likewise.
23709 2023-08-07  Jan Beulich  <jbeulich@suse.com>
23711         * config/i386/sse.md
23712         (<avx512>_<complexopname>_<mode><maskc_name><round_name>): Add
23713         "prefix" attribute.
23714         (avx512fp16_<complexopname>sh_v8hf<mask_scalarc_name><round_scalarcz_name>):
23715         Likewise.
23717 2023-08-07  Jan Beulich  <jbeulich@suse.com>
23719         * config/i386/sse.md (xop_phadd<u>bw): Add "prefix",
23720         "prefix_extra", and "mode" attributes.
23721         (xop_phadd<u>bd): Likewise.
23722         (xop_phadd<u>bq): Likewise.
23723         (xop_phadd<u>wd): Likewise.
23724         (xop_phadd<u>wq): Likewise.
23725         (xop_phadd<u>dq): Likewise.
23726         (xop_phsubbw): Likewise.
23727         (xop_phsubwd): Likewise.
23728         (xop_phsubdq): Likewise.
23729         (xop_rotl<mode>3): Add "prefix" and "prefix_extra" attributes.
23730         (xop_rotr<mode>3): Likewise.
23731         (xop_frcz<mode>2): Likewise.
23732         (*xop_vmfrcz<mode>2): Likewise.
23733         (xop_vrotl<mode>3): Add "prefix" attribute. Change
23734         "prefix_extra" to 1.
23735         (xop_sha<mode>3): Likewise.
23736         (xop_shl<mode>3): Likewise.
23738 2023-08-07  Jan Beulich  <jbeulich@suse.com>
23740         * config/i386/sse.md
23741         (*<avx512>_eq<mode>3<mask_scalar_merge_name>_1): Drop
23742         "prefix_extra".
23743         (avx512dq_vextract<shuffletype>64x2_1_mask): Likewise.
23744         (*avx512dq_vextract<shuffletype>64x2_1): Likewise.
23745         (avx512f_vextract<shuffletype>32x4_1_mask): Likewise.
23746         (*avx512f_vextract<shuffletype>32x4_1): Likewise.
23747         (vec_extract_lo_<mode>_mask [AVX512 forms]): Likewise.
23748         (vec_extract_lo_<mode> [AVX512 forms]): Likewise.
23749         (vec_extract_hi_<mode>_mask [AVX512 forms]): Likewise.
23750         (vec_extract_hi_<mode> [AVX512 forms]): Likewise.
23751         (@vec_extract_lo_<mode> [AVX512 forms]): Likewise.
23752         (@vec_extract_hi_<mode> [AVX512 forms]): Likewise.
23753         (vec_extract_lo_v64qi): Likewise.
23754         (vec_extract_hi_v64qi): Likewise.
23755         (*vec_widen_umult_even_v16si<mask_name>): Likewise.
23756         (*vec_widen_smult_even_v16si<mask_name>): Likewise.
23757         (*avx512f_<code><mode>3<mask_name>): Likewise.
23758         (*vec_extractv4ti): Likewise.
23759         (avx512bw_<code>v32qiv32hi2<mask_name>): Likewise.
23760         (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1): Likewise.
23761         Add "length_immediate".
23763 2023-08-07  Jan Beulich  <jbeulich@suse.com>
23765         * config/i386/i386.md (@rdrand<mode>): Add "prefix_0f". Drop
23766         "prefix_extra".
23767         (@rdseed<mode>): Likewise.
23768         * config/i386/mmx.md (<code><mode>3 [smaxmin and umaxmin cases]):
23769         Adjust "prefix_extra".
23770         * config/i386/sse.md (@vec_set<mode>_0): Likewise.
23771         (*sse4_1_<code><mode>3<mask_name>): Likewise.
23772         (*avx2_eq<mode>3): Likewise.
23773         (avx2_gt<mode>3): Likewise.
23774         (<sse2p4_1>_pinsr<ssemodesuffix>): Likewise.
23775         (*vec_extract<mode>): Likewise.
23776         (<vi8_sse4_1_avx2_avx512>_movntdqa): Likewise.
23778 2023-08-07  Jan Beulich  <jbeulich@suse.com>
23780         * config/i386/i386.md (rd<fsgs>base<mode>): Add "prefix_0f" and
23781         "prefix_rep". Drop "prefix_extra".
23782         (wr<fsgs>base<mode>): Likewise.
23783         (ptwrite<mode>): Likewise.
23785 2023-08-07  Jan Beulich  <jbeulich@suse.com>
23787         * config/i386/i386.md (isa): Move up.
23788         (length_immediate): Handle "fma4".
23789         (prefix): Handle "ssemuladd".
23790         * config/i386/sse.md (*fma_fmadd_<mode>): Add "prefix" attribute.
23791         (<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name><round_name>):
23792         Likewise.
23793         (<avx512>_fmadd_<mode>_mask<round_name>): Likewise.
23794         (<avx512>_fmadd_<mode>_mask3<round_name>): Likewise.
23795         (<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name><round_name>):
23796         Likewise.
23797         (<avx512>_fmsub_<mode>_mask<round_name>): Likewise.
23798         (<avx512>_fmsub_<mode>_mask3<round_name>): Likewise.
23799         (*fma_fnmadd_<mode>): Likewise.
23800         (<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name><round_name>):
23801         Likewise.
23802         (<avx512>_fnmadd_<mode>_mask<round_name>): Likewise.
23803         (<avx512>_fnmadd_<mode>_mask3<round_name>): Likewise.
23804         (<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name><round_name>):
23805         Likewise.
23806         (<avx512>_fnmsub_<mode>_mask<round_name>): Likewise.
23807         (<avx512>_fnmsub_<mode>_mask3<round_name>): Likewise.
23808         (<sd_mask_codefor>fma_fmaddsub_<mode><sd_maskz_name><round_name>):
23809         Likewise.
23810         (<avx512>_fmaddsub_<mode>_mask<round_name>): Likewise.
23811         (<avx512>_fmaddsub_<mode>_mask3<round_name>): Likewise.
23812         (<sd_mask_codefor>fma_fmsubadd_<mode><sd_maskz_name><round_name>):
23813         Likewise.
23814         (<avx512>_fmsubadd_<mode>_mask<round_name>): Likewise.
23815         (<avx512>_fmsubadd_<mode>_mask3<round_name>): Likewise.
23816         (*fmai_fmadd_<mode>): Likewise.
23817         (*fmai_fmsub_<mode>): Likewise.
23818         (*fmai_fnmadd_<mode><round_name>): Likewise.
23819         (*fmai_fnmsub_<mode><round_name>): Likewise.
23820         (avx512f_vmfmadd_<mode>_mask<round_name>): Likewise.
23821         (avx512f_vmfmadd_<mode>_mask3<round_name>): Likewise.
23822         (avx512f_vmfmadd_<mode>_maskz_1<round_name>): Likewise.
23823         (*avx512f_vmfmsub_<mode>_mask<round_name>): Likewise.
23824         (avx512f_vmfmsub_<mode>_mask3<round_name>): Likewise.
23825         (*avx512f_vmfmsub_<mode>_maskz_1<round_name>): Likewise.
23826         (avx512f_vmfnmadd_<mode>_mask<round_name>): Likewise.
23827         (avx512f_vmfnmadd_<mode>_mask3<round_name>): Likewise.
23828         (avx512f_vmfnmadd_<mode>_maskz_1<round_name>): Likewise.
23829         (*avx512f_vmfnmsub_<mode>_mask<round_name>): Likewise.
23830         (*avx512f_vmfnmsub_<mode>_mask3<round_name>): Likewise.
23831         (*avx512f_vmfnmsub_<mode>_maskz_1<round_name>): Likewise.
23832         (*fma4i_vmfmadd_<mode>): Likewise.
23833         (*fma4i_vmfmsub_<mode>): Likewise.
23834         (*fma4i_vmfnmadd_<mode>): Likewise.
23835         (*fma4i_vmfnmsub_<mode>): Likewise.
23836         (fma_<complexopname>_<mode><sdc_maskz_name><round_name>): Likewise.
23837         (<avx512>_<complexopname>_<mode>_mask<round_name>): Likewise.
23838         (avx512fp16_fma_<complexopname>sh_v8hf<mask_scalarcz_name><round_scalarcz_name>):
23839         Likewise.
23840         (avx512fp16_<complexopname>sh_v8hf_mask<round_name>): Likewise.
23841         (xop_p<macs><ssemodesuffix><ssemodesuffix>): Likewise.
23842         (xop_p<macs>dql): Likewise.
23843         (xop_p<macs>dqh): Likewise.
23844         (xop_p<macs>wd): Likewise.
23845         (xop_p<madcs>wd): Likewise.
23846         (fma_<complexpairopname>_<mode>_pair): Likewise. Add "mode" attribute.
23848 2023-08-07  Jan Beulich  <jbeulich@suse.com>
23850         * config/i386/i386.md (length_immediate): Handle "sse4arg".
23851         (prefix): Likewise.
23852         (*xop_pcmov_<mode>): Add "mode" attribute.
23853         * config/i386/mmx.md (*xop_maskcmp<mode>3): Drop "prefix_data16",
23854         "prefix_rep", "prefix_extra", and "length_immediate" attributes.
23855         (*xop_maskcmp_uns<mode>3): Likewise. Switch "type" to "sse4arg".
23856         (*xop_pcmov_<mode>): Add "mode" attribute.
23857         * config/i386/sse.md (xop_pcmov_<mode><avxsizesuffix>): Add "mode"
23858         attribute.
23859         (xop_maskcmp<mode>3): Drop "prefix_data16", "prefix_rep",
23860         "prefix_extra", and "length_immediate" attributes.
23861         (xop_maskcmp_uns<mode>3): Likewise. Switch "type" to "sse4arg".
23862         (xop_maskcmp_uns2<mode>3): Drop "prefix_data16", "prefix_extra",
23863         and "length_immediate" attributes. Switch "type" to "sse4arg".
23864         (xop_pcom_tf<mode>3): Likewise.
23865         (xop_vpermil2<mode>3): Drop "length_immediate" attribute.
23867 2023-08-07  Jan Beulich  <jbeulich@suse.com>
23869         * config/i386/i386.md (prefix_extra): Correct comment. Fold
23870         cases yielding 2 into ones yielding 1.
23872 2023-08-07  Jan Hubicka  <jh@suse.cz>
23874         PR tree-optimization/106293
23875         * tree-vect-loop-manip.cc (vect_loop_versioning): Fix profile update.
23876         * tree-vect-loop.cc (vect_transform_loop): Likewise.
23878 2023-08-07  Andrew Pinski  <apinski@marvell.com>
23880         PR tree-optimization/96695
23881         * match.pd (min_value, max_value): Extend to
23882         pointer types too.
23884 2023-08-06  Jan Hubicka  <jh@suse.cz>
23886         * config/i386/cpuid.h (__get_cpuid_count, __get_cpuid_max): Add
23887         __builtin_expect that CPU likely supports cpuid.
23889 2023-08-06  Jan Hubicka  <jh@suse.cz>
23891         * tree-loop-distribution.cc (loop_distribution::execute): Disable
23892         distribution for loops with estimated iterations 0.
23894 2023-08-06  Jan Hubicka  <jh@suse.cz>
23896         * tree-vect-loop-manip.cc (vect_do_peeling): Fix profile update of peeled epilogues.
23898 2023-08-04  Xiao Zeng  <zengxiao@eswincomputing.com>
23900         * config/riscv/riscv.cc (riscv_expand_conditional_move): Recognize
23901         more Zicond patterns.  Fix whitespace typo.
23902         (riscv_rtx_costs): Remove accidental code duplication.
23903         Co-authored-by: Jeff Law <jlaw@ventanamicro.com>
23905 2023-08-04  Yan Simonaytes  <simonaytes.yan@ispras.ru>
23907         PR target/110202
23908         * config/i386/i386-protos.h
23909         (vpternlog_redundant_operand_mask): Declare.
23910         (substitute_vpternlog_operands): Declare.
23911         * config/i386/i386.cc
23912         (vpternlog_redundant_operand_mask): New helper.
23913         (substitute_vpternlog_operands): New function.  Use them...
23914         * config/i386/sse.md: ... here in new VPTERNLOG define_splits.
23916 2023-08-04  Roger Sayle  <roger@nextmovesoftware.com>
23918         * expmed.cc (extract_bit_field_1): Document that an UNSIGNEDP
23919         value of -1 is equivalent to don't care.
23920         (extract_integral_bit_field): Indicate that we don't require
23921         the most significant word to be zero extended, if we're about
23922         to sign extend it.
23923         (extract_fixed_bit_field_1): Document that an UNSIGNEDP value
23924         of -1 is equivalent to don't care.  Don't clear the most
23925         significant bits with AND mask when UNSIGNEDP is -1.
23927 2023-08-04  Roger Sayle  <roger@nextmovesoftware.com>
23929         * config/i386/sse.md (define_split): Convert highpart:DF extract
23930         from V2DFmode register into a sse2_storehpd instruction.
23931         (define_split): Likewise, convert lowpart:DF extract from V2DF
23932         register into a sse2_storelpd instruction.
23934 2023-08-04  Qing Zhao  <qing.zhao@oracle.com>
23936         * doc/invoke.texi (-Wflex-array-member-not-at-end): Document
23937         new option.
23939 2023-08-04  Vladimir N. Makarov  <vmakarov@redhat.com>
23941         * lra-lives.cc (process_bb_lives): Check input insn pattern hard regs
23942         against early clobber hard regs.
23944 2023-08-04  Tamar Christina  <tamar.christina@arm.com>
23946         * doc/extend.texi: Document it.
23948 2023-08-04  Tamar Christina  <tamar.christina@arm.com>
23950         PR target/106346
23951         * config/aarch64/aarch64-simd.md (vec_widen_<sur>shiftl_lo_<mode>,
23952         vec_widen_<sur>shiftl_hi_<mode>): Remove.
23953         (aarch64_<sur>shll<mode>_internal): Renamed to...
23954         (aarch64_<su>shll<mode>): .. This.
23955         (aarch64_<sur>shll2<mode>_internal): Renamed to...
23956         (aarch64_<su>shll2<mode>): .. This.
23957         (aarch64_<sur>shll_n<mode>, aarch64_<sur>shll2_n<mode>): Re-use new
23958         optabs.
23959         * config/aarch64/constraints.md (D2, DL): New.
23960         * config/aarch64/predicates.md (aarch64_simd_shll_imm_vec): New.
23962 2023-08-04  Tamar Christina  <tamar.christina@arm.com>
23964         * gensupport.cc (conlist): Support length 0 attribute.
23966 2023-08-04  Tamar Christina  <tamar.christina@arm.com>
23968         * config/aarch64/aarch64.cc (aarch64_bool_compound_p): New.
23969         (aarch64_adjust_stmt_cost, aarch64_vector_costs::count_ops): Use it.
23971 2023-08-04  Tamar Christina  <tamar.christina@arm.com>
23973         * config/aarch64/aarch64.cc (aarch64_multiply_add_p): Update handling
23974         of constants.
23975         (aarch64_adjust_stmt_cost): Use it.
23976         (aarch64_vector_costs::count_ops): Likewise.
23977         (aarch64_vector_costs::add_stmt_cost): Pass vinfo to
23978         aarch64_adjust_stmt_cost.
23980 2023-08-04  Richard Biener  <rguenther@suse.de>
23982         PR tree-optimization/110838
23983         * tree-vect-patterns.cc (vect_recog_over_widening_pattern):
23984         Fix right-shift value sanitizing.  Properly emit external
23985         def mangling in the preheader rather than in the pattern
23986         def sequence where it will fail vectorizing.
23988 2023-08-04  Matthew Malcomson  <matthew.malcomson@arm.com>
23990         PR middle-end/110316
23991         PR middle-end/9903
23992         * timevar.cc (NANOSEC_PER_SEC, TICKS_TO_NANOSEC,
23993         CLOCKS_TO_NANOSEC, nanosec_to_floating_sec, percent_of): New.
23994         (TICKS_TO_MSEC, CLOCKS_TO_MSEC): Remove these macros.
23995         (timer::validate_phases): Use integral arithmetic to check
23996         validity.
23997         (timer::print_row, timer::print): Convert from integral
23998         nanoseconds to floating point seconds before printing.
23999         (timer::all_zero): Change limit to nanosec count instead of
24000         fractional count of seconds.
24001         (make_json_for_timevar_time_def): Convert from integral
24002         nanoseconds to floating point seconds before recording.
24003         * timevar.h (struct timevar_time_def): Update all measurements
24004         to use uint64_t nanoseconds rather than seconds stored in a
24005         double.
24007 2023-08-04  Richard Biener  <rguenther@suse.de>
24009         PR tree-optimization/110838
24010         * match.pd (([rl]shift @0 out-of-bounds) -> zero): Restrict
24011         the arithmetic right-shift case to non-negative operands.
24013 2023-08-04  Pan Li  <pan2.li@intel.com>
24015         Revert:
24016         2023-08-04  Pan Li  <pan2.li@intel.com>
24018         * config/riscv/riscv-vector-builtins-bases.cc
24019         (class vfmacc_frm): New class for vfmacc frm.
24020         (vfmacc_frm_obj): New declaration.
24021         (BASE): Ditto.
24022         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24023         * config/riscv/riscv-vector-builtins-functions.def
24024         (vfmacc_frm): New function definition.
24025         * config/riscv/riscv-vector-builtins.cc
24026         (function_expander::use_ternop_insn): Add frm operand support.
24027         * config/riscv/vector.md: Add vfmuladd to frm_mode.
24029 2023-08-04  Pan Li  <pan2.li@intel.com>
24031         Revert:
24032         2023-08-04  Pan Li  <pan2.li@intel.com>
24034         * config/riscv/riscv-vector-builtins-bases.cc
24035         (class vfnmacc_frm): New class for vfnmacc.
24036         (vfnmacc_frm_obj): New declaration.
24037         (BASE): Ditto.
24038         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24039         * config/riscv/riscv-vector-builtins-functions.def
24040         (vfnmacc_frm): New function definition.
24042 2023-08-04  Pan Li  <pan2.li@intel.com>
24044         Revert:
24045         2023-08-04  Pan Li  <pan2.li@intel.com>
24047         * config/riscv/riscv-vector-builtins-bases.cc
24048         (class vfmsac_frm): New class for vfmsac frm.
24049         (vfmsac_frm_obj): New declaration.
24050         (BASE): Ditto.
24051         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24052         * config/riscv/riscv-vector-builtins-functions.def
24053         (vfmsac_frm): New function definition.
24055 2023-08-04  Pan Li  <pan2.li@intel.com>
24057         Revert:
24058         2023-08-04  Pan Li  <pan2.li@intel.com>
24060         * config/riscv/riscv-vector-builtins-bases.cc
24061         (class vfnmsac_frm): New class for vfnmsac frm.
24062         (vfnmsac_frm_obj): New declaration.
24063         (BASE): Ditto.
24064         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24065         * config/riscv/riscv-vector-builtins-functions.def
24066         (vfnmsac_frm): New function definition.
24068 2023-08-04  Georg-Johann Lay  <avr@gjlay.de>
24070         * config/avr/avr-mcus.def (avr64dd14, avr64dd20, avr64dd28, avr64dd32)
24071         (avr64ea28, avr64ea32, avr64ea48, attiny424, attiny426, attiny427)
24072         (attiny824, attiny826, attiny827, attiny1624, attiny1626, attiny1627)
24073         (attiny3224, attiny3226, attiny3227, avr16dd14, avr16dd20, avr16dd28)
24074         (avr16dd32, avr32dd14, avr32dd20, avr32dd28, avr32dd32)
24075         (attiny102, attiny104): New devices.
24076         * doc/avr-mmcu.texi: Regenerate.
24078 2023-08-04  Georg-Johann Lay  <avr@gjlay.de>
24080         * config/avr/avr-mcus.def (avr128d*, avr64d*): Fix their FLASH_SIZE
24081         and PM_OFFSET entries.
24083 2023-08-04  Andrew Pinski  <apinski@marvell.com>
24085         PR tree-optimization/110874
24086         * gimple-match-head.cc (gimple_bit_not_with_nop): New declaration.
24087         (gimple_maybe_cmp): Likewise.
24088         (gimple_bitwise_inverted_equal_p): Rewrite to use gimple_bit_not_with_nop
24089         and gimple_maybe_cmp instead of being recursive.
24090         * match.pd (bit_not_with_nop): New match pattern.
24091         (maybe_cmp): Likewise.
24093 2023-08-04  Drew Ross  <drross@redhat.com>
24095         PR middle-end/101955
24096         * match.pd ((signed x << c) >> c): New canonicalization.
24098 2023-08-04  Pan Li  <pan2.li@intel.com>
24100         * config/riscv/riscv-vector-builtins-bases.cc
24101         (class vfnmsac_frm): New class for vfnmsac frm.
24102         (vfnmsac_frm_obj): New declaration.
24103         (BASE): Ditto.
24104         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24105         * config/riscv/riscv-vector-builtins-functions.def
24106         (vfnmsac_frm): New function definition.
24108 2023-08-04  Pan Li  <pan2.li@intel.com>
24110         * config/riscv/riscv-vector-builtins-bases.cc
24111         (class vfmsac_frm): New class for vfmsac frm.
24112         (vfmsac_frm_obj): New declaration.
24113         (BASE): Ditto.
24114         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24115         * config/riscv/riscv-vector-builtins-functions.def
24116         (vfmsac_frm): New function definition.
24118 2023-08-04  Pan Li  <pan2.li@intel.com>
24120         * config/riscv/riscv-vector-builtins-bases.cc
24121         (class vfnmacc_frm): New class for vfnmacc.
24122         (vfnmacc_frm_obj): New declaration.
24123         (BASE): Ditto.
24124         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24125         * config/riscv/riscv-vector-builtins-functions.def
24126         (vfnmacc_frm): New function definition.
24128 2023-08-04  Hao Liu  <hliu@os.amperecomputing.com>
24130         PR target/110625
24131         * config/aarch64/aarch64.cc (aarch64_force_single_cycle): check
24132         STMT_VINFO_REDUC_DEF to avoid failures in info_for_reduction.
24134 2023-08-04  Pan Li  <pan2.li@intel.com>
24136         * config/riscv/riscv-vector-builtins-bases.cc
24137         (class vfmacc_frm): New class for vfmacc frm.
24138         (vfmacc_frm_obj): New declaration.
24139         (BASE): Ditto.
24140         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24141         * config/riscv/riscv-vector-builtins-functions.def
24142         (vfmacc_frm): New function definition.
24143         * config/riscv/riscv-vector-builtins.cc
24144         (function_expander::use_ternop_insn): Add frm operand support.
24145         * config/riscv/vector.md: Add vfmuladd to frm_mode.
24147 2023-08-04  Pan Li  <pan2.li@intel.com>
24149         * config/riscv/riscv-vector-builtins-bases.cc
24150         (vfwmul_frm_obj): New declaration.
24151         (vfwmul_frm): Ditto.
24152         * config/riscv/riscv-vector-builtins-bases.h:
24153         (vfwmul_frm): Ditto.
24154         * config/riscv/riscv-vector-builtins-functions.def
24155         (vfwmul_frm): New function definition.
24156         * config/riscv/vector.md: (frm_mode) Add vfwmul to frm_mode.
24158 2023-08-04  Pan Li  <pan2.li@intel.com>
24160         * config/riscv/riscv-vector-builtins-bases.cc
24161         (binop_frm): New declaration.
24162         (reverse_binop_frm): Likewise.
24163         (BASE): Likewise.
24164         * config/riscv/riscv-vector-builtins-bases.h:
24165         (vfdiv_frm): New extern declaration.
24166         (vfrdiv_frm): Likewise.
24167         * config/riscv/riscv-vector-builtins-functions.def
24168         (vfdiv_frm): New function definition.
24169         (vfrdiv_frm): Likewise.
24170         * config/riscv/vector.md: Add vfdiv to frm_mode.
24172 2023-08-03  Jan Hubicka  <jh@suse.cz>
24174         * tree-cfg.cc (print_loop_info): Print entry count.
24176 2023-08-03  Jan Hubicka  <jh@suse.cz>
24178         * tree-ssa-loop-split.cc (split_loop): Update estimated iteration counts.
24180 2023-08-03  Jan Hubicka  <jh@suse.cz>
24182         PR bootstrap/110857
24183         * cfgloopmanip.cc (scale_loop_profile): (Un)initialize
24184         unadjusted_exit_count.
24186 2023-08-03  Aldy Hernandez  <aldyh@redhat.com>
24188         * ipa-prop.cc (ipa_compute_jump_functions_for_edge): Read global
24189         value/mask.
24191 2023-08-03  Xiao Zeng  <zengxiao@eswincomputing.com>
24193         * config/riscv/riscv.cc (riscv_expand_conditional_move): Recognize
24194         various Zicond patterns.
24195         * config/riscv/riscv.md (mov<mode>cc): Allow TARGET_ZICOND.  Use
24196         sfb_alu_operand for both arms of the conditional move.
24197         Co-authored-by: Jeff Law <jlaw@ventanamicro.com>
24199 2023-08-03  Cupertino Miranda  <cupertino.miranda@oracle.com>
24201         PR target/107844
24202         PR target/107479
24203         PR target/107480
24204         PR target/107481
24205         * config.gcc: Added core-builtins.cc and .o files.
24206         * config/bpf/bpf-passes.def: Removed file.
24207         * config/bpf/bpf-protos.h (bpf_add_core_reloc,
24208         bpf_replace_core_move_operands): New prototypes.
24209         * config/bpf/bpf.cc (enum bpf_builtins, is_attr_preserve_access,
24210         maybe_make_core_relo, bpf_core_field_info, bpf_core_compute,
24211         bpf_core_get_index, bpf_core_new_decl, bpf_core_walk,
24212         bpf_is_valid_preserve_field_info_arg, is_attr_preserve_access,
24213         handle_attr_preserve, pass_data_bpf_core_attr, pass_bpf_core_attr):
24214         Removed.
24215         (def_builtin, bpf_expand_builtin, bpf_resolve_overloaded_builtin): Changed.
24216         * config/bpf/bpf.md (define_expand mov<MM:mode>): Changed.
24217         (mov_reloc_core<mode>): Added.
24218         * config/bpf/core-builtins.cc (struct cr_builtin, enum
24219         cr_decision struct cr_local, struct cr_final, struct
24220         core_builtin_helpers, enum bpf_plugin_states): Added types.
24221         (builtins_data, core_builtin_helpers, core_builtin_type_defs):
24222         Added variables.
24223         (allocate_builtin_data, get_builtin-data, search_builtin_data,
24224         remove_parser_plugin, compare_same_kind, compare_same_ptr_expr,
24225         compare_same_ptr_type, is_attr_preserve_access, core_field_info,
24226         bpf_core_get_index, compute_field_expr,
24227         pack_field_expr_for_access_index, pack_field_expr_for_preserve_field,
24228         process_field_expr, pack_enum_value, process_enum_value, pack_type,
24229         process_type, bpf_require_core_support, make_core_relo, read_kind,
24230         kind_access_index, kind_preserve_field_info, kind_enum_value,
24231         kind_type_id, kind_preserve_type_info, get_core_builtin_fndecl_for_type,
24232         bpf_handle_plugin_finish_type, bpf_init_core_builtins,
24233         construct_builtin_core_reloc, bpf_resolve_overloaded_core_builtin,
24234         bpf_expand_core_builtin, bpf_add_core_reloc,
24235         bpf_replace_core_move_operands): Added functions.
24236         * config/bpf/core-builtins.h (enum bpf_builtins): Added.
24237         (bpf_init_core_builtins, bpf_expand_core_builtin,
24238         bpf_resolve_overloaded_core_builtin): Added functions.
24239         * config/bpf/coreout.cc (struct bpf_core_extra): Added.
24240         (bpf_core_reloc_add, output_asm_btfext_core_reloc): Changed.
24241         * config/bpf/coreout.h (bpf_core_reloc_add) Changed prototype.
24242         * config/bpf/t-bpf: Added core-builtins.o.
24243         * doc/extend.texi: Added documentation for new BPF builtins.
24245 2023-08-03  Andrew MacLeod  <amacleod@redhat.com>
24247         * gimple-range-fold.cc (fold_using_range::range_of_range_op): Add
24248         ranges to the call to relation_fold_and_or.
24249         (fold_using_range::relation_fold_and_or): Add op1 and op2 ranges.
24250         (fur_source::register_outgoing_edges): Add op1 and op2 ranges.
24251         * gimple-range-fold.h (relation_fold_and_or): Adjust params.
24252         * gimple-range-gori.cc (gori_compute::compute_operand_range): Add
24253         a varying op1 and op2 to call.
24254         * range-op-float.cc (range_operator::op1_op2_relation): New dafaults.
24255         (operator_equal::op1_op2_relation): New float version.
24256         (operator_not_equal::op1_op2_relation): Ditto.
24257         (operator_lt::op1_op2_relation): Ditto.
24258         (operator_le::op1_op2_relation): Ditto.
24259         (operator_gt::op1_op2_relation): Ditto.
24260         (operator_ge::op1_op2_relation) Ditto.
24261         * range-op-mixed.h (operator_equal::op1_op2_relation): New float
24262         prototype.
24263         (operator_not_equal::op1_op2_relation): Ditto.
24264         (operator_lt::op1_op2_relation): Ditto.
24265         (operator_le::op1_op2_relation): Ditto.
24266         (operator_gt::op1_op2_relation): Ditto.
24267         (operator_ge::op1_op2_relation): Ditto.
24268         * range-op.cc (range_op_handler::op1_op2_relation): Dispatch new
24269         variations.
24270         (range_operator::op1_op2_relation): Add extra params.
24271         (operator_equal::op1_op2_relation): Ditto.
24272         (operator_not_equal::op1_op2_relation): Ditto.
24273         (operator_lt::op1_op2_relation): Ditto.
24274         (operator_le::op1_op2_relation): Ditto.
24275         (operator_gt::op1_op2_relation): Ditto.
24276         (operator_ge::op1_op2_relation): Ditto.
24277         * range-op.h (range_operator): New prototypes.
24278         (range_op_handler): Ditto.
24280 2023-08-03  Andrew MacLeod  <amacleod@redhat.com>
24282         * gimple-range-gori.cc (gori_compute::compute_operand1_range):
24283         Use identity relation.
24284         (gori_compute::compute_operand2_range): Ditto.
24285         * value-relation.cc (get_identity_relation): New.
24286         * value-relation.h (get_identity_relation): New prototype.
24288 2023-08-03  Andrew MacLeod  <amacleod@redhat.com>
24290         * value-range.h (Value_Range::set_varying): Set the type.
24291         (Value_Range::set_zero): Ditto.
24292         (Value_Range::set_nonzero): Ditto.
24294 2023-08-03  Jeff Law  <jeffreyalaw@gmail.com>
24296         * config/riscv/riscv.cc (riscv_rtx_costs): Remove errant hunk from
24297         recent commit.
24299 2023-08-03  Pan Li  <pan2.li@intel.com>
24301         * config/riscv/riscv-vector-builtins-bases.cc: Add vfsub.
24303 2023-08-03  Richard Sandiford  <richard.sandiford@arm.com>
24305         * poly-int.h (can_div_trunc_p): Succeed for more boundary conditions.
24307 2023-08-03  Richard Biener  <rguenther@suse.de>
24309         PR tree-optimization/110838
24310         * tree-vect-patterns.cc (vect_recog_over_widening_pattern):
24311         Adjust the shift operand of RSHIFT_EXPRs.
24313 2023-08-03  Richard Biener  <rguenther@suse.de>
24315         PR tree-optimization/110702
24316         * tree-ssa-loop-ivopts.cc (rewrite_use_address): When
24317         we created a NULL pointer based access rewrite that to
24318         a LEA.
24320 2023-08-03  Richard Biener  <rguenther@suse.de>
24322         * tree-ssa-sink.cc: Include tree-ssa-live.h.
24323         (pass_sink_code::execute): Instantiate virtual_operand_live
24324         and pass it down.
24325         (sink_code_in_bb): Pass down virtual_operand_live.
24326         (statement_sink_location): Get virtual_operand_live and
24327         verify we are not sinking loads across stores by looking up
24328         the live virtual operand at the sink location.
24330 2023-08-03  Richard Biener  <rguenther@suse.de>
24332         * tree-ssa-live.h (class virtual_operand_live): New.
24333         * tree-ssa-live.cc (virtual_operand_live::init): New.
24334         (virtual_operand_live::get_live_in): Likewise.
24335         (virtual_operand_live::get_live_out): Likewise.
24337 2023-08-03  Richard Biener  <rguenther@suse.de>
24339         * passes.def: Exchange loop splitting and final value
24340         replacement passes.
24342 2023-08-03  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
24344         * config/s390/s390.cc (expand_perm_as_a_vlbr_vstbr_candidate):
24345         New function which handles bswap patterns for vec_perm_const.
24346         (vectorize_vec_perm_const_1): Call new function.
24347         * config/s390/vector.md (*bswap<mode>): Fix operands in output
24348         template.
24349         (*vstbr<mode>): New insn.
24351 2023-08-03  Alexandre Oliva  <oliva@adacore.com>
24353         * config/vxworks-smp.opt: New.  Introduce -msmp.
24354         * config.gcc: Enable it on powerpc* vxworks prior to 7r*.
24355         * config/rs6000/vxworks.h (STARTFILE_PREFIX_SPEC): Choose
24356         lib_smp when -msmp is present in the command line.
24357         * doc/invoke.texi: Document it.
24359 2023-08-03  Yanzhang Wang  <yanzhang.wang@intel.com>
24361         * config/riscv/riscv.cc (riscv_save_reg_p): Save ra for leaf
24362         when enabling -mno-omit-leaf-frame-pointer
24363         (riscv_option_override): Override omit-frame-pointer.
24364         (riscv_frame_pointer_required): Save s0 for non-leaf function
24365         (TARGET_FRAME_POINTER_REQUIRED): Override defination
24366         * config/riscv/riscv.opt: Add option support.
24368 2023-08-03  Roger Sayle  <roger@nextmovesoftware.com>
24370         PR target/110792
24371         * config/i386/i386.md (<any_rotate>ti3): For rotations by 64 bits
24372         place operand in a register before gen_<insn>64ti2_doubleword.
24373         (<any_rotate>di3): Likewise, for rotations by 32 bits, place
24374         operand in a register before gen_<insn>32di2_doubleword.
24375         (<any_rotate>32di2_doubleword): Constrain operand to be in register.
24376         (<any_rotate>64ti2_doubleword): Likewise.
24378 2023-08-03  Pan Li  <pan2.li@intel.com>
24380         * config/riscv/riscv-vector-builtins-bases.cc
24381         (vfmul_frm_obj): New declaration.
24382         (Base): Likewise.
24383         * config/riscv/riscv-vector-builtins-bases.h: Likewise.
24384         * config/riscv/riscv-vector-builtins-functions.def
24385         (vfmul_frm): New function definition.
24386         * config/riscv/vector.md: Add vfmul to frm_mode.
24388 2023-08-03  Andrew Pinski  <apinski@marvell.com>
24390         * match.pd (`~X & X`): Check that the types match.
24391         (`~x | x`, `~x ^ x`): Likewise.
24393 2023-08-03  Pan Li  <pan2.li@intel.com>
24395         * config/riscv/riscv-vector-builtins-bases.h: Remove
24396         redudant declaration.
24398 2023-08-03  Pan Li  <pan2.li@intel.com>
24400         * config/riscv/riscv-vector-builtins-bases.cc (BASE): Add
24401         vfwsub frm.
24402         * config/riscv/riscv-vector-builtins-bases.h: Add declaration.
24403         * config/riscv/riscv-vector-builtins-functions.def (vfwsub_frm):
24404         Add vfwsub function definitions.
24406 2023-08-02  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
24408         PR rtl-optimization/110867
24409         * combine.cc (simplify_compare_const): Try the optimization only
24410         in case the constant fits into the comparison mode.
24412 2023-08-02  Jeff Law  <jlaw@ventanamicro.com>
24414         * config/riscv/zicond.md: Remove incorrect zicond patterns and
24415         renumber/rename them.
24416         (zero.nez.<GPR:MODE><X:mode>.opt2): Fix output string.
24418 2023-08-02  Richard Biener  <rguenther@suse.de>
24420         * tree-phinodes.h (add_phi_node_to_bb): Remove.
24421         * tree-phinodes.cc  (add_phi_node_to_bb): Make static.
24423 2023-08-02  Jan Beulich  <jbeulich@suse.com>
24425         * config/i386/sse.md (vec_dupv2df<mask_name>): Fold the middle
24426         two of the alternatives.
24428 2023-08-02  Richard Biener  <rguenther@suse.de>
24430         PR tree-optimization/92335
24431         * tree-ssa-sink.cc (select_best_block): Before loop
24432         optimizations avoid sinking unconditional loads/stores
24433         in innermost loops to conditional executed places.
24435 2023-08-02  Andrew Pinski  <apinski@marvell.com>
24437         * gimple-match-head.cc (gimple_bitwise_inverted_equal_p): Valueize
24438         the comparison operands before comparing them.
24440 2023-08-02  Andrew Pinski  <apinski@marvell.com>
24442         * match.pd (`~X & X`, `~X | X`): Move over to
24443         use bitwise_inverted_equal_p, removing :c as bitwise_inverted_equal_p
24444         handles that already.
24445         Remove range test simplifications to true/false as they
24446         are now handled by these patterns.
24448 2023-08-02  Andrew Pinski  <apinski@marvell.com>
24450         * tree-ssa-phiopt.cc (match_simplify_replacement): Mark's cond
24451         statement's lhs and rhs to check if trivial dead.
24452         Rename inserted_exprs to exprs_maybe_dce; also move it so
24453         bitmap is not allocated if not needed.
24455 2023-08-02  Pan Li  <pan2.li@intel.com>
24457         * config/riscv/riscv-vector-builtins-bases.cc
24458         (class widen_binop_frm): New class for binop frm.
24459         (BASE): Add vfwadd_frm.
24460         * config/riscv/riscv-vector-builtins-bases.h: New declaration.
24461         * config/riscv/riscv-vector-builtins-functions.def
24462         (vfwadd_frm): New function definition.
24463         * config/riscv/riscv-vector-builtins-shapes.cc
24464         (BASE_NAME_MAX_LEN): New macro.
24465         (struct alu_frm_def): Leverage new base class.
24466         (struct build_frm_base): New build base for frm.
24467         (struct widen_alu_frm_def): New struct for widen alu frm.
24468         (SHAPE): Add widen_alu_frm shape.
24469         * config/riscv/riscv-vector-builtins-shapes.h: New declaration.
24470         * config/riscv/vector.md (frm_mode): Add vfwalu type.
24472 2023-08-02  Jan Hubicka  <jh@suse.cz>
24474         * cfgloop.h (loop_count_in): Declare.
24475         * cfgloopanal.cc (expected_loop_iterations_by_profile): Use count_in.
24476         (loop_count_in): Move here from ...
24477         * cfgloopmanip.cc (loop_count_in): ... here.
24478         (scale_loop_profile): Improve dumping; cast iteration bound to sreal.
24480 2023-08-02  Jan Hubicka  <jh@suse.cz>
24482         * cfg.cc (scale_strictly_dominated_blocks): New function.
24483         * cfg.h (scale_strictly_dominated_blocks): Declare.
24484         * tree-cfg.cc (fold_loop_internal_call): Fixup CFG profile.
24486 2023-08-02  Richard Biener  <rguenther@suse.de>
24488         PR rtl-optimization/110587
24489         * lra-spills.cc (return_regno_p): Remove.
24490         (regno_in_use_p): Likewise.
24491         (lra_final_code_change): Do not remove noop moves
24492         between hard registers.
24494 2023-08-02  liuhongt  <hongtao.liu@intel.com>
24496         PR target/81904
24497         * config/i386/sse.md (vec_fmaddsub<mode>4): Extend to vector
24498         HFmode, use mode iterator VFH instead.
24499         (vec_fmsubadd<mode>4): Ditto.
24500         (<sd_mask_codefor>fma_fmaddsub_<mode><sd_maskz_name><round_name>):
24501         Remove scalar mode from iterator, use VFH_AVX512VL instead.
24502         (<sd_mask_codefor>fma_fmsubadd_<mode><sd_maskz_name><round_name>):
24503         Ditto.
24505 2023-08-02  liuhongt  <hongtao.liu@intel.com>
24507         * config/i386/sse.md (*avx2_lddqu_inserti_to_bcasti): New
24508         pre_reload define_insn_and_split.
24510 2023-08-02  Xiao Zeng  <zengxiao@eswincomputing.com>
24512         * config/riscv/riscv.cc (riscv_rtx_costs): Add costing for
24513         using Zicond to implement some conditional moves.
24515 2023-08-02  Jeff Law  <jlaw@ventanamicro.com>
24517         * config/riscv/zicond.md: Use the X iterator instead of ANYI
24518         on the comparison input operands.
24520 2023-08-02  Xiao Zeng  <zengxiao@eswincomputing.com>
24522         * config/riscv/riscv.cc (riscv_rtx_costs, case IF_THEN_ELSE): Add
24523         Zicond costing.
24524         (case SET): For INSNs that just set a REG, take the cost from the
24525         SET_SRC.
24526         Co-authored-by: Jeff Law <jlaw@ventanamicro.com>
24528 2023-08-02  Hu, Lin1  <lin1.hu@intel.com>
24530         * common/config/i386/i386-common.cc (OPTION_MASK_ISA2_AMX_INT8_SET):
24531         Change OPTION_MASK_ISA2_AMX_TILE to OPTION_MASK_ISA2_AMX_TILE_SET.
24532         (OPTION_MASK_ISA2_AMX_BF16_SET): Ditto
24533         (OPTION_MASK_ISA2_AMX_FP16_SET): Ditto
24534         (OPTION_MASK_ISA2_AMX_COMPLEX_SET): Ditto
24535         (OPTION_MASK_ISA_ABM_SET):
24536         Change OPTION_MASK_ISA_POPCNT to OPTION_MASK_ISA_POPCNT_SET.
24538 2023-08-01  Andreas Krebbel  <krebbel@linux.ibm.com>
24540         * config/s390/s390.cc (s390_encode_section_info): Assume external
24541         symbols without explicit alignment to be unaligned if
24542         -munaligned-symbols has been specified.
24543         * config/s390/s390.opt (-munaligned-symbols): New option.
24545 2023-08-01  Richard Ball  <richard.ball@arm.com>
24547         * gimple-fold.cc (fold_ctor_reference):
24548         Add support for poly_int.
24550 2023-08-01  Georg-Johann Lay  <avr@gjlay.de>
24552         PR target/110220
24553         * config/avr/avr.cc (avr_optimize_casesi): Set JUMP_LABEL and
24554         LABEL_NUSES of new conditional branch instruction.
24556 2023-08-01  Jan Hubicka  <jh@suse.cz>
24558         * tree-vect-loop-manip.cc (vect_do_peeling): Fix profile update after
24559         constant prologue peeling.
24561 2023-08-01  Christophe Lyon  <christophe.lyon@linaro.org>
24563         * doc/sourcebuild.texi (arm_v8_1m_main_cde_mve_fp): Fix spelling.
24565 2023-08-01  Pan Li  <pan2.li@intel.com>
24566             Juzhe-Zhong  <juzhe.zhong@rivai.ai>
24568         * config/riscv/riscv.cc (DYNAMIC_FRM_RTL): New macro.
24569         (STATIC_FRM_P): Ditto.
24570         (struct mode_switching_info): New struct for mode switching.
24571         (struct machine_function): Add new field mode switching.
24572         (riscv_emit_frm_mode_set): Add DYN_CALL emit.
24573         (riscv_frm_adjust_mode_after_call): New function for call mode.
24574         (riscv_frm_emit_after_call_in_bb_end): New function for emit
24575         insn when call as the end of bb.
24576         (riscv_frm_mode_needed): New function for frm mode needed.
24577         (frm_unknown_dynamic_p): Remove call check.
24578         (riscv_mode_needed): Extrac function for frm.
24579         (riscv_frm_mode_after): Add DYN_CALL after.
24580         (riscv_mode_entry): Remove backup rtl initialization.
24581         * config/riscv/vector.md (frm_mode): Add dyn_call.
24582         (fsrmsi_restore_exit): Rename to _volatile.
24583         (fsrmsi_restore_volatile): Likewise.
24585 2023-08-01  Pan Li  <pan2.li@intel.com>
24587         * config/riscv/riscv-vector-builtins-bases.cc
24588         (class reverse_binop_frm): Add new template for reversed frm.
24589         (vfsub_frm_obj): New obj.
24590         (vfrsub_frm_obj): Likewise.
24591         * config/riscv/riscv-vector-builtins-bases.h:
24592         (vfsub_frm): New declaration.
24593         (vfrsub_frm): Likewise.
24594         * config/riscv/riscv-vector-builtins-functions.def
24595         (vfsub_frm): New function define.
24596         (vfrsub_frm): Likewise.
24598 2023-08-01  Andrew Pinski  <apinski@marvell.com>
24600         PR tree-optimization/93044
24601         * match.pd (nested int casts): A truncation (to the same size or smaller)
24602         can always remove the inner cast.
24604 2023-07-31  Hamza Mahfooz  <someguy@effective-light.com>
24606         PR c/65213
24607         * doc/invoke.texi (-Wmissing-variable-declarations): Document
24608         new option.
24610 2023-07-31  Andrew Pinski  <apinski@marvell.com>
24612         PR tree-optimization/106164
24613         * match.pd (`a != b & a <= b`, `a != b & a >= b`,
24614         `a == b | a < b`, `a == b | a > b`): Handle these cases
24615         too.
24617 2023-07-31  Andrew Pinski  <apinski@marvell.com>
24619         PR tree-optimization/106164
24620         * match.pd: Extend the `(X CMP1 CST1) AND/IOR (X CMP2 CST2)`
24621         patterns to support `(X CMP1 Y) AND/IOR (X CMP2 Y)`.
24623 2023-07-31  Andrew Pinski  <apinski@marvell.com>
24625         PR tree-optimization/100864
24626         * generic-match-head.cc (bitwise_inverted_equal_p): New function.
24627         * gimple-match-head.cc (bitwise_inverted_equal_p): New macro.
24628         (gimple_bitwise_inverted_equal_p): New function.
24629         * match.pd ((~x | y) & x): Use bitwise_inverted_equal_p
24630         instead of direct matching bit_not.
24632 2023-07-31  Costas Argyris  <costas.argyris@gmail.com>
24634         PR driver/77576
24635         * gcc-ar.cc (main): Expand argv and use
24636         temporary response file to call ar if any
24637         expansions were made.
24639 2023-07-31  Andrew MacLeod  <amacleod@redhat.com>
24641         PR tree-optimization/110582
24642         * gimple-range-fold.cc (fur_list::get_operand): Do not use the
24643         range vector for non-ssa names.
24645 2023-07-31  David Malcolm  <dmalcolm@redhat.com>
24647         PR analyzer/109361
24648         * diagnostic-client-data-hooks.h (class sarif_object): New forward
24649         decl.
24650         (diagnostic_client_data_hooks::add_sarif_invocation_properties):
24651         New vfunc.
24652         * diagnostic-format-sarif.cc: Include "diagnostic-format-sarif.h".
24653         (class sarif_invocation): Inherit from sarif_object rather than
24654         json::object.
24655         (class sarif_result): Likewise.
24656         (class sarif_ice_notification): Likewise.
24657         (sarif_object::get_or_create_properties): New.
24658         (sarif_invocation::prepare_to_flush): Add "context" param.  Use it
24659         to call the context's add_sarif_invocation_properties hook.
24660         (sarif_builder::flush_to_file): Pass m_context to
24661         sarif_invocation::prepare_to_flush.
24662         * diagnostic-format-sarif.h: New header.
24663         * doc/invoke.texi (Developer Options): Clarify that -ftime-report
24664         writes to stderr.  Document that if SARIF diagnostic output is
24665         requested then any timing information is written in JSON form as
24666         part of the SARIF output, rather than to stderr.
24667         * timevar.cc: Include "json.h".
24668         (timer::named_items::m_hash_map): Split out type into...
24669         (timer::named_items::hash_map_t): ...this new typedef.
24670         (timer::named_items::make_json): New function.
24671         (timevar_diff): New function.
24672         (make_json_for_timevar_time_def): New function.
24673         (timer::timevar_def::make_json): New function.
24674         (timer::make_json): New function.
24675         * timevar.h (class json::value): New forward decl.
24676         (timer::make_json): New decl.
24677         (timer::timevar_def::make_json): New decl.
24678         * tree-diagnostic-client-data-hooks.cc: Include
24679         "diagnostic-format-sarif.h" and "timevar.h".
24680         (compiler_data_hooks::add_sarif_invocation_properties): New vfunc
24681         implementation.
24683 2023-07-31  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
24685         * combine.cc (simplify_compare_const): Narrow comparison of
24686         memory and constant.
24687         (try_combine): Adapt new function signature.
24688         (simplify_comparison): Adapt new function signature.
24690 2023-07-31  Kito Cheng  <kito.cheng@sifive.com>
24692         * config/riscv/riscv-v.cc (expand_vec_series): Drop unused
24693         variable.
24694         (expand_vector_init_insert_elems): Ditto.
24696 2023-07-31  Hao Liu  <hliu@os.amperecomputing.com>
24698         PR target/110625
24699         * config/aarch64/aarch64.cc (count_ops): Only '* count' for
24700         single_defuse_cycle while counting reduction_latency.
24702 2023-07-31  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
24704         * internal-fn.def (DEF_INTERNAL_COND_FN): New macro.
24705         (DEF_INTERNAL_SIGNED_COND_FN): Ditto.
24706         (COND_ADD): Remove.
24707         (COND_SUB): Ditto.
24708         (COND_MUL): Ditto.
24709         (COND_DIV): Ditto.
24710         (COND_MOD): Ditto.
24711         (COND_RDIV): Ditto.
24712         (COND_MIN): Ditto.
24713         (COND_MAX): Ditto.
24714         (COND_FMIN): Ditto.
24715         (COND_FMAX): Ditto.
24716         (COND_AND): Ditto.
24717         (COND_IOR): Ditto.
24718         (COND_XOR): Ditto.
24719         (COND_SHL): Ditto.
24720         (COND_SHR): Ditto.
24721         (COND_FMA): Ditto.
24722         (COND_FMS): Ditto.
24723         (COND_FNMA): Ditto.
24724         (COND_FNMS): Ditto.
24725         (COND_NEG): Ditto.
24726         (COND_LEN_ADD): Ditto.
24727         (COND_LEN_SUB): Ditto.
24728         (COND_LEN_MUL): Ditto.
24729         (COND_LEN_DIV): Ditto.
24730         (COND_LEN_MOD): Ditto.
24731         (COND_LEN_RDIV): Ditto.
24732         (COND_LEN_MIN): Ditto.
24733         (COND_LEN_MAX): Ditto.
24734         (COND_LEN_FMIN): Ditto.
24735         (COND_LEN_FMAX): Ditto.
24736         (COND_LEN_AND): Ditto.
24737         (COND_LEN_IOR): Ditto.
24738         (COND_LEN_XOR): Ditto.
24739         (COND_LEN_SHL): Ditto.
24740         (COND_LEN_SHR): Ditto.
24741         (COND_LEN_FMA): Ditto.
24742         (COND_LEN_FMS): Ditto.
24743         (COND_LEN_FNMA): Ditto.
24744         (COND_LEN_FNMS): Ditto.
24745         (COND_LEN_NEG): Ditto.
24746         (ADD): New macro define.
24747         (SUB): Ditto.
24748         (MUL): Ditto.
24749         (DIV): Ditto.
24750         (MOD): Ditto.
24751         (RDIV): Ditto.
24752         (MIN): Ditto.
24753         (MAX): Ditto.
24754         (FMIN): Ditto.
24755         (FMAX): Ditto.
24756         (AND): Ditto.
24757         (IOR): Ditto.
24758         (XOR): Ditto.
24759         (SHL): Ditto.
24760         (SHR): Ditto.
24761         (FMA): Ditto.
24762         (FMS): Ditto.
24763         (FNMA): Ditto.
24764         (FNMS): Ditto.
24765         (NEG): Ditto.
24767 2023-07-31  Roger Sayle  <roger@nextmovesoftware.com>
24769         PR target/110843
24770         * config/i386/i386-features.cc (compute_convert_gain): Check
24771         TARGET_AVX512VL (not TARGET_AVX512F) when considering V2DImode
24772         and V4SImode rotates in STV.
24773         (general_scalar_chain::convert_rotate): Likewise.
24775 2023-07-31  Kito Cheng  <kito.cheng@sifive.com>
24777         * config/riscv/autovec.md (abs<mode>2): Remove `.require ()`.
24778         * config/riscv/riscv-protos.h (get_mask_mode): Update return
24779         type.
24780         * config/riscv/riscv-v.cc (rvv_builder::rvv_builder): Remove
24781         `.require ()`.
24782         (emit_vlmax_insn): Ditto.
24783         (emit_vlmax_fp_insn): Ditto.
24784         (emit_vlmax_ternary_insn): Ditto.
24785         (emit_vlmax_fp_ternary_insn): Ditto.
24786         (emit_nonvlmax_fp_ternary_tu_insn): Ditto.
24787         (emit_nonvlmax_insn): Ditto.
24788         (emit_vlmax_slide_insn): Ditto.
24789         (emit_nonvlmax_slide_tu_insn): Ditto.
24790         (emit_vlmax_merge_insn): Ditto.
24791         (emit_vlmax_masked_insn): Ditto.
24792         (emit_nonvlmax_masked_insn): Ditto.
24793         (emit_vlmax_masked_store_insn): Ditto.
24794         (emit_nonvlmax_masked_store_insn): Ditto.
24795         (emit_vlmax_masked_mu_insn): Ditto.
24796         (emit_nonvlmax_tu_insn): Ditto.
24797         (emit_nonvlmax_fp_tu_insn): Ditto.
24798         (emit_scalar_move_insn): Ditto.
24799         (emit_vlmax_compress_insn): Ditto.
24800         (emit_vlmax_reduction_insn): Ditto.
24801         (emit_vlmax_fp_reduction_insn): Ditto.
24802         (emit_nonvlmax_fp_reduction_insn): Ditto.
24803         (expand_vec_series): Ditto.
24804         (expand_vector_init_merge_repeating_sequence): Ditto.
24805         (expand_vec_perm): Ditto.
24806         (shuffle_merge_patterns): Ditto.
24807         (shuffle_compress_patterns): Ditto.
24808         (shuffle_decompress_patterns): Ditto.
24809         (expand_reduction): Ditto.
24810         (get_mask_mode): Update return type.
24811         * config/riscv/riscv.cc (riscv_get_mask_mode): Check vector type
24812         is valid, and use new get_mask_mode interface.
24814 2023-07-31  Pan Li  <pan2.li@intel.com>
24816         * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_frm_def):
24817         Move rm suffix before mask.
24819 2023-07-31  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
24821         * config/riscv/autovec-vls.md (@vec_duplicate<mode>): New pattern.
24822         * config/riscv/riscv-v.cc (autovectorize_vector_modes): Add VLS autovec
24823         support.
24825 2023-07-29  Roger Sayle  <roger@nextmovesoftware.com>
24827         PR target/110790
24828         * config/i386/i386.md (extv<mode>): Use QImode for offsets.
24829         (extzv<mode>): Likewise.
24830         (insv<mode>): Likewise.
24831         (*testqi_ext_3): Likewise.
24832         (*btr<mode>_2): Likewise.
24833         (define_split): Likewise.
24834         (*btsq_imm): Likewise.
24835         (*btrq_imm): Likewise.
24836         (*btcq_imm): Likewise.
24837         (define_peephole2 x3): Likewise.
24838         (*bt<mode>): Likewise
24839         (*bt<mode>_mask): New define_insn_and_split.
24840         (*jcc_bt<mode>): Use QImode for offsets.
24841         (*jcc_bt<mode>_1): Delete obsolete pattern.
24842         (*jcc_bt<mode>_mask): Use QImode offsets.
24843         (*jcc_bt<mode>_mask_1): Likewise.
24844         (define_split): Likewise.
24845         (*bt<mode>_setcqi): Likewise.
24846         (*bt<mode>_setncqi): Likewise.
24847         (*bt<mode>_setnc<mode>): Likewise.
24848         (*bt<mode>_setncqi_2): Likewise.
24849         (*bt<mode>_setc<mode>_mask): New define_insn_and_split.
24850         (bmi2_bzhi_<mode>3): Use QImode offsets.
24851         (*bmi2_bzhi_<mode>3): Likewise.
24852         (*bmi2_bzhi_<mode>3_1): Likewise.
24853         (*bmi2_bzhi_<mode>3_1_ccz): Likewise.
24854         (@tbm_bextri_<mode>): Likewise.
24856 2023-07-29  Jan Hubicka  <jh@suse.cz>
24858         * profile-count.cc (profile_probability::sqrt): New member function.
24859         (profile_probability::pow): Likewise.
24860         * profile-count.h: (profile_probability::sqrt): Declare
24861         (profile_probability::pow): Likewise.
24862         * tree-vect-loop-manip.cc (vect_loop_versioning): Fix profile update.
24864 2023-07-28  Andrew MacLeod  <amacleod@redhat.com>
24866         * gimple-range-cache.cc (ssa_cache::merge_range): New.
24867         (ssa_lazy_cache::merge_range): New.
24868         * gimple-range-cache.h (class ssa_cache): Adjust protoypes.
24869         (class ssa_lazy_cache): Ditto.
24870         * gimple-range.cc (assume_query::calculate_op): Use merge_range.
24872 2023-07-28  Andrew MacLeod  <amacleod@redhat.com>
24874         * tree-ssa-propagate.cc (substitute_and_fold_engine::value_on_edge):
24875         Move from value-query.cc.
24876         (substitute_and_fold_engine::value_of_stmt): Ditto.
24877         (substitute_and_fold_engine::range_of_expr): New.
24878         * tree-ssa-propagate.h (substitute_and_fold_engine): Inherit from
24879         range_query.  New prototypes.
24880         * value-query.cc (value_query::value_on_edge): Relocate.
24881         (value_query::value_of_stmt): Ditto.
24882         * value-query.h (class value_query): Remove.
24883         (class range_query): Remove base class.  Adjust prototypes.
24885 2023-07-28  Andrew MacLeod  <amacleod@redhat.com>
24887         PR tree-optimization/110205
24888         * gimple-range-cache.h (ranger_cache::m_estimate): Delete.
24889         * range-op-mixed.h (operator_bitwise_xor::op1_op2_relation_effect):
24890         Add final override.
24891         * range-op.cc (operator_lshift): Add missing final overrides.
24892         (operator_rshift): Ditto.
24894 2023-07-28  Jose E. Marchesi  <jose.marchesi@oracle.com>
24896         * config/bpf/bpf.cc (bpf_option_override): Disable tail-call
24897         optimizations in BPF target.
24899 2023-07-28  Honza  <jh@ryzen4.suse.cz>
24901         * cfgloopmanip.cc (loop_count_in): Break out from ...
24902         (loop_exit_for_scaling): Break out from ...
24903         (update_loop_exit_probability_scale_dom_bbs): Break out from ...;
24904         add more sanity check and debug info.
24905         (scale_loop_profile): ... here.
24906         (create_empty_loop_on_edge): Fix whitespac.
24907         * cfgloopmanip.h (update_loop_exit_probability_scale_dom_bbs): Declare.
24908         * loop-unroll.cc (unroll_loop_constant_iterations): Use
24909         update_loop_exit_probability_scale_dom_bbs.
24910         * tree-ssa-loop-manip.cc (update_exit_probability_after_unrolling): Remove.
24911         (tree_transform_and_unroll_loop): Use
24912         update_loop_exit_probability_scale_dom_bbs.
24913         * tree-ssa-loop-split.cc (split_loop): Use
24914         update_loop_exit_probability_scale_dom_bbs.
24916 2023-07-28  Jan Hubicka  <jh@suse.cz>
24918         PR middle-end/77689
24919         * tree-ssa-loop-split.cc: Include value-query.h.
24920         (split_at_bb_p): Analyze cases where EQ/NE can be turned
24921         into LT/LE/GT/GE; return updated guard code.
24922         (split_loop): Use guard code.
24924 2023-07-28  Roger Sayle  <roger@nextmovesoftware.com>
24925             Richard Biener  <rguenther@suse.de>
24927         PR middle-end/28071
24928         PR rtl-optimization/110587
24929         * expr.cc (emit_group_load_1): Simplify logic for calling
24930         force_reg on ORIG_SRC, to avoid making a copy if the source
24931         is already in a pseudo register.
24933 2023-07-28  Jan Hubicka  <jh@suse.cz>
24935         PR middle-end/106923
24936         * tree-ssa-loop-split.cc (connect_loops): Change probability
24937         of the test preconditioning second loop to very_likely.
24938         (fix_loop_bb_probability): Handle correctly case where
24939         on of the arms of the conditional is empty.
24940         (split_loop): Fold the test guarding first condition to
24941         see if it is constant true; Set correct entry block
24942         probabilities of the split loops; determine correct loop
24943         eixt probabilities.
24945 2023-07-28  xuli  <xuli1@eswincomputing.com>
24947         * config/riscv/riscv-vector-builtins-bases.cc: remove rounding mode of
24948         vsadd[u] and vssub[u].
24949         * config/riscv/vector.md: Ditto.
24951 2023-07-28  Jan Hubicka  <jh@suse.cz>
24953         * tree-ssa-loop-split.cc (split_loop): Also support NE driven
24954         loops when IV test is not overflowing.
24956 2023-07-28  liuhongt  <hongtao.liu@intel.com>
24958         PR target/110788
24959         * config/i386/sse.md (avx512cd_maskb_vec_dup<mode>): Add
24960         UNSPEC_MASKOP.
24961         (avx512cd_maskw_vec_dup<mode>): Ditto.
24963 2023-07-27  David Faust  <david.faust@oracle.com>
24965         PR target/110782
24966         PR target/110784
24967         * config/bpf/bpf.opt (msmov): New option.
24968         * config/bpf/bpf.cc (bpf_option_override): Handle it here.
24969         * config/bpf/bpf.md (*extendsidi2): New.
24970         (extendhidi2): New.
24971         (extendqidi2): New.
24972         (extendsisi2): New.
24973         (extendhisi2): New.
24974         (extendqisi2): New.
24975         * doc/invoke.texi (Option Summary): Add -msmov eBPF option.
24976         (eBPF Options): Add -m[no-]smov.  Document that -mcpu=v4
24977         also enables -msmov.
24979 2023-07-27  David Faust  <david.faust@oracle.com>
24981         * doc/invoke.texi (Option Summary): Remove -mkernel eBPF option.
24982         Add -mbswap and -msdiv eBPF options.
24983         (eBPF Options): Remove -mkernel.  Add -mno-{jmpext, jmp32,
24984         alu32, v3-atomics, bswap, sdiv}.  Document that -mcpu=v4 also
24985         enables -msdiv.
24987 2023-07-27  David Faust  <david.faust@oracle.com>
24989         * config/bpf/bpf.md (add<AM:mode>3): Use %w2 instead of %w1
24990         in pseudo-C dialect output template.
24991         (sub<AM:mode>3): Likewise.
24993 2023-07-27  Jan Hubicka  <jh@suse.cz>
24995         * tree-vect-loop.cc (optimize_mask_stores): Make store
24996         likely.
24998 2023-07-27  Jan Hubicka  <jh@suse.cz>
25000         * cfgloop.h (single_dom_exit): Declare.
25001         * cfgloopmanip.h (update_exit_probability_after_unrolling): Declare.
25002         * cfgrtl.cc (struct cfg_hooks): Fix comment.
25003         * loop-unroll.cc (unroll_loop_constant_iterations): Update exit edge.
25004         * tree-ssa-loop-ivopts.h (single_dom_exit): Do not declare it here.
25005         * tree-ssa-loop-manip.cc (update_exit_probability_after_unrolling):
25006         Break out from ...
25007         (tree_transform_and_unroll_loop): ... here;
25009 2023-07-27  Jan Hubicka  <jh@suse.cz>
25011         * cfgloopmanip.cc (scale_dominated_blocks_in_loop): Move here from
25012         tree-ssa-loop-manip.cc and avoid recursion.
25013         (scale_loop_profile): Use scale_dominated_blocks_in_loop.
25014         (duplicate_loop_body_to_header_edge): Add DLTHE_FLAG_FLAT_PROFILE
25015         flag.
25016         * cfgloopmanip.h (DLTHE_FLAG_FLAT_PROFILE): Define.
25017         (scale_dominated_blocks_in_loop): Declare.
25018         * predict.cc (dump_prediction): Do not ICE on uninitialized probability.
25019         (change_edge_frequency): Remove.
25020         * predict.h (change_edge_frequency): Remove.
25021         * tree-ssa-loop-manip.cc (scale_dominated_blocks_in_loop): Move to
25022         cfgloopmanip.cc.
25023         (niter_for_unrolled_loop): Remove.
25024         (tree_transform_and_unroll_loop): Fix profile update.
25026 2023-07-27  Jan Hubicka  <jh@suse.cz>
25028         * tree-ssa-loop-im.cc (execute_sm_if_changed): Turn cap probability
25029         to guessed; fix count of new_bb.
25031 2023-07-27  Jan Hubicka  <jh@suse.cz>
25033         * profile-count.h (profile_count::apply_probability): Fix
25034         handling of uninitialized probabilities, optimize scaling
25035         by probability 1.
25037 2023-07-27  Richard Biener  <rguenther@suse.de>
25039         PR tree-optimization/91838
25040         * gimple-match-head.cc: Include attribs.h and asan.h.
25041         * generic-match-head.cc: Likewise.
25042         * match.pd (([rl]shift @0 out-of-bounds) -> zero): New pattern.
25044 2023-07-27  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
25046         * config/riscv/riscv-modes.def (VECTOR_BOOL_MODE): Add VLS modes.
25047         (ADJUST_ALIGNMENT): Ditto.
25048         (ADJUST_PRECISION): Ditto.
25049         (VLS_MODES): Ditto.
25050         (VECTOR_MODE_WITH_PREFIX): Ditto.
25051         * config/riscv/riscv-opts.h (TARGET_VECTOR_VLS): New macro.
25052         * config/riscv/riscv-protos.h (riscv_v_ext_vls_mode_p): New function.
25053         * config/riscv/riscv-v.cc (INCLUDE_ALGORITHM): Add include.
25054         (legitimize_move): Enable basic VLS modes support.
25055         (get_vlmul): Ditto.
25056         (get_ratio): Ditto.
25057         (get_vector_mode): Ditto.
25058         * config/riscv/riscv-vector-switch.def (VLS_ENTRY): Add vls modes.
25059         * config/riscv/riscv.cc (riscv_v_ext_vls_mode_p): New function.
25060         (VLS_ENTRY): New macro.
25061         (riscv_v_ext_mode_p): Add vls modes.
25062         (riscv_get_v_regno_alignment): New function.
25063         (riscv_print_operand): Add vls modes.
25064         (riscv_hard_regno_nregs): Ditto.
25065         (riscv_hard_regno_mode_ok): Ditto.
25066         (riscv_regmode_natural_size): Ditto.
25067         (riscv_vectorize_preferred_vector_alignment): Ditto.
25068         * config/riscv/riscv.md: Ditto.
25069         * config/riscv/vector-iterators.md: Ditto.
25070         * config/riscv/vector.md: Ditto.
25071         * config/riscv/autovec-vls.md: New file.
25073 2023-07-27  Pan Li  <pan2.li@intel.com>
25075         * config/riscv/riscv_vector.h (enum RVV_CSR): Removed.
25076         (vread_csr): Ditto.
25077         (vwrite_csr): Ditto.
25079 2023-07-27  demin.han  <demin.han@starfivetech.com>
25081         * config/riscv/autovec.md: Delete which_alternative use in split
25083 2023-07-27  Richard Biener  <rguenther@suse.de>
25085         * tree-ssa-sink.cc (sink_code_in_bb): Remove recursion, instead
25086         use a worklist ...
25087         (pass_sink_code::execute): ... in the caller.
25089 2023-07-27  Kewen Lin  <linkw@linux.ibm.com>
25090             Richard Biener  <rguenther@suse.de>
25092         PR tree-optimization/110776
25093         * tree-vect-stmts.cc (vectorizable_load): Always cost VMAT_ELEMENTWISE
25094         as scalar load.
25096 2023-07-26  Xiao Zeng  <zengxiao@eswincomputing.com>
25098         * config/riscv/riscv.md: Include zicond.md
25099         * config/riscv/zicond.md: New file.
25101 2023-07-26  Xiao Zeng  <zengxiao@eswincomputing.com>
25103         * common/config/riscv/riscv-common.cc: New extension.
25104         * config/riscv/riscv-opts.h (MASK_ZICOND): New mask.
25105         (TARGET_ZICOND): New target.
25107 2023-07-26  Carl Love  <cel@us.ibm.com>
25109         * config/rs6000/rs6000-c.cc (find_instance): Add new parameter that
25110         specifies the number of built-in arguments to check.
25111         (altivec_resolve_overloaded_builtin): Update calls to find_instance
25112         to pass the number of built-in arguments to be checked.
25114 2023-07-26  David Faust  <david.faust@oracle.com>
25116         * config/bpf/bpf.opt (mv3-atomics): New option.
25117         * config/bpf/bpf.cc (bpf_option_override): Handle it here.
25118         * config/bpf/bpf.h (enum_reg_class): Add R0 class.
25119         (REG_CLASS_NAMES): Likewise.
25120         (REG_CLASS_CONTENTS): Likewise.
25121         (REGNO_REG_CLASS): Handle R0.
25122         * config/bpf/bpf.md (UNSPEC_XADD): Rename to UNSPEC_AADD.
25123         (UNSPEC_AAND): New unspec.
25124         (UNSPEC_AOR): Likewise.
25125         (UNSPEC_AXOR): Likewise.
25126         (UNSPEC_AFADD): Likewise.
25127         (UNSPEC_AFAND): Likewise.
25128         (UNSPEC_AFOR): Likewise.
25129         (UNSPEC_AFXOR): Likewise.
25130         (UNSPEC_AXCHG): Likewise.
25131         (UNSPEC_ACMPX): Likewise.
25132         (atomic_add<mode>): Use UNSPEC_AADD and atomic type attribute.
25133         Move to...
25134         * config/bpf/atomic.md: ...Here. New file.
25135         * config/bpf/constraints.md (t): New constraint for R0.
25136         * doc/invoke.texi (eBPF Options): Document -mv3-atomics.
25138 2023-07-26  Matthew Malcomson  <matthew.malcomson@arm.com>
25140         * tree-vect-stmts.cc (get_group_load_store_type): Reformat
25141         comment.
25143 2023-07-26  Carl Love  <cel@us.ibm.com>
25145         * config/rs6000/rs6000-builtins.def: Rename
25146         __builtin_altivec_vreplace_un_uv2di as __builtin_altivec_vreplace_un_udi
25147         __builtin_altivec_vreplace_un_uv4si as __builtin_altivec_vreplace_un_usi
25148         __builtin_altivec_vreplace_un_v2df as __builtin_altivec_vreplace_un_df
25149         __builtin_altivec_vreplace_un_v2di as __builtin_altivec_vreplace_un_di
25150         __builtin_altivec_vreplace_un_v4sf as __builtin_altivec_vreplace_un_sf
25151         __builtin_altivec_vreplace_un_v4si as __builtin_altivec_vreplace_un_si.
25152         Rename VREPLACE_UN_UV2DI as VREPLACE_UN_UDI, VREPLACE_UN_UV4SI as
25153         VREPLACE_UN_USI, VREPLACE_UN_V2DF as VREPLACE_UN_DF,
25154         VREPLACE_UN_V2DI as VREPLACE_UN_DI, VREPLACE_UN_V4SF as
25155         VREPLACE_UN_SF, VREPLACE_UN_V4SI as VREPLACE_UN_SI.
25156         Rename vreplace_un_v2di as vreplace_un_di, vreplace_un_v4si as
25157         vreplace_un_si, vreplace_un_v2df as vreplace_un_df,
25158         vreplace_un_v2di as vreplace_un_di, vreplace_un_v4sf as
25159         vreplace_un_sf, vreplace_un_v4si as vreplace_un_si.
25160         * config/rs6000/rs6000-c.cc (find_instance): Add case
25161         RS6000_OVLD_VEC_REPLACE_UN.
25162         * config/rs6000/rs6000-overload.def (__builtin_vec_replace_un):
25163         Fix first argument type.  Rename VREPLACE_UN_UV4SI as
25164         VREPLACE_UN_USI, VREPLACE_UN_V4SI as VREPLACE_UN_SI,
25165         VREPLACE_UN_UV2DI as VREPLACE_UN_UDI, VREPLACE_UN_V2DI as
25166         VREPLACE_UN_DI, VREPLACE_UN_V4SF as VREPLACE_UN_SF,
25167         VREPLACE_UN_V2DF as VREPLACE_UN_DF.
25168         * config/rs6000/vsx.md (REPLACE_ELT): Rename the mode_iterator
25169         REPLACE_ELT_V for vector modes.
25170         (REPLACE_ELT): New scalar mode iterator.
25171         (REPLACE_ELT_char): Add scalar attributes.
25172         (vreplace_un_<mode>): Change iterator and mode attribute.
25174 2023-07-26  David Malcolm  <dmalcolm@redhat.com>
25176         PR analyzer/104940
25177         * Makefile.in (ANALYZER_OBJS): Add analyzer/symbol.o.
25179 2023-07-26  Richard Biener  <rguenther@suse.de>
25181         PR tree-optimization/106081
25182         * tree-vect-slp.cc (vect_optimize_slp_pass::start_choosing_layouts):
25183         Assign layout -1 to splats.
25185 2023-07-26  Aldy Hernandez  <aldyh@redhat.com>
25187         * range-op-mixed.h (class operator_cast): Add update_bitmask.
25188         * range-op.cc (operator_cast::update_bitmask): New.
25189         (operator_cast::fold_range): Call update_bitmask.
25191 2023-07-26  Li Xu  <xuli1@eswincomputing.com>
25193         * config/riscv/riscv-vector-builtins.def (vfloat16mf4x2_t): Change
25194         scalar type to float16, eliminate warning.
25195         (vfloat16mf4x3_t): Ditto.
25196         (vfloat16mf4x4_t): Ditto.
25197         (vfloat16mf4x5_t): Ditto.
25198         (vfloat16mf4x6_t): Ditto.
25199         (vfloat16mf4x7_t): Ditto.
25200         (vfloat16mf4x8_t): Ditto.
25201         (vfloat16mf2x2_t): Ditto.
25202         (vfloat16mf2x3_t): Ditto.
25203         (vfloat16mf2x4_t): Ditto.
25204         (vfloat16mf2x5_t): Ditto.
25205         (vfloat16mf2x6_t): Ditto.
25206         (vfloat16mf2x7_t): Ditto.
25207         (vfloat16mf2x8_t): Ditto.
25208         (vfloat16m1x2_t): Ditto.
25209         (vfloat16m1x3_t): Ditto.
25210         (vfloat16m1x4_t): Ditto.
25211         (vfloat16m1x5_t): Ditto.
25212         (vfloat16m1x6_t): Ditto.
25213         (vfloat16m1x7_t): Ditto.
25214         (vfloat16m1x8_t): Ditto.
25215         (vfloat16m2x2_t): Ditto.
25216         (vfloat16m2x3_t): Ditto.
25217         (vfloat16m2x4_t): Ditto.
25218         (vfloat16m4x2_t): Ditto.
25219         * config/riscv/vector-iterators.md: add RVVM4x2DF in iterator V4T.
25220         * config/riscv/vector.md: add tuple mode in attr sew.
25222 2023-07-26  Uros Bizjak  <ubizjak@gmail.com>
25224         PR target/110762
25225         * config/i386/i386.md (plusminusmult): New code iterator.
25226         * config/i386/mmx.md (mmxdoublevecmode): New mode attribute.
25227         (movq_<mode>_to_sse): New expander.
25228         (<plusminusmult:insn>v2sf3): Macroize expander from addv2sf3,
25229         subv2sf3 and mulv2sf3 using plusminusmult code iterator.  Rewrite
25230         as a wrapper around V4SFmode operation.
25231         (mmx_addv2sf3): Change operand 1 and operand 2 predicates to
25232         nonimmediate_operand.
25233         (*mmx_addv2sf3): Remove SSE alternatives.  Change operand 1 and
25234         operand 2 predicates to nonimmediate_operand.
25235         (mmx_subv2sf3): Change operand 2 predicate to nonimmediate_operand.
25236         (mmx_subrv2sf3): Change operand 1 predicate to nonimmediate_operand.
25237         (*mmx_subv2sf3): Remove SSE alternatives.  Change operand 1 and
25238         operand 2 predicates to nonimmediate_operand.
25239         (mmx_mulv2sf3): Change operand 1 and operand 2 predicates to
25240         nonimmediate_operand.
25241         (*mmx_mulv2sf3): Remove SSE alternatives.  Change operand 1 and
25242         operand 2 predicates to nonimmediate_operand.
25243         (divv2sf3): Rewrite as a wrapper around V4SFmode operation.
25244         (<smaxmin:code>v2sf3): Ditto.
25245         (mmx_<smaxmin:code>v2sf3): Change operand 1 and operand 2
25246         predicates to nonimmediate_operand.
25247         (*mmx_<smaxmin:code>v2sf3): Remove SSE alternatives.  Change
25248         operand 1 and operand 2 predicates to nonimmediate_operand.
25249         (mmx_ieee_<ieee_maxmin>v2sf3): Ditto.
25250         (sqrtv2sf2): Rewrite as a wrapper around V4SFmode operation.
25251         (*mmx_haddv2sf3_low): Ditto.
25252         (*mmx_hsubv2sf3_low): Ditto.
25253         (vec_addsubv2sf3): Ditto.
25254         (*mmx_maskcmpv2sf3_comm): Remove.
25255         (*mmx_maskcmpv2sf3): Remove.
25256         (vec_cmpv2sfv2si): Rewrite as a wrapper around V4SFmode operation.
25257         (vcond<V2FI:mode>v2sf): Ditto.
25258         (fmav2sf4): Ditto.
25259         (fmsv2sf4): Ditto.
25260         (fnmav2sf4): Ditto.
25261         (fnmsv2sf4): Ditto.
25262         (fix_truncv2sfv2si2): Ditto.
25263         (fixuns_truncv2sfv2si2): Ditto.
25264         (mmx_fix_truncv2sfv2si2): Remove SSE alternatives.
25265         Change operand 1 predicate to nonimmediate_operand.
25266         (floatv2siv2sf2): Rewrite as a wrapper around V4SFmode operation.
25267         (floatunsv2siv2sf2): Ditto.
25268         (mmx_floatv2siv2sf2): Remove SSE alternatives.
25269         Change operand 1 predicate to nonimmediate_operand.
25270         (nearbyintv2sf2): Rewrite as a wrapper around V4SFmode operation.
25271         (rintv2sf2): Ditto.
25272         (lrintv2sfv2si2): Ditto.
25273         (ceilv2sf2): Ditto.
25274         (lceilv2sfv2si2): Ditto.
25275         (floorv2sf2): Ditto.
25276         (lfloorv2sfv2si2): Ditto.
25277         (btruncv2sf2): Ditto.
25278         (roundv2sf2): Ditto.
25279         (lroundv2sfv2si2): Ditto.
25280         (*mmx_roundv2sf2): Remove.
25282 2023-07-26  Jose E. Marchesi  <jose.marchesi@oracle.com>
25284         * config/bpf/bpf.md: Fix neg{SI,DI}2 insn.
25286 2023-07-26  Richard Biener  <rguenther@suse.de>
25288         PR tree-optimization/110799
25289         * tree-ssa-pre.cc (compute_avail): More thoroughly match
25290         up TBAA behavior of redundant loads.
25292 2023-07-26  Jakub Jelinek  <jakub@redhat.com>
25294         PR tree-optimization/110755
25295         * range-op-float.cc (frange_arithmetic): Change +0 result to -0
25296         for PLUS_EXPR or MINUS_EXPR if -frounding-math, inf is negative and
25297         it is exact op1 + (-op1) or op1 - op1.
25299 2023-07-26  Kewen Lin  <linkw@linux.ibm.com>
25301         PR target/110741
25302         * config/rs6000/vsx.md (define_insn xxeval): Correct vsx
25303         operands output with "x".
25305 2023-07-26  Aldy Hernandez  <aldyh@redhat.com>
25307         * range-op.cc (class operator_absu): Add update_bitmask.
25308         (operator_absu::update_bitmask): New.
25310 2023-07-26  Aldy Hernandez  <aldyh@redhat.com>
25312         * range-op-mixed.h (class operator_abs): Add update_bitmask.
25313         * range-op.cc (operator_abs::update_bitmask): New.
25315 2023-07-26  Aldy Hernandez  <aldyh@redhat.com>
25317         * range-op-mixed.h (class operator_bitwise_not): Add update_bitmask.
25318         * range-op.cc (operator_bitwise_not::update_bitmask): New.
25320 2023-07-26  Aldy Hernandez  <aldyh@redhat.com>
25322         * range-op.cc (update_known_bitmask): Handle unary operators.
25324 2023-07-26  Aldy Hernandez  <aldyh@redhat.com>
25326         * tree-ssa-ccp.cc (bit_value_unop): Initialize val when appropriate.
25328 2023-07-26  Jin Ma  <jinma@linux.alibaba.com>
25330         * config/riscv/riscv.md: Likewise.
25332 2023-07-26  Jan Hubicka  <jh@suse.cz>
25334         * profile-count.cc (profile_count::to_sreal_scale): Value is not know
25335         if we divide by zero.
25337 2023-07-25  David Faust  <david.faust@oracle.com>
25339         * config/bpf/bpf.cc (bpf_print_operand_address): Don't print
25340         enclosing parentheses for pseudo-C dialect.
25341         * config/bpf/bpf.md (zero_exdendhidi2): Add parentheses around
25342         operands of pseudo-C dialect output templates where needed.
25343         (zero_extendqidi2): Likewise.
25344         (zero_extendsidi2): Likewise.
25345         (*mov<MM:mode>): Likewise.
25347 2023-07-25  Aldy Hernandez  <aldyh@redhat.com>
25349         * tree-ssa-ccp.cc (value_mask_to_min_max): Make static.
25350         (bit_value_mult_const): Same.
25351         (get_individual_bits): Same.
25353 2023-07-25  Haochen Gui  <guihaoc@gcc.gnu.org>
25355         PR target/103605
25356         * config/rs6000/rs6000-builtin.cc (rs6000_gimple_fold_builtin): Gimple
25357         fold RS6000_BIF_XSMINDP and RS6000_BIF_XSMAXDP when fast-math is set.
25358         * config/rs6000/rs6000.md (FMINMAX): New int iterator.
25359         (minmax_op): New int attribute.
25360         (UNSPEC_FMAX, UNSPEC_FMIN): New unspecs.
25361         (f<minmax_op><mode>3): New pattern by UNSPEC_FMAX and UNSPEC_FMIN.
25362         * config/rs6000/rs6000-builtins.def (__builtin_vsx_xsmaxdp): Set
25363         pattern to fmaxdf3.
25364         (__builtin_vsx_xsmindp): Set pattern to fmindf3.
25366 2023-07-24  David Faust  <david.faust@oracle.com>
25368         * config/bpf/bpf.md (nop): Add pseudo-c asm dialect template.
25370 2023-07-24  Drew Ross  <drross@redhat.com>
25371             Jakub Jelinek  <jakub@redhat.com>
25373         PR middle-end/109986
25374         * generic-match-head.cc (bitwise_equal_p): New macro.
25375         * gimple-match-head.cc (bitwise_equal_p): New macro.
25376         (gimple_nop_convert): Declare.
25377         (gimple_bitwise_equal_p): Helper for bitwise_equal_p.
25378         * match.pd ((~X | Y) ^ X -> ~(X & Y)): New simplification.
25380 2023-07-24  Jeff Law  <jlaw@ventanamicro.com>
25382         * common/config/riscv/riscv-common.cc (riscv_subset_list::add): Use
25383         single quote rather than backquote in diagnostic.
25385 2023-07-24  Jose E. Marchesi  <jose.marchesi@oracle.com>
25387         PR target/110783
25388         * config/bpf/bpf.opt: New command-line option -msdiv.
25389         * config/bpf/bpf.md: Conditionalize sdiv/smod on bpf_has_sdiv.
25390         * config/bpf/bpf.cc (bpf_option_override): Initialize
25391         bpf_has_sdiv.
25392         * doc/invoke.texi (eBPF Options): Document -msdiv.
25394 2023-07-24  Jeff Law  <jlaw@ventanamicro.com>
25396         * config/riscv/riscv.cc (riscv_option_override): Spell out
25397         greater than and use cannot in diagnostic string.
25399 2023-07-24  Richard Biener  <rguenther@suse.de>
25401         * tree-vectorizer.h (_slp_tree::push_vec_def): Add.
25402         (_slp_tree::vec_stmts): Remove.
25403         (SLP_TREE_VEC_STMTS): Remove.
25404         * tree-vect-slp.cc (_slp_tree::push_vec_def): Define.
25405         (_slp_tree::_slp_tree): Adjust.
25406         (_slp_tree::~_slp_tree): Likewise.
25407         (vect_get_slp_vect_def): Simplify.
25408         (vect_get_slp_defs): Likewise.
25409         (vect_transform_slp_perm_load_1): Adjust.
25410         (vect_add_slp_permutation): Likewise.
25411         (vect_schedule_slp_node): Likewise.
25412         (vectorize_slp_instance_root_stmt): Likewise.
25413         (vect_schedule_scc): Likewise.
25414         * tree-vect-stmts.cc (vectorizable_bswap): Use push_vec_def.
25415         (vectorizable_call): Likewise.
25416         (vectorizable_call): Likewise.
25417         (vect_create_vectorized_demotion_stmts): Likewise.
25418         (vectorizable_conversion): Likewise.
25419         (vectorizable_assignment): Likewise.
25420         (vectorizable_shift): Likewise.
25421         (vectorizable_operation): Likewise.
25422         (vectorizable_load): Likewise.
25423         (vectorizable_condition): Likewise.
25424         (vectorizable_comparison): Likewise.
25425         * tree-vect-loop.cc (vect_create_epilog_for_reduction): Adjust.
25426         (vectorize_fold_left_reduction): Use push_vec_def.
25427         (vect_transform_reduction): Likewise.
25428         (vect_transform_cycle_phi): Likewise.
25429         (vectorizable_lc_phi): Likewise.
25430         (vectorizable_phi): Likewise.
25431         (vectorizable_recurr): Likewise.
25432         (vectorizable_induction): Likewise.
25433         (vectorizable_live_operation): Likewise.
25435 2023-07-24  Richard Biener  <rguenther@suse.de>
25437         * tree-ssa-loop.cc: Remove unused tree-vectorizer.h include.
25439 2023-07-24  Richard Biener  <rguenther@suse.de>
25441         * config/i386/i386-builtins.cc: Remove tree-vectorizer.h include.
25442         * config/i386/i386-expand.cc: Likewise.
25443         * config/i386/i386-features.cc: Likewise.
25444         * config/i386/i386-options.cc: Likewise.
25446 2023-07-24  Robin Dapp  <rdapp@ventanamicro.com>
25448         * tree-vect-stmts.cc (vectorizable_conversion): Handle
25449         more demotion/promotion for modifier == NONE.
25451 2023-07-24  Roger Sayle  <roger@nextmovesoftware.com>
25453         PR target/110787
25454         PR target/110790
25455         Revert patch.
25456         * config/i386/i386.md (extv<mode>): Use QImode for offsets.
25457         (extzv<mode>): Likewise.
25458         (insv<mode>): Likewise.
25459         (*testqi_ext_3): Likewise.
25460         (*btr<mode>_2): Likewise.
25461         (define_split): Likewise.
25462         (*btsq_imm): Likewise.
25463         (*btrq_imm): Likewise.
25464         (*btcq_imm): Likewise.
25465         (define_peephole2 x3): Likewise.
25466         (*bt<mode>): Likewise
25467         (*bt<mode>_mask): New define_insn_and_split.
25468         (*jcc_bt<mode>): Use QImode for offsets.
25469         (*jcc_bt<mode>_1): Delete obsolete pattern.
25470         (*jcc_bt<mode>_mask): Use QImode offsets.
25471         (*jcc_bt<mode>_mask_1): Likewise.
25472         (define_split): Likewise.
25473         (*bt<mode>_setcqi): Likewise.
25474         (*bt<mode>_setncqi): Likewise.
25475         (*bt<mode>_setnc<mode>): Likewise.
25476         (*bt<mode>_setncqi_2): Likewise.
25477         (*bt<mode>_setc<mode>_mask): New define_insn_and_split.
25478         (bmi2_bzhi_<mode>3): Use QImode offsets.
25479         (*bmi2_bzhi_<mode>3): Likewise.
25480         (*bmi2_bzhi_<mode>3_1): Likewise.
25481         (*bmi2_bzhi_<mode>3_1_ccz): Likewise.
25482         (@tbm_bextri_<mode>): Likewise.
25484 2023-07-24  Jose E. Marchesi  <jose.marchesi@oracle.com>
25486         * config/bpf/bpf-opts.h (enum bpf_kernel_version): Remove enum.
25487         * config/bpf/bpf.opt (mkernel): Remove option.
25488         * config/bpf/bpf.cc (bpf_target_macros): Do not define
25489         BPF_KERNEL_VERSION_CODE.
25491 2023-07-24  Jose E. Marchesi  <jose.marchesi@oracle.com>
25493         PR target/110786
25494         * config/bpf/bpf.opt (mcpu): Add ISA_V4 and make it the default.
25495         (mbswap): New option.
25496         * config/bpf/bpf-opts.h (enum bpf_isa_version): New value ISA_V4.
25497         * config/bpf/bpf.cc (bpf_option_override): Set bpf_has_bswap.
25498         * config/bpf/bpf.md: Use bswap instructions if available for
25499         bswap* insn, and fix constraint.
25500         * doc/invoke.texi (eBPF Options): Document -mcpu=v4 and -mbswap.
25502 2023-07-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
25504         * config/riscv/autovec.md (fold_left_plus_<mode>): New pattern.
25505         (mask_len_fold_left_plus_<mode>): Ditto.
25506         * config/riscv/riscv-protos.h (enum insn_type): New enum.
25507         (enum reduction_type): Ditto.
25508         (expand_reduction): Add in-order reduction.
25509         * config/riscv/riscv-v.cc (emit_nonvlmax_fp_reduction_insn): New function.
25510         (expand_reduction): Add in-order reduction.
25512 2023-07-24  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
25514         * tree-vect-loop.cc (get_masked_reduction_fn): Add mask_len_fold_left_plus.
25515         (vectorize_fold_left_reduction): Ditto.
25516         (vectorizable_reduction): Ditto.
25517         (vect_transform_reduction): Ditto.
25519 2023-07-24  Richard Biener  <rguenther@suse.de>
25521         PR tree-optimization/110777
25522         * tree-ssa-sccvn.cc (eliminate_dom_walker::eliminate_avail):
25523         Avoid propagating abnormals.
25525 2023-07-24  Richard Biener  <rguenther@suse.de>
25527         PR tree-optimization/110766
25528         * tree-scalar-evolution.cc
25529         (analyze_and_compute_bitwise_induction_effect): Check the PHI
25530         is defined in the loop header.
25532 2023-07-24  Kewen Lin  <linkw@linux.ibm.com>
25534         PR tree-optimization/110740
25535         * tree-vect-loop.cc (vect_analyze_loop_costing): Do not vectorize a
25536         loop with a single scalar iteration.
25538 2023-07-24  Pan Li  <pan2.li@intel.com>
25540         * config/riscv/riscv-vector-builtins-shapes.cc
25541         (struct alu_frm_def): Take range check.
25543 2023-07-22  Vineet Gupta  <vineetg@rivosinc.com>
25545         PR target/110748
25546         * config/riscv/predicates.md (const_0_operand): Add back
25547         const_double.
25549 2023-07-22  Roger Sayle  <roger@nextmovesoftware.com>
25551         * config/i386/i386-expand.cc (ix86_expand_move): Disable the
25552         64-bit insertions into TImode optimizations with -O0, unless
25553         the function has the "naked" attribute (for PR target/110533).
25555 2023-07-22  Andrew Pinski  <apinski@marvell.com>
25557         PR target/110778
25558         * rtl.h (extended_count): Change last argument type
25559         to bool.
25561 2023-07-22  Roger Sayle  <roger@nextmovesoftware.com>
25563         * config/i386/i386.md (extv<mode>): Use QImode for offsets.
25564         (extzv<mode>): Likewise.
25565         (insv<mode>): Likewise.
25566         (*testqi_ext_3): Likewise.
25567         (*btr<mode>_2): Likewise.
25568         (define_split): Likewise.
25569         (*btsq_imm): Likewise.
25570         (*btrq_imm): Likewise.
25571         (*btcq_imm): Likewise.
25572         (define_peephole2 x3): Likewise.
25573         (*bt<mode>): Likewise
25574         (*bt<mode>_mask): New define_insn_and_split.
25575         (*jcc_bt<mode>): Use QImode for offsets.
25576         (*jcc_bt<mode>_1): Delete obsolete pattern.
25577         (*jcc_bt<mode>_mask): Use QImode offsets.
25578         (*jcc_bt<mode>_mask_1): Likewise.
25579         (define_split): Likewise.
25580         (*bt<mode>_setcqi): Likewise.
25581         (*bt<mode>_setncqi): Likewise.
25582         (*bt<mode>_setnc<mode>): Likewise.
25583         (*bt<mode>_setncqi_2): Likewise.
25584         (*bt<mode>_setc<mode>_mask): New define_insn_and_split.
25585         (bmi2_bzhi_<mode>3): Use QImode offsets.
25586         (*bmi2_bzhi_<mode>3): Likewise.
25587         (*bmi2_bzhi_<mode>3_1): Likewise.
25588         (*bmi2_bzhi_<mode>3_1_ccz): Likewise.
25589         (@tbm_bextri_<mode>): Likewise.
25591 2023-07-22  Jeff Law  <jlaw@ventanamicro.com>
25593         * config/bfin/bfin.md (ones): Fix length computation.
25595 2023-07-22  Vladimir N. Makarov  <vmakarov@redhat.com>
25597         * lra-eliminations.cc (update_reg_eliminate): Fix the assert.
25598         (lra_update_fp2sp_elimination): Use HARD_FRAME_POINTER_REGNUM
25599         instead of FRAME_POINTER_REGNUM to spill pseudos.
25601 2023-07-21  Roger Sayle  <roger@nextmovesoftware.com>
25602             Richard Biener  <rguenther@suse.de>
25604         PR c/110699
25605         * gimplify.cc (gimplify_compound_lval):  If the array's type
25606         is error_mark_node then return GS_ERROR.
25608 2023-07-21  Cupertino Miranda  <cupertino.miranda@oracle.com>
25610         PR target/110770
25611         * config/bpf/bpf.opt: Added option -masm=<dialect>.
25612         * config/bpf/bpf-opts.h (enum bpf_asm_dialect): New type.
25613         * config/bpf/bpf.cc (bpf_print_register): New function.
25614         (bpf_print_register): Support pseudo-c syntax for registers.
25615         (bpf_print_operand_address): Likewise.
25616         * config/bpf/bpf.h (ASM_SPEC): handle -msasm.
25617         (ASSEMBLER_DIALECT): Define.
25618         * config/bpf/bpf.md: Added pseudo-c templates.
25619         * doc/invoke.texi (-masm=): New eBPF option item.
25621 2023-07-21  Cupertino Miranda  <cupertino.miranda@oracle.com>
25623         * config/bpf/bpf.md: fixed template for neg instruction.
25625 2023-07-21  Jan Hubicka  <jh@suse.cz>
25627         PR target/110727
25628         * tree-vect-loop.cc (scale_profile_for_vect_loop): Avoid scaling flat
25629         profiles by vectorization factor.
25630         (vect_transform_loop): Check for flat profiles.
25632 2023-07-21  Jan Hubicka  <jh@suse.cz>
25634         * cfgloop.h (maybe_flat_loop_profile): Declare
25635         * cfgloopanal.cc (maybe_flat_loop_profile): New function.
25636         * tree-cfg.cc (print_loop_info): Print info about flat profiles.
25638 2023-07-21  Jan Hubicka  <jh@suse.cz>
25640         * cfgloop.cc (get_estimated_loop_iterations): Use sreal::to_nearest_int
25641         * cfgloopanal.cc (expected_loop_iterations_unbounded): Likewise.
25642         * predict.cc (estimate_bb_frequencies): Likewise.
25643         * profile.cc (branch_prob): Likewise.
25644         * tree-ssa-loop-niter.cc (estimate_numbers_of_iterations): Likewise
25646 2023-07-21  Iain Sandoe  <iain@sandoe.co.uk>
25648         * config.in: Regenerate.
25649         * config/darwin.h (DARWIN_LD_DEMANGLE): New.
25650         (LINK_COMMAND_SPEC_A): Add demangle handling.
25651         * configure: Regenerate.
25652         * configure.ac: Detect linker support for '-demangle'.
25654 2023-07-21  Jan Hubicka  <jh@suse.cz>
25656         * sreal.cc (sreal::to_nearest_int): New.
25657         (sreal_verify_basics): Verify also to_nearest_int.
25658         (verify_aritmetics): Likewise.
25659         (sreal_verify_conversions): New.
25660         (sreal_cc_tests): Call sreal_verify_conversions.
25661         * sreal.h: (sreal::to_nearest_int): Declare
25663 2023-07-21  Jan Hubicka  <jh@suse.cz>
25665         * tree-ssa-loop-ch.cc (enum ch_decision): New enum.
25666         (should_duplicate_loop_header_p): Return info on profitability.
25667         (do_while_loop_p): Watch for constant conditionals.
25668         (update_profile_after_ch): Do not sanity check that all
25669         static exits are taken.
25670         (ch_base::copy_headers): Run on all loops.
25671         (pass_ch::process_loop_p): Improve heuristics by handling also
25672         do_while loop and duplicating shortest sequence containing all
25673         winning blocks.
25675 2023-07-21  Jan Hubicka  <jh@suse.cz>
25677         * tree-ssa-loop-niter.cc (finite_loop_p): Reorder to do cheap
25678         tests first; update finite_p flag.
25680 2023-07-21  Jan Hubicka  <jh@suse.cz>
25682         * cfgloop.cc (flow_loop_dump): Use print_loop_info.
25683         * cfgloop.h (print_loop_info): Declare.
25684         * tree-cfg.cc (print_loop_info): Break out from ...; add
25685         printing of missing fields and profile
25686         (print_loop): ... here.
25688 2023-07-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
25690         * config/riscv/riscv-v.cc (expand_gather_scatter): Remove redundant variables.
25692 2023-07-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
25694         * tree-vect-stmts.cc (check_load_store_for_partial_vectors): Change condition order.
25695         (vectorizable_operation): Ditto.
25697 2023-07-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
25699         * config/riscv/autovec.md: Align order of mask and len.
25700         * config/riscv/riscv-v.cc (expand_load_store): Ditto.
25701         (expand_gather_scatter): Ditto.
25702         * doc/md.texi: Ditto.
25703         * internal-fn.cc (add_len_and_mask_args): Ditto.
25704         (add_mask_and_len_args): Ditto.
25705         (expand_partial_load_optab_fn): Ditto.
25706         (expand_partial_store_optab_fn): Ditto.
25707         (expand_scatter_store_optab_fn): Ditto.
25708         (expand_gather_load_optab_fn): Ditto.
25709         (internal_fn_len_index): Ditto.
25710         (internal_fn_mask_index): Ditto.
25711         (internal_len_load_store_bias): Ditto.
25712         * tree-vect-stmts.cc (vectorizable_store): Ditto.
25713         (vectorizable_load): Ditto.
25715 2023-07-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
25717         * config/riscv/autovec.md (len_maskload<mode><vm>): Change LEN_MASK into MASK_LEN.
25718         (mask_len_load<mode><vm>): Ditto.
25719         (len_maskstore<mode><vm>): Ditto.
25720         (mask_len_store<mode><vm>): Ditto.
25721         (len_mask_gather_load<RATIO64:mode><RATIO64I:mode>): Ditto.
25722         (mask_len_gather_load<RATIO64:mode><RATIO64I:mode>): Ditto.
25723         (len_mask_gather_load<RATIO32:mode><RATIO32I:mode>): Ditto.
25724         (mask_len_gather_load<RATIO32:mode><RATIO32I:mode>): Ditto.
25725         (len_mask_gather_load<RATIO16:mode><RATIO16I:mode>): Ditto.
25726         (mask_len_gather_load<RATIO16:mode><RATIO16I:mode>): Ditto.
25727         (len_mask_gather_load<RATIO8:mode><RATIO8I:mode>): Ditto.
25728         (mask_len_gather_load<RATIO8:mode><RATIO8I:mode>): Ditto.
25729         (len_mask_gather_load<RATIO4:mode><RATIO4I:mode>): Ditto.
25730         (mask_len_gather_load<RATIO4:mode><RATIO4I:mode>): Ditto.
25731         (len_mask_gather_load<RATIO2:mode><RATIO2I:mode>): Ditto.
25732         (mask_len_gather_load<RATIO2:mode><RATIO2I:mode>): Ditto.
25733         (len_mask_gather_load<RATIO1:mode><RATIO1:mode>): Ditto.
25734         (mask_len_gather_load<RATIO1:mode><RATIO1:mode>): Ditto.
25735         (len_mask_scatter_store<RATIO64:mode><RATIO64I:mode>): Ditto.
25736         (mask_len_scatter_store<RATIO64:mode><RATIO64I:mode>): Ditto.
25737         (len_mask_scatter_store<RATIO32:mode><RATIO32I:mode>): Ditto.
25738         (mask_len_scatter_store<RATIO32:mode><RATIO32I:mode>): Ditto.
25739         (len_mask_scatter_store<RATIO16:mode><RATIO16I:mode>): Ditto.
25740         (mask_len_scatter_store<RATIO16:mode><RATIO16I:mode>): Ditto.
25741         (len_mask_scatter_store<RATIO8:mode><RATIO8I:mode>): Ditto.
25742         (mask_len_scatter_store<RATIO8:mode><RATIO8I:mode>): Ditto.
25743         (len_mask_scatter_store<RATIO4:mode><RATIO4I:mode>): Ditto.
25744         (mask_len_scatter_store<RATIO4:mode><RATIO4I:mode>): Ditto.
25745         (len_mask_scatter_store<RATIO2:mode><RATIO2I:mode>): Ditto.
25746         (mask_len_scatter_store<RATIO2:mode><RATIO2I:mode>): Ditto.
25747         (len_mask_scatter_store<RATIO1:mode><RATIO1:mode>): Ditto.
25748         (mask_len_scatter_store<RATIO1:mode><RATIO1:mode>): Ditto.
25749         * doc/md.texi: Ditto.
25750         * genopinit.cc (main): Ditto.
25751         (CMP_NAME): Ditto. Ditto.
25752         * gimple-fold.cc (arith_overflowed_p): Ditto.
25753         (gimple_fold_partial_load_store_mem_ref): Ditto.
25754         (gimple_fold_call): Ditto.
25755         * internal-fn.cc (len_maskload_direct): Ditto.
25756         (mask_len_load_direct): Ditto.
25757         (len_maskstore_direct): Ditto.
25758         (mask_len_store_direct): Ditto.
25759         (expand_call_mem_ref): Ditto.
25760         (expand_len_maskload_optab_fn): Ditto.
25761         (expand_mask_len_load_optab_fn): Ditto.
25762         (expand_len_maskstore_optab_fn): Ditto.
25763         (expand_mask_len_store_optab_fn): Ditto.
25764         (direct_len_maskload_optab_supported_p): Ditto.
25765         (direct_mask_len_load_optab_supported_p): Ditto.
25766         (direct_len_maskstore_optab_supported_p): Ditto.
25767         (direct_mask_len_store_optab_supported_p): Ditto.
25768         (internal_load_fn_p): Ditto.
25769         (internal_store_fn_p): Ditto.
25770         (internal_gather_scatter_fn_p): Ditto.
25771         (internal_fn_len_index): Ditto.
25772         (internal_fn_mask_index): Ditto.
25773         (internal_fn_stored_value_index): Ditto.
25774         (internal_len_load_store_bias): Ditto.
25775         * internal-fn.def (LEN_MASK_GATHER_LOAD): Ditto.
25776         (MASK_LEN_GATHER_LOAD): Ditto.
25777         (LEN_MASK_LOAD): Ditto.
25778         (MASK_LEN_LOAD): Ditto.
25779         (LEN_MASK_SCATTER_STORE): Ditto.
25780         (MASK_LEN_SCATTER_STORE): Ditto.
25781         (LEN_MASK_STORE): Ditto.
25782         (MASK_LEN_STORE): Ditto.
25783         * optabs-query.cc (supports_vec_gather_load_p): Ditto.
25784         (supports_vec_scatter_store_p): Ditto.
25785         * optabs-tree.cc (target_supports_mask_load_store_p): Ditto.
25786         (target_supports_len_load_store_p): Ditto.
25787         * optabs.def (OPTAB_CD): Ditto.
25788         * tree-ssa-alias.cc (ref_maybe_used_by_call_p_1): Ditto.
25789         (call_may_clobber_ref_p_1): Ditto.
25790         * tree-ssa-dse.cc (initialize_ao_ref_for_dse): Ditto.
25791         (dse_optimize_stmt): Ditto.
25792         * tree-ssa-loop-ivopts.cc (get_mem_type_for_internal_fn): Ditto.
25793         (get_alias_ptr_type_for_ptr_address): Ditto.
25794         * tree-vect-data-refs.cc (vect_gather_scatter_fn_p): Ditto.
25795         * tree-vect-patterns.cc (vect_recog_gather_scatter_pattern): Ditto.
25796         * tree-vect-stmts.cc (check_load_store_for_partial_vectors): Ditto.
25797         (vect_get_strided_load_store_ops): Ditto.
25798         (vectorizable_store): Ditto.
25799         (vectorizable_load): Ditto.
25801 2023-07-21  Haochen Jiang  <haochen.jiang@intel.com>
25803         * config/i386/i386.opt: Fix a typo.
25805 2023-07-21  Richard Biener  <rguenther@suse.de>
25807         PR tree-optimization/88540
25808         * tree-ssa-phiopt.cc (minmax_replacement): Do not give up
25809         with NaNs but handle the simple case by if-converting to a
25810         COND_EXPR.
25812 2023-07-21  Andrew Pinski  <apinski@marvell.com>
25814         * match.pd (minmax<minmax<a,b>,a>->minmax<a,b>): New
25815         transformation.
25817 2023-07-21  Richard Biener  <rguenther@suse.de>
25819         PR tree-optimization/110742
25820         * tree-vect-slp.cc (vect_optimize_slp_pass::get_result_with_layout):
25821         Do not materialize an edge permutation in an external node with
25822         vector defs.
25823         (vect_slp_analyze_node_operations_1): Guard purely internal
25824         nodes better.
25826 2023-07-21  Jan Hubicka  <jh@suse.cz>
25828         * cfgloop.cc: Include sreal.h.
25829         (flow_loop_dump): Dump sreal iteration exsitmate.
25830         (get_estimated_loop_iterations): Update.
25831         * cfgloop.h (expected_loop_iterations_by_profile): Declare.
25832         * cfgloopanal.cc (expected_loop_iterations_by_profile): New function.
25833         (expected_loop_iterations_unbounded): Use new API.
25834         * cfgloopmanip.cc (scale_loop_profile): Use
25835         expected_loop_iterations_by_profile
25836         * predict.cc (pass_profile::execute): Likewise.
25837         * profile.cc (branch_prob): Likewise.
25838         * tree-ssa-loop-niter.cc: Include sreal.h.
25839         (estimate_numbers_of_iterations): Likewise
25841 2023-07-21  Kewen Lin  <linkw@linux.ibm.com>
25843         PR tree-optimization/110744
25844         * tree-ssa-sccvn.cc (vn_reference_lookup_3): Correct the index of bias
25845         operand for ifn IFN_LEN_STORE.
25847 2023-07-21  liuhongt  <hongtao.liu@intel.com>
25849         PR target/89701
25850         * common.opt: (fcf-protection=): Add EnumSet attribute to
25851         support combination of params.
25853 2023-07-21  David Malcolm  <dmalcolm@redhat.com>
25855         PR middle-end/110612
25856         * text-art/table.cc (table_geometry::table_geometry): Drop m_table
25857         field.
25858         (table_geometry::table_x_to_canvas_x): Add cast to comparison.
25859         (table_geometry::table_y_to_canvas_y): Likewise.
25860         * text-art/table.h (table_geometry::m_table): Drop unused field.
25861         * text-art/widget.h (wrapper_widget::update_child_alloc_rects):
25862         Add "override".
25864 2023-07-20  Uros Bizjak  <ubizjak@gmail.com>
25866         PR target/110717
25867         * config/i386/i386-features.cc
25868         (general_scalar_chain::compute_convert_gain): Calculate gain
25869         for extend higpart case.
25870         (general_scalar_chain::convert_op): Handle
25871         ASHIFTRT/ASHIFT combined RTX.
25872         (general_scalar_to_vector_candidate_p): Enable ASHIFTRT for
25873         SImode for SSE2 targets.  Handle ASHIFTRT/ASHIFT combined RTX.
25874         * config/i386/i386.md (*extend<dwi>2_doubleword_highpart):
25875         New define_insn_and_split pattern.
25876         (*extendv2di2_highpart_stv): Ditto.
25878 2023-07-20  Vladimir N. Makarov  <vmakarov@redhat.com>
25880         * lra-constraints.cc (simplify_operand_subreg): Check frame pointer
25881         simplification.
25883 2023-07-20  Andrew Pinski  <apinski@marvell.com>
25885         * combine.cc (dump_combine_stats): Remove.
25886         (dump_combine_total_stats): Remove.
25887         (total_attempts, total_merges, total_extras,
25888         total_successes): Remove.
25889         (combine_instructions): Don't increment total stats
25890         instead use statistics_counter_event.
25891         * dumpfile.cc (print_combine_total_stats): Remove.
25892         * dumpfile.h (print_combine_total_stats): Remove.
25893         (dump_combine_total_stats): Remove.
25894         * passes.cc (finish_optimization_passes):
25895         Don't call print_combine_total_stats.
25896         * rtl.h (dump_combine_total_stats): Remove.
25897         (dump_combine_stats): Remove.
25899 2023-07-20  Jan Hubicka  <jh@suse.cz>
25901         * tree-ssa-loop-ch.cc (should_duplicate_loop_header_p): Use BIT instead of TRUTH
25902         logical ops.
25904 2023-07-20  Martin Jambor  <mjambor@suse.cz>
25906         * doc/invoke.texi (analyzer-text-art-string-ellipsis-threshold): New.
25907         (analyzer-text-art-ideal-canvas-width): Likewise.
25908         (analyzer-text-art-string-ellipsis-head-len): Likewise.
25909         (analyzer-text-art-string-ellipsis-tail-len): Likewise.
25911 2023-07-20  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
25913         * tree-vect-stmts.cc (check_load_store_for_partial_vectors):
25914         Refine code structure.
25916 2023-07-20  Jan Hubicka  <jh@suse.cz>
25918         * tree-ssa-loop-ch.cc (edge_range_query): Rename to ...
25919         (get_range_query): ... this one; do
25920         (static_loop_exit): Add query parametr, turn ranger to reference.
25921         (loop_static_stmt_p): New function.
25922         (loop_static_op_p): New function.
25923         (loop_iv_derived_p): Remove.
25924         (loop_combined_static_and_iv_p): New function.
25925         (should_duplicate_loop_header_p): Discover combined onditionals;
25926         do not track iv derived; improve dumps.
25927         (pass_ch::execute): Fix whitespace.
25929 2023-07-20  Richard Biener  <rguenther@suse.de>
25931         PR tree-optimization/110204
25932         * tree-ssa-sccvn.cc (eliminate_dom_walker::eliminate_avail):
25933         Look through copies generated by PRE.
25935 2023-07-20  Matthew Malcomson  <matthew.malcomson@arm.com>
25937         * tree-vect-stmts.cc (get_group_load_store_type): Account for
25938         `gap` when checking if need to peel twice.
25940 2023-07-20  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
25942         PR middle-end/77928
25943         * doc/extend.texi: Document iseqsig builtin.
25944         * builtins.cc (fold_builtin_iseqsig): New function.
25945         (fold_builtin_2): Handle BUILT_IN_ISEQSIG.
25946         (is_inexpensive_builtin): Handle BUILT_IN_ISEQSIG.
25947         * builtins.def (BUILT_IN_ISEQSIG): New built-in.
25949 2023-07-20  Pan Li  <pan2.li@intel.com>
25951         * config/riscv/vector.md: Fix incorrect match_operand.
25953 2023-07-20  Roger Sayle  <roger@nextmovesoftware.com>
25955         * config/i386/i386-expand.cc (ix86_expand_move): Don't call
25956         force_reg, to use SUBREG rather than create a new pseudo when
25957         inserting DFmode fields into TImode with insvti_{high,low}part.
25958         * config/i386/i386.md (*concat<mode><dwi>3_3): Split into two
25959         define_insn_and_split...
25960         (*concatditi3_3): 64-bit implementation.  Provide alternative
25961         that allows register allocation to use SSE registers that is
25962         split into vec_concatv2di after reload.
25963         (*concatsidi3_3): 32-bit implementation.
25965 2023-07-20  Richard Biener  <rguenther@suse.de>
25967         PR middle-end/61747
25968         * internal-fn.cc (expand_vec_cond_optab_fn): When the
25969         value operands are equal to the original comparison operands
25970         preserve that equality by re-using the comparison expansion.
25971         * optabs.cc (emit_conditional_move): When the value operands
25972         are equal to the comparison operands and would be forced to
25973         a register by prepare_cmp_insn do so earlier, preserving the
25974         equality.
25976 2023-07-20  Pan Li  <pan2.li@intel.com>
25978         * config/riscv/vector.md: Align pattern format.
25980 2023-07-20  Haochen Jiang  <haochen.jiang@intel.com>
25982         * doc/invoke.texi: Remove AVX512VP2INTERSECT in
25983         Granite Rapids{, D} from documentation.
25985 2023-07-20  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
25987         * config/riscv/autovec.md
25988         (len_mask_gather_load<VNX16_QHSD:mode><VNX16_QHSDI:mode>):
25989         Refactor RVV machine modes.
25990         (len_mask_gather_load<VNX16_QHS:mode><VNX16_QHSI:mode>): Ditto.
25991         (len_mask_gather_load<VNX32_QHS:mode><VNX32_QHSI:mode>): Ditto.
25992         (len_mask_gather_load<VNX32_QH:mode><VNX32_QHI:mode>): Ditto.
25993         (len_mask_gather_load<VNX64_QH:mode><VNX64_QHI:mode>): Ditto.
25994         (len_mask_gather_load<mode><mode>): Ditto.
25995         (len_mask_gather_load<VNX64_Q:mode><VNX64_Q:mode>): Ditto.
25996         (len_mask_scatter_store<VNX16_QHSD:mode><VNX16_QHSDI:mode>): Ditto.
25997         (len_mask_scatter_store<VNX32_QHS:mode><VNX32_QHSI:mode>): Ditto.
25998         (len_mask_scatter_store<VNX16_QHS:mode><VNX16_QHSI:mode>): Ditto.
25999         (len_mask_scatter_store<VNX64_QH:mode><VNX64_QHI:mode>): Ditto.
26000         (len_mask_scatter_store<VNX32_QH:mode><VNX32_QHI:mode>): Ditto.
26001         (len_mask_scatter_store<mode><mode>): Ditto.
26002         (len_mask_scatter_store<VNX64_Q:mode><VNX64_Q:mode>): Ditto.
26003         * config/riscv/riscv-modes.def (VECTOR_BOOL_MODE): Ditto.
26004         (ADJUST_NUNITS): Ditto.
26005         (ADJUST_ALIGNMENT): Ditto.
26006         (ADJUST_BYTESIZE): Ditto.
26007         (ADJUST_PRECISION): Ditto.
26008         (RVV_MODES): Ditto.
26009         (RVV_WHOLE_MODES): Ditto.
26010         (RVV_FRACT_MODE): Ditto.
26011         (RVV_NF8_MODES): Ditto.
26012         (RVV_NF4_MODES): Ditto.
26013         (VECTOR_MODES_WITH_PREFIX): Ditto.
26014         (VECTOR_MODE_WITH_PREFIX): Ditto.
26015         (RVV_TUPLE_MODES): Ditto.
26016         (RVV_NF2_MODES): Ditto.
26017         (RVV_TUPLE_PARTIAL_MODES): Ditto.
26018         * config/riscv/riscv-v.cc (struct mode_vtype_group): Ditto.
26019         (ENTRY): Ditto.
26020         (TUPLE_ENTRY): Ditto.
26021         (get_vlmul): Ditto.
26022         (get_nf): Ditto.
26023         (get_ratio): Ditto.
26024         (preferred_simd_mode): Ditto.
26025         (autovectorize_vector_modes): Ditto.
26026         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_TYPE): Ditto.
26027         * config/riscv/riscv-vector-builtins.def (DEF_RVV_TYPE): Ditto.
26028         (vbool64_t): Ditto.
26029         (vbool32_t): Ditto.
26030         (vbool16_t): Ditto.
26031         (vbool8_t): Ditto.
26032         (vbool4_t): Ditto.
26033         (vbool2_t): Ditto.
26034         (vbool1_t): Ditto.
26035         (vint8mf8_t): Ditto.
26036         (vuint8mf8_t): Ditto.
26037         (vint8mf4_t): Ditto.
26038         (vuint8mf4_t): Ditto.
26039         (vint8mf2_t): Ditto.
26040         (vuint8mf2_t): Ditto.
26041         (vint8m1_t): Ditto.
26042         (vuint8m1_t): Ditto.
26043         (vint8m2_t): Ditto.
26044         (vuint8m2_t): Ditto.
26045         (vint8m4_t): Ditto.
26046         (vuint8m4_t): Ditto.
26047         (vint8m8_t): Ditto.
26048         (vuint8m8_t): Ditto.
26049         (vint16mf4_t): Ditto.
26050         (vuint16mf4_t): Ditto.
26051         (vint16mf2_t): Ditto.
26052         (vuint16mf2_t): Ditto.
26053         (vint16m1_t): Ditto.
26054         (vuint16m1_t): Ditto.
26055         (vint16m2_t): Ditto.
26056         (vuint16m2_t): Ditto.
26057         (vint16m4_t): Ditto.
26058         (vuint16m4_t): Ditto.
26059         (vint16m8_t): Ditto.
26060         (vuint16m8_t): Ditto.
26061         (vint32mf2_t): Ditto.
26062         (vuint32mf2_t): Ditto.
26063         (vint32m1_t): Ditto.
26064         (vuint32m1_t): Ditto.
26065         (vint32m2_t): Ditto.
26066         (vuint32m2_t): Ditto.
26067         (vint32m4_t): Ditto.
26068         (vuint32m4_t): Ditto.
26069         (vint32m8_t): Ditto.
26070         (vuint32m8_t): Ditto.
26071         (vint64m1_t): Ditto.
26072         (vuint64m1_t): Ditto.
26073         (vint64m2_t): Ditto.
26074         (vuint64m2_t): Ditto.
26075         (vint64m4_t): Ditto.
26076         (vuint64m4_t): Ditto.
26077         (vint64m8_t): Ditto.
26078         (vuint64m8_t): Ditto.
26079         (vfloat16mf4_t): Ditto.
26080         (vfloat16mf2_t): Ditto.
26081         (vfloat16m1_t): Ditto.
26082         (vfloat16m2_t): Ditto.
26083         (vfloat16m4_t): Ditto.
26084         (vfloat16m8_t): Ditto.
26085         (vfloat32mf2_t): Ditto.
26086         (vfloat32m1_t): Ditto.
26087         (vfloat32m2_t): Ditto.
26088         (vfloat32m4_t): Ditto.
26089         (vfloat32m8_t): Ditto.
26090         (vfloat64m1_t): Ditto.
26091         (vfloat64m2_t): Ditto.
26092         (vfloat64m4_t): Ditto.
26093         (vfloat64m8_t): Ditto.
26094         * config/riscv/riscv-vector-switch.def (ENTRY): Ditto.
26095         (TUPLE_ENTRY): Ditto.
26096         * config/riscv/riscv-vsetvl.cc (change_insn): Ditto.
26097         * config/riscv/riscv.cc (riscv_valid_lo_sum_p): Ditto.
26098         (riscv_v_adjust_nunits): Ditto.
26099         (riscv_v_adjust_bytesize): Ditto.
26100         (riscv_v_adjust_precision): Ditto.
26101         (riscv_convert_vector_bits): Ditto.
26102         * config/riscv/riscv.h (riscv_v_adjust_nunits): Ditto.
26103         * config/riscv/riscv.md: Ditto.
26104         * config/riscv/vector-iterators.md: Ditto.
26105         * config/riscv/vector.md
26106         (@pred_indexed_<order>store<VNX16_QHSD:mode><VNX16_QHSDI:mode>): Ditto.
26107         (@pred_indexed_<order>store<VNX16_QHS:mode><VNX16_QHSI:mode>): Ditto.
26108         (@pred_indexed_<order>store<VNX32_QHS:mode><VNX32_QHSI:mode>): Ditto.
26109         (@pred_indexed_<order>store<VNX32_QH:mode><VNX32_QHI:mode>): Ditto.
26110         (@pred_indexed_<order>store<VNX64_QH:mode><VNX64_QHI:mode>): Ditto.
26111         (@pred_indexed_<order>store<VNX64_Q:mode><VNX64_Q:mode>): Ditto.
26112         (@pred_indexed_<order>store<VNX128_Q:mode><VNX128_Q:mode>): Ditto.
26113         (@pred_indexed_<order>load<V1T:mode><V1I:mode>): Ditto.
26114         (@pred_indexed_<order>load<V1T:mode><VNX1_QHSDI:mode>): Ditto.
26115         (@pred_indexed_<order>load<V2T:mode><V2I:mode>): Ditto.
26116         (@pred_indexed_<order>load<V2T:mode><VNX2_QHSDI:mode>): Ditto.
26117         (@pred_indexed_<order>load<V4T:mode><V4I:mode>): Ditto.
26118         (@pred_indexed_<order>load<V4T:mode><VNX4_QHSDI:mode>): Ditto.
26119         (@pred_indexed_<order>load<V8T:mode><V8I:mode>): Ditto.
26120         (@pred_indexed_<order>load<V8T:mode><VNX8_QHSDI:mode>): Ditto.
26121         (@pred_indexed_<order>load<V16T:mode><V16I:mode>): Ditto.
26122         (@pred_indexed_<order>load<V16T:mode><VNX16_QHSI:mode>): Ditto.
26123         (@pred_indexed_<order>load<V32T:mode><V32I:mode>): Ditto.
26124         (@pred_indexed_<order>load<V32T:mode><VNX32_QHI:mode>): Ditto.
26125         (@pred_indexed_<order>load<V64T:mode><V64I:mode>): Ditto.
26126         (@pred_indexed_<order>store<V1T:mode><V1I:mode>): Ditto.
26127         (@pred_indexed_<order>store<V1T:mode><VNX1_QHSDI:mode>): Ditto.
26128         (@pred_indexed_<order>store<V2T:mode><V2I:mode>): Ditto.
26129         (@pred_indexed_<order>store<V2T:mode><VNX2_QHSDI:mode>): Ditto.
26130         (@pred_indexed_<order>store<V4T:mode><V4I:mode>): Ditto.
26131         (@pred_indexed_<order>store<V4T:mode><VNX4_QHSDI:mode>): Ditto.
26132         (@pred_indexed_<order>store<V8T:mode><V8I:mode>): Ditto.
26133         (@pred_indexed_<order>store<V8T:mode><VNX8_QHSDI:mode>): Ditto.
26134         (@pred_indexed_<order>store<V16T:mode><V16I:mode>): Ditto.
26135         (@pred_indexed_<order>store<V16T:mode><VNX16_QHSI:mode>): Ditto.
26136         (@pred_indexed_<order>store<V32T:mode><V32I:mode>): Ditto.
26137         (@pred_indexed_<order>store<V32T:mode><VNX32_QHI:mode>): Ditto.
26138         (@pred_indexed_<order>store<V64T:mode><V64I:mode>): Ditto.
26140 2023-07-19  Vladimir N. Makarov  <vmakarov@redhat.com>
26142         * lra-int.h (lra_update_fp2sp_elimination): New prototype.
26143         (lra_asm_insn_error): New prototype.
26144         * lra-spills.cc (remove_pseudos): Add check for pseudo slot memory
26145         existence.
26146         (lra_spill): Call lra_update_fp2sp_elimination.
26147         * lra-eliminations.cc: Remove trailing spaces.
26148         (elimination_fp2sp_occured_p): New static flag.
26149         (lra_eliminate_regs_1): Set the flag up.
26150         (update_reg_eliminate): Modify the assert for stack to frame
26151         pointer elimination.
26152         (lra_update_fp2sp_elimination): New function.
26153         (lra_eliminate): Clear flag elimination_fp2sp_occured_p.
26155 2023-07-19  Andrew Carlotti  <andrew.carlotti@arm.com>
26157         * config/aarch64/aarch64.h (TARGET_MEMTAG): Remove armv8.5
26158         dependency.
26159         * config/aarch64/arm_acle.h: Remove unnecessary armv8.x
26160         dependencies from target pragmas.
26161         * config/aarch64/arm_fp16.h (target): Likewise.
26162         * config/aarch64/arm_neon.h (target): Likewise.
26164 2023-07-19  Andrew Pinski  <apinski@marvell.com>
26166         PR tree-optimization/110252
26167         * tree-ssa-phiopt.cc (class auto_flow_sensitive): New class.
26168         (auto_flow_sensitive::auto_flow_sensitive): New constructor.
26169         (auto_flow_sensitive::~auto_flow_sensitive): New deconstructor.
26170         (match_simplify_replacement): Temporarily
26171         remove the flow sensitive info on the two statements that might
26172         be moved.
26174 2023-07-19  Andrew Pinski  <apinski@marvell.com>
26176         * gimple-fold.cc (fosa_unwind): Replace `vrange_storage *`
26177         with flow_sensitive_info_storage.
26178         (follow_outer_ssa_edges): Update how to save off the flow
26179         sensitive info.
26180         (maybe_fold_comparisons_from_match_pd): Update restoring
26181         of flow sensitive info.
26182         * tree-ssanames.cc (flow_sensitive_info_storage::save): New method.
26183         (flow_sensitive_info_storage::restore): New method.
26184         (flow_sensitive_info_storage::save_and_clear): New method.
26185         (flow_sensitive_info_storage::clear_storage): New method.
26186         * tree-ssanames.h (class flow_sensitive_info_storage): New class.
26188 2023-07-19  Andrew Pinski  <apinski@marvell.com>
26190         PR tree-optimization/110726
26191         * match.pd ((a|b)&(a==b),a|(a==b),(a&b)|(a==b)):
26192         Add checks to make sure the type was one bit precision
26193         intergal type.
26195 2023-07-19  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
26197         * doc/md.texi: Add mask_len_fold_left_plus.
26198         * internal-fn.cc (mask_len_fold_left_direct): Ditto.
26199         (expand_mask_len_fold_left_optab_fn): Ditto.
26200         (direct_mask_len_fold_left_optab_supported_p): Ditto.
26201         * internal-fn.def (MASK_LEN_FOLD_LEFT_PLUS): Ditto.
26202         * optabs.def (OPTAB_D): Ditto.
26204 2023-07-19  Jakub Jelinek  <jakub@redhat.com>
26206         * tree-switch-conversion.h (class bit_test_cluster): Fix comment typo.
26208 2023-07-19  Jakub Jelinek  <jakub@redhat.com>
26210         PR tree-optimization/110731
26211         * wide-int.cc (wi::divmod_internal): Always unpack dividend and
26212         divisor as UNSIGNED regardless of sgn.
26214 2023-07-19  Lehua Ding  <lehua.ding@rivai.ai>
26216         * common/config/riscv/riscv-common.cc (riscv_supported_std_ext): Init.
26217         (standard_extensions_p): Add check.
26218         (riscv_subset_list::add): Just return NULL if it failed before.
26219         (riscv_subset_list::parse_std_ext): Continue parse when find a error
26220         (riscv_subset_list::parse): Just return NULL if it failed before.
26221         * config/riscv/riscv-subset.h (class riscv_subset_list): Add field.
26223 2023-07-19  Jan Beulich  <jbeulich@suse.com>
26225         * config/i386/i386-expand.cc (ix86_expand_vector_init_duplicate):
26226         Use gen_vec_set_0.
26227         (ix86_expand_vector_extract): Use gen_vec_extract_lo /
26228         gen_vec_extract_hi.
26229         (expand_vec_perm_broadcast_1): Use gen_vec_interleave_high /
26230         gen_vec_interleave_low. Rename local variable.
26232 2023-07-19  Jan Beulich  <jbeulich@suse.com>
26234         * config/i386/sse.md (vec_dupv2df<mask_name>): Add new AVX512F
26235         alternative. Move AVX512VL part of condition to new "enabled"
26236         attribute.
26238 2023-07-19  liuhongt  <hongtao.liu@intel.com>
26240         PR target/109504
26241         * config/i386/i386-builtins.cc
26242         (ix86_register_float16_builtin_type): Remove TARGET_SSE2.
26243         (ix86_register_bf16_builtin_type): Ditto.
26244         * config/i386/i386-c.cc (ix86_target_macros): When TARGET_SSE2
26245         isn't available, undef the macros which are used to check the
26246         backend support of the _Float16/__bf16 types when building
26247         libstdc++ and libgcc.
26248         * config/i386/i386.cc (construct_container): Issue errors for
26249         HFmode/BFmode when TARGET_SSE2 is not available.
26250         (function_value_32): Ditto.
26251         (ix86_scalar_mode_supported_p): Remove TARGET_SSE2 for HFmode/BFmode.
26252         (ix86_libgcc_floating_mode_supported_p): Ditto.
26253         (ix86_emit_support_tinfos): Adjust codes.
26254         (ix86_invalid_conversion): Return diagnostic message string
26255         when there's conversion from/to BF/HFmode w/o TARGET_SSE2.
26256         (ix86_invalid_unary_op): New function.
26257         (ix86_invalid_binary_op): Ditto.
26258         (TARGET_INVALID_UNARY_OP): Define.
26259         (TARGET_INVALID_BINARY_OP): Define.
26260         * config/i386/immintrin.h [__SSE2__]: Remove for fp16/bf16
26261         related instrinsics header files.
26262         * config/i386/i386.h (VALID_SSE2_TYPE_MODE): New macro.
26264 2023-07-18  Uros Bizjak  <ubizjak@gmail.com>
26266         * dwarf2asm.cc: Change FALSE to false.
26267         * dwarf2cfi.cc (execute_dwarf2_frame): Change return type to void.
26268         * dwarf2out.cc (matches_main_base): Change return type from
26269         int to bool.  Change "last_match" variable to bool.
26270         (dump_struct_debug): Change return type from int to bool.
26271         Change "matches" and "result" function arguments to bool.
26272         (is_pseudo_reg): Change return type from int to bool.
26273         (is_tagged_type): Ditto.
26274         (same_loc_p): Ditto.
26275         (same_dw_val_p): Change return type from int to bool and adjust
26276         function body accordingly.
26277         (same_attr_p): Ditto.
26278         (same_die_p): Ditto.
26279         (is_type_die): Ditto.
26280         (is_declaration_die): Ditto.
26281         (should_move_die_to_comdat): Ditto.
26282         (is_base_type): Ditto.
26283         (is_based_loc): Ditto.
26284         (local_scope_p): Ditto.
26285         (class_scope_p): Ditto.
26286         (class_or_namespace_scope_p): Ditto.
26287         (is_tagged_type): Ditto.
26288         (is_rust): Use void argument.
26289         (is_nested_in_subprogram): Change return type from int to bool.
26290         (contains_subprogram_definition): Ditto.
26291         (gen_struct_or_union_type_die): Change "nested", "complete"
26292         and "ns_decl" variables to bool.
26293         (is_naming_typedef_decl): Change FALSE to false.
26295 2023-07-18  Jan Hubicka  <jh@suse.cz>
26297         * tree-ssa-loop-ch.cc (edge_range_query): Take loop argument; be ready
26298         for queries not in headers.
26299         (static_loop_exit): Add basic blck parameter; update use of
26300         edge_range_query
26301         (should_duplicate_loop_header_p): Add ranger and static_exits
26302         parameter.  Do not account statements that will be optimized
26303         out after duplicaiton in overall size. Add ranger query to
26304         find static exits.
26305         (update_profile_after_ch):  Take static_exits has set instead of
26306         single eliminated_edge.
26307         (ch_base::copy_headers): Do all analysis in the first pass;
26308         remember invariant_exits and static_exits.
26310 2023-07-18  Jason Merrill  <jason@redhat.com>
26312         * fold-const.cc (native_interpret_aggregate): Skip empty fields.
26314 2023-07-18  Gaius Mulley  <gaiusmod2@gmail.com>
26316         * doc/gm2.texi (Semantic checking): Change example testwithptr
26317         to testnew6.
26319 2023-07-18  Richard Biener  <rguenther@suse.de>
26321         PR middle-end/105715
26322         * gimple-isel.cc (gimple_expand_vec_exprs): Merge into...
26323         (pass_gimple_isel::execute): ... this.  Duplicate
26324         comparison defs of COND_EXPRs.
26326 2023-07-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
26328         * config/riscv/riscv-selftests.cc (run_poly_int_selftests): Add more selftests.
26329         * config/riscv/riscv.cc (riscv_legitimize_poly_move): Dynamic adjust size of VLA vectors.
26330         (riscv_convert_vector_bits): Ditto.
26332 2023-07-18  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
26334         * config/riscv/autovec.md (vec_shl_insert_<mode>): New patterns.
26335         * config/riscv/riscv-v.cc (shuffle_compress_patterns): Fix bugs.
26337 2023-07-18  Juergen Christ  <jchrist@linux.ibm.com>
26339         * config/s390/vx-builtins.md: New vsel pattern.
26341 2023-07-18  liuhongt  <hongtao.liu@intel.com>
26343         PR target/110438
26344         * config/i386/sse.md (<mask_codefor>one_cmpl<mode>2<mask_name>):
26345         Remove # from assemble output.
26347 2023-07-18  liuhongt  <hongtao.liu@intel.com>
26349         PR target/110591
26350         * config/i386/sync.md (cmpccxadd_<mode>): Adjust the pattern
26351         to explicitly set FLAGS_REG like *cmp<mode>_1, also add extra
26352         3 define_peephole2 after the pattern.
26354 2023-07-18  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
26356         * rtl-ssa/internals.inl: Fix when mode1 and mode2 are not ordred.
26358 2023-07-18  Pan Li  <pan2.li@intel.com>
26359             Juzhe-Zhong  <juzhe.zhong@rivai.ai>
26361         * config/riscv/riscv.cc (struct machine_function): Add new field.
26362         (riscv_static_frm_mode_p): New function.
26363         (riscv_emit_frm_mode_set): New function for emit FRM.
26364         (riscv_emit_mode_set): Extract function for FRM.
26365         (riscv_mode_needed): Fix the TODO.
26366         (riscv_mode_entry): Initial dynamic frm RTL.
26367         (riscv_mode_exit): Return DYN_EXIT.
26368         * config/riscv/riscv.md: Add rdfrm.
26369         * config/riscv/vector-iterators.md (unspecv): Add DYN_EXIT unspecv.
26370         * config/riscv/vector.md (frm_modee): Add new mode dyn_exit.
26371         (fsrm): Removed.
26372         (fsrmsi_backup): New pattern for swap.
26373         (fsrmsi_restore): New pattern for restore.
26374         (fsrmsi_restore_exit): New pattern for restore exit.
26375         (frrmsi): New pattern for backup.
26377 2023-07-17  Arsen Arsenović  <arsen@aarsen.me>
26379         * doc/extend.texi: Add @cindex on __auto_type.
26381 2023-07-17  Uros Bizjak  <ubizjak@gmail.com>
26383         * combine-stack-adj.cc (stack_memref_p): Change return type from
26384         int to bool and adjust function body accordingly.
26385         (rest_of_handle_stack_adjustments): Change return type to void.
26387 2023-07-17  Uros Bizjak  <ubizjak@gmail.com>
26389         * combine.cc (struct reg_stat_type): Change last_set_invalid to bool.
26390         (cant_combine_insn_p): Change return type from int to bool and adjust
26391         function body accordingly.
26392         (can_combine_p): Ditto.
26393         (combinable_i3pat): Ditto.  Change "i1_not_in_src" and "i0_not_in_src"
26394         function arguments from int to bool.
26395         (contains_muldiv): Change return type from int to bool and adjust
26396         function body accordingly.
26397         (try_combine): Ditto. Change "new_direct_jump" pointer function
26398         argument from int to bool.  Change "substed_i2", "substed_i1",
26399         "substed_i0", "added_sets_0", "added_sets_1", "added_sets_2",
26400         "i2dest_in_i2src", "i1dest_in_i1src", "i2dest_in_i1src",
26401         "i0dest_in_i0src", "i1dest_in_i0src", "i2dest_in_i0src",
26402         "i2dest_killed", "i1dest_killed", "i0dest_killed", "i1_feeds_i2_n",
26403         "i0_feeds_i2_n", "i0_feeds_i1_n", "i3_subst_into_i2", "have_mult",
26404         "swap_i2i3", "split_i2i3" and "changed_i3_dest" variables
26405         from int to bool.
26406         (subst): Change "in_dest", "in_cond" and "unique_copy" function
26407         arguments from int to bool.
26408         (combine_simplify_rtx): Change "in_dest" and "in_cond" function
26409         arguments from int to bool.
26410         (make_extraction): Change "unsignedp", "in_dest" and "in_compare"
26411         function argument from int to bool.
26412         (force_int_to_mode): Change "just_select" function argument
26413         from int to bool.  Change "next_select" variable to bool.
26414         (rtx_equal_for_field_assignment_p): Change return type from
26415         int to bool and adjust function body accordingly.
26416         (merge_outer_ops): Ditto.  Change "pcomp_p" pointer function
26417         argument from int to bool.
26418         (get_last_value_validate): Change return type from int to bool
26419         and adjust function body accordingly.
26420         (reg_dead_at_p): Ditto.
26421         (reg_bitfield_target_p): Ditto.
26422         (combine_instructions): Ditto.  Change "new_direct_jump"
26423         variable to bool.
26424         (can_combine_p): Change return type from int to bool
26425         and adjust function body accordingly.
26426         (likely_spilled_retval_p): Ditto.
26427         (can_change_dest_mode): Change "added_sets" function argument
26428         from int to bool.
26429         (find_split_point): Change "unsignedp" variable to bool.
26430         (simplify_if_then_else): Change "comparison_p" and "swapped"
26431         variables to bool.
26432         (simplify_set): Change "other_changed" variable to bool.
26433         (expand_compound_operation): Change "unsignedp" variable to bool.
26434         (force_to_mode): Change "just_select" function argument
26435         from int to bool.  Change "next_select" variable to bool.
26436         (extended_count): Change "unsignedp" function argument to bool.
26437         (simplify_shift_const_1): Change "complement_p" variable to bool.
26438         (simplify_comparison): Change "changed" variable to bool.
26439         (rest_of_handle_combine): Change return type to void.
26441 2023-07-17  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26443         PR plugins/110610
26444         * Makefile.in (INTERNAL_FN_H): Add insn-opinit.h.
26446 2023-07-17  Senthil Kumar Selvaraj  <saaadhu@gcc.gnu.org>
26448         * ira.cc (setup_reg_class_relations): Continue
26449         if regclass cl3 is hard_reg_set_empty_p.
26451 2023-07-17  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
26453         * config/riscv/riscv.cc (riscv_option_override): Add sorry check.
26455 2023-07-17  Martin Jambor  <mjambor@suse.cz>
26457         * tree-ssa-loop-ivcanon.cc (try_peel_loop): Remove unused variable
26458         entry_count.
26460 2023-07-17  Aldy Hernandez  <aldyh@redhat.com>
26462         * tree-ssa-ccp.cc (ccp_finalize): Export value/mask known bits.
26464 2023-07-17  Lehua Ding  <lehua.ding@rivai.ai>
26466         PR target/110696
26467         * common/config/riscv/riscv-common.cc (riscv_subset_list::handle_implied_ext):
26468         recur add all implied extensions.
26469         (riscv_subset_list::check_implied_ext): Add new method.
26470         (riscv_subset_list::parse): Call checker check_implied_ext.
26471         * config/riscv/riscv-subset.h: Add new method.
26473 2023-07-17  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
26475         * config/riscv/autovec.md (reduc_plus_scal_<mode>): New pattern.
26476         (reduc_smax_scal_<mode>): Ditto.
26477         (reduc_umax_scal_<mode>): Ditto.
26478         (reduc_smin_scal_<mode>): Ditto.
26479         (reduc_umin_scal_<mode>): Ditto.
26480         (reduc_and_scal_<mode>): Ditto.
26481         (reduc_ior_scal_<mode>): Ditto.
26482         (reduc_xor_scal_<mode>): Ditto.
26483         * config/riscv/riscv-protos.h (enum insn_type): Add reduction.
26484         (expand_reduction): New function.
26485         * config/riscv/riscv-v.cc (emit_vlmax_reduction_insn): Ditto.
26486         (emit_vlmax_fp_reduction_insn): Ditto.
26487         (get_m1_mode): Ditto.
26488         (expand_cond_len_binop): Fix name.
26489         (expand_reduction): New function
26490         * config/riscv/riscv-vsetvl.cc (gen_vsetvl_pat): Fix VSETVL BUG.
26491         (validate_change_or_fail): New function.
26492         (change_insn): Fix VSETVL BUG.
26493         (change_vsetvl_insn): Ditto.
26494         (pass_vsetvl::backward_demand_fusion): Ditto.
26495         (pass_vsetvl::df_post_optimization): Ditto.
26497 2023-07-17  Aldy Hernandez  <aldyh@redhat.com>
26499         * ipa-prop.cc (ipcp_update_bits): Export value/mask known bits.
26501 2023-07-17  Christoph Müllner  <christoph.muellner@vrull.eu>
26503         * config/riscv/riscv.cc (riscv_regno_ok_for_index_p):
26504         Remove parameter name from declaration of unused parameter.
26506 2023-07-17  Kewen Lin  <linkw@linux.ibm.com>
26508         PR tree-optimization/110652
26509         * tree-vect-stmts.cc (vectorizable_load): Initialize new_temp as
26510         NULL_TREE.
26512 2023-07-17  Richard Biener  <rguenther@suse.de>
26514         PR tree-optimization/110669
26515         * tree-scalar-evolution.cc (analyze_and_compute_bitop_with_inv_effect):
26516         Check we matched a header PHI.
26518 2023-07-17  Aldy Hernandez  <aldyh@redhat.com>
26520         * tree-ssanames.cc (set_bitmask): New.
26521         * tree-ssanames.h (set_bitmask): New.
26523 2023-07-17  Aldy Hernandez  <aldyh@redhat.com>
26525         * value-range.cc (irange_bitmask::verify_mask): Mask need not be
26526         normalized.
26527         * value-range.h (irange_bitmask::union_): Normalize beforehand.
26528         (irange_bitmask::intersect): Same.
26530 2023-07-17  Andrew Pinski  <apinski@marvell.com>
26532         PR tree-optimization/95923
26533         * match.pd ((a|b)&(a==b),a|(a==b),(a&b)|(a==b)): New transformation.
26535 2023-07-17  Roger Sayle  <roger@nextmovesoftware.com>
26537         * tree-if-conv.cc (predicate_scalar_phi): Make the arguments
26538         to the std::sort comparison lambda function const.
26540 2023-07-17  Andrew Pinski  <apinski@marvell.com>
26542         PR tree-optimization/110666
26543         * match.pd (A NEEQ (A NEEQ CST)): Fix Outer EQ case.
26545 2023-07-17  Mo, Zewei  <zewei.mo@intel.com>
26547         * common/config/i386/cpuinfo.h (get_intel_cpu): Handle Lunar Lake,
26548         Arrow Lake and Arrow Lake S.
26549         * common/config/i386/i386-common.cc:
26550         (processor_name): Add arrowlake.
26551         (processor_alias_table): Add arrow lake, arrow lake s and lunar
26552         lake.
26553         * common/config/i386/i386-cpuinfo.h (enum processor_subtypes):
26554         Add INTEL_COREI7_ARROWLAKE and INTEL_COREI7_ARROWLAKE_S.
26555         * config.gcc: Add -march=arrowlake and -march=arrowlake-s.
26556         * config/i386/driver-i386.cc (host_detect_local_cpu): Handle
26557         arrowlake-s.
26558         * config/i386/i386-c.cc (ix86_target_macros_internal): Add
26559         arrowlake.
26560         * config/i386/i386-options.cc (m_ARROWLAKE): New.
26561         (processor_cost_table): Add arrowlake.
26562         * config/i386/i386.h (enum processor_type):
26563         Add PROCESSOR_ARROWLAKE.
26564         * config/i386/x86-tune.def: Add m_ARROWLAKE.
26565         * doc/extend.texi: Add arrowlake and arrowlake-s.
26566         * doc/invoke.texi: Ditto.
26568 2023-07-17  Haochen Jiang  <haochen.jiang@intel.com>
26570         * config/i386/sse.md (VI2_AVX2): Delete V32HI since we actually
26571         have the same iterator. Also renaming all the occurence to
26572         VI2_AVX2_AVX512BW.
26573         (usdot_prod<mode>): New define_expand.
26574         (udot_prod<mode>): Ditto.
26576 2023-07-17  Haochen Jiang  <haochen.jiang@intel.com>
26578         * common/config/i386/cpuinfo.h (get_available_features):
26579         Detech SM4.
26580         * common/config/i386/i386-common.cc (OPTION_MASK_ISA2_SM4_SET,
26581         OPTION_MASK_ISA2_SM4_UNSET): New.
26582         (OPTION_MASK_ISA2_AVX_UNSET): Add SM4.
26583         (ix86_handle_option): Handle -msm4.
26584         * common/config/i386/i386-cpuinfo.h (enum processor_features):
26585         Add FEATURE_SM4.
26586         * common/config/i386/i386-isas.h: Add ISA_NAME_TABLE_ENTRY for
26587         sm4.
26588         * config.gcc: Add sm4intrin.h.
26589         * config/i386/cpuid.h (bit_SM4): New.
26590         * config/i386/i386-builtin.def (BDESC): Add new builtins.
26591         * config/i386/i386-c.cc (ix86_target_macros_internal): Define
26592         __SM4__.
26593         * config/i386/i386-isa.def (SM4): Add DEF_PTA(SM4).
26594         * config/i386/i386-options.cc (isa2_opts): Add -msm4.
26595         (ix86_valid_target_attribute_inner_p): Handle sm4.
26596         * config/i386/i386.opt: Add option -msm4.
26597         * config/i386/immintrin.h: Include sm4intrin.h
26598         * config/i386/sse.md (vsm4key4_<mode>): New define insn.
26599         (vsm4rnds4_<mode>): Ditto.
26600         * doc/extend.texi: Document sm4.
26601         * doc/invoke.texi: Document -msm4.
26602         * doc/sourcebuild.texi: Document target sm4.
26603         * config/i386/sm4intrin.h: New file.
26605 2023-07-17  Haochen Jiang  <haochen.jiang@intel.com>
26607         * common/config/i386/cpuinfo.h (get_available_features):
26608         Detect SHA512.
26609         * common/config/i386/i386-common.cc (OPTION_MASK_ISA2_SHA512_SET,
26610         OPTION_MASK_ISA2_SHA512_UNSET): New.
26611         (OPTION_MASK_ISA2_AVX_UNSET): Add SHA512.
26612         (ix86_handle_option): Handle -msha512.
26613         * common/config/i386/i386-cpuinfo.h (enum processor_features):
26614         Add FEATURE_SHA512.
26615         * common/config/i386/i386-isas.h: Add ISA_NAME_TABLE_ENTRY for
26616         sha512.
26617         * config.gcc: Add sha512intrin.h.
26618         * config/i386/cpuid.h (bit_SHA512): New.
26619         * config/i386/i386-builtin-types.def:
26620         Add DEF_FUNCTION_TYPE (V4DI, V4DI, V4DI, V2DI).
26621         * config/i386/i386-builtin.def (BDESC): Add new builtins.
26622         * config/i386/i386-c.cc (ix86_target_macros_internal): Define
26623         __SHA512__.
26624         * config/i386/i386-expand.cc (ix86_expand_args_builtin): Handle
26625         V4DI_FTYPE_V4DI_V4DI_V2DI and V4DI_FTYPE_V4DI_V2DI.
26626         * config/i386/i386-isa.def (SHA512): Add DEF_PTA(SHA512).
26627         * config/i386/i386-options.cc (isa2_opts): Add -msha512.
26628         (ix86_valid_target_attribute_inner_p): Handle sha512.
26629         * config/i386/i386.opt: Add option -msha512.
26630         * config/i386/immintrin.h: Include sha512intrin.h.
26631         * config/i386/sse.md (vsha512msg1): New define insn.
26632         (vsha512msg2): Ditto.
26633         (vsha512rnds2): Ditto.
26634         * doc/extend.texi: Document sha512.
26635         * doc/invoke.texi: Document -msha512.
26636         * doc/sourcebuild.texi: Document target sha512.
26637         * config/i386/sha512intrin.h: New file.
26639 2023-07-17  Haochen Jiang  <haochen.jiang@intel.com>
26641         * common/config/i386/cpuinfo.h (get_available_features):
26642         Detect SM3.
26643         * common/config/i386/i386-common.cc (OPTION_MASK_ISA2_SM3_SET,
26644         OPTION_MASK_ISA2_SM3_UNSET): New.
26645         (OPTION_MASK_ISA2_AVX_UNSET): Add SM3.
26646         (ix86_handle_option): Handle -msm3.
26647         * common/config/i386/i386-cpuinfo.h (enum processor_features):
26648         Add FEATURE_SM3.
26649         * common/config/i386/i386-isas.h: Add ISA_NAME_TABLE_ENTRY for
26650         SM3.
26651         * config.gcc: Add sm3intrin.h
26652         * config/i386/cpuid.h (bit_SM3): New.
26653         * config/i386/i386-builtin-types.def:
26654         Add DEF_FUNCTION_TYPE (V4SI, V4SI, V4SI, V4SI, INT).
26655         * config/i386/i386-builtin.def (BDESC): Add new builtins.
26656         * config/i386/i386-c.cc (ix86_target_macros_internal): Define
26657         __SM3__.
26658         * config/i386/i386-expand.cc (ix86_expand_args_builtin): Handle
26659         V4SI_FTYPE_V4SI_V4SI_V4SI_INT.
26660         * config/i386/i386-isa.def (SM3): Add DEF_PTA(SM3).
26661         * config/i386/i386-options.cc (isa2_opts): Add -msm3.
26662         (ix86_valid_target_attribute_inner_p): Handle sm3.
26663         * config/i386/i386.opt: Add option -msm3.
26664         * config/i386/immintrin.h: Include sm3intrin.h.
26665         * config/i386/sse.md (vsm3msg1): New define insn.
26666         (vsm3msg2): Ditto.
26667         (vsm3rnds2): Ditto.
26668         * doc/extend.texi: Document sm3.
26669         * doc/invoke.texi: Document -msm3.
26670         * doc/sourcebuild.texi: Document target sm3.
26671         * config/i386/sm3intrin.h: New file.
26673 2023-07-17  Kong Lingling  <lingling.kong@intel.com>
26674             Haochen Jiang  <haochen.jiang@intel.com>
26676         * common/config/i386/cpuinfo.h (get_available_features): Detect
26677         avxvnniint16.
26678         * common/config/i386/i386-common.cc
26679         (OPTION_MASK_ISA2_AVXVNNIINT16_SET): New.
26680         (OPTION_MASK_ISA2_AVXVNNIINT16_UNSET): Ditto.
26681         (ix86_handle_option): Handle -mavxvnniint16.
26682         * common/config/i386/i386-cpuinfo.h (enum processor_features):
26683         Add FEATURE_AVXVNNIINT16.
26684         * common/config/i386/i386-isas.h: Add ISA_NAME_TABLE_ENTRY for
26685         avxvnniint16.
26686         * config.gcc: Add avxvnniint16.h.
26687         * config/i386/avxvnniint16intrin.h: New file.
26688         * config/i386/cpuid.h (bit_AVXVNNIINT16): New.
26689         * config/i386/i386-builtin.def: Add new builtins.
26690         * config/i386/i386-c.cc (ix86_target_macros_internal): Define
26691         __AVXVNNIINT16__.
26692         * config/i386/i386-options.cc (isa2_opts): Add -mavxvnniint16.
26693         (ix86_valid_target_attribute_inner_p): Handle avxvnniint16intrin.h.
26694         * config/i386/i386-isa.def: Add DEF_PTA(AVXVNNIINT16).
26695         * config/i386/i386.opt: Add option -mavxvnniint16.
26696         * config/i386/immintrin.h: Include avxvnniint16.h.
26697         * config/i386/sse.md
26698         (vpdp<vpdpwprodtype>_<mode>): New define_insn.
26699         * doc/extend.texi: Document avxvnniint16.
26700         * doc/invoke.texi: Document -mavxvnniint16.
26701         * doc/sourcebuild.texi: Document target avxvnniint16.
26703 2023-07-16  Jan Hubicka  <jh@suse.cz>
26705         PR middle-end/110649
26706         * tree-vect-loop.cc (scale_profile_for_vect_loop): Rewrite.
26707         (vect_transform_loop): Move scale_profile_for_vect_loop after
26708         upper bound updates.
26710 2023-07-16  Jan Hubicka  <jh@suse.cz>
26712         PR tree-optimization/110649
26713         * tree-vect-loop.cc (optimize_mask_stores): Set correctly
26714         probability of the if-then-else construct.
26716 2023-07-16  Jan Hubicka  <jh@suse.cz>
26718         PR middle-end/110649
26719         * tree-ssa-loop-ivcanon.cc (try_peel_loop): Avoid double profile update.
26721 2023-07-15  Andrew Pinski  <apinski@marvell.com>
26723         * doc/contrib.texi: Update my entry.
26725 2023-07-15  John David Anglin  <danglin@gcc.gnu.org>
26727         * config/pa/pa.md: Define constants R1_REGNUM, R19_REGNUM and
26728         R27_REGNUM.
26729         (tgd_load): Restrict to !TARGET_64BIT. Use register constants.
26730         (tld_load): Likewise.
26731         (tgd_load_pic): Change to expander.
26732         (tld_load_pic, tld_offset_load, tp_load): Likewise.
26733         (tie_load_pic, tle_load): Likewise.
26734         (tgd_load_picsi, tgd_load_picdi): New.
26735         (tld_load_picsi, tld_load_picdi): New.
26736         (tld_offset_load<P:mode>): New.
26737         (tp_load<P:mode>): New.
26738         (tie_load_picsi, tie_load_picdi): New.
26739         (tle_load<P:mode>): New.
26741 2023-07-14  Christophe Lyon  <christophe.lyon@linaro.org>
26743         * config/arm/arm-mve-builtins-base.cc (vcmlaq, vcmlaq_rot90)
26744         (vcmlaq_rot180, vcmlaq_rot270): New.
26745         * config/arm/arm-mve-builtins-base.def (vcmlaq, vcmlaq_rot90)
26746         (vcmlaq_rot180, vcmlaq_rot270): New.
26747         * config/arm/arm-mve-builtins-base.h: (vcmlaq, vcmlaq_rot90)
26748         (vcmlaq_rot180, vcmlaq_rot270): New.
26749         * config/arm/arm-mve-builtins.cc
26750         (function_instance::has_inactive_argument): Handle vcmlaq,
26751         vcmlaq_rot90, vcmlaq_rot180, vcmlaq_rot270.
26752         * config/arm/arm_mve.h (vcmlaq): Delete.
26753         (vcmlaq_rot180): Delete.
26754         (vcmlaq_rot270): Delete.
26755         (vcmlaq_rot90): Delete.
26756         (vcmlaq_m): Delete.
26757         (vcmlaq_rot180_m): Delete.
26758         (vcmlaq_rot270_m): Delete.
26759         (vcmlaq_rot90_m): Delete.
26760         (vcmlaq_f16): Delete.
26761         (vcmlaq_rot180_f16): Delete.
26762         (vcmlaq_rot270_f16): Delete.
26763         (vcmlaq_rot90_f16): Delete.
26764         (vcmlaq_f32): Delete.
26765         (vcmlaq_rot180_f32): Delete.
26766         (vcmlaq_rot270_f32): Delete.
26767         (vcmlaq_rot90_f32): Delete.
26768         (vcmlaq_m_f32): Delete.
26769         (vcmlaq_m_f16): Delete.
26770         (vcmlaq_rot180_m_f32): Delete.
26771         (vcmlaq_rot180_m_f16): Delete.
26772         (vcmlaq_rot270_m_f32): Delete.
26773         (vcmlaq_rot270_m_f16): Delete.
26774         (vcmlaq_rot90_m_f32): Delete.
26775         (vcmlaq_rot90_m_f16): Delete.
26776         (__arm_vcmlaq_f16): Delete.
26777         (__arm_vcmlaq_rot180_f16): Delete.
26778         (__arm_vcmlaq_rot270_f16): Delete.
26779         (__arm_vcmlaq_rot90_f16): Delete.
26780         (__arm_vcmlaq_f32): Delete.
26781         (__arm_vcmlaq_rot180_f32): Delete.
26782         (__arm_vcmlaq_rot270_f32): Delete.
26783         (__arm_vcmlaq_rot90_f32): Delete.
26784         (__arm_vcmlaq_m_f32): Delete.
26785         (__arm_vcmlaq_m_f16): Delete.
26786         (__arm_vcmlaq_rot180_m_f32): Delete.
26787         (__arm_vcmlaq_rot180_m_f16): Delete.
26788         (__arm_vcmlaq_rot270_m_f32): Delete.
26789         (__arm_vcmlaq_rot270_m_f16): Delete.
26790         (__arm_vcmlaq_rot90_m_f32): Delete.
26791         (__arm_vcmlaq_rot90_m_f16): Delete.
26792         (__arm_vcmlaq): Delete.
26793         (__arm_vcmlaq_rot180): Delete.
26794         (__arm_vcmlaq_rot270): Delete.
26795         (__arm_vcmlaq_rot90): Delete.
26796         (__arm_vcmlaq_m): Delete.
26797         (__arm_vcmlaq_rot180_m): Delete.
26798         (__arm_vcmlaq_rot270_m): Delete.
26799         (__arm_vcmlaq_rot90_m): Delete.
26801 2023-07-14  Christophe Lyon  <christophe.lyon@linaro.org>
26803         * config/arm/arm_mve_builtins.def (vcmlaq_rot90_f)
26804         (vcmlaq_rot270_f, vcmlaq_rot180_f, vcmlaq_f): Add "_f" suffix.
26805         * config/arm/iterators.md (MVE_VCMLAQ_M): New.
26806         (mve_insn): Add vcmla.
26807         (rot): Add VCMLAQ_M_F, VCMLAQ_ROT90_M_F, VCMLAQ_ROT180_M_F,
26808         VCMLAQ_ROT270_M_F.
26809         (mve_rot): Add VCMLAQ_M_F, VCMLAQ_ROT90_M_F, VCMLAQ_ROT180_M_F,
26810         VCMLAQ_ROT270_M_F.
26811         * config/arm/mve.md (mve_vcmlaq<mve_rot><mode>): Rename into ...
26812         (@mve_<mve_insn>q<mve_rot>_f<mode>): ... this.
26813         (mve_vcmlaq_m_f<mode>, mve_vcmlaq_rot180_m_f<mode>)
26814         (mve_vcmlaq_rot270_m_f<mode>, mve_vcmlaq_rot90_m_f<mode>): Merge
26815         into ...
26816         (@mve_<mve_insn>q<mve_rot>_m_f<mode>): ... this.
26818 2023-07-14  Christophe Lyon  <christophe.lyon@linaro.org>
26820         * config/arm/arm-mve-builtins-base.cc (vcmulq, vcmulq_rot90)
26821         (vcmulq_rot180, vcmulq_rot270): New.
26822         * config/arm/arm-mve-builtins-base.def (vcmulq, vcmulq_rot90)
26823         (vcmulq_rot180, vcmulq_rot270): New.
26824         * config/arm/arm-mve-builtins-base.h: (vcmulq, vcmulq_rot90)
26825         (vcmulq_rot180, vcmulq_rot270): New.
26826         * config/arm/arm_mve.h (vcmulq_rot90): Delete.
26827         (vcmulq_rot270): Delete.
26828         (vcmulq_rot180): Delete.
26829         (vcmulq): Delete.
26830         (vcmulq_m): Delete.
26831         (vcmulq_rot180_m): Delete.
26832         (vcmulq_rot270_m): Delete.
26833         (vcmulq_rot90_m): Delete.
26834         (vcmulq_x): Delete.
26835         (vcmulq_rot90_x): Delete.
26836         (vcmulq_rot180_x): Delete.
26837         (vcmulq_rot270_x): Delete.
26838         (vcmulq_rot90_f16): Delete.
26839         (vcmulq_rot270_f16): Delete.
26840         (vcmulq_rot180_f16): Delete.
26841         (vcmulq_f16): Delete.
26842         (vcmulq_rot90_f32): Delete.
26843         (vcmulq_rot270_f32): Delete.
26844         (vcmulq_rot180_f32): Delete.
26845         (vcmulq_f32): Delete.
26846         (vcmulq_m_f32): Delete.
26847         (vcmulq_m_f16): Delete.
26848         (vcmulq_rot180_m_f32): Delete.
26849         (vcmulq_rot180_m_f16): Delete.
26850         (vcmulq_rot270_m_f32): Delete.
26851         (vcmulq_rot270_m_f16): Delete.
26852         (vcmulq_rot90_m_f32): Delete.
26853         (vcmulq_rot90_m_f16): Delete.
26854         (vcmulq_x_f16): Delete.
26855         (vcmulq_x_f32): Delete.
26856         (vcmulq_rot90_x_f16): Delete.
26857         (vcmulq_rot90_x_f32): Delete.
26858         (vcmulq_rot180_x_f16): Delete.
26859         (vcmulq_rot180_x_f32): Delete.
26860         (vcmulq_rot270_x_f16): Delete.
26861         (vcmulq_rot270_x_f32): Delete.
26862         (__arm_vcmulq_rot90_f16): Delete.
26863         (__arm_vcmulq_rot270_f16): Delete.
26864         (__arm_vcmulq_rot180_f16): Delete.
26865         (__arm_vcmulq_f16): Delete.
26866         (__arm_vcmulq_rot90_f32): Delete.
26867         (__arm_vcmulq_rot270_f32): Delete.
26868         (__arm_vcmulq_rot180_f32): Delete.
26869         (__arm_vcmulq_f32): Delete.
26870         (__arm_vcmulq_m_f32): Delete.
26871         (__arm_vcmulq_m_f16): Delete.
26872         (__arm_vcmulq_rot180_m_f32): Delete.
26873         (__arm_vcmulq_rot180_m_f16): Delete.
26874         (__arm_vcmulq_rot270_m_f32): Delete.
26875         (__arm_vcmulq_rot270_m_f16): Delete.
26876         (__arm_vcmulq_rot90_m_f32): Delete.
26877         (__arm_vcmulq_rot90_m_f16): Delete.
26878         (__arm_vcmulq_x_f16): Delete.
26879         (__arm_vcmulq_x_f32): Delete.
26880         (__arm_vcmulq_rot90_x_f16): Delete.
26881         (__arm_vcmulq_rot90_x_f32): Delete.
26882         (__arm_vcmulq_rot180_x_f16): Delete.
26883         (__arm_vcmulq_rot180_x_f32): Delete.
26884         (__arm_vcmulq_rot270_x_f16): Delete.
26885         (__arm_vcmulq_rot270_x_f32): Delete.
26886         (__arm_vcmulq_rot90): Delete.
26887         (__arm_vcmulq_rot270): Delete.
26888         (__arm_vcmulq_rot180): Delete.
26889         (__arm_vcmulq): Delete.
26890         (__arm_vcmulq_m): Delete.
26891         (__arm_vcmulq_rot180_m): Delete.
26892         (__arm_vcmulq_rot270_m): Delete.
26893         (__arm_vcmulq_rot90_m): Delete.
26894         (__arm_vcmulq_x): Delete.
26895         (__arm_vcmulq_rot90_x): Delete.
26896         (__arm_vcmulq_rot180_x): Delete.
26897         (__arm_vcmulq_rot270_x): Delete.
26899 2023-07-14  Christophe Lyon  <christophe.lyon@linaro.org>
26901         * config/arm/arm_mve_builtins.def (vcmulq_rot90_f)
26902         (vcmulq_rot270_f, vcmulq_rot180_f, vcmulq_f): Add "_f" suffix.
26903         * config/arm/iterators.md (MVE_VCADDQ_VCMULQ)
26904         (MVE_VCADDQ_VCMULQ_M): New.
26905         (mve_insn): Add vcmul.
26906         (rot): Add VCMULQ_M_F, VCMULQ_ROT90_M_F, VCMULQ_ROT180_M_F,
26907         VCMULQ_ROT270_M_F.
26908         (VCMUL): Delete.
26909         (mve_rot): Add VCMULQ_M_F, VCMULQ_ROT90_M_F, VCMULQ_ROT180_M_F,
26910         VCMULQ_ROT270_M_F.
26911         * config/arm/mve.md (mve_vcmulq<mve_rot><mode>): Merge into
26912         @mve_<mve_insn>q<mve_rot>_f<mode>.
26913         (mve_vcmulq_m_f<mode>, mve_vcmulq_rot180_m_f<mode>)
26914         (mve_vcmulq_rot270_m_f<mode>, mve_vcmulq_rot90_m_f<mode>): Merge
26915         into @mve_<mve_insn>q<mve_rot>_m_f<mode>.
26917 2023-07-14  Christophe Lyon  <christophe.lyon@linaro.org>
26919         * config/arm/arm-mve-builtins-base.cc (vcaddq_rot90)
26920         (vcaddq_rot270, vhcaddq_rot90, vhcaddq_rot270): New.
26921         * config/arm/arm-mve-builtins-base.def (vcaddq_rot90)
26922         (vcaddq_rot270, vhcaddq_rot90, vhcaddq_rot270): New.
26923         * config/arm/arm-mve-builtins-base.h: (vcaddq_rot90)
26924         (vcaddq_rot270, vhcaddq_rot90, vhcaddq_rot270): New.
26925         * config/arm/arm-mve-builtins-functions.h (class
26926         unspec_mve_function_exact_insn_rot): New.
26927         * config/arm/arm_mve.h (vcaddq_rot90): Delete.
26928         (vcaddq_rot270): Delete.
26929         (vhcaddq_rot90): Delete.
26930         (vhcaddq_rot270): Delete.
26931         (vcaddq_rot270_m): Delete.
26932         (vcaddq_rot90_m): Delete.
26933         (vhcaddq_rot270_m): Delete.
26934         (vhcaddq_rot90_m): Delete.
26935         (vcaddq_rot90_x): Delete.
26936         (vcaddq_rot270_x): Delete.
26937         (vhcaddq_rot90_x): Delete.
26938         (vhcaddq_rot270_x): Delete.
26939         (vcaddq_rot90_u8): Delete.
26940         (vcaddq_rot270_u8): Delete.
26941         (vhcaddq_rot90_s8): Delete.
26942         (vhcaddq_rot270_s8): Delete.
26943         (vcaddq_rot90_s8): Delete.
26944         (vcaddq_rot270_s8): Delete.
26945         (vcaddq_rot90_u16): Delete.
26946         (vcaddq_rot270_u16): Delete.
26947         (vhcaddq_rot90_s16): Delete.
26948         (vhcaddq_rot270_s16): Delete.
26949         (vcaddq_rot90_s16): Delete.
26950         (vcaddq_rot270_s16): Delete.
26951         (vcaddq_rot90_u32): Delete.
26952         (vcaddq_rot270_u32): Delete.
26953         (vhcaddq_rot90_s32): Delete.
26954         (vhcaddq_rot270_s32): Delete.
26955         (vcaddq_rot90_s32): Delete.
26956         (vcaddq_rot270_s32): Delete.
26957         (vcaddq_rot90_f16): Delete.
26958         (vcaddq_rot270_f16): Delete.
26959         (vcaddq_rot90_f32): Delete.
26960         (vcaddq_rot270_f32): Delete.
26961         (vcaddq_rot270_m_s8): Delete.
26962         (vcaddq_rot270_m_s32): Delete.
26963         (vcaddq_rot270_m_s16): Delete.
26964         (vcaddq_rot270_m_u8): Delete.
26965         (vcaddq_rot270_m_u32): Delete.
26966         (vcaddq_rot270_m_u16): Delete.
26967         (vcaddq_rot90_m_s8): Delete.
26968         (vcaddq_rot90_m_s32): Delete.
26969         (vcaddq_rot90_m_s16): Delete.
26970         (vcaddq_rot90_m_u8): Delete.
26971         (vcaddq_rot90_m_u32): Delete.
26972         (vcaddq_rot90_m_u16): Delete.
26973         (vhcaddq_rot270_m_s8): Delete.
26974         (vhcaddq_rot270_m_s32): Delete.
26975         (vhcaddq_rot270_m_s16): Delete.
26976         (vhcaddq_rot90_m_s8): Delete.
26977         (vhcaddq_rot90_m_s32): Delete.
26978         (vhcaddq_rot90_m_s16): Delete.
26979         (vcaddq_rot270_m_f32): Delete.
26980         (vcaddq_rot270_m_f16): Delete.
26981         (vcaddq_rot90_m_f32): Delete.
26982         (vcaddq_rot90_m_f16): Delete.
26983         (vcaddq_rot90_x_s8): Delete.
26984         (vcaddq_rot90_x_s16): Delete.
26985         (vcaddq_rot90_x_s32): Delete.
26986         (vcaddq_rot90_x_u8): Delete.
26987         (vcaddq_rot90_x_u16): Delete.
26988         (vcaddq_rot90_x_u32): Delete.
26989         (vcaddq_rot270_x_s8): Delete.
26990         (vcaddq_rot270_x_s16): Delete.
26991         (vcaddq_rot270_x_s32): Delete.
26992         (vcaddq_rot270_x_u8): Delete.
26993         (vcaddq_rot270_x_u16): Delete.
26994         (vcaddq_rot270_x_u32): Delete.
26995         (vhcaddq_rot90_x_s8): Delete.
26996         (vhcaddq_rot90_x_s16): Delete.
26997         (vhcaddq_rot90_x_s32): Delete.
26998         (vhcaddq_rot270_x_s8): Delete.
26999         (vhcaddq_rot270_x_s16): Delete.
27000         (vhcaddq_rot270_x_s32): Delete.
27001         (vcaddq_rot90_x_f16): Delete.
27002         (vcaddq_rot90_x_f32): Delete.
27003         (vcaddq_rot270_x_f16): Delete.
27004         (vcaddq_rot270_x_f32): Delete.
27005         (__arm_vcaddq_rot90_u8): Delete.
27006         (__arm_vcaddq_rot270_u8): Delete.
27007         (__arm_vhcaddq_rot90_s8): Delete.
27008         (__arm_vhcaddq_rot270_s8): Delete.
27009         (__arm_vcaddq_rot90_s8): Delete.
27010         (__arm_vcaddq_rot270_s8): Delete.
27011         (__arm_vcaddq_rot90_u16): Delete.
27012         (__arm_vcaddq_rot270_u16): Delete.
27013         (__arm_vhcaddq_rot90_s16): Delete.
27014         (__arm_vhcaddq_rot270_s16): Delete.
27015         (__arm_vcaddq_rot90_s16): Delete.
27016         (__arm_vcaddq_rot270_s16): Delete.
27017         (__arm_vcaddq_rot90_u32): Delete.
27018         (__arm_vcaddq_rot270_u32): Delete.
27019         (__arm_vhcaddq_rot90_s32): Delete.
27020         (__arm_vhcaddq_rot270_s32): Delete.
27021         (__arm_vcaddq_rot90_s32): Delete.
27022         (__arm_vcaddq_rot270_s32): Delete.
27023         (__arm_vcaddq_rot270_m_s8): Delete.
27024         (__arm_vcaddq_rot270_m_s32): Delete.
27025         (__arm_vcaddq_rot270_m_s16): Delete.
27026         (__arm_vcaddq_rot270_m_u8): Delete.
27027         (__arm_vcaddq_rot270_m_u32): Delete.
27028         (__arm_vcaddq_rot270_m_u16): Delete.
27029         (__arm_vcaddq_rot90_m_s8): Delete.
27030         (__arm_vcaddq_rot90_m_s32): Delete.
27031         (__arm_vcaddq_rot90_m_s16): Delete.
27032         (__arm_vcaddq_rot90_m_u8): Delete.
27033         (__arm_vcaddq_rot90_m_u32): Delete.
27034         (__arm_vcaddq_rot90_m_u16): Delete.
27035         (__arm_vhcaddq_rot270_m_s8): Delete.
27036         (__arm_vhcaddq_rot270_m_s32): Delete.
27037         (__arm_vhcaddq_rot270_m_s16): Delete.
27038         (__arm_vhcaddq_rot90_m_s8): Delete.
27039         (__arm_vhcaddq_rot90_m_s32): Delete.
27040         (__arm_vhcaddq_rot90_m_s16): Delete.
27041         (__arm_vcaddq_rot90_x_s8): Delete.
27042         (__arm_vcaddq_rot90_x_s16): Delete.
27043         (__arm_vcaddq_rot90_x_s32): Delete.
27044         (__arm_vcaddq_rot90_x_u8): Delete.
27045         (__arm_vcaddq_rot90_x_u16): Delete.
27046         (__arm_vcaddq_rot90_x_u32): Delete.
27047         (__arm_vcaddq_rot270_x_s8): Delete.
27048         (__arm_vcaddq_rot270_x_s16): Delete.
27049         (__arm_vcaddq_rot270_x_s32): Delete.
27050         (__arm_vcaddq_rot270_x_u8): Delete.
27051         (__arm_vcaddq_rot270_x_u16): Delete.
27052         (__arm_vcaddq_rot270_x_u32): Delete.
27053         (__arm_vhcaddq_rot90_x_s8): Delete.
27054         (__arm_vhcaddq_rot90_x_s16): Delete.
27055         (__arm_vhcaddq_rot90_x_s32): Delete.
27056         (__arm_vhcaddq_rot270_x_s8): Delete.
27057         (__arm_vhcaddq_rot270_x_s16): Delete.
27058         (__arm_vhcaddq_rot270_x_s32): Delete.
27059         (__arm_vcaddq_rot90_f16): Delete.
27060         (__arm_vcaddq_rot270_f16): Delete.
27061         (__arm_vcaddq_rot90_f32): Delete.
27062         (__arm_vcaddq_rot270_f32): Delete.
27063         (__arm_vcaddq_rot270_m_f32): Delete.
27064         (__arm_vcaddq_rot270_m_f16): Delete.
27065         (__arm_vcaddq_rot90_m_f32): Delete.
27066         (__arm_vcaddq_rot90_m_f16): Delete.
27067         (__arm_vcaddq_rot90_x_f16): Delete.
27068         (__arm_vcaddq_rot90_x_f32): Delete.
27069         (__arm_vcaddq_rot270_x_f16): Delete.
27070         (__arm_vcaddq_rot270_x_f32): Delete.
27071         (__arm_vcaddq_rot90): Delete.
27072         (__arm_vcaddq_rot270): Delete.
27073         (__arm_vhcaddq_rot90): Delete.
27074         (__arm_vhcaddq_rot270): Delete.
27075         (__arm_vcaddq_rot270_m): Delete.
27076         (__arm_vcaddq_rot90_m): Delete.
27077         (__arm_vhcaddq_rot270_m): Delete.
27078         (__arm_vhcaddq_rot90_m): Delete.
27079         (__arm_vcaddq_rot90_x): Delete.
27080         (__arm_vcaddq_rot270_x): Delete.
27081         (__arm_vhcaddq_rot90_x): Delete.
27082         (__arm_vhcaddq_rot270_x): Delete.
27084 2023-07-14  Christophe Lyon  <christophe.lyon@linaro.org>
27086         * config/arm/arm_mve_builtins.def (vcaddq_rot90_, vcaddq_rot270_)
27087         (vcaddq_rot90_f, vcaddq_rot90_f): Add "_" or "_f" suffix.
27088         * config/arm/iterators.md (mve_insn): Add vcadd, vhcadd.
27089         (isu): Add UNSPEC_VCADD90, UNSPEC_VCADD270, VCADDQ_ROT270_M_U,
27090         VCADDQ_ROT270_M_S, VCADDQ_ROT90_M_U, VCADDQ_ROT90_M_S,
27091         VHCADDQ_ROT90_M_S, VHCADDQ_ROT270_M_S, VHCADDQ_ROT90_S,
27092         VHCADDQ_ROT270_S.
27093         (rot): Add VCADDQ_ROT90_M_F, VCADDQ_ROT90_M_S, VCADDQ_ROT90_M_U,
27094         VCADDQ_ROT270_M_F, VCADDQ_ROT270_M_S, VCADDQ_ROT270_M_U,
27095         VHCADDQ_ROT90_S, VHCADDQ_ROT270_S, VHCADDQ_ROT90_M_S,
27096         VHCADDQ_ROT270_M_S.
27097         (mve_rot): Add VCADDQ_ROT90_M_F, VCADDQ_ROT90_M_S,
27098         VCADDQ_ROT90_M_U, VCADDQ_ROT270_M_F, VCADDQ_ROT270_M_S,
27099         VCADDQ_ROT270_M_U, VHCADDQ_ROT90_S, VHCADDQ_ROT270_S,
27100         VHCADDQ_ROT90_M_S, VHCADDQ_ROT270_M_S.
27101         (supf): Add VHCADDQ_ROT90_M_S, VHCADDQ_ROT270_M_S,
27102         VHCADDQ_ROT90_S, VHCADDQ_ROT270_S, UNSPEC_VCADD90,
27103         UNSPEC_VCADD270.
27104         (VCADDQ_ROT270_M): Delete.
27105         (VCADDQ_M_F VxCADDQ VxCADDQ_M): New.
27106         (VCADDQ_ROT90_M): Delete.
27107         * config/arm/mve.md (mve_vcaddq<mve_rot><mode>)
27108         (mve_vhcaddq_rot270_s<mode>, mve_vhcaddq_rot90_s<mode>): Merge
27109         into ...
27110         (@mve_<mve_insn>q<mve_rot>_<supf><mode>): ... this.
27111         (mve_vcaddq<mve_rot><mode>): Rename into ...
27112         (@mve_<mve_insn>q<mve_rot>_f<mode>): ... this
27113         (mve_vcaddq_rot270_m_<supf><mode>)
27114         (mve_vcaddq_rot90_m_<supf><mode>, mve_vhcaddq_rot270_m_s<mode>)
27115         (mve_vhcaddq_rot90_m_s<mode>): Merge into ...
27116         (@mve_<mve_insn>q<mve_rot>_m_<supf><mode>): ... this.
27117         (mve_vcaddq_rot270_m_f<mode>, mve_vcaddq_rot90_m_f<mode>): Merge
27118         into ...
27119         (@mve_<mve_insn>q<mve_rot>_m_f<mode>): ... this.
27121 2023-07-14  Roger Sayle  <roger@nextmovesoftware.com>
27123         PR target/110588
27124         * config/i386/i386.md (*bt<mode>_setcqi): Prefer string form
27125         preparation statement over braces for a single statement.
27126         (*bt<mode>_setncqi): Likewise.
27127         (*bt<mode>_setncqi_2): New define_insn_and_split.
27129 2023-07-14  Roger Sayle  <roger@nextmovesoftware.com>
27131         * config/i386/i386-expand.cc (ix86_expand_move): Generalize special
27132         case inserting of 64-bit values into a TImode register, to handle
27133         both DImode and DFmode using either *insvti_lowpart_1
27134         or *isnvti_highpart_1.
27136 2023-07-14  Uros Bizjak  <ubizjak@gmail.com>
27138         PR target/110206
27139         * fwprop.cc (contains_paradoxical_subreg_p): Move to ...
27140         * rtlanal.cc (contains_paradoxical_subreg_p): ... here.
27141         * rtlanal.h (contains_paradoxical_subreg_p): Add prototype.
27142         * cprop.cc (try_replace_reg): Do not set REG_EQUAL note
27143         when the original source contains a paradoxical subreg.
27145 2023-07-14  Jan Hubicka  <jh@suse.cz>
27147         * passes.cc (execute_function_todo): Remove
27148         TODO_rebuild_frequencies
27149         * passes.def: Add rebuild_frequencies pass.
27150         * predict.cc (estimate_bb_frequencies): Drop
27151         force parameter.
27152         (tree_estimate_probability): Update call of
27153         estimate_bb_frequencies.
27154         (rebuild_frequencies): Turn into a pass; verify CFG profile consistency
27155         first and do not rebuild if not necessary.
27156         (class pass_rebuild_frequencies): New.
27157         (make_pass_rebuild_frequencies): New.
27158         * profile-count.h: Add profile_count::very_large_p.
27159         * tree-inline.cc (optimize_inline_calls): Do not return
27160         TODO_rebuild_frequencies
27161         * tree-pass.h (TODO_rebuild_frequencies): Remove.
27162         (make_pass_rebuild_frequencies): Declare.
27164 2023-07-14  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
27166         * config/riscv/autovec.md (cond_len_fma<mode>): New pattern.
27167         * config/riscv/riscv-protos.h (enum insn_type): New enum.
27168         (expand_cond_len_ternop): New function.
27169         * config/riscv/riscv-v.cc (emit_nonvlmax_fp_ternary_tu_insn): Ditto.
27170         (expand_cond_len_ternop): Ditto.
27172 2023-07-14  Jose E. Marchesi  <jose.marchesi@oracle.com>
27174         PR target/110657
27175         * config/bpf/bpf.md: Enable instruction scheduling.
27177 2023-07-14  Tamar Christina  <tamar.christina@arm.com>
27179         PR tree-optimization/109154
27180         * tree-if-conv.cc (INCLUDE_ALGORITHM): Include.
27181         (struct bb_predicate): Add no_predicate_stmts.
27182         (set_bb_predicate): Increase predicate count.
27183         (set_bb_predicate_gimplified_stmts): Conditionally initialize
27184         no_predicate_stmts.
27185         (get_bb_num_predicate_stmts): New.
27186         (init_bb_predicate): Initialzie no_predicate_stmts.
27187         (release_bb_predicate): Cleanup no_predicate_stmts.
27188         (insert_gimplified_predicates): Preserve no_predicate_stmts.
27190 2023-07-14  Tamar Christina  <tamar.christina@arm.com>
27192         PR tree-optimization/109154
27193         * tree-if-conv.cc (gen_simplified_condition,
27194         gen_phi_nest_statement): New.
27195         (gen_phi_arg_condition, predicate_scalar_phi): Use it.
27197 2023-07-14  Richard Biener  <rguenther@suse.de>
27199         * gimple.h (gimple_phi_arg): New const overload.
27200         (gimple_phi_arg_def): Make gimple arg const.
27201         (gimple_phi_arg_def_from_edge): New inline function.
27202         * tree-phinodes.h (gimple_phi_arg_imm_use_ptr_from_edge):
27203         Likewise.
27204         * tree-ssa-operands.h (PHI_ARG_DEF_FROM_EDGE): Direct to
27205         new inline function.
27206         (PHI_ARG_DEF_PTR_FROM_EDGE): Likewise.
27208 2023-07-14  Monk Chiang  <monk.chiang@sifive.com>
27210         * common/config/riscv/riscv-common.cc:
27211         (riscv_implied_info): Add zihintntl item.
27212         (riscv_ext_version_table): Ditto.
27213         (riscv_ext_flag_table): Ditto.
27214         * config/riscv/riscv-opts.h (MASK_ZIHINTNTL): New macro.
27215         (TARGET_ZIHINTNTL): Ditto.
27217 2023-07-14  Die Li  <lidie@eswincomputing.com>
27219         * config/riscv/riscv.md: Remove redundant portion in and<mode>3.
27221 2023-07-14  Oleg Endo  <olegendo@gcc.gnu.org>
27223         PR target/101469
27224         * config/sh/sh.md (peephole2): Handle case where eliminated reg is also
27225         used by the address of the following memory operand.
27227 2023-07-13  Mikael Pettersson  <mikpelinux@gmail.com>
27229         PR target/107841
27230         * config/pdp11/pdp11.cc (pdp11_expand_epilogue): Also
27231         deallocate alloca-only frame.
27233 2023-07-13  Iain Sandoe  <iain@sandoe.co.uk>
27235         PR target/110624
27236         * config/darwin.h (DARWIN_PLATFORM_ID): New.
27237         (LINK_COMMAND_A): Use DARWIN_PLATFORM_ID to pass OS, OS version
27238         and SDK data to the static linker.
27240 2023-07-13  Carl Love  <cel@us.ibm.com>
27242         * config/rs6000/rs6000-builtins.def (__builtin_set_fpscr_rn): Update
27243         built-in definition return type.
27244         * config/rs6000/rs6000-c.cc (rs6000_target_modify_macros): Add check,
27245         define __SET_FPSCR_RN_RETURNS_FPSCR__ macro.
27246         * config/rs6000/rs6000.md (rs6000_set_fpscr_rn): Add return
27247         argument to return FPSCR fields.
27248         * doc/extend.texi (__builtin_set_fpscr_rn): Update description for
27249         the return value.  Add description for
27250         __SET_FPSCR_RN_RETURNS_FPSCR__ macro.
27252 2023-07-13  Uros Bizjak  <ubizjak@gmail.com>
27254         PR target/106966
27255         * config/alpha/alpha.cc (alpha_emit_set_long_const):
27256         Always use DImode when constructing long const.
27258 2023-07-13  Uros Bizjak  <ubizjak@gmail.com>
27260         * haifa-sched.cc: Change TRUE/FALSE to true/false.
27261         * ira.cc: Ditto.
27262         * lra-assigns.cc: Ditto.
27263         * lra-constraints.cc: Ditto.
27264         * sel-sched.cc: Ditto.
27266 2023-07-13  Andrew Pinski  <apinski@marvell.com>
27268         PR tree-optimization/110293
27269         PR tree-optimization/110539
27270         * match.pd: Expand the `x != (typeof x)(x == 0)`
27271         pattern to handle where the inner and outer comparsions
27272         are either `!=` or `==` and handle other constants
27273         than 0.
27275 2023-07-13  Vladimir N. Makarov  <vmakarov@redhat.com>
27277         PR middle-end/109520
27278         * lra-int.h (lra_insn_recog_data): Add member asm_reloads_num.
27279         (lra_asm_insn_error): New prototype.
27280         * lra.cc: Include rtl_error.h.
27281         (lra_set_insn_recog_data): Initialize asm_reloads_num.
27282         (lra_asm_insn_error): New func whose code is taken from ...
27283         * lra-assigns.cc (lra_split_hard_reg_for): ... here.  Use lra_asm_insn_error.
27284         * lra-constraints.cc (curr_insn_transform): Check reloads nummber for asm.
27286 2023-07-13  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
27288         * genmatch.cc (commutative_op): Add COND_LEN_*
27289         * internal-fn.cc (first_commutative_argument): Ditto.
27290         (CASE): Ditto.
27291         (get_unconditional_internal_fn): Ditto.
27292         (can_interpret_as_conditional_op_p): Ditto.
27293         (internal_fn_len_index): Ditto.
27294         * internal-fn.h (can_interpret_as_conditional_op_p): Ditt.
27295         * tree-ssa-math-opts.cc (convert_mult_to_fma_1): Ditto.
27296         (convert_mult_to_fma): Ditto.
27297         (math_opts_dom_walker::after_dom_children): Ditto.
27299 2023-07-13  Pan Li  <pan2.li@intel.com>
27301         * config/riscv/riscv.cc (vxrm_rtx): New static var.
27302         (frm_rtx): Ditto.
27303         (global_state_unknown_p): Removed.
27304         (riscv_entity_mode_after): Removed.
27305         (asm_insn_p): New function.
27306         (vxrm_unknown_p): New function for fixed-point.
27307         (riscv_vxrm_mode_after): Ditto.
27308         (frm_unknown_dynamic_p): New function for floating-point.
27309         (riscv_frm_mode_after): Ditto.
27310         (riscv_mode_after): Leverage new functions.
27312 2023-07-13  Kewen Lin  <linkw@linux.ibm.com>
27314         * tree-vect-stmts.cc (vect_model_load_cost): Remove.
27315         (vectorizable_load): Adjust the cost handling on VMAT_CONTIGUOUS without
27316         calling vect_model_load_cost.
27318 2023-07-13  Kewen Lin  <linkw@linux.ibm.com>
27320         * tree-vect-stmts.cc (vect_model_load_cost): Assert this function only
27321         handle memory_access_type VMAT_CONTIGUOUS, remove some
27322         VMAT_CONTIGUOUS_PERMUTE related handlings.
27323         (vectorizable_load): Adjust the cost handling on VMAT_CONTIGUOUS_PERMUTE
27324         without calling vect_model_load_cost.
27326 2023-07-13  Kewen Lin  <linkw@linux.ibm.com>
27328         * tree-vect-stmts.cc (vect_model_load_cost): Assert it won't get
27329         VMAT_CONTIGUOUS_REVERSE any more.
27330         (vectorizable_load): Adjust the costing handling on
27331         VMAT_CONTIGUOUS_REVERSE without calling vect_model_load_cost.
27333 2023-07-13  Kewen Lin  <linkw@linux.ibm.com>
27335         * tree-vect-stmts.cc (vectorizable_load): Adjust the cost handling on
27336         VMAT_LOAD_STORE_LANES without calling vect_model_load_cost.
27337         (vectorizable_load): Remove VMAT_LOAD_STORE_LANES related handling and
27338         assert it will never get VMAT_LOAD_STORE_LANES.
27340 2023-07-13  Kewen Lin  <linkw@linux.ibm.com>
27342         * tree-vect-stmts.cc (vectorizable_load): Adjust the cost handling on
27343         VMAT_GATHER_SCATTER without calling vect_model_load_cost.
27344         (vect_model_load_cost): Adjut the assertion on VMAT_GATHER_SCATTER,
27345         remove VMAT_GATHER_SCATTER related handlings and the related parameter
27346         gs_info.
27348 2023-07-13  Kewen Lin  <linkw@linux.ibm.com>
27350         * tree-vect-stmts.cc (vectorizable_load): Adjust the cost handling
27351         on VMAT_ELEMENTWISE and VMAT_STRIDED_SLP without calling
27352         vect_model_load_cost.
27353         (vect_model_load_cost): Assert it won't get VMAT_ELEMENTWISE and
27354         VMAT_STRIDED_SLP any more, and remove their related handlings.
27356 2023-07-13  Kewen Lin  <linkw@linux.ibm.com>
27358         * tree-vect-stmts.cc (hoist_defs_of_uses): Add one argument HOIST_P.
27359         (vectorizable_load): Adjust the handling on VMAT_INVARIANT to respect
27360         hoisting decision and without calling vect_model_load_cost.
27361         (vect_model_load_cost): Assert it won't get VMAT_INVARIANT any more
27362         and remove VMAT_INVARIANT related handlings.
27364 2023-07-13  Kewen Lin  <linkw@linux.ibm.com>
27366         * tree-vect-stmts.cc (vect_build_gather_load_calls): Add the handlings
27367         on costing with one extra argument cost_vec.
27368         (vectorizable_load): Adjust the call to vect_build_gather_load_calls.
27369         (vect_model_load_cost): Assert it won't get VMAT_GATHER_SCATTER with
27370         gs_info.decl set any more.
27372 2023-07-13  Kewen Lin  <linkw@linux.ibm.com>
27374         * tree-vect-stmts.cc (vectorizable_load): Move and duplicate the call
27375         to vect_model_load_cost down to some different transform paths
27376         according to the handlings of different vect_memory_access_types.
27378 2023-07-13  Kewen Lin  <linkw@linux.ibm.com>
27380         * tree.h (wi::from_mpz): Hide from GENERATOR_FILE.
27382 2023-07-13  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
27384         * config/riscv/autovec.md
27385         (len_mask_gather_load<VNX1_QHSD:mode><VNX1_QHSDI:mode>): New pattern.
27386         (len_mask_gather_load<VNX2_QHSD:mode><VNX2_QHSDI:mode>): Ditto.
27387         (len_mask_gather_load<VNX4_QHSD:mode><VNX4_QHSDI:mode>): Ditto.
27388         (len_mask_gather_load<VNX8_QHSD:mode><VNX8_QHSDI:mode>): Ditto.
27389         (len_mask_gather_load<VNX16_QHSD:mode><VNX16_QHSDI:mode>): Ditto.
27390         (len_mask_gather_load<VNX32_QHS:mode><VNX32_QHSI:mode>): Ditto.
27391         (len_mask_gather_load<VNX64_QH:mode><VNX64_QHI:mode>): Ditto.
27392         (len_mask_gather_load<mode><mode>): Ditto.
27393         (len_mask_scatter_store<VNX1_QHSD:mode><VNX1_QHSDI:mode>): Ditto.
27394         (len_mask_scatter_store<VNX2_QHSD:mode><VNX2_QHSDI:mode>): Ditto.
27395         (len_mask_scatter_store<VNX4_QHSD:mode><VNX4_QHSDI:mode>): Ditto.
27396         (len_mask_scatter_store<VNX8_QHSD:mode><VNX8_QHSDI:mode>): Ditto.
27397         (len_mask_scatter_store<VNX16_QHSD:mode><VNX16_QHSDI:mode>): Ditto.
27398         (len_mask_scatter_store<VNX32_QHS:mode><VNX32_QHSI:mode>): Ditto.
27399         (len_mask_scatter_store<VNX64_QH:mode><VNX64_QHI:mode>): Ditto.
27400         (len_mask_scatter_store<mode><mode>): Ditto.
27401         * config/riscv/predicates.md (const_1_operand): New predicate.
27402         (vector_gs_scale_operand_16): Ditto.
27403         (vector_gs_scale_operand_32): Ditto.
27404         (vector_gs_scale_operand_64): Ditto.
27405         (vector_gs_extension_operand): Ditto.
27406         (vector_gs_scale_operand_16_rv32): Ditto.
27407         (vector_gs_scale_operand_32_rv32): Ditto.
27408         * config/riscv/riscv-protos.h (enum insn_type): Add gather/scatter.
27409         (expand_gather_scatter): New function.
27410         * config/riscv/riscv-v.cc (gen_const_vector_dup): Add gather/scatter.
27411         (emit_vlmax_masked_store_insn): New function.
27412         (emit_nonvlmax_masked_store_insn): Ditto.
27413         (modulo_sel_indices): Ditto.
27414         (expand_vec_perm): Fix SLP for gather/scatter.
27415         (prepare_gather_scatter): New function.
27416         (expand_gather_scatter): Ditto.
27417         * config/riscv/riscv.cc (riscv_legitimize_move): Fix bug of
27418         (subreg:SI (DI CONST_POLY_INT)).
27419         * config/riscv/vector-iterators.md: Add gather/scatter.
27420         * config/riscv/vector.md (vec_duplicate<mode>): Use "@" instead.
27421         (@vec_duplicate<mode>): Ditto.
27422         (@pred_indexed_<order>store<VNX16_QHS:mode><VNX16_QHSDI:mode>):
27423         Fix name.
27424         (@pred_indexed_<order>store<VNX16_QHSD:mode><VNX16_QHSDI:mode>): Ditto.
27426 2023-07-12  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
27428         * config/riscv/autovec.md (cond_len_<optab><mode>): New pattern.
27429         * config/riscv/riscv-protos.h (enum insn_type): New enum.
27430         (expand_cond_len_binop): New function.
27431         * config/riscv/riscv-v.cc (emit_nonvlmax_tu_insn): Ditto.
27432         (emit_nonvlmax_fp_tu_insn): Ditto.
27433         (need_fp_rounding_p): Ditto.
27434         (expand_cond_len_binop): Ditto.
27435         * config/riscv/riscv.cc (riscv_preferred_else_value): Ditto.
27436         (TARGET_PREFERRED_ELSE_VALUE): New target hook.
27438 2023-07-12  Jan Hubicka  <jh@suse.cz>
27440         * tree-cfg.cc (gimple_duplicate_sese_region): Rename to ...
27441         (gimple_duplicate_seme_region): ... this; break out profile updating
27442         code to ...
27443         * tree-ssa-loop-ch.cc (update_profile_after_ch): ... here.
27444         (ch_base::copy_headers): Update.
27445         * tree-cfg.h (gimple_duplicate_sese_region): Rename to ...
27446         (gimple_duplicate_seme_region): ... this.
27448 2023-07-12  Aldy Hernandez  <aldyh@redhat.com>
27450         PR tree-optimization/107043
27451         * range-op.cc (operator_bitwise_and::op1_range): Update bitmask.
27453 2023-07-12  Aldy Hernandez  <aldyh@redhat.com>
27455         PR tree-optimization/107053
27456         * gimple-range-op.cc (cfn_popcount): Use known set bits.
27458 2023-07-12  Uros Bizjak  <ubizjak@gmail.com>
27460         * ira.cc (equiv_init_varies_p): Change return type from int to bool
27461         and adjust function body accordingly.
27462         (equiv_init_movable_p): Ditto.
27463         (memref_used_between_p): Ditto.
27464         * lra-constraints.cc (valid_address_p): Ditto.
27466 2023-07-12  Aldy Hernandez  <aldyh@redhat.com>
27468         * range-op.cc (irange_to_masked_value): Remove.
27469         (update_known_bitmask): Update irange value/mask pair instead of
27470         only updating nonzero bits.
27472 2023-07-12  Jan Hubicka  <jh@suse.cz>
27474         * tree-cfg.cc (gimple_duplicate_sese_region): Add ORIG_ELIMINATED_EDGES
27475         parameter and rewrite profile updating code to handle edges elimination.
27476         * tree-cfg.h (gimple_duplicate_sese_region): Update prototpe.
27477         * tree-ssa-loop-ch.cc (loop_invariant_op_p): New function.
27478         (loop_iv_derived_p): New function.
27479         (should_duplicate_loop_header_p): Track invariant exit edges; fix handling
27480         of PHIs and propagation of IV derived variables.
27481         (ch_base::copy_headers): Pass around the invariant edges hash set.
27483 2023-07-12  Uros Bizjak  <ubizjak@gmail.com>
27485         * ifcvt.cc (cond_exec_changed_p): Change variable to bool.
27486         (last_active_insn): Change "skip_use_p" function argument to bool.
27487         (noce_operand_ok): Change return type from int to bool.
27488         (find_cond_trap): Ditto.
27489         (block_jumps_and_fallthru_p): Change "fallthru_p" and
27490         "jump_p" variables to bool.
27491         (noce_find_if_block): Change return type from int to bool.
27492         (cond_exec_find_if_block): Ditto.
27493         (find_if_case_1): Ditto.
27494         (find_if_case_2): Ditto.
27495         (dead_or_predicable): Ditto. Change "reversep" function arg to bool.
27496         (block_jumps_and_fallthru): Rename from block_jumps_and_fallthru_p.
27497         (cond_exec_process_insns): Change return type from int to bool.
27498         Change "mod_ok" function arg to bool.
27499         (cond_exec_process_if_block): Change return type from int to bool.
27500         Change "do_multiple_p" function arg to bool.  Change "then_mod_ok"
27501         variable to bool.
27502         (noce_emit_store_flag): Change return type from int to bool.
27503         Change "reversep" function arg to bool.  Change "cond_complex"
27504         variable to bool.
27505         (noce_try_move): Change return type from int to bool.
27506         (noce_try_ifelse_collapse): Ditto.
27507         (noce_try_store_flag): Ditto. Change "reversep" variable to bool.
27508         (noce_try_addcc): Change return type from int to bool.  Change
27509         "subtract" variable to bool.
27510         (noce_try_store_flag_constants): Change return type from int to bool.
27511         (noce_try_store_flag_mask): Ditto.  Change "reversep" variable to bool.
27512         (noce_try_cmove): Change return type from int to bool.
27513         (noce_try_cmove_arith): Ditto. Change "is_mem" variable to bool.
27514         (noce_try_minmax): Change return type from int to bool.  Change
27515         "unsignedp" variable to bool.
27516         (noce_try_abs): Change return type from int to bool.  Change
27517         "negate" variable to bool.
27518         (noce_try_sign_mask): Change return type from int to bool.
27519         (noce_try_move): Ditto.
27520         (noce_try_store_flag_constants): Ditto.
27521         (noce_try_cmove): Ditto.
27522         (noce_try_cmove_arith): Ditto.
27523         (noce_try_minmax): Ditto.  Change "unsignedp" variable to bool.
27524         (noce_try_bitop): Change return type from int to bool.
27525         (noce_operand_ok): Ditto.
27526         (noce_convert_multiple_sets): Ditto.
27527         (noce_convert_multiple_sets_1): Ditto.
27528         (noce_process_if_block): Ditto.
27529         (check_cond_move_block): Ditto.
27530         (cond_move_process_if_block): Ditto. Change "success_p"
27531         variable to bool.
27532         (rest_of_handle_if_conversion): Change return type to void.
27534 2023-07-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
27536         * internal-fn.cc (FOR_EACH_CODE_MAPPING): Adapt for COND_LEN_* support.
27537         (CASE): Ditto.
27538         (get_conditional_len_internal_fn): New function.
27539         * internal-fn.h (get_conditional_len_internal_fn): Ditto.
27540         * tree-vect-stmts.cc (vectorizable_operation): Adapt for COND_LEN_*
27541         support.
27543 2023-07-12  Roger Sayle  <roger@nextmovesoftware.com>
27545         PR target/91681
27546         * config/i386/i386.md (*add<dwi>3_doubleword_concat_zext): Typo.
27548 2023-07-12  Roger Sayle  <roger@nextmovesoftware.com>
27550         PR target/91681
27551         * config/i386/i386.md (*add<dwi>3_doubleword_concat_zext): New
27552         define_insn_and_split derived from *add<dwi>3_doubleword_concat
27553         and *add<dwi>3_doubleword_zext.
27555 2023-07-12  Roger Sayle  <roger@nextmovesoftware.com>
27557         PR target/110598
27558         * config/i386/i386.md (peephole2): Check !reg_mentioned_p when
27559         optimizing rega = 0; rega op= regb for op in [XOR,IOR,PLUS].
27560         (peephole2): Simplify rega = 0; rega op= rega cases.
27562 2023-07-12  Roger Sayle  <roger@nextmovesoftware.com>
27564         * config/i386/i386-expand.cc (ix86_expand_int_compare): If
27565         testing a TImode SUBREG of a 128-bit vector register against
27566         zero, use a PTEST instruction instead of first moving it to
27567         a pair of scalar registers.
27569 2023-07-12  Robin Dapp  <rdapp@ventanamicro.com>
27571         * genopinit.cc (main): Adjust maximal number of optabs and
27572         machine modes.
27573         * gensupport.cc (find_optab): Shift optab by 20 and mode by
27574         10 bits.
27575         * optabs-query.h (optab_handler): Ditto.
27576         (convert_optab_handler): Ditto.
27578 2023-07-12  Richard Biener  <rguenther@suse.de>
27580         PR tree-optimization/110630
27581         * tree-vect-slp.cc (vect_add_slp_permutation): New
27582         offset parameter, honor that for the extract code generation.
27583         (vectorizable_slp_permutation_1): Handle offsetted identities.
27585 2023-07-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
27587         * config/riscv/autovec.md (smul<mode>3_highpart): New pattern.
27588         (umul<mode>3_highpart): Ditto.
27590 2023-07-12  Jan Beulich  <jbeulich@suse.com>
27592         * config/i386/i386.md (extendbfsf2_1): Add new AVX512F
27593         alternative. Adjust original last alternative's "prefix"
27594         attribute to maybe_evex.
27596 2023-07-12  Jan Beulich  <jbeulich@suse.com>
27598         * config/i386/sse.md (vec_dupv4sf): Make first alternative use
27599         vbroadcastss for AVX2. New AVX512F alternative.
27600         (*vec_dupv4si): New AVX2 and AVX512F alternatives using
27601         vpbroadcastd. Replace sselog1 by sseshuf1 in "type" attribute.
27603 2023-07-12  Christoph Müllner  <christoph.muellner@vrull.eu>
27605         * config/riscv/peephole.md: Remove XThead* peephole passes.
27606         * config/riscv/thead.md: Include thead-peephole.md.
27607         * config/riscv/thead-peephole.md: New file.
27609 2023-07-12  Christoph Müllner  <christoph.muellner@vrull.eu>
27611         * config/riscv/riscv-protos.h (riscv_regno_ok_for_index_p):
27612         New prototype.
27613         (riscv_index_reg_class): Likewise.
27614         * config/riscv/riscv.cc (riscv_regno_ok_for_index_p): New function.
27615         (riscv_index_reg_class): New function.
27616         * config/riscv/riscv.h (INDEX_REG_CLASS): Call new function
27617         riscv_index_reg_class().
27618         (REGNO_OK_FOR_INDEX_P): Call new function
27619         riscv_regno_ok_for_index_p().
27621 2023-07-12  Christoph Müllner  <christoph.muellner@vrull.eu>
27623         * config/riscv/riscv-protos.h (enum riscv_address_type):
27624         New location of type definition.
27625         (struct riscv_address_info): Likewise.
27626         * config/riscv/riscv.cc (enum riscv_address_type):
27627         Old location of type definition.
27628         (struct riscv_address_info): Likewise.
27630 2023-07-12  Christoph Müllner  <christoph.muellner@vrull.eu>
27632         * config/riscv/riscv.h (Xmode): New macro.
27634 2023-07-12  Christoph Müllner  <christoph.muellner@vrull.eu>
27636         * config/riscv/riscv.cc (riscv_print_operand_address): Use
27637         output_addr_const rather than riscv_print_operand.
27639 2023-07-12  Christoph Müllner  <christoph.muellner@vrull.eu>
27641         * config/riscv/thead.md: Adjust constraints of th_addsl.
27643 2023-07-12  Christoph Müllner  <christoph.muellner@vrull.eu>
27645         * config/riscv/thead.cc (th_mempair_operands_p):
27646         Fix documentation of th_mempair_order_operands().
27648 2023-07-12  Christoph Müllner  <christoph.muellner@vrull.eu>
27650         * config/riscv/thead.cc (th_mempair_save_regs):
27651         Emit REG_FRAME_RELATED_EXPR notes in prologue.
27653 2023-07-12  Christoph Müllner  <christoph.muellner@vrull.eu>
27655         * config/riscv/riscv.md: No base-ISA extension splitter for XThead*.
27656         * config/riscv/thead.md (*extend<SHORT:mode><SUPERQI:mode>2_th_ext):
27657         New XThead extension INSN.
27658         (*zero_extendsidi2_th_extu): New XThead extension INSN.
27659         (*zero_extendhi<GPR:mode>2_th_extu): New XThead extension INSN.
27661 2023-07-12  liuhongt  <hongtao.liu@intel.com>
27663         PR target/110438
27664         PR target/110202
27665         * config/i386/predicates.md
27666         (int_float_vector_all_ones_operand): New predicate.
27667         * config/i386/sse.md (*vmov<mode>_constm1_pternlog_false_dep): New
27668         define_insn.
27669         (*<avx512>_cvtmask2<ssemodesuffix><mode>_pternlog_false_dep):
27670         Ditto.
27671         (*<avx512>_cvtmask2<ssemodesuffix><mode>_pternlog_false_dep):
27672         Ditto.
27673         (*<avx512>_cvtmask2<ssemodesuffix><mode>): Adjust to
27674         define_insn_and_split to avoid false dependence.
27675         (*<avx512>_cvtmask2<ssemodesuffix><mode>): Ditto.
27676         (<mask_codefor>one_cmpl<mode>2<mask_name>): Adjust constraint
27677         of operands 1 to '0' to avoid false dependence.
27678         (*andnot<mode>3): Ditto.
27679         (iornot<mode>3): Ditto.
27680         (*<nlogic><mode>3): Ditto.
27682 2023-07-12  Mo, Zewei  <zewei.mo@intel.com>
27684         * common/config/i386/cpuinfo.h
27685         (get_intel_cpu): Handle Granite Rapids D.
27686         * common/config/i386/i386-common.cc:
27687         (processor_alias_table): Add graniterapids-d.
27688         * common/config/i386/i386-cpuinfo.h
27689         (enum processor_subtypes): Add INTEL_COREI7_GRANITERAPIDS_D.
27690         * config.gcc: Add -march=graniterapids-d.
27691         * config/i386/driver-i386.cc (host_detect_local_cpu):
27692         Handle graniterapids-d.
27693         * config/i386/i386.h: (PTA_GRANITERAPIDS_D): New.
27694         * doc/extend.texi: Add graniterapids-d.
27695         * doc/invoke.texi: Ditto.
27697 2023-07-12  Haochen Jiang  <haochen.jiang@intel.com>
27699         * config/i386/i386-builtins.cc (ix86_init_mmx_sse_builtins):
27700         Add OPTION_MASK_ISA_AVX512VL.
27701         * config/i386/i386-expand.cc (ix86_check_builtin_isa_match):
27702         Ditto.
27704 2023-07-11  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
27706         * config/riscv/riscv-protos.h (enum insn_type): Add vcompress optimization.
27707         * config/riscv/riscv-v.cc (emit_vlmax_compress_insn): Ditto.
27708         (shuffle_compress_patterns): Ditto.
27709         (expand_vec_perm_const_1): Ditto.
27711 2023-07-11  Uros Bizjak  <ubizjak@gmail.com>
27713         * cfghooks.cc (verify_flow_info): Change "err" variable to bool.
27714         * cfghooks.h (struct cfg_hooks): Change return type of
27715         verify_flow_info from integer to bool.
27716         * cfgrtl.cc (can_delete_note_p): Change return type from int to bool.
27717         (can_delete_label_p): Ditto.
27718         (rtl_verify_flow_info): Change return type from int to bool
27719         and adjust function body accordingly.  Change "err" variable to bool.
27720         (rtl_verify_flow_info_1): Ditto.
27721         (free_bb_for_insn): Change return type to void.
27722         (rtl_merge_blocks): Change "b_empty" variable to bool.
27723         (try_redirect_by_replacing_jump): Change "fallthru" variable to bool.
27724         (verify_hot_cold_block_grouping): Change return type from int to bool.
27725         Change "err" variable to bool.
27726         (rtl_verify_edges): Ditto.
27727         (rtl_verify_bb_insns): Ditto.
27728         (rtl_verify_bb_pointers): Ditto.
27729         (rtl_verify_bb_insn_chain): Ditto.
27730         (rtl_verify_fallthru): Ditto.
27731         (rtl_verify_bb_layout): Ditto.
27732         (purge_all_dead_edges): Change "purged" variable to bool.
27733         * cfgrtl.h (free_bb_for_insn): Change return type from int to void.
27734         * postreload-gcse.cc (expr_hasher::equal): Change "equiv_p" to bool.
27735         (load_killed_in_block_p): Change return type from int to bool
27736         and adjust function body accordingly.
27737         (oprs_unchanged_p): Return true/false.
27738         (rest_of_handle_gcse2): Change return type to void.
27739         * tree-cfg.cc (gimple_verify_flow_info): Change return type from
27740         int to bool.  Change "err" variable to bool.
27742 2023-07-11  Gaius Mulley  <gaiusmod2@gmail.com>
27744         * doc/gm2.texi (-Wuninit-variable-checking=) New item.
27746 2023-07-11  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
27748         * doc/md.texi: Add COND_LEN_* operations for loop control with length.
27749         * internal-fn.cc (cond_len_unary_direct): Ditto.
27750         (cond_len_binary_direct): Ditto.
27751         (cond_len_ternary_direct): Ditto.
27752         (expand_cond_len_unary_optab_fn): Ditto.
27753         (expand_cond_len_binary_optab_fn): Ditto.
27754         (expand_cond_len_ternary_optab_fn): Ditto.
27755         (direct_cond_len_unary_optab_supported_p): Ditto.
27756         (direct_cond_len_binary_optab_supported_p): Ditto.
27757         (direct_cond_len_ternary_optab_supported_p): Ditto.
27758         * internal-fn.def (COND_LEN_ADD): Ditto.
27759         (COND_LEN_SUB): Ditto.
27760         (COND_LEN_MUL): Ditto.
27761         (COND_LEN_DIV): Ditto.
27762         (COND_LEN_MOD): Ditto.
27763         (COND_LEN_RDIV): Ditto.
27764         (COND_LEN_MIN): Ditto.
27765         (COND_LEN_MAX): Ditto.
27766         (COND_LEN_FMIN): Ditto.
27767         (COND_LEN_FMAX): Ditto.
27768         (COND_LEN_AND): Ditto.
27769         (COND_LEN_IOR): Ditto.
27770         (COND_LEN_XOR): Ditto.
27771         (COND_LEN_SHL): Ditto.
27772         (COND_LEN_SHR): Ditto.
27773         (COND_LEN_FMA): Ditto.
27774         (COND_LEN_FMS): Ditto.
27775         (COND_LEN_FNMA): Ditto.
27776         (COND_LEN_FNMS): Ditto.
27777         (COND_LEN_NEG): Ditto.
27778         * optabs.def (OPTAB_D): Ditto.
27780 2023-07-11  Richard Biener  <rguenther@suse.de>
27782         PR tree-optimization/110614
27783         * tree-vect-data-refs.cc (vect_supportable_dr_alignment):
27784         SLP splats are not suitable for re-align ops.
27786 2023-07-10  Peter Bergner  <bergner@linux.ibm.com>
27788         * config/rs6000/predicates.md (quad_memory_operand): Remove redundant
27789         MEM_P usage.
27790         (vsx_quad_dform_memory_operand): Likewise.
27792 2023-07-10  Uros Bizjak  <ubizjak@gmail.com>
27794         * reorg.cc (stop_search_p): Change return type from int to bool
27795         and adjust function body accordingly.
27796         (resource_conflicts_p): Ditto.
27797         (insn_references_resource_p): Change return type from int to bool.
27798         (insn_sets_resource_p): Ditto.
27799         (redirect_with_delay_slots_safe_p): Ditto.
27800         (condition_dominates_p): Change return type from int to bool
27801         and adjust function body accordingly.
27802         (redirect_with_delay_list_safe_p): Ditto.
27803         (check_annul_list_true_false): Ditto.  Change "annul_true_p"
27804         function argument to bool.
27805         (steal_delay_list_from_target): Change "pannul_p" function
27806         argument to bool pointer.  Change "must_annul" and "used_annul"
27807         variables from int to bool.
27808         (steal_delay_list_from_fallthrough): Ditto.
27809         (own_thread_p): Change return type from int to bool and adjust
27810         function body accordingly.  Change "allow_fallthrough" function
27811         argument to bool.
27812         (reorg_redirect_jump): Change return type from int to bool.
27813         (fill_simple_delay_slots): Change "non_jumps_p" function
27814         argument from int to bool.  Change "maybe_never" varible to bool.
27815         (fill_slots_from_thread): Change "likely", "thread_if_true" and
27816         "own_thread" function arguments to bool.  Change "lose" and
27817         "must_annul" variables to bool.
27818         (delete_from_delay_slot): Change "had_barrier" variable to bool.
27819         (try_merge_delay_insns): Change "annul_p" variable to bool.
27820         (fill_eager_delay_slots): Change "own_target" and "own_fallthrouhg"
27821         variables to bool.
27822         (rest_of_handle_delay_slots): Change return type from int to void
27823         and adjust function body accordingly.
27825 2023-07-10  Kito Cheng  <kito.cheng@sifive.com>
27827         * doc/extend.texi (RISC-V Operand Modifiers): New.
27829 2023-07-10  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
27831         * config/riscv/riscv-vsetvl.cc (add_label_notes): Remove it.
27832         (insert_insn_end_basic_block): Ditto.
27833         (pass_vsetvl::commit_vsetvls): Adapt for new helper function.
27834         * gcse.cc (insert_insn_end_basic_block):  Export as global function.
27835         * gcse.h (insert_insn_end_basic_block): Ditto.
27837 2023-07-10  Christophe Lyon   <christophe.lyon@linaro.org>
27839         PR target/110268
27840         * config/arm/arm-builtins.cc (arm_init_mve_builtins): Handle LTO.
27841         (arm_builtin_decl): Hahndle MVE builtins.
27842         * config/arm/arm-mve-builtins.cc (builtin_decl): New function.
27843         (add_unique_function): Fix handling of
27844         __ARM_MVE_PRESERVE_USER_NAMESPACE.
27845         (add_overloaded_function): Likewise.
27846         * config/arm/arm-protos.h (builtin_decl): New declaration.
27848 2023-07-10  Christophe Lyon  <christophe.lyon@linaro.org>
27850         * doc/sourcebuild.texi (arm_v8_1m_main_cde_mve_fp): Document.
27852 2023-07-10  Xi Ruoyao  <xry111@xry111.site>
27854         PR tree-optimization/110557
27855         * tree-vect-patterns.cc (vect_recog_bitfield_ref_pattern):
27856         Ensure the output sign-extended if necessary.
27858 2023-07-10  Roger Sayle  <roger@nextmovesoftware.com>
27860         * config/i386/i386.md (peephole2): Transform xchg insn with a
27861         REG_UNUSED note to a (simple) move.
27862         (*insvti_lowpart_1): New define_insn_and_split.
27863         (*insvdi_lowpart_1): Likewise.
27865 2023-07-10  Roger Sayle  <roger@nextmovesoftware.com>
27867         * config/i386/i386-features.cc (compute_convert_gain): Tweak
27868         gains/costs for ROTATE/ROTATERT by integer constant on AVX512VL.
27869         (general_scalar_chain::convert_rotate): On TARGET_AVX512F generate
27870         avx512vl_rolv2di or avx412vl_rolv4si when appropriate.
27872 2023-07-10  liuhongt  <hongtao.liu@intel.com>
27874         PR target/110170
27875         * config/i386/i386.md (*ieee_max<mode>3_1): New pre_reload
27876         splitter to detect fp max pattern.
27877         (*ieee_min<mode>3_1): Ditto, but for fp min pattern.
27879 2023-07-09  Jan Hubicka  <jh@suse.cz>
27881         * cfg.cc (check_bb_profile): Dump counts with relative frequency.
27882         (dump_edge_info): Likewise.
27883         (dump_bb_info): Likewise.
27884         * profile-count.cc (profile_count::dump): Add comma between quality and
27885         freq.
27887 2023-07-08  Jan Hubicka  <jh@suse.cz>
27889         PR tree-optimization/110600
27890         * cfgloopmanip.cc (scale_loop_profile): Add mising profile_dump check.
27892 2023-07-08  Jan Hubicka  <jh@suse.cz>
27894         PR middle-end/110590
27895         * cfgloopmanip.cc (scale_loop_profile): Avoid scaling exits within
27896         inner loops and be more careful about inconsistent profiles.
27897         (duplicate_loop_body_to_header_edge): Fix profile update when eliminated
27898         exit is followed by other exit.
27900 2023-07-08  Uros Bizjak  <ubizjak@gmail.com>
27902         * cprop.cc (reg_available_p): Change return type from int to bool.
27903         (reg_not_set_p): Ditto.
27904         (try_replace_reg): Ditto.  Change "success" variable to bool.
27905         (cprop_jump): Change return type from int to void
27906         and adjust function body accordingly.
27907         (constprop_register): Ditto.
27908         (cprop_insn): Ditto.  Change "changed" variable to bool.
27909         (local_cprop_pass): Change return type from int to void
27910         and adjust function body accordingly.
27911         (bypass_block): Ditto.  Change "change", "may_be_loop_header"
27912         and "removed_p" variables to bool.
27913         (bypass_conditional_jumps): Change return type from int to void
27914         and adjust function body accordingly.  Change "changed"
27915         variable to bool.
27916         (one_cprop_pass): Ditto.
27918 2023-07-08  Uros Bizjak  <ubizjak@gmail.com>
27920         * gcse.cc (expr_equiv_p): Change return type from int to bool.
27921         (oprs_unchanged_p): Change return type from int to void
27922         and adjust function body accordingly.
27923         (oprs_anticipatable_p): Ditto.
27924         (oprs_available_p): Ditto.
27925         (insert_expr_in_table): Ditto.  Change "antic_p" and "avail_p"
27926         arguments to bool. Change "found" variable to bool.
27927         (load_killed_in_block_p): Change return type from int to void and
27928         adjust function body accordingly.  Change "avail_p" argument to bool.
27929         (pre_expr_reaches_here_p): Change return type from int to void
27930         and adjust function body accordingly.
27931         (pre_delete): Ditto.  Change "changed" variable to bool.
27932         (pre_gcse): Change return type from int to void
27933         and adjust function body accordingly. Change "did_insert" and
27934         "changed" variables to bool.
27935         (one_pre_gcse_pass): Change return type from int to void
27936         and adjust function body accordingly.  Change "changed" variable
27937         to bool.
27938         (should_hoist_expr_to_dom): Change return type from int to void
27939         and adjust function body accordingly.  Change
27940         "visited_allocated_locally" variable to bool.
27941         (hoist_code): Change return type from int to void and adjust
27942         function body accordingly.  Change "changed" variable to bool.
27943         (one_code_hoisting_pass): Ditto.
27944         (pre_edge_insert): Change return type from int to void and adjust
27945         function body accordingly.  Change "did_insert" variable to bool.
27946         (pre_expr_reaches_here_p_work): Change return type from int to void
27947         and adjust function body accordingly.
27948         (simple_mem): Ditto.
27949         (want_to_gcse_p): Change return type from int to void
27950         and adjust function body accordingly.
27951         (can_assign_to_reg_without_clobbers_p): Update function body
27952         for bool return type.
27953         (hash_scan_set): Change "antic_p" and "avail_p" variables to bool.
27954         (pre_insert_copies): Change "added_copy" variable to bool.
27956 2023-07-08  Jonathan Wakely  <jwakely@redhat.com>
27958         PR c++/110595
27959         PR c++/110596
27960         * doc/invoke.texi (Warning Options): Fix typos.
27962 2023-07-07  Jan Hubicka  <jh@suse.cz>
27964         * profile-count.cc (profile_count::dump): Add FUN
27965         parameter; print relative frequency.
27966         (profile_count::debug): Update.
27967         * profile-count.h (profile_count::dump): Update
27968         prototype.
27970 2023-07-07  Roger Sayle  <roger@nextmovesoftware.com>
27972         PR target/43644
27973         PR target/110533
27974         * config/i386/i386-expand.cc (ix86_expand_move): Convert SETs of
27975         TImode destinations from paradoxical SUBREGs (setting the lowpart)
27976         into explicit zero extensions.  Use *insvti_highpart_1 instruction
27977         to set the highpart of a TImode destination.
27979 2023-07-07  Jan Hubicka  <jh@suse.cz>
27981         * predict.cc (force_edge_cold): Use
27982         set_edge_probability_and_rescale_others; improve dumps.
27984 2023-07-07  Jan Hubicka  <jh@suse.cz>
27986         * cfgloopmanip.cc (scale_loop_profile): Fix computation of count_in and scaling blocks
27987         after exit.
27988         * tree-vect-loop-manip.cc (vect_do_peeling): Scale loop profile of the epilogue if bound
27989         is known.
27991 2023-07-07  Juergen Christ  <jchrist@linux.ibm.com>
27993         * config/s390/s390.cc (vec_init): Fix default case
27995 2023-07-07  Vladimir N. Makarov  <vmakarov@redhat.com>
27997         * lra-assigns.cc (assign_by_spills): Add reload insns involving
27998         reload pseudos with non-refined class to be processed on the next
27999         sub-pass.
28000         * lra-constraints.cc (enough_allocatable_hard_regs_p): New func.
28001         (in_class_p): Use it.
28002         (print_curr_insn_alt): New func.
28003         (process_alt_operands): Use it.  Improve debug info.
28004         (curr_insn_transform): Use print_curr_insn_alt.  Refine reload
28005         pseudo class if it is not refined yet.
28007 2023-07-07  Aldy Hernandez  <aldyh@redhat.com>
28009         * value-range.cc (irange::get_bitmask_from_range): Return all the
28010         known bits for a singleton.
28011         (irange::set_range_from_bitmask): Set a range of a singleton when
28012         all bits are known.
28014 2023-07-07  Aldy Hernandez  <aldyh@redhat.com>
28016         * value-range.cc (irange::intersect): Leave normalization to
28017         caller.
28019 2023-07-07  Aldy Hernandez  <aldyh@redhat.com>
28021         * data-streamer-in.cc (streamer_read_value_range): Adjust for
28022         value/mask.
28023         * data-streamer-out.cc (streamer_write_vrange): Same.
28024         * range-op.cc (operator_cast::fold_range): Same.
28025         * value-range-pretty-print.cc
28026         (vrange_printer::print_irange_bitmasks): Same.
28027         * value-range-storage.cc (irange_storage::write_lengths_address):
28028         Same.
28029         (irange_storage::set_irange): Same.
28030         (irange_storage::get_irange): Same.
28031         (irange_storage::size): Same.
28032         (irange_storage::dump): Same.
28033         * value-range-storage.h: Same.
28034         * value-range.cc (debug): New.
28035         (irange_bitmask::dump): New.
28036         (add_vrange): Adjust for value/mask.
28037         (irange::operator=): Same.
28038         (irange::set): Same.
28039         (irange::verify_range): Same.
28040         (irange::operator==): Same.
28041         (irange::contains_p): Same.
28042         (irange::irange_single_pair_union): Same.
28043         (irange::union_): Same.
28044         (irange::intersect): Same.
28045         (irange::invert): Same.
28046         (irange::get_nonzero_bits_from_range): Rename to...
28047         (irange::get_bitmask_from_range): ...this.
28048         (irange::set_range_from_nonzero_bits): Rename to...
28049         (irange::set_range_from_bitmask): ...this.
28050         (irange::set_nonzero_bits): Rename to...
28051         (irange::update_bitmask): ...this.
28052         (irange::get_nonzero_bits): Rename to...
28053         (irange::get_bitmask): ...this.
28054         (irange::intersect_nonzero_bits): Rename to...
28055         (irange::intersect_bitmask): ...this.
28056         (irange::union_nonzero_bits): Rename to...
28057         (irange::union_bitmask): ...this.
28058         (irange_bitmask::verify_mask): New.
28059         * value-range.h (class irange_bitmask): New.
28060         (irange_bitmask::set_unknown): New.
28061         (irange_bitmask::unknown_p): New.
28062         (irange_bitmask::irange_bitmask): New.
28063         (irange_bitmask::get_precision): New.
28064         (irange_bitmask::get_nonzero_bits): New.
28065         (irange_bitmask::set_nonzero_bits): New.
28066         (irange_bitmask::operator==): New.
28067         (irange_bitmask::union_): New.
28068         (irange_bitmask::intersect): New.
28069         (class irange): Friend vrange_printer.
28070         (irange::varying_compatible_p): Adjust for bitmask.
28071         (irange::set_varying): Same.
28072         (irange::set_nonzero): Same.
28074 2023-07-07  Jan Beulich  <jbeulich@suse.com>
28076         * config/i386/sse.md (*vec_extractv2ti): Drop g modifiers.
28078 2023-07-07  Jan Beulich  <jbeulich@suse.com>
28080         * config/i386/sse.md (@vec_extract_hi_<mode>): Drop last
28081         alternative. Switch new last alternative's "isa" attribute to
28082         "avx512vl".
28083         (vec_extract_hi_v32qi): Likewise.
28085 2023-07-07  Pan Li  <pan2.li@intel.com>
28086             Robin Dapp  <rdapp@ventanamicro.com>
28088         * config/riscv/riscv.cc (riscv_emit_mode_set): Avoid emit insn
28089         when FRM_MODE_DYN.
28090         (riscv_mode_entry): Take FRM_MODE_DYN as entry mode.
28091         (riscv_mode_exit): Likewise for exit mode.
28092         (riscv_mode_needed): Likewise for needed mode.
28093         (riscv_mode_after): Likewise for after mode.
28095 2023-07-07  Pan Li  <pan2.li@intel.com>
28097         * config/riscv/vector.md: Fix typo.
28099 2023-07-06  Jan Hubicka  <jh@suse.cz>
28101         PR middle-end/25623
28102         * tree-ssa-loop-ch.cc (ch_base::copy_headers): Scale loop frequency to maximal number
28103         of iterations determined.
28104         * tree-ssa-loop-ivcanon.cc (try_unroll_loop_completely): Likewise.
28106 2023-07-06  Jan Hubicka  <jh@suse.cz>
28108         * cfgloopmanip.cc (scale_loop_profile): Rewrite exit edge
28109         probability update to be safe on loops with subloops.
28110         Make bound parameter to be iteration bound.
28111         * tree-ssa-loop-ivcanon.cc (try_peel_loop): Update call
28112         of scale_loop_profile.
28113         * tree-vect-loop-manip.cc (vect_do_peeling): Likewise.
28115 2023-07-06  Hao Liu OS  <hliu@os.amperecomputing.com>
28117         PR tree-optimization/110449
28118         * tree-vect-loop.cc (vectorizable_induction): use vec_n to replace
28119         vec_loop for the unrolled loop.
28121 2023-07-06  Jan Hubicka  <jh@suse.cz>
28123         * cfg.cc (set_edge_probability_and_rescale_others): New function.
28124         (update_bb_profile_for_threading): Use it; simplify the rest.
28125         * cfg.h (set_edge_probability_and_rescale_others): Declare.
28126         * profile-count.h (profile_probability::apply_scale): New.
28128 2023-07-06  Claudiu Zissulescu  <claziss@gmail.com>
28130         * doc/extend.texi (ARC Built-in Functions): Update documentation
28131         with missing builtins.
28133 2023-07-06  Richard Biener  <rguenther@suse.de>
28135         PR tree-optimization/110556
28136         * tree-ssa-tail-merge.cc (gimple_equal_p): Check
28137         assign code and all operands of non-stores.
28139 2023-07-06  Richard Biener  <rguenther@suse.de>
28141         PR tree-optimization/110563
28142         * tree-vectorizer.h (vect_determine_partial_vectors_and_peeling):
28143         Remove second argument.
28144         * tree-vect-loop.cc (vect_determine_partial_vectors_and_peeling):
28145         Remove for_epilogue_p argument.  Merge assert ...
28146         (vect_analyze_loop_2): ... with check done before determining
28147         partial vectors by moving it after.
28148         * tree-vect-loop-manip.cc (vect_do_peeling): Adjust.
28150 2023-07-06  Thomas Schwinge  <thomas@codesourcery.com>
28152         * ggc-common.cc (gt_pch_note_reorder, gt_pch_save): Tighten up a
28153         few things re 'reorder' option and strings.
28154         * stringpool.cc (gt_pch_p_S): This is now 'gcc_unreachable'.
28156 2023-07-06  Thomas Schwinge  <thomas@codesourcery.com>
28158         * gengtype-parse.cc: Clean up obsolete parametrized structs
28159         remnants.
28160         * gengtype.cc: Likewise.
28161         * gengtype.h: Likewise.
28163 2023-07-06  Thomas Schwinge  <thomas@codesourcery.com>
28165         * gengtype.cc (struct walk_type_data): Remove 'needs_cast_p'.
28166         Adjust all users.
28168 2023-07-06  Thomas Schwinge  <thomas@codesourcery.com>
28170         * gengtype-parse.cc (token_names): Add '"user"'.
28171         * gengtype.h (gty_token): Add 'UNUSED_PARAM_IS' for use with
28172         'FIRST_TOKEN_WITH_VALUE'.
28174 2023-07-06  Thomas Schwinge  <thomas@codesourcery.com>
28176         * doc/gty.texi (GTY Options) <string_length>: Enhance.
28178 2023-07-06  Thomas Schwinge  <thomas@codesourcery.com>
28180         * gengtype.cc (write_root, write_roots): Explicitly reject
28181         'string_length' option.
28182         * doc/gty.texi (GTY Options) <string_length>: Document.
28184 2023-07-06  Thomas Schwinge  <thomas@codesourcery.com>
28186         * ggc-internal.h (ggc_pch_count_object, ggc_pch_alloc_object)
28187         (ggc_pch_write_object): Remove 'bool is_string' argument.
28188         * ggc-common.cc: Adjust.
28189         * ggc-page.cc: Likewise.
28191 2023-07-06  Roger Sayle  <roger@nextmovesoftware.com>
28193         * dwarf2out.cc (mem_loc_descriptor): Handle COPYSIGN.
28195 2023-07-06  Hongyu Wang  <hongyu.wang@intel.com>
28197         * doc/extend.texi: Move x86 inlining rule to a new subsubsection
28198         and add description for inling of function with arch and tune
28199         attributes.
28201 2023-07-06  Richard Biener  <rguenther@suse.de>
28203         PR tree-optimization/110515
28204         * tree-ssa-pre.cc (compute_avail): Make code dealing
28205         with hoisting loads with different alias-sets more
28206         robust.
28208 2023-07-06  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
28210         * tree-vect-stmts.cc (vect_get_strided_load_store_ops): Fix ICE.
28212 2023-07-06  Hongyu Wang  <hongyu.wang@intel.com>
28214         * config/i386/i386.cc (ix86_can_inline_p): If callee has
28215         default arch=x86-64 and tune=generic, do not block the
28216         inlining to its caller. Also allow callee with different
28217         arch= to be inlined if it has always_inline attribute and
28218         it's ISA is subset of caller's.
28220 2023-07-06  liuhongt  <hongtao.liu@intel.com>
28222         * config/i386/i386.cc (ix86_rtx_costs): Adjust rtx_cost for
28223         DF/SFmode AND/IOR/XOR/ANDN operations.
28225 2023-07-06  Andrew Pinski  <apinski@marvell.com>
28227         PR middle-end/110554
28228         * tree-vect-generic.cc (expand_vector_condition): For comparisons,
28229         just build using boolean_type_node instead of the cond_type.
28230         For non-comparisons/non-scalar-bitmask, build a ` != 0` gimple
28231         that will feed into the COND_EXPR.
28233 2023-07-06  liuhongt  <hongtao.liu@intel.com>
28235         PR target/110170
28236         * config/i386/i386.md (movdf_internal): Disparage slightly for
28237         2 alternatives (r,v) and (v,r) by adding constraint modifier
28238         '?'.
28240 2023-07-06  Jeevitha Palanisamy  <jeevitha@linux.ibm.com>
28242         PR target/106907
28243         * config/rs6000/rs6000.cc (rs6000_expand_vector_extract): Remove redundant
28244         initialization of new_addr.
28246 2023-07-06  Hao Liu  <hliu@os.amperecomputing.com>
28248         PR tree-optimization/110474
28249         * tree-vect-loop.cc (vect_analyze_loop_2): unscale the VF by suggested
28250         unroll factor while selecting the epilog vect loop VF.
28252 2023-07-05  Andrew MacLeod  <amacleod@redhat.com>
28254         * gimple-range-gori.cc (compute_operand_range): Convert to a tail
28255         call.
28257 2023-07-05  Andrew MacLeod  <amacleod@redhat.com>
28259         * gimple-range-gori.cc (compute_operand_range): After calling
28260         compute_operand2_range, recursively call self if needed.
28261         (compute_operand2_range): Turn into a leaf function.
28262         (gori_compute::compute_operand1_and_operand2_range): Finish
28263         operand2 calculation.
28264         * gimple-range-gori.h (compute_operand2_range): Remove name param.
28266 2023-07-05  Andrew MacLeod  <amacleod@redhat.com>
28268         * gimple-range-gori.cc (compute_operand_range): After calling
28269         compute_operand1_range, recursively call self if needed.
28270         (compute_operand1_range): Turn into a leaf function.
28271         (gori_compute::compute_operand1_and_operand2_range): Finish
28272         operand1 calculation.
28273         * gimple-range-gori.h (compute_operand1_range): Remove name param.
28275 2023-07-05  Andrew MacLeod  <amacleod@redhat.com>
28277         * gimple-range-gori.cc (compute_operand_range): Check for
28278         operand interdependence when both op1 and op2 are computed.
28279         (compute_operand1_and_operand2_range): No checks required now.
28281 2023-07-05  Andrew MacLeod  <amacleod@redhat.com>
28283         * gimple-range-gori.cc (compute_operand_range): Check for
28284         a relation between op1 and op2 and use that instead.
28285         (compute_operand1_range): Don't look for a relation override.
28286         (compute_operand2_range): Ditto.
28288 2023-07-05  Jonathan Wakely  <jwakely@redhat.com>
28290         * doc/contrib.texi (Contributors): Update my entry.
28292 2023-07-05  Filip Kastl  <filip.kastl@gmail.com>
28294         * value-prof.cc (gimple_mod_subtract_transform): Correct edge
28295         prob calculation.
28297 2023-07-05  Uros Bizjak  <ubizjak@gmail.com>
28299         * sched-int.h (struct haifa_sched_info): Change can_schedule_ready_p,
28300         scehdule_more_p and contributes_to_priority indirect frunction
28301         type from int to bool.
28302         (no_real_insns_p): Change return type from int to bool.
28303         (contributes_to_priority): Ditto.
28304         * haifa-sched.cc (no_real_insns_p): Change return type from
28305         int to bool and adjust function body accordingly.
28306         * modulo-sched.cc (try_scheduling_node_in_cycle): Change "success"
28307         variable type from int to bool.
28308         (ps_insn_advance_column): Change return type from int to bool.
28309         (ps_has_conflicts): Ditto. Change "has_conflicts"
28310         variable type from int to bool.
28311         * sched-deps.cc (deps_may_trap_p): Change return type from int to bool.
28312         (conditions_mutex_p): Ditto.
28313         * sched-ebb.cc (schedule_more_p): Ditto.
28314         (ebb_contributes_to_priority): Change return type from
28315         int to bool and adjust function body accordingly.
28316         * sched-rgn.cc (is_cfg_nonregular): Ditto.
28317         (check_live_1): Ditto.
28318         (is_pfree): Ditto.
28319         (find_conditional_protection): Ditto.
28320         (is_conditionally_protected): Ditto.
28321         (is_prisky): Ditto.
28322         (is_exception_free): Ditto.
28323         (haifa_find_rgns): Change "unreachable" and "too_large_failure"
28324         variables from int to bool.
28325         (extend_rgns): Change "rescan" variable from int to bool.
28326         (check_live): Change return type from
28327         int to bool and adjust function body accordingly.
28328         (can_schedule_ready_p): Ditto.
28329         (schedule_more_p): Ditto.
28330         (contributes_to_priority): Ditto.
28332 2023-07-05  Robin Dapp  <rdapp@ventanamicro.com>
28334         * doc/md.texi: Document that vec_set and vec_extract must not
28335         fail.
28336         * gimple-isel.cc (gimple_expand_vec_set_expr): Rename this...
28337         (gimple_expand_vec_set_extract_expr): ...to this.
28338         (gimple_expand_vec_exprs): Call renamed function.
28339         * internal-fn.cc (vec_extract_direct): Add.
28340         (expand_vec_extract_optab_fn): New function to expand
28341         vec_extract optab.
28342         (direct_vec_extract_optab_supported_p): Add.
28343         * internal-fn.def (VEC_EXTRACT): Add.
28344         * optabs.cc (can_vec_extract_var_idx_p): New function.
28345         * optabs.h (can_vec_extract_var_idx_p): Declare.
28347 2023-07-05  Robin Dapp  <rdapp@ventanamicro.com>
28349         * config/riscv/autovec.md: Add gen_lowpart.
28351 2023-07-05  Robin Dapp  <rdapp@ventanamicro.com>
28353         * config/riscv/autovec.md: Allow register index operand.
28355 2023-07-05  Pan Li  <pan2.li@intel.com>
28357         * config/riscv/riscv-vector-builtins.cc
28358         (function_expander::use_exact_insn): Use FRM_DYN instead of const0.
28360 2023-07-05  Robin Dapp  <rdapp@ventanamicro.com>
28362         * config/riscv/autovec.md: Use float_truncate.
28364 2023-07-05  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
28366         * internal-fn.cc (internal_fn_len_index): Apply
28367         LEN_MASK_GATHER_LOAD/SCATTER_STORE into vectorizer.
28368         (internal_fn_mask_index): Ditto.
28369         * optabs-query.cc (supports_vec_gather_load_p): Ditto.
28370         (supports_vec_scatter_store_p): Ditto.
28371         * tree-vect-data-refs.cc (vect_gather_scatter_fn_p): Ditto.
28372         * tree-vect-patterns.cc (vect_recog_gather_scatter_pattern): Ditto.
28373         * tree-vect-stmts.cc (check_load_store_for_partial_vectors): Ditto.
28374         (vect_get_strided_load_store_ops): Ditto.
28375         (vectorizable_store): Ditto.
28376         (vectorizable_load): Ditto.
28378 2023-07-05  Robin Dapp  <rdapp@ventanamicro.com>
28379             Juzhe-Zhong  <juzhe.zhong@rivai.ai>
28381         * simplify-rtx.cc (native_encode_rtx): Ditto.
28382         (native_decode_vector_rtx): Ditto.
28383         (simplify_const_vector_byte_offset): Ditto.
28384         (simplify_const_vector_subreg): Ditto.
28385         * tree.cc (build_truth_vector_type_for_mode): Ditto.
28386         * varasm.cc (output_constant_pool_2): Ditto.
28388 2023-07-05  YunQiang Su  <yunqiang.su@cipunited.com>
28390         * config/mips/mips.cc (mips_expand_block_move): don't expand for
28391         r6 with -mno-unaligned-access option if one or both of src and
28392         dest are unaligned. restruct: return directly if length is not const.
28393         (mips_block_move_straight): emit_move if ISA_HAS_UNALIGNED_ACCESS.
28395 2023-07-05  Jan Beulich  <jbeulich@suse.com>
28397         PR target/100711
28398         * config/i386/sse.md: New splitters to simplify
28399         not;vec_duplicate as a singular vpternlog.
28400         (one_cmpl<mode>2): Allow broadcast for operand 1.
28401         (<mask_codefor>one_cmpl<mode>2<mask_name>): Likewise.
28403 2023-07-05  Jan Beulich  <jbeulich@suse.com>
28405         PR target/100711
28406         * config/i386/sse.md: New splitters to simplify
28407         not;vec_duplicate;{ior,xor} as vec_duplicate;{iornot,xnor}.
28409 2023-07-05  Jan Beulich  <jbeulich@suse.com>
28411         PR target/100711
28412         * config/i386/sse.md: Permit non-immediate operand 1 in AVX2
28413         form of splitter for PR target/100711.
28415 2023-07-05  Richard Biener  <rguenther@suse.de>
28417         PR middle-end/110541
28418         * tree.def (VEC_PERM_EXPR): Adjust documentation to reflect
28419         reality.
28421 2023-07-05  Jan Beulich  <jbeulich@suse.com>
28423         PR target/93768
28424         * config/i386/sse.md (*andnot<mode>3): Add new alternatives
28425         for memory form operand 1.
28427 2023-07-05  Jan Beulich  <jbeulich@suse.com>
28429         PR target/93768
28430         * config/i386/i386.cc (ix86_rtx_costs): Further special-case
28431         bitwise vector operations.
28432         * config/i386/sse.md (*iornot<mode>3): New insn.
28433         (*xnor<mode>3): Likewise.
28434         (*<nlogic><mode>3): Likewise.
28435         (andor): New code iterator.
28436         (nlogic): New code attribute.
28437         (ternlog_nlogic): Likewise.
28439 2023-07-05  Richard Biener  <rguenther@suse.de>
28441         * tree-vect-stmts.cc (vect_mark_relevant): Fix typo.
28443 2023-07-05  yulong  <shiyulong@iscas.ac.cn>
28445         * config/riscv/vector.md: Add float16 attr at sew、vlmul and ratio.
28447 2023-07-05  yulong  <shiyulong@iscas.ac.cn>
28449         * config/riscv/genrvv-type-indexer.cc (valid_type): Enable FP16 tuple.
28450         * config/riscv/riscv-modes.def (RVV_TUPLE_MODES): New macro.
28451         (ADJUST_ALIGNMENT): Ditto.
28452         (RVV_TUPLE_PARTIAL_MODES): Ditto.
28453         (ADJUST_NUNITS): Ditto.
28454         * config/riscv/riscv-vector-builtins-types.def (vfloat16mf4x2_t):
28455         New types.
28456         (vfloat16mf4x3_t): Ditto.
28457         (vfloat16mf4x4_t): Ditto.
28458         (vfloat16mf4x5_t): Ditto.
28459         (vfloat16mf4x6_t): Ditto.
28460         (vfloat16mf4x7_t): Ditto.
28461         (vfloat16mf4x8_t): Ditto.
28462         (vfloat16mf2x2_t): Ditto.
28463         (vfloat16mf2x3_t): Ditto.
28464         (vfloat16mf2x4_t): Ditto.
28465         (vfloat16mf2x5_t): Ditto.
28466         (vfloat16mf2x6_t): Ditto.
28467         (vfloat16mf2x7_t): Ditto.
28468         (vfloat16mf2x8_t): Ditto.
28469         (vfloat16m1x2_t): Ditto.
28470         (vfloat16m1x3_t): Ditto.
28471         (vfloat16m1x4_t): Ditto.
28472         (vfloat16m1x5_t): Ditto.
28473         (vfloat16m1x6_t): Ditto.
28474         (vfloat16m1x7_t): Ditto.
28475         (vfloat16m1x8_t): Ditto.
28476         (vfloat16m2x2_t): Ditto.
28477         (vfloat16m2x3_t): Ditto.
28478         (vfloat16m2x4_t): Ditto.
28479         (vfloat16m4x2_t): Ditto.
28480         * config/riscv/riscv-vector-builtins.def (vfloat16mf4x2_t): New macro.
28481         (vfloat16mf4x3_t): Ditto.
28482         (vfloat16mf4x4_t): Ditto.
28483         (vfloat16mf4x5_t): Ditto.
28484         (vfloat16mf4x6_t): Ditto.
28485         (vfloat16mf4x7_t): Ditto.
28486         (vfloat16mf4x8_t): Ditto.
28487         (vfloat16mf2x2_t): Ditto.
28488         (vfloat16mf2x3_t): Ditto.
28489         (vfloat16mf2x4_t): Ditto.
28490         (vfloat16mf2x5_t): Ditto.
28491         (vfloat16mf2x6_t): Ditto.
28492         (vfloat16mf2x7_t): Ditto.
28493         (vfloat16mf2x8_t): Ditto.
28494         (vfloat16m1x2_t): Ditto.
28495         (vfloat16m1x3_t): Ditto.
28496         (vfloat16m1x4_t): Ditto.
28497         (vfloat16m1x5_t): Ditto.
28498         (vfloat16m1x6_t): Ditto.
28499         (vfloat16m1x7_t): Ditto.
28500         (vfloat16m1x8_t): Ditto.
28501         (vfloat16m2x2_t): Ditto.
28502         (vfloat16m2x3_t): Ditto.
28503         (vfloat16m2x4_t): Ditto.
28504         (vfloat16m4x2_t): Ditto.
28505         * config/riscv/riscv-vector-switch.def (TUPLE_ENTRY): New.
28506         * config/riscv/riscv.md: New.
28507         * config/riscv/vector-iterators.md: New.
28509 2023-07-04  Andrew Pinski  <apinski@marvell.com>
28511         PR tree-optimization/110487
28512         * match.pd (a !=/== CST1 ? CST2 : CST3): Always
28513         build a nonstandard integer and use that.
28515 2023-07-04  Andrew Pinski  <apinski@marvell.com>
28517         * match.pd (a?-1:0): Cast type an integer type
28518         rather the type before the negative.
28519         (a?0:-1): Likewise.
28521 2023-07-04  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
28523         * config/xtensa/xtensa.cc (machine_function, xtensa_expand_prologue):
28524         Change to use HARD_REG_BIT and its macros.
28525         * config/xtensa/xtensa.md
28526         (peephole2: regmove elimination during DFmode input reload):
28527         Likewise.
28529 2023-07-04  Richard Biener  <rguenther@suse.de>
28531         PR tree-optimization/110491
28532         * tree-ssa-phiopt.cc (match_simplify_replacement): Check
28533         whether the PHI args are possibly undefined before folding
28534         the COND_EXPR.
28536 2023-07-04  Pan Li  <pan2.li@intel.com>
28537             Thomas Schwinge  <thomas@codesourcery.com>
28539         * lto-streamer-in.cc (lto_input_mode_table): Stream in the mode
28540         bits for machine mode table.
28541         * lto-streamer-out.cc (lto_write_mode_table): Stream out the
28542         HOST machine mode bits.
28543         * lto-streamer.h (struct lto_file_decl_data): New fields mode_bits.
28544         * tree-streamer.cc (streamer_mode_table): Take MAX_MACHINE_MODE
28545         as the table size.
28546         * tree-streamer.h (streamer_mode_table): Ditto.
28547         (bp_pack_machine_mode): Take 1 << ceil_log2 (MAX_MACHINE_MODE)
28548         as the packing limit.
28549         (bp_unpack_machine_mode): Ditto with 'file_data->mode_bits'.
28551 2023-07-04  Thomas Schwinge  <thomas@codesourcery.com>
28553         * lto-streamer.h (class lto_input_block): Capture
28554         'lto_file_decl_data *file_data' instead of just
28555         'unsigned char *mode_table'.
28556         * ipa-devirt.cc (ipa_odr_read_section): Adjust.
28557         * ipa-fnsummary.cc (inline_read_section): Likewise.
28558         * ipa-icf.cc (sem_item_optimizer::read_section): Likewise.
28559         * ipa-modref.cc (read_section): Likewise.
28560         * ipa-prop.cc (ipa_prop_read_section, read_replacements_section):
28561         Likewise.
28562         * ipa-sra.cc (isra_read_summary_section): Likewise.
28563         * lto-cgraph.cc (input_cgraph_opt_section): Likewise.
28564         * lto-section-in.cc (lto_create_simple_input_block): Likewise.
28565         * lto-streamer-in.cc (lto_read_body_or_constructor)
28566         (lto_input_toplevel_asms): Likewise.
28567         * tree-streamer.h (bp_unpack_machine_mode): Likewise.
28569 2023-07-04  Richard Biener  <rguenther@suse.de>
28571         * tree-ssa-phiopt.cc (pass_phiopt::execute): Mark SSA undefs.
28572         (empty_bb_or_one_feeding_into_p): Check for them.
28573         * tree-ssa.h (gimple_uses_undefined_value_p): Remove.
28574         * tree-ssa.cc (gimple_uses_undefined_value_p): Likewise.
28576 2023-07-04  Richard Biener  <rguenther@suse.de>
28578         * tree-vect-loop.cc (vect_analyze_loop_costing): Remove
28579         check guarding scalar_niter underflow.
28581 2023-07-04  Hao Liu  <hliu@os.amperecomputing.com>
28583         PR tree-optimization/110531
28584         * tree-vect-loop.cc (vect_analyze_loop_1): initialize
28585         slp_done_for_suggested_uf to false.
28587 2023-07-04  Richard Biener  <rguenther@suse.de>
28589         PR tree-optimization/110228
28590         * tree-ssa-ifcombine.cc (pass_tree_ifcombine::execute):
28591         Mark SSA may-undefs.
28592         (bb_no_side_effects_p): Check stmt uses for undefs.
28594 2023-07-04  Richard Biener  <rguenther@suse.de>
28596         PR tree-optimization/110436
28597         * tree-vect-stmts.cc (vect_mark_relevant): Expand dumping,
28598         force live but not relevant pattern stmts relevant.
28600 2023-07-04  Lili Cui  <lili.cui@intel.com>
28602         * config/i386/i386.h: Add PTA_ENQCMD and PTA_UINTR to PTA_SIERRAFOREST.
28603         * doc/invoke.texi: Update new isa to march=sierraforest and grandridge.
28605 2023-07-04  Richard Biener  <rguenther@suse.de>
28607         PR middle-end/110495
28608         * tree.h (TREE_OVERFLOW): Do not mention VECTOR_CSTs
28609         since we do not set TREE_OVERFLOW on those since the
28610         introduction of VL vectors.
28611         * match.pd (x +- CST +- CST): For VECTOR_CST do not look
28612         at TREE_OVERFLOW to determine validity of association.
28614 2023-07-04  Richard Biener  <rguenther@suse.de>
28616         PR tree-optimization/110310
28617         * tree-vect-loop.cc (vect_determine_partial_vectors_and_peeling):
28618         Move costing part ...
28619         (vect_analyze_loop_costing): ... here.  Integrate better
28620         estimate for epilogues from ...
28621         (vect_analyze_loop_2): Call vect_determine_partial_vectors_and_peeling
28622         with actual epilogue status.
28623         * tree-vect-loop-manip.cc (vect_do_peeling): ... here and
28624         avoid cancelling epilogue vectorization.
28625         (vect_update_epilogue_niters): Remove.  No longer update
28626         epilogue LOOP_VINFO_NITERS.
28628 2023-07-04  Pan Li  <pan2.li@intel.com>
28630         Revert:
28631         2023-07-03  Pan Li  <pan2.li@intel.com>
28633         * config/riscv/vector.md: Fix typo.
28635 2023-07-04  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
28637         * doc/md.texi: Add len_mask_gather_load/len_mask_scatter_store.
28638         * internal-fn.cc (expand_scatter_store_optab_fn): Ditto.
28639         (expand_gather_load_optab_fn): Ditto.
28640         (internal_load_fn_p): Ditto.
28641         (internal_store_fn_p): Ditto.
28642         (internal_gather_scatter_fn_p): Ditto.
28643         (internal_fn_len_index): Ditto.
28644         (internal_fn_mask_index): Ditto.
28645         (internal_fn_stored_value_index): Ditto.
28646         * internal-fn.def (LEN_MASK_GATHER_LOAD): Ditto.
28647         (LEN_MASK_SCATTER_STORE): Ditto.
28648         * optabs.def (OPTAB_CD): Ditto.
28650 2023-07-04  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
28652         * config/riscv/riscv-vsetvl.cc
28653         (vector_insn_info::parse_insn): Add early break.
28655 2023-07-04  Hans-Peter Nilsson  <hp@axis.com>
28657         * config/cris/cris.md (CRIS_UNSPEC_SWAP_BITS): Remove.
28658         ("cris_swap_bits", "ctzsi2"): Use bitreverse instead.
28660 2023-07-04  Hans-Peter Nilsson  <hp@axis.com>
28662         * dwarf2out.cc (mem_loc_descriptor): Handle BITREVERSE.
28664 2023-07-03  Christoph Müllner  <christoph.muellner@vrull.eu>
28666         * common/config/riscv/riscv-common.cc: Add support for zvbb,
28667         zvbc, zvkg, zvkned, zvknha, zvknhb, zvksed, zvksh, zvkn,
28668         zvknc, zvkng, zvks, zvksc, zvksg, zvkt and the implied subsets.
28669         * config/riscv/arch-canonicalize: Add canonicalization info for
28670         zvkn, zvknc, zvkng, zvks, zvksc, zvksg.
28671         * config/riscv/riscv-opts.h (MASK_ZVBB): New macro.
28672         (MASK_ZVBC): Likewise.
28673         (TARGET_ZVBB): Likewise.
28674         (TARGET_ZVBC): Likewise.
28675         (MASK_ZVKG): Likewise.
28676         (MASK_ZVKNED): Likewise.
28677         (MASK_ZVKNHA): Likewise.
28678         (MASK_ZVKNHB): Likewise.
28679         (MASK_ZVKSED): Likewise.
28680         (MASK_ZVKSH): Likewise.
28681         (MASK_ZVKN): Likewise.
28682         (MASK_ZVKNC): Likewise.
28683         (MASK_ZVKNG): Likewise.
28684         (MASK_ZVKS): Likewise.
28685         (MASK_ZVKSC): Likewise.
28686         (MASK_ZVKSG): Likewise.
28687         (MASK_ZVKT): Likewise.
28688         (TARGET_ZVKG): Likewise.
28689         (TARGET_ZVKNED): Likewise.
28690         (TARGET_ZVKNHA): Likewise.
28691         (TARGET_ZVKNHB): Likewise.
28692         (TARGET_ZVKSED): Likewise.
28693         (TARGET_ZVKSH): Likewise.
28694         (TARGET_ZVKN): Likewise.
28695         (TARGET_ZVKNC): Likewise.
28696         (TARGET_ZVKNG): Likewise.
28697         (TARGET_ZVKS): Likewise.
28698         (TARGET_ZVKSC): Likewise.
28699         (TARGET_ZVKSG): Likewise.
28700         (TARGET_ZVKT): Likewise.
28701         * config/riscv/riscv.opt: Introduction of riscv_zv{b,k}_subext.
28703 2023-07-03  Andrew Pinski  <apinski@marvell.com>
28705         PR middle-end/110510
28706         * except.h (struct eh_landing_pad_d): Add chain_next GTY.
28708 2023-07-03  Iain Sandoe  <iain@sandoe.co.uk>
28710         * config/darwin.h: Avoid duplicate multiply_defined specs on
28711         earlier Darwin versions with shared libgcc.
28713 2023-07-03  Uros Bizjak  <ubizjak@gmail.com>
28715         * tree.h (tree_int_cst_equal): Change return type from int to bool.
28716         (operand_equal_for_phi_arg_p): Ditto.
28717         (tree_map_base_marked_p): Ditto.
28718         * tree.cc (contains_placeholder_p): Update function body
28719         for bool return type.
28720         (type_cache_hasher::equal): Ditto.
28721         (tree_map_base_hash): Change return type
28722         from int to void and adjust function body accordingly.
28723         (tree_int_cst_equal): Ditto.
28724         (operand_equal_for_phi_arg_p): Ditto.
28725         (get_narrower): Change "first" variable to bool.
28726         (cl_option_hasher::equal): Update function body for bool return type.
28727         * ggc.h (ggc_set_mark): Change return type from int to bool.
28728         (ggc_marked_p): Ditto.
28729         * ggc-page.cc (gt_ggc_mx): Change return type
28730         from int to void and adjust function body accordingly.
28731         (ggc_set_mark): Ditto.
28733 2023-07-03  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
28735         * config/riscv/autovec.md: Change order of
28736         LEN_MASK_LOAD/LEN_MASK_STORE/LEN_LOAD/LEN_STORE arguments.
28737         * config/riscv/riscv-v.cc (expand_load_store): Ditto.
28738         * doc/md.texi: Ditto.
28739         * gimple-fold.cc (gimple_fold_partial_load_store_mem_ref): Ditto.
28740         * internal-fn.cc (len_maskload_direct): Ditto.
28741         (len_maskstore_direct): Ditto.
28742         (add_len_and_mask_args): New function.
28743         (expand_partial_load_optab_fn): Change order of
28744         LEN_MASK_LOAD/LEN_MASK_STORE/LEN_LOAD/LEN_STORE arguments.
28745         (expand_partial_store_optab_fn): Ditto.
28746         (internal_fn_len_index): New function.
28747         (internal_fn_mask_index): Change order of
28748         LEN_MASK_LOAD/LEN_MASK_STORE/LEN_LOAD/LEN_STORE arguments.
28749         (internal_fn_stored_value_index): Ditto.
28750         (internal_len_load_store_bias): Ditto.
28751         * internal-fn.h (internal_fn_len_index): New function.
28752         * tree-ssa-dse.cc (initialize_ao_ref_for_dse): Change order of
28753         LEN_MASK_LOAD/LEN_MASK_STORE/LEN_LOAD/LEN_STORE arguments.
28754         * tree-vect-stmts.cc (vectorizable_store): Ditto.
28755         (vectorizable_load): Ditto.
28757 2023-07-03  Gaius Mulley  <gaiusmod2@gmail.com>
28759         PR modula2/110125
28760         * doc/gm2.texi (Semantic checking): Include examples using
28761         -Wuninit-variable-checking.
28763 2023-07-03  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
28765         * config/riscv/autovec-opt.md (*double_widen_fnma<mode>): New pattern.
28766         (*single_widen_fnma<mode>): Ditto.
28767         (*double_widen_fms<mode>): Ditto.
28768         (*single_widen_fms<mode>): Ditto.
28769         (*double_widen_fnms<mode>): Ditto.
28770         (*single_widen_fnms<mode>): Ditto.
28772 2023-07-03  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
28774         * config/riscv/autovec-opt.md (@pred_single_widen_mul<any_extend:su><mode>): Change "@"
28775         into "*" in pattern name which simplifies build files.
28776         (*pred_single_widen_mul<any_extend:su><mode>): Ditto.
28777         (*pred_single_widen_mul<mode>): New pattern.
28779 2023-07-03  Richard Sandiford  <richard.sandiford@arm.com>
28781         * config/aarch64/aarch64-simd.md (vec_extract<mode><Vhalf>): Expect
28782         the index to be 0 or 1.
28784 2023-07-03  Lehua Ding  <lehua.ding@rivai.ai>
28786         Revert:
28787         2023-07-03  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
28789         * config/riscv/autovec-opt.md (*double_widen_fnma<mode>): New pattern.
28790         (*single_widen_fnma<mode>): Ditto.
28791         (*double_widen_fms<mode>): Ditto.
28792         (*single_widen_fms<mode>): Ditto.
28793         (*double_widen_fnms<mode>): Ditto.
28794         (*single_widen_fnms<mode>): Ditto.
28796 2023-07-03  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
28798         * config/riscv/autovec-opt.md (*double_widen_fnma<mode>): New pattern.
28799         (*single_widen_fnma<mode>): Ditto.
28800         (*double_widen_fms<mode>): Ditto.
28801         (*single_widen_fms<mode>): Ditto.
28802         (*double_widen_fnms<mode>): Ditto.
28803         (*single_widen_fnms<mode>): Ditto.
28805 2023-07-03  Pan Li  <pan2.li@intel.com>
28807         * config/riscv/vector.md: Fix typo.
28809 2023-07-03  Richard Biener  <rguenther@suse.de>
28811         PR tree-optimization/110506
28812         * tree-vect-patterns.cc (vect_recog_rotate_pattern): Re-order
28813         TYPE_PRECISION access with INTEGRAL_TYPE_P check.
28815 2023-07-03  Richard Biener  <rguenther@suse.de>
28817         PR tree-optimization/110506
28818         * tree-ssa-ccp.cc (get_value_for_expr): Check for integral
28819         type before relying on TYPE_PRECISION to produce a nonzero mask.
28821 2023-07-03  Jie Mei  <jie.mei@oss.cipunited.com>
28823         * config/mips/mips.md(*and<mode>3_mips16): Generates
28824         ZEB/ZEH instructions.
28826 2023-07-03  Jie Mei  <jie.mei@oss.cipunited.com>
28828         * config/mips/mips.cc(mips_9bit_offset_address_p): Restrict the
28829         address register to M16_REGS for MIPS16.
28830         (BUILTIN_AVAIL_MIPS16E2): Defined a new macro.
28831         (AVAIL_MIPS16E2_OR_NON_MIPS16): Same as above.
28832         (AVAIL_NON_MIPS16 (cache..)): Update to
28833         AVAIL_MIPS16E2_OR_NON_MIPS16.
28834         * config/mips/mips.h (ISA_HAS_CACHE): Add clause for ISA_HAS_MIPS16E2.
28835         * config/mips/mips.md (mips_cache): Mark as extended MIPS16.
28837 2023-07-03  Jie Mei  <jie.mei@oss.cipunited.com>
28839         * config/mips/mips.h(ISA_HAS_9BIT_DISPLACEMENT): Add clause
28840         for ISA_HAS_MIPS16E2.
28841         (ISA_HAS_SYNC): Same as above.
28842         (ISA_HAS_LL_SC): Same as above.
28844 2023-07-03  Jie Mei  <jie.mei@oss.cipunited.com>
28846         * config/mips/mips.cc(mips_expand_ins_as_unaligned_store):
28847         Add logics for generating instruction.
28848         * config/mips/mips.h(ISA_HAS_LWL_LWR): Add clause for ISA_HAS_MIPS16E2.
28849         * config/mips/mips.md(mov_<load>l): Generates instructions.
28850         (mov_<load>r): Same as above.
28851         (mov_<store>l): Adjusted for the conditions above.
28852         (mov_<store>r): Same as above.
28853         (mov_<store>l_mips16e2): Add machine description for `define_insn mov_<store>l_mips16e2`.
28854         (mov_<store>r_mips16e2): Add machine description for `define_insn mov_<store>r_mips16e2`.
28856 2023-07-03  Jie Mei  <jie.mei@oss.cipunited.com>
28858         * config/mips/mips.cc(mips_symbol_insns_1): Generates LUI instruction.
28859         (mips_const_insns): Same as above.
28860         (mips_output_move): Same as above.
28861         (mips_output_function_prologue): Same as above.
28862         * config/mips/mips.md: Same as above
28864 2023-07-03  Jie Mei  <jie.mei@oss.cipunited.com>
28866         * config/mips/constraints.md(Yz): New constraints for mips16e2.
28867         * config/mips/mips-protos.h(mips_bit_clear_p): Declared new function.
28868         (mips_bit_clear_info): Same as above.
28869         * config/mips/mips.cc(mips_bit_clear_info): New function for
28870         generating instructions.
28871         (mips_bit_clear_p): Same as above.
28872         * config/mips/mips.h(ISA_HAS_EXT_INS): Add clause for ISA_HAS_MIPS16E2.
28873         * config/mips/mips.md(extended_mips16): Generates EXT and INS instructions.
28874         (*and<mode>3): Generates INS instruction.
28875         (*and<mode>3_mips16): Generates EXT, INS and ANDI instructions.
28876         (ior<mode>3): Add logics for ORI instruction.
28877         (*ior<mode>3_mips16_asmacro): Generates ORI instrucion.
28878         (*ior<mode>3_mips16): Add logics for XORI instruction.
28879         (*xor<mode>3_mips16): Generates XORI instrucion.
28880         (*extzv<mode>): Add logics for EXT instruction.
28881         (*insv<mode>): Add logics for INS instruction.
28882         * config/mips/predicates.md(bit_clear_operand): New predicate for
28883         generating bitwise instructions.
28884         (and_reg_operand): Add logics for generating bitwise instructions.
28886 2023-07-03  Jie Mei  <jie.mei@oss.cipunited.com>
28888         * config/mips/mips.cc(mips_regno_mode_ok_for_base_p): Generate instructions
28889         that uses global pointer register.
28890         (mips16_unextended_reference_p): Same as above.
28891         (mips_pic_base_register): Same as above.
28892         (mips_init_relocs): Same as above.
28893         * config/mips/mips.h(MIPS16_GP_LOADS): Defined a new macro.
28894         (GLOBAL_POINTER_REGNUM): Moved to machine description `mips.md`.
28895         * config/mips/mips.md(GLOBAL_POINTER_REGNUM): Moved to here from above.
28896         (*lowsi_mips16_gp):New `define_insn *low<mode>_mips16`.
28898 2023-07-03  Jie Mei  <jie.mei@oss.cipunited.com>
28900         * config/mips/mips.h(ISA_HAS_CONDMOVE): Add condition for ISA_HAS_MIPS16E2.
28901         * config/mips/mips.md(*mov<GPR:mode>_on_<MOVECC:mode>): Add logics for MOVx insts.
28902         (*mov<GPR:mode>_on_<MOVECC:mode>_mips16e2): Generate MOVx instruction.
28903         (*mov<GPR:mode>_on_<GPR2:mode>_ne): Add logics for MOVx insts.
28904         (*mov<GPR:mode>_on_<GPR2:mode>_ne_mips16e2): Generate MOVx instruction.
28905         * config/mips/predicates.md(reg_or_0_operand_mips16e2): New predicate for MOVx insts.
28907 2023-07-03  Jie Mei  <jie.mei@oss.cipunited.com>
28909         * config/mips/mips.cc(mips_file_start): Add mips16e2 info
28910         for output file.
28911         * config/mips/mips.h(__mips_mips16e2): Defined a new
28912         predefine macro.
28913         (ISA_HAS_MIPS16E2): Defined a new macro.
28914         (ASM_SPEC): Pass mmips16e2 to the assembler.
28915         * config/mips/mips.opt: Add -m(no-)mips16e2 option.
28916         * config/mips/predicates.md: Add clause for TARGET_MIPS16E2.
28917         * doc/invoke.texi: Add -m(no-)mips16e2 option..
28919 2023-07-02  Jakub Jelinek  <jakub@redhat.com>
28921         PR tree-optimization/110508
28922         * tree-ssa-math-opts.cc (match_uaddc_usubc): Only replace re2 with
28923         REALPART_EXPR opf nlhs if re2 is non-NULL.
28925 2023-07-02  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
28927         * config/xtensa/xtensa.cc (xtensa_match_CLAMPS_imms_p):
28928         Simplify.
28929         * config/xtensa/xtensa.md (*xtensa_clamps):
28930         Add TARGET_MINMAX to the condition.
28932 2023-07-02  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
28934         * config/xtensa/xtensa.md (*eqne_INT_MIN):
28935         Add missing ":SI" to the match_operator.
28937 2023-07-02  Iain Sandoe  <iain@sandoe.co.uk>
28939         PR target/108743
28940         * config/darwin.opt: Add fconstant-cfstrings alias to
28941         mconstant-cfstrings.
28942         * doc/invoke.texi: Amend invocation descriptions to reflect
28943         that the fconstant-cfstrings is a target-option alias and to
28944         add the missing mconstant-cfstrings option description to the
28945         Darwin section.
28947 2023-07-01  Jan Hubicka  <jh@suse.cz>
28949         * tree-cfg.cc (gimple_duplicate_sese_region): Add elliminated_edge
28950         parmaeter; update profile.
28951         * tree-cfg.h (gimple_duplicate_sese_region): Update prototype.
28952         * tree-ssa-loop-ch.cc (entry_loop_condition_is_static): Rename to ...
28953         (static_loop_exit): ... this; return the edge to be elliminated.
28954         (ch_base::copy_headers): Handle profile updating for eliminated exits.
28956 2023-07-01  Roger Sayle  <roger@nextmovesoftware.com>
28958         * config/i386/i386-features.cc (compute_convert_gain): Provide
28959         gains/costs for ROTATE and ROTATERT (by an integer constant).
28960         (general_scalar_chain::convert_rotate): New helper function to
28961         convert a DImode or SImode rotation by an integer constant into
28962         SSE vector form.
28963         (general_scalar_chain::convert_insn): Call the new convert_rotate
28964         for ROTATE and ROTATERT.
28965         (general_scalar_to_vector_candidate_p): Consider ROTATE and
28966         ROTATERT to be candidates if the second operand is an integer
28967         constant, valid for a rotation (or shift) in the given mode.
28968         * config/i386/i386-features.h (general_scalar_chain): Add new
28969         helper method convert_rotate.
28971 2023-07-01  Jan Hubicka  <jh@suse.cz>
28973         PR tree-optimization/103680
28974         * cfg.cc (update_bb_profile_for_threading): Fix profile update;
28975         make message clearer.
28977 2023-06-30  Qing Zhao  <qing.zhao@oracle.com>
28979         PR tree-optimization/101832
28980         * tree-object-size.cc (addr_object_size): Handle structure/union type
28981         when it has flexible size.
28983 2023-06-30  Eric Botcazou  <ebotcazou@adacore.com>
28985         * gimple-fold.cc (fold_array_ctor_reference): Fix head comment.
28986         (fold_nonarray_ctor_reference): Likewise.  Specifically deal
28987         with integral bit-fields.
28988         (fold_ctor_reference): Make sure that the constructor uses the
28989         native storage order.
28991 2023-06-30  Jan Hubicka  <jh@suse.cz>
28993         PR middle-end/109849
28994         * predict.cc (estimate_bb_frequencies): Turn to static function.
28995         (expr_expected_value_1): Fix handling of binary expressions with
28996         predicted values.
28997         * predict.def (PRED_MALLOC_NONNULL): Move later in the priority queue.
28998         (PRED_BUILTIN_EXPECT_WITH_PROBABILITY): Move to almost top of the priority
28999         queue.
29000         * predict.h (estimate_bb_frequencies): No longer declare it.
29002 2023-06-30  Uros Bizjak  <ubizjak@gmail.com>
29004         * fold-const.h (multiple_of_p): Change return type from int to bool.
29005         * fold-const.cc (split_tree): Change negl_p, neg_litp_p,
29006         neg_conp_p and neg_var_p variables to bool.
29007         (const_binop): Change sat_p variable to bool.
29008         (merge_ranges): Change no_overlap variable to bool.
29009         (extract_muldiv_1): Change same_p variable to bool.
29010         (tree_swap_operands_p): Update function body for bool return type.
29011         (fold_truth_andor): Change commutative variable to bool.
29012         (multiple_of_p): Change return type
29013         from int to void and adjust function body accordingly.
29014         * optabs.h (expand_twoval_unop): Change return type from int to bool.
29015         (expand_twoval_binop): Ditto.
29016         (can_compare_p): Ditto.
29017         (have_add2_insn): Ditto.
29018         (have_addptr3_insn): Ditto.
29019         (have_sub2_insn): Ditto.
29020         (have_insn_for): Ditto.
29021         * optabs.cc (add_equal_note): Ditto.
29022         (widen_operand): Change no_extend argument from int to bool.
29023         (expand_binop): Ditto.
29024         (expand_twoval_unop): Change return type
29025         from int to void and adjust function body accordingly.
29026         (expand_twoval_binop): Ditto.
29027         (can_compare_p): Ditto.
29028         (have_add2_insn): Ditto.
29029         (have_addptr3_insn): Ditto.
29030         (have_sub2_insn): Ditto.
29031         (have_insn_for): Ditto.
29033 2023-06-30  Oluwatamilore Adebayo  <oluwatamilore.adebayo@arm.com>
29035         * config/aarch64/aarch64-simd.md
29036         (vec_widen_<su>abdl_lo_<mode>, vec_widen_<su>abdl_hi_<mode>):
29037         Expansions for abd vec widen optabs.
29038         (aarch64_<su>abdl<mode>_insn): VQW based abdl RTL.
29039         * config/aarch64/iterators.md (USMAX_EXT): Code attributes
29040         that give the appropriate extend RTL for the max RTL.
29042 2023-06-30  Oluwatamilore Adebayo  <oluwatamilore.adebayo@arm.com>
29044         * internal-fn.def (VEC_WIDEN_ABD): New internal hilo optab.
29045         * optabs.def (vec_widen_sabd_optab,
29046         vec_widen_sabd_hi_optab, vec_widen_sabd_lo_optab,
29047         vec_widen_sabd_odd_even, vec_widen_sabd_even_optab,
29048         vec_widen_uabd_optab,
29049         vec_widen_uabd_hi_optab, vec_widen_uabd_lo_optab,
29050         vec_widen_uabd_odd_even, vec_widen_uabd_even_optab):
29051         New optabs.
29052         * doc/md.texi: Document them.
29053         * tree-vect-patterns.cc (vect_recog_abd_pattern): Update to
29054         to build a VEC_WIDEN_ABD call if the input precision is smaller
29055         than the precision of the output.
29056         (vect_recog_widen_abd_pattern): Should an ABD expression be
29057         found preceeding an extension, replace the two with a
29058         VEC_WIDEN_ABD.
29060 2023-06-30  Pan Li  <pan2.li@intel.com>
29062         * config/riscv/vector.md: Refactor the common condition.
29064 2023-06-30  Richard Biener  <rguenther@suse.de>
29066         PR tree-optimization/110496
29067         * gimple-ssa-store-merging.cc (find_bswap_or_nop_1): Re-order
29068         verifying and TYPE_PRECISION query for the BIT_FIELD_REF case.
29070 2023-06-30  Richard Biener  <rguenther@suse.de>
29072         PR middle-end/110489
29073         * statistics.cc (curr_statistics_hash): Add argument
29074         indicating whether we should allocate the hash.
29075         (statistics_fini_pass): If the hash isn't allocated
29076         only print the summary header.
29078 2023-06-30  Segher Boessenkool  <segher@kernel.crashing.org>
29079             Thomas Schwinge  <thomas@codesourcery.com>
29081         * config/nvptx/nvptx.cc (TARGET_LRA_P): Remove.
29083 2023-06-30  Jovan Dmitrović  <jovan.dmitrovic@syrmia.com>
29085         PR target/109435
29086         * config/mips/mips.cc (mips_function_arg_alignment): Returns
29087         the alignment of function argument. In case of typedef type,
29088         it returns the aligment of the aliased type.
29089         (mips_function_arg_boundary): Relocated calculation of the
29090         aligment of function arguments.
29092 2023-06-29  Jan Hubicka  <jh@suse.cz>
29094         PR tree-optimization/109849
29095         * ipa-fnsummary.cc (decompose_param_expr): Skip
29096         functions returning its parameter.
29097         (set_cond_stmt_execution_predicate): Return early
29098         if predicate was constructed.
29100 2023-06-29  Qing Zhao  <qing.zhao@oracle.com>
29102         PR c/77650
29103         * doc/extend.texi: Document GCC extension on a structure containing
29104         a flexible array member to be a member of another structure.
29106 2023-06-29  Qing Zhao  <qing.zhao@oracle.com>
29108         * print-tree.cc (print_node): Print new bit type_include_flexarray.
29109         * tree-core.h (struct tree_type_common): Use bit no_named_args_stdarg_p
29110         as type_include_flexarray for RECORD_TYPE or UNION_TYPE.
29111         * tree-streamer-in.cc (unpack_ts_type_common_value_fields): Stream
29112         in bit no_named_args_stdarg_p properly for its corresponding type.
29113         * tree-streamer-out.cc (pack_ts_type_common_value_fields): Stream
29114         out bit no_named_args_stdarg_p properly for its corresponding type.
29115         * tree.h (TYPE_INCLUDES_FLEXARRAY): New macro TYPE_INCLUDES_FLEXARRAY.
29117 2023-06-29  Aldy Hernandez  <aldyh@redhat.com>
29119         * tree-vrp.cc (maybe_set_nonzero_bits): Move from here...
29120         * tree-ssa-dom.cc (maybe_set_nonzero_bits): ...to here.
29121         * tree-vrp.h (maybe_set_nonzero_bits): Remove.
29123 2023-06-29  Aldy Hernandez  <aldyh@redhat.com>
29125         * value-range.cc (frange::set): Do not call verify_range.
29126         (frange::normalize_kind): Verify range.
29127         (frange::union_nans): Do not call verify_range.
29128         (frange::union_): Same.
29129         (frange::intersect): Same.
29130         (irange::irange_single_pair_union): Call normalize_kind if
29131         necessary.
29132         (irange::union_): Same.
29133         (irange::intersect): Same.
29134         (irange::set_range_from_nonzero_bits): Verify range.
29135         (irange::set_nonzero_bits): Call normalize_kind if necessary.
29136         (irange::get_nonzero_bits): Tweak comment.
29137         (irange::intersect_nonzero_bits): Call normalize_kind if
29138         necessary.
29139         (irange::union_nonzero_bits): Same.
29140         * value-range.h (irange::normalize_kind): Verify range.
29142 2023-06-29  Uros Bizjak  <ubizjak@gmail.com>
29144         * cselib.h (rtx_equal_for_cselib_1):
29145         Change return type from int to bool.
29146         (references_value_p): Ditto.
29147         (rtx_equal_for_cselib_p): Ditto.
29148         * expr.h (can_store_by_pieces): Ditto.
29149         (try_casesi): Ditto.
29150         (try_tablejump): Ditto.
29151         (safe_from_p): Ditto.
29152         * sbitmap.h (bitmap_equal_p): Ditto.
29153         * cselib.cc (references_value_p): Change return type
29154         from int to void and adjust function body accordingly.
29155         (rtx_equal_for_cselib_1): Ditto.
29156         * expr.cc (is_aligning_offset): Ditto.
29157         (can_store_by_pieces): Ditto.
29158         (mostly_zeros_p): Ditto.
29159         (all_zeros_p): Ditto.
29160         (safe_from_p): Ditto.
29161         (is_aligning_offset): Ditto.
29162         (try_casesi): Ditto.
29163         (try_tablejump): Ditto.
29164         (store_constructor): Change "need_to_clear" and
29165         "const_bounds_p" variables to bool.
29166         * sbitmap.cc (bitmap_equal_p):  Change return type from int to bool.
29168 2023-06-29  Robin Dapp  <rdapp@ventanamicro.com>
29170         * tree-ssa-math-opts.cc (divmod_candidate_p): Use
29171         element_precision.
29173 2023-06-29  Richard Biener  <rguenther@suse.de>
29175         PR tree-optimization/110460
29176         * tree-vect-stmts.cc (get_related_vectype_for_scalar_type):
29177         Only allow integral, pointer and scalar float type scalar_type.
29179 2023-06-29  Lili Cui  <lili.cui@intel.com>
29181         PR tree-optimization/110148
29182         * tree-ssa-reassoc.cc (rewrite_expr_tree_parallel): Handle loop-carried
29183         ops in this function.
29185 2023-06-29  Richard Biener  <rguenther@suse.de>
29187         PR middle-end/110452
29188         * expr.cc (store_constructor): Handle uniform boolean
29189         vectors with integer mode specially.
29191 2023-06-29  Richard Biener  <rguenther@suse.de>
29193         PR middle-end/110461
29194         * match.pd (bitop (convert@2 @0) (convert?@3 @1)): Disable
29195         for VECTOR_TYPE_P.
29197 2023-06-29  Richard Sandiford  <richard.sandiford@arm.com>
29199         * vec.h (gt_pch_nx): Add overloads for va_gc_atomic.
29200         (array_slice): Relax va_gc constructor to handle all vectors
29201         with a vl_embed layout.
29203 2023-06-29  Pan Li  <pan2.li@intel.com>
29205         * config/riscv/riscv.cc (riscv_emit_mode_set): Add emit for FRM.
29206         (riscv_mode_needed): Likewise.
29207         (riscv_entity_mode_after): Likewise.
29208         (riscv_mode_after): Likewise.
29209         (riscv_mode_entry): Likewise.
29210         (riscv_mode_exit): Likewise.
29211         * config/riscv/riscv.h (NUM_MODES_FOR_MODE_SWITCHING): Add number
29212         for FRM.
29213         * config/riscv/riscv.md: Add FRM register.
29214         * config/riscv/vector-iterators.md: Add FRM type.
29215         * config/riscv/vector.md (frm_mode): Define new attr for FRM mode.
29216         (fsrm): Define new insn for fsrm instruction.
29218 2023-06-29  Pan Li  <pan2.li@intel.com>
29220         * config/riscv/riscv-protos.h (enum floating_point_rounding_mode):
29221         Add macro for static frm min and max.
29222         * config/riscv/riscv-vector-builtins-bases.cc
29223         (class binop_frm): New class for floating-point with frm.
29224         (BASE): Add vfadd for frm.
29225         * config/riscv/riscv-vector-builtins-bases.h: Likewise.
29226         * config/riscv/riscv-vector-builtins-functions.def
29227         (vfadd_frm): Likewise.
29228         * config/riscv/riscv-vector-builtins-shapes.cc
29229         (struct alu_frm_def): New struct for alu with frm.
29230         (SHAPE): Add alu with frm.
29231         * config/riscv/riscv-vector-builtins-shapes.h: Likewise.
29232         * config/riscv/riscv-vector-builtins.cc
29233         (function_checker::report_out_of_range_and_not): New function
29234         for report out of range and not val.
29235         (function_checker::require_immediate_range_or): New function
29236         for checking in range or one val.
29237         * config/riscv/riscv-vector-builtins.h: Add function decl.
29239 2023-06-29  Cui, Lili  <lili.cui@intel.com>
29241         * common/config/i386/cpuinfo.h (get_intel_cpu): Remove model value 0xa8
29242         from Rocketlake, move model value 0xbf from Alderlake to Raptorlake.
29244 2023-06-28  Hans-Peter Nilsson  <hp@axis.com>
29246         PR target/110144
29247         * config/cris/cris.cc (cris_postdbr_cmpelim): Don't apply PATTERN
29248         to insn before validating it.
29250 2023-06-28  Jan Hubicka  <jh@suse.cz>
29252         PR middle-end/110334
29253         * ipa-fnsummary.h (ipa_fn_summary): Add
29254         safe_to_inline_to_always_inline.
29255         * ipa-inline.cc (can_early_inline_edge_p): ICE
29256         if SSA is not built; do cycle checking for
29257         always_inline functions.
29258         (inline_always_inline_functions): Be recrusive;
29259         watch for cycles; do not updat overall summary.
29260         (early_inliner): Do not give up on always_inlines.
29261         * ipa-utils.cc (ipa_reverse_postorder): Do not skip
29262         always inlines.
29264 2023-06-28  Uros Bizjak  <ubizjak@gmail.com>
29266         * output.h (leaf_function_p): Change return type from int to bool.
29267         (final_forward_branch_p): Ditto.
29268         (only_leaf_regs_used): Ditto.
29269         (maybe_assemble_visibility): Ditto.
29270         * varasm.h (supports_one_only): Ditto.
29271         * rtl.h (compute_alignments): Change return type from int to void.
29272         * final.cc (app_on): Change return type from int to bool.
29273         (compute_alignments): Change return type from int to void
29274         and adjust function body accordingly.
29275         (shorten_branches):  Change "something_changed" variable
29276         type from int to bool.
29277         (leaf_function_p):  Change return type from int to bool
29278         and adjust function body accordingly.
29279         (final_forward_branch_p): Ditto.
29280         (only_leaf_regs_used): Ditto.
29281         * varasm.cc (contains_pointers_p): Change return type from
29282         int to bool and adjust function body accordingly.
29283         (compare_constant): Ditto.
29284         (maybe_assemble_visibility): Ditto.
29285         (supports_one_only): Ditto.
29287 2023-06-28  Manolis Tsamis  <manolis.tsamis@vrull.eu>
29289         PR debug/110308
29290         * regcprop.cc (maybe_mode_change): Check stack_pointer_rtx mode.
29291         (maybe_copy_reg_attrs): New function.
29292         (find_oldest_value_reg): Use maybe_copy_reg_attrs.
29293         (copyprop_hardreg_forward_1): Ditto.
29295 2023-06-28  Richard Biener  <rguenther@suse.de>
29297         PR tree-optimization/110434
29298         * tree-nrv.cc (pass_nrv::execute): Remove CLOBBERs of
29299         VAR we replace with <retval>.
29301 2023-06-28  Richard Biener  <rguenther@suse.de>
29303         PR tree-optimization/110451
29304         * tree-ssa-loop-im.cc (stmt_cost): [VEC_]COND_EXPR and
29305         tcc_comparison are expensive.
29307 2023-06-28  Roger Sayle  <roger@nextmovesoftware.com>
29309         * config/i386/i386-expand.cc (ix86_expand_branch): Also use ptest
29310         for TImode comparisons on 32-bit architectures.
29311         * config/i386/i386.md (cbranch<mode>4): Change from SDWIM to
29312         SWIM1248x to exclude/avoid TImode being conditional on -m64.
29313         (cbranchti4): New define_expand for TImode on both TARGET_64BIT
29314         and/or with TARGET_SSE4_1.
29315         * config/i386/predicates.md (ix86_timode_comparison_operator):
29316         New predicate that depends upon TARGET_64BIT.
29317         (ix86_timode_comparison_operand): Likewise.
29319 2023-06-28  Roger Sayle  <roger@nextmovesoftware.com>
29321         PR target/78794
29322         * config/i386/i386-features.cc (compute_convert_gain): Provide
29323         more accurate gains for conversion of scalar comparisons to
29324         PTEST.
29326 2023-06-28  Richard Biener  <rguenther@suse.de>
29328         PR tree-optimization/110443
29329         * tree-vect-slp.cc (vect_build_slp_tree_1): Reject non-grouped
29330         gather loads.
29332 2023-06-28  Haochen Gui  <guihaoc@gcc.gnu.org>
29334         * config/rs6000/rs6000.md (peephole2 for compare_and_move): New.
29335         (peephole2 for move_and_compare): New.
29336         (mode_iterator WORD): New.  Set the mode to SI/DImode by
29337         TARGET_POWERPC64.
29338         (*mov<mode>_internal2): Change the mode iterator from P to WORD.
29339         (split pattern for compare_and_move): Likewise.
29341 2023-06-28  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
29343         * config/riscv/autovec-opt.md (*double_widen_fma<mode>): New pattern.
29344         (*single_widen_fma<mode>): Ditto.
29346 2023-06-28  Haochen Gui  <guihaoc@gcc.gnu.org>
29348         PR target/104124
29349         * config/rs6000/altivec.md (*altivec_vupkhs<VU_char>_direct): Rename
29350         to...
29351         (altivec_vupkhs<VU_char>_direct): ...this.
29352         * config/rs6000/predicates.md (vspltisw_vupkhsw_constant_split): New
29353         predicate to test if a constant can be loaded with vspltisw and
29354         vupkhsw.
29355         (easy_vector_constant): Call vspltisw_vupkhsw_constant_p to Check if
29356         a vector constant can be synthesized with a vspltisw and a vupkhsw.
29357         * config/rs6000/rs6000-protos.h (vspltisw_vupkhsw_constant_p):
29358         Declare.
29359         * config/rs6000/rs6000.cc (vspltisw_vupkhsw_constant_p): New
29360         function to return true if OP mode is V2DI and can be synthesized
29361         with vupkhsw and vspltisw.
29362         * config/rs6000/vsx.md (*vspltisw_v2di_split): New insn to load up
29363         constants with vspltisw and vupkhsw.
29365 2023-06-28  Jan Hubicka  <jh@suse.cz>
29367         PR tree-optimization/110377
29368         * ipa-prop.cc (ipa_compute_jump_functions_for_edge): Pass statement to
29369         the ranger query.
29370         (ipa_analyze_node): Enable ranger.
29372 2023-06-28  Richard Biener  <rguenther@suse.de>
29374         * tree.h (TYPE_PRECISION): Check for non-VECTOR_TYPE.
29375         (TYPE_PRECISION_RAW): Provide raw access to the precision
29376         field.
29377         * tree.cc (verify_type_variant): Compare TYPE_PRECISION_RAW.
29378         (gimple_canonical_types_compatible_p): Likewise.
29379         * tree-streamer-out.cc (pack_ts_type_common_value_fields):
29380         Stream TYPE_PRECISION_RAW.
29381         * tree-streamer-in.cc (unpack_ts_type_common_value_fields):
29382         Likewise.
29383         * lto-streamer-out.cc (hash_tree): Hash TYPE_PRECISION_RAW.
29385 2023-06-28  Alexandre Oliva  <oliva@adacore.com>
29387         * doc/extend.texi (zero-call-used-regs): Document leafy and
29388         variants thereof.
29389         * flag-types.h (zero_regs_flags): Add LEAFY_MODE, as well as
29390         LEAFY and variants.
29391         * function.cc (gen_call_ued_regs_seq): Set only_used for leaf
29392         functions in leafy mode.
29393         * opts.cc (zero_call_used_regs_opts): Add leafy and variants.
29395 2023-06-28  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
29397         * config/riscv/riscv-vector-builtins-bases.cc: Adapt expand.
29398         * config/riscv/vector.md (@pred_single_widen_<plus_minus:optab><mode>):
29399         Remove.
29400         (@pred_single_widen_add<mode>): New pattern.
29401         (@pred_single_widen_sub<mode>): New pattern.
29403 2023-06-28  liuhongt  <hongtao.liu@intel.com>
29405         * config/i386/i386.cc (ix86_invalid_conversion): New function.
29406         (TARGET_INVALID_CONVERSION): Define as
29407         ix86_invalid_conversion.
29409 2023-06-27  Robin Dapp  <rdapp@ventanamicro.com>
29411         * config/riscv/autovec.md (<optab><vnconvert><mode>2): New
29412         expander.
29413         (<float_cvt><vnconvert><mode>2): Ditto.
29414         (<optab><mode><vnconvert>2): Ditto.
29415         (<float_cvt><mode><vnconvert>2): Ditto.
29416         * config/riscv/vector-iterators.md: Add vnconvert.
29418 2023-06-27  Robin Dapp  <rdapp@ventanamicro.com>
29420         * config/riscv/autovec.md (extend<v_double_trunc><mode>2): New
29421         expander.
29422         (extend<v_quad_trunc><mode>2): Ditto.
29423         (trunc<mode><v_double_trunc>2): Ditto.
29424         (trunc<mode><v_quad_trunc>2): Ditto.
29425         * config/riscv/vector-iterators.md: Add VQEXTF and HF to
29426         V_QUAD_TRUNC and v_quad_trunc.
29428 2023-06-27  Robin Dapp  <rdapp@ventanamicro.com>
29430         * config/riscv/autovec.md (<float_cvt><vconvert><mode>2): New
29431         expander.
29433 2023-06-27  Robin Dapp  <rdapp@ventanamicro.com>
29435         * config/riscv/autovec.md (copysign<mode>3): Add expander.
29436         (xorsign<mode>3): Ditto.
29437         * config/riscv/riscv-vector-builtins-bases.cc (class vfsgnjn):
29438         New class.
29439         * config/riscv/vector-iterators.md (copysign): Remove ncopysign.
29440         (xorsign): Ditto.
29441         (n): Ditto.
29442         (x): Ditto.
29443         * config/riscv/vector.md (@pred_ncopysign<mode>): Split off.
29444         (@pred_ncopysign<mode>_scalar): Ditto.
29446 2023-06-27  Robin Dapp  <rdapp@ventanamicro.com>
29448         * config/riscv/autovec.md: VF_AUTO -> VF.
29449         * config/riscv/vector-iterators.md: Introduce VF_ZVFHMIN,
29450         VWEXTF_ZVFHMIN and use TARGET_ZVFH in VWCONVERTI, VHF and
29451         VHF_LMUL1.
29452         * config/riscv/vector.md: Use new iterators.
29454 2023-06-27  Robin Dapp  <rdapp@ventanamicro.com>
29456         * match.pd: Use element_mode and check if target supports
29457         operation with new type.
29459 2023-06-27  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
29461         * config/aarch64/aarch64-sve-builtins-base.cc
29462         (svdupq_impl::fold_nonconst_dupq): New method.
29463         (svdupq_impl::fold): Call fold_nonconst_dupq.
29465 2023-06-27  Andrew Pinski  <apinski@marvell.com>
29467         PR middle-end/110420
29468         PR middle-end/103979
29469         PR middle-end/98619
29470         * gimplify.cc (gimplify_asm_expr): Mark asm with labels as volatile.
29472 2023-06-27  Aldy Hernandez  <aldyh@redhat.com>
29474         * ipa-cp.cc (decide_whether_version_node): Adjust comment.
29475         * ipa-fnsummary.cc (evaluate_conditions_for_known_args): Adjust
29476         for Value_Range.
29477         (set_switch_stmt_execution_predicate): Same.
29478         * ipa-prop.cc (ipa_compute_jump_functions_for_edge): Same.
29480 2023-06-27  Aldy Hernandez  <aldyh@redhat.com>
29482         * ipa-prop.cc (struct ipa_vr_ggc_hash_traits): Adjust for use with
29483         ipa_vr instead of value_range.
29484         (gt_pch_nx): Same.
29485         (gt_ggc_mx): Same.
29486         (ipa_get_value_range): Same.
29487         * value-range.cc (gt_pch_nx): Move to ipa-prop.cc and adjust for
29488         ipa_vr.
29489         (gt_ggc_mx): Same.
29491 2023-06-27  Aldy Hernandez  <aldyh@redhat.com>
29493         * ipa-cp.cc (ipa_vr_operation_and_type_effects): New.
29494         * ipa-prop.cc (ipa_get_value_range): Adjust for ipa_vr.
29495         (ipa_set_jfunc_vr): Take a range.
29496         (ipa_compute_jump_functions_for_edge): Pass range to
29497         ipa_set_jfunc_vr.
29498         (ipa_write_jump_function): Call streamer write helper.
29499         (ipa_read_jump_function): Call streamer read helper.
29500         * ipa-prop.h (class ipa_vr): Change m_vr to an ipa_vr.
29502 2023-06-27  Richard Sandiford  <richard.sandiford@arm.com>
29504         * gengtype-parse.cc (consume_until_comma_or_eos): Parse "= { ... }"
29505         as a probable initializer rather than a probable complete statement.
29507 2023-06-27  Richard Biener  <rguenther@suse.de>
29509         PR tree-optimization/96208
29510         * tree-vect-slp.cc (vect_build_slp_tree_1): Allow
29511         a non-grouped load if it is the same for all lanes.
29512         (vect_build_slp_tree_2): Handle not grouped loads.
29513         (vect_optimize_slp_pass::remove_redundant_permutations):
29514         Likewise.
29515         (vect_transform_slp_perm_load_1): Likewise.
29516         * tree-vect-stmts.cc (vect_model_load_cost): Likewise.
29517         (get_group_load_store_type): Likewise.  Handle
29518         invariant accesses.
29519         (vectorizable_load): Likewise.
29521 2023-06-27  liuhongt  <hongtao.liu@intel.com>
29523         PR rtl-optimization/110237
29524         * config/i386/sse.md (<avx512>_store<mode>_mask): Refine with
29525         UNSPEC_MASKMOV.
29526         (maskstore<mode><avx512fmaskmodelower): Ditto.
29527         (*<avx512>_store<mode>_mask): New define_insn, it's renamed
29528         from original <avx512>_store<mode>_mask.
29530 2023-06-27  liuhongt  <hongtao.liu@intel.com>
29532         * config/i386/i386-features.cc (pass_insert_vzeroupper:gate):
29533         Move flag_expensive_optimizations && !optimize_size to ..
29534         * config/i386/i386-options.cc (ix86_option_override_internal):
29535         .. this, it makes -mvzeroupper independent of optimization
29536         level, but still keeps the behavior of architecture
29537         tuning(emit_vzeroupper) unchanged.
29539 2023-06-27  liuhongt  <hongtao.liu@intel.com>
29541         PR target/82735
29542         * config/i386/i386.cc (ix86_avx_u127_mode_needed): Don't emit
29543         vzeroupper for vzeroupper call_insn.
29545 2023-06-27  Andrew Pinski  <apinski@marvell.com>
29547         * doc/extend.texi (__builtin_alloca_with_align_and_max): Fix
29548         defbuiltin usage.
29550 2023-06-27  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
29552         * config/riscv/riscv-v.cc (expand_const_vector): Fix stepped vector
29553         with base != 0.
29555 2023-06-26  Andrew Pinski  <apinski@marvell.com>
29557         * doc/extend.texi (access attribute): Add
29558         cindex for it.
29559         (interrupt/interrupt_handler attribute):
29560         Likewise.
29562 2023-06-26  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
29564         * config/aarch64/aarch64-simd.md (aarch64_sqrshrun_n<mode>_insn):
29565         Use <DWI> instead of <V2XWIDE>.
29566         (aarch64_sqrshrun_n<mode>): Likewise.
29568 2023-06-26  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
29570         * config/aarch64/aarch64-protos.h (aarch64_const_vec_rsra_rnd_imm_p):
29571         Rename to...
29572         (aarch64_rnd_imm_p): ... This.
29573         * config/aarch64/predicates.md (aarch64_simd_rsra_rnd_imm_vec):
29574         Rename to...
29575         (aarch64_int_rnd_operand): ... This.
29576         (aarch64_simd_rshrn_imm_vec): Delete.
29577         * config/aarch64/aarch64-simd.md (aarch64_<sra_op>rsra_n<mode>_insn):
29578         Adjust for the above.
29579         (aarch64_<sra_op>rshr_n<mode><vczle><vczbe>_insn): Likewise.
29580         (*aarch64_<shrn_op>rshrn_n<mode>_insn): Likewise.
29581         (*aarch64_sqrshrun_n<mode>_insn<vczle><vczbe>): Likewise.
29582         (aarch64_sqrshrun_n<mode>_insn): Likewise.
29583         (aarch64_<shrn_op>rshrn2_n<mode>_insn_le): Likewise.
29584         (aarch64_<shrn_op>rshrn2_n<mode>_insn_be): Likewise.
29585         (aarch64_sqrshrun2_n<mode>_insn_le): Likewise.
29586         (aarch64_sqrshrun2_n<mode>_insn_be): Likewise.
29587         * config/aarch64/aarch64.cc (aarch64_const_vec_rsra_rnd_imm_p):
29588         Rename to...
29589         (aarch64_rnd_imm_p): ... This.
29591 2023-06-26  Andreas Krebbel  <krebbel@linux.ibm.com>
29593         * config/s390/s390.cc (s390_encode_section_info): Set
29594         SYMBOL_FLAG_SET_NOTALIGN2 only if the symbol has explicitely been
29595         misaligned.
29597 2023-06-26  Jan Hubicka  <jh@suse.cz>
29599         PR tree-optimization/109849
29600         * tree-ssa-dce.cc (make_forwarders_with_degenerate_phis): Fix profile
29601         count of newly constructed forwarder block.
29603 2023-06-26  Andrew Carlotti  <andrew.carlotti@arm.com>
29605         * doc/optinfo.texi: Fix "steam" -> "stream".
29607 2023-06-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
29609         * tree-ssa-dse.cc (initialize_ao_ref_for_dse): Add LEN_MASK_STORE and
29610         fix LEN_STORE.
29611         (dse_optimize_stmt): Add LEN_MASK_STORE.
29613 2023-06-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
29615         * gimple-fold.cc (gimple_fold_partial_load_store_mem_ref): Fix gimple
29616         fold of LOAD/STORE with length.
29618 2023-06-26  Andrew MacLeod  <amacleod@redhat.com>
29620         * gimple-range-gori.cc (compute_operand1_and_operand2_range):
29621         Check for interdependence between operands 1 and 2.
29623 2023-06-26  Richard Sandiford  <richard.sandiford@arm.com>
29625         * tree-vect-stmts.cc (vectorizable_conversion): Take multi_step_cvt
29626         into account when costing non-widening/truncating conversions.
29628 2023-06-26  Richard Biener  <rguenther@suse.de>
29630         PR tree-optimization/110381
29631         * tree-vect-slp.cc (vect_optimize_slp_pass::start_choosing_layouts):
29632         Materialize permutes before fold-left reductions.
29634 2023-06-26  Pan Li  <pan2.li@intel.com>
29636         * config/riscv/riscv-vector-builtins-bases.h: Remove duplicated decl.
29638 2023-06-26  Richard Biener  <rguenther@suse.de>
29640         * varasm.cc (initializer_constant_valid_p_1): Also
29641         constrain the type of value to be scalar integral
29642         before dispatching to narrowing_initializer_constant_valid_p.
29644 2023-06-26  Richard Biener  <rguenther@suse.de>
29646         * tree-ssa-scopedtables.cc (hashable_expr_equal_p):
29647         Use element_precision.
29649 2023-06-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
29651         * config/riscv/autovec.md (vcond<V:mode><VI:mode>): Remove redundant
29652         vcond patterns.
29653         (vcondu<V:mode><VI:mode>): Ditto.
29654         * config/riscv/riscv-protos.h (expand_vcond): Ditto.
29655         * config/riscv/riscv-v.cc (expand_vcond): Ditto.
29657 2023-06-26  Richard Biener  <rguenther@suse.de>
29659         PR tree-optimization/110392
29660         * gimple-predicate-analysis.cc (uninit_analysis::is_use_guarded):
29661         Do early exits on true/false predicate only after normalization.
29663 2023-06-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
29665         * tree-ssa-sccvn.cc (vn_reference_lookup_3): Change name "len" into
29666         "length".
29668 2023-06-26  Roger Sayle  <roger@nextmovesoftware.com>
29670         * config/i386/i386.md (peephole2): Simplify zeroing a register
29671         followed by an IOR, XOR or PLUS operation on it, into a move.
29672         (*ashl<dwi>3_doubleword_highpart): New define_insn_and_split to
29673         eliminate (and hide from reload) unnecessary word to doubleword
29674         extensions that are followed by left shifts by sufficiently large,
29675         but valid, bit counts.
29677 2023-06-26  liuhongt  <hongtao.liu@intel.com>
29679         PR tree-optimization/110371
29680         PR tree-optimization/110018
29681         * tree-vect-stmts.cc (vectorizable_conversion): Use cvt_op to
29682         save intermediate type operand instead of "subtle" vec_dest
29683         for case NONE.
29685 2023-06-26  liuhongt  <hongtao.liu@intel.com>
29687         PR tree-optimization/110371
29688         PR tree-optimization/110018
29689         * tree-vect-stmts.cc (vectorizable_conversion): Don't use
29690         intermiediate type for FIX_TRUNC_EXPR when ftrapping-math.
29692 2023-06-26  Hongyu Wang  <hongyu.wang@intel.com>
29694         * config/i386/i386-options.cc (ix86_valid_target_attribute_tree):
29695         Override tune_string with arch_string if tune_string is not
29696         explicitly specified.
29698 2023-06-25  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
29700         * config/riscv/riscv-vsetvl.cc (vector_insn_info::parse_insn): Ehance
29701         AVL propagation.
29702         * config/riscv/riscv-vsetvl.h: New function.
29704 2023-06-25  Li Xu  <xuli1@eswincomputing.com>
29706         * config/riscv/riscv-vector-builtins-bases.cc: change emit_insn to
29707         emit_move_insn
29709 2023-06-25  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
29711         * config/riscv/autovec.md (len_load_<mode>): Remove.
29712         (len_maskload<mode><vm>): Remove.
29713         (len_store_<mode>): New pattern.
29714         (len_maskstore<mode><vm>): New pattern.
29715         * config/riscv/predicates.md (autovec_length_operand): New predicate.
29716         * config/riscv/riscv-protos.h (enum insn_type): New enum.
29717         (expand_load_store): New function.
29718         * config/riscv/riscv-v.cc (emit_vlmax_masked_insn): Ditto.
29719         (emit_nonvlmax_masked_insn): Ditto.
29720         (expand_load_store): Ditto.
29721         * config/riscv/riscv-vector-builtins.cc
29722         (function_expander::use_contiguous_store_insn): Add avl_type operand
29723         into pred_store.
29724         * config/riscv/vector.md: Ditto.
29726 2023-06-25  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
29728         * internal-fn.cc (expand_partial_store_optab_fn): Fix bug of BIAS
29729         argument index.
29731 2023-06-25  Pan Li  <pan2.li@intel.com>
29733         * config/riscv/vector.md: Revert.
29735 2023-06-25  Pan Li  <pan2.li@intel.com>
29737         * config/riscv/genrvv-type-indexer.cc (valid_type): Revert changes.
29738         * config/riscv/riscv-modes.def (RVV_TUPLE_MODES): Ditto.
29739         (ADJUST_ALIGNMENT): Ditto.
29740         (RVV_TUPLE_PARTIAL_MODES): Ditto.
29741         (ADJUST_NUNITS): Ditto.
29742         * config/riscv/riscv-vector-builtins-types.def (vfloat16mf4x2_t): Ditto.
29743         (vfloat16mf4x3_t): Ditto.
29744         (vfloat16mf4x4_t): Ditto.
29745         (vfloat16mf4x5_t): Ditto.
29746         (vfloat16mf4x6_t): Ditto.
29747         (vfloat16mf4x7_t): Ditto.
29748         (vfloat16mf4x8_t): Ditto.
29749         (vfloat16mf2x2_t): Ditto.
29750         (vfloat16mf2x3_t): Ditto.
29751         (vfloat16mf2x4_t): Ditto.
29752         (vfloat16mf2x5_t): Ditto.
29753         (vfloat16mf2x6_t): Ditto.
29754         (vfloat16mf2x7_t): Ditto.
29755         (vfloat16mf2x8_t): Ditto.
29756         (vfloat16m1x2_t): Ditto.
29757         (vfloat16m1x3_t): Ditto.
29758         (vfloat16m1x4_t): Ditto.
29759         (vfloat16m1x5_t): Ditto.
29760         (vfloat16m1x6_t): Ditto.
29761         (vfloat16m1x7_t): Ditto.
29762         (vfloat16m1x8_t): Ditto.
29763         (vfloat16m2x2_t): Ditto.
29764         (vfloat16m2x3_t): Diito.
29765         (vfloat16m2x4_t): Diito.
29766         (vfloat16m4x2_t): Diito.
29767         * config/riscv/riscv-vector-builtins.def (vfloat16mf4x2_t): Ditto.
29768         (vfloat16mf4x3_t): Ditto.
29769         (vfloat16mf4x4_t): Ditto.
29770         (vfloat16mf4x5_t): Ditto.
29771         (vfloat16mf4x6_t): Ditto.
29772         (vfloat16mf4x7_t): Ditto.
29773         (vfloat16mf4x8_t): Ditto.
29774         (vfloat16mf2x2_t): Ditto.
29775         (vfloat16mf2x3_t): Ditto.
29776         (vfloat16mf2x4_t): Ditto.
29777         (vfloat16mf2x5_t): Ditto.
29778         (vfloat16mf2x6_t): Ditto.
29779         (vfloat16mf2x7_t): Ditto.
29780         (vfloat16mf2x8_t): Ditto.
29781         (vfloat16m1x2_t): Ditto.
29782         (vfloat16m1x3_t): Ditto.
29783         (vfloat16m1x4_t): Ditto.
29784         (vfloat16m1x5_t): Ditto.
29785         (vfloat16m1x6_t): Ditto.
29786         (vfloat16m1x7_t): Ditto.
29787         (vfloat16m1x8_t): Ditto.
29788         (vfloat16m2x2_t): Ditto.
29789         (vfloat16m2x3_t): Ditto.
29790         (vfloat16m2x4_t): Ditto.
29791         (vfloat16m4x2_t): Ditto.
29792         * config/riscv/riscv-vector-switch.def (TUPLE_ENTRY): Ditto.
29793         * config/riscv/riscv.md: Ditto.
29794         * config/riscv/vector-iterators.md: Ditto.
29796 2023-06-25  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
29798         * gimple-fold.cc (arith_overflowed_p): Apply LEN_MASK_{LOAD,STORE}.
29799         (gimple_fold_partial_load_store_mem_ref): Ditto.
29800         (gimple_fold_partial_store): Ditto.
29801         (gimple_fold_call): Ditto.
29803 2023-06-25  liuhongt  <hongtao.liu@intel.com>
29805         PR target/110309
29806         * config/i386/sse.md (maskload<mode><avx512fmaskmodelower>):
29807         Refine pattern with UNSPEC_MASKLOAD.
29808         (maskload<mode><avx512fmaskmodelower>): Ditto.
29809         (*<avx512>_load<mode>_mask): Extend mode iterator to
29810         VI12HFBF_AVX512VL.
29811         (*<avx512>_load<mode>): Ditto.
29813 2023-06-25  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
29815         * tree-ssa-alias.cc (call_may_clobber_ref_p_1): Add LEN_MASK_STORE.
29817 2023-06-25  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
29819         * tree-ssa-alias.cc (ref_maybe_used_by_call_p_1): Apply
29820         LEN_MASK_{LOAD,STORE}
29822 2023-06-25  yulong  <shiyulong@iscas.ac.cn>
29824         * config/riscv/vector.md: Add float16 attr at sew、vlmul and ratio.
29826 2023-06-24  Roger Sayle  <roger@nextmovesoftware.com>
29828         * config/i386/i386.md (*<code>qi_ext<mode>_3): New define_insn.
29830 2023-06-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
29832         * config/riscv/autovec.md (*fma<mode>): set clobber to Pmode in expand stage.
29833         (*fma<VI:mode><P:mode>): Ditto.
29834         (*fnma<mode>): Ditto.
29835         (*fnma<VI:mode><P:mode>): Ditto.
29837 2023-06-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
29839         * config/riscv/autovec.md (fma<mode>4): New pattern.
29840         (*fma<mode>): Ditto.
29841         (fnma<mode>4): Ditto.
29842         (*fnma<mode>): Ditto.
29843         (fms<mode>4): Ditto.
29844         (*fms<mode>): Ditto.
29845         (fnms<mode>4): Ditto.
29846         (*fnms<mode>): Ditto.
29847         * config/riscv/riscv-protos.h (emit_vlmax_fp_ternary_insn):
29848         New function.
29849         * config/riscv/riscv-v.cc (emit_vlmax_fp_ternary_insn): Ditto.
29850         * config/riscv/vector.md: Fix attribute bug.
29852 2023-06-24  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
29854         * tree-ssa-loop-ivopts.cc (get_mem_type_for_internal_fn):
29855         Apply LEN_MASK_{LOAD,STORE}.
29857 2023-06-24  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
29859         * tree-ssa-loop-ivopts.cc (get_alias_ptr_type_for_ptr_address):
29860         Add LEN_MASK_{LOAD,STORE}.
29862 2023-06-24  David Malcolm  <dmalcolm@redhat.com>
29864         * diagnostic-format-sarif.cc: Add #define INCLUDE_VECTOR.
29865         * diagnostic.cc: Likewise.
29866         * text-art/box-drawing.cc: Likewise.
29867         * text-art/canvas.cc: Likewise.
29868         * text-art/ruler.cc: Likewise.
29869         * text-art/selftests.cc: Likewise.
29870         * text-art/selftests.h (text_art::canvas): New forward decl.
29871         * text-art/style.cc: Add #define INCLUDE_VECTOR.
29872         * text-art/styled-string.cc: Likewise.
29873         * text-art/table.cc: Likewise.
29874         * text-art/table.h: Remove #include <vector>.
29875         * text-art/theme.cc: Add #define INCLUDE_VECTOR.
29876         * text-art/types.h: Check that INCLUDE_VECTOR is defined.
29877         Remove #include of <vector> and <string>.
29878         * text-art/widget.cc: Add #define INCLUDE_VECTOR.
29879         * text-art/widget.h: Remove #include <vector>.
29881 2023-06-24  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
29883         * internal-fn.cc (expand_partial_store_optab_fn): Adapt for LEN_MASK_STORE.
29884         (internal_load_fn_p): Add LEN_MASK_LOAD.
29885         (internal_store_fn_p): Add LEN_MASK_STORE.
29886         (internal_fn_mask_index): Add LEN_MASK_{LOAD,STORE}.
29887         (internal_fn_stored_value_index): Add LEN_MASK_STORE.
29888         (internal_len_load_store_bias):  Add LEN_MASK_{LOAD,STORE}.
29889         * optabs-tree.cc (can_vec_mask_load_store_p): Adapt for LEN_MASK_{LOAD,STORE}.
29890         (get_len_load_store_mode): Ditto.
29891         * optabs-tree.h (can_vec_mask_load_store_p): Ditto.
29892         (get_len_load_store_mode): Ditto.
29893         * tree-vect-stmts.cc (check_load_store_for_partial_vectors): Ditto.
29894         (get_all_ones_mask): New function.
29895         (vectorizable_store): Apply LEN_MASK_{LOAD,STORE} into vectorizer.
29896         (vectorizable_load): Ditto.
29898 2023-06-23  Marek Polacek  <polacek@redhat.com>
29900         * doc/cpp.texi (__cplusplus): Document value for -std=c++26 and
29901         -std=gnu++26.  Document that for C++23, its value is 202302L.
29902         * doc/invoke.texi: Document -std=c++26 and -std=gnu++26.
29903         * dwarf2out.cc (highest_c_language): Handle GNU C++26.
29904         (gen_compile_unit_die): Likewise.
29906 2023-06-23  Jan Hubicka  <jh@suse.cz>
29908         * tree-ssa-phiprop.cc (propagate_with_phi): Compute post dominators on
29909         demand.
29910         (pass_phiprop::execute): Do not compute it here; return
29911         update_ssa_only_virtuals if something changed.
29912         (pass_data_phiprop): Remove TODO_update_ssa from todos.
29914 2023-06-23   Michael Meissner  <meissner@linux.ibm.com>
29915             Aaron Sawdey   <acsawdey@linux.ibm.com>
29917         PR target/105325
29918         * config/rs6000/genfusion.pl (gen_ld_cmpi_p10_one): Fix problems that
29919         allowed prefixed lwa to be generated.
29920         * config/rs6000/fusion.md: Regenerate.
29921         * config/rs6000/predicates.md (ds_form_mem_operand): Delete.
29922         * config/rs6000/rs6000.md (prefixed attribute): Add support for load
29923         plus compare immediate fused insns.
29924         (maybe_prefixed): Likewise.
29926 2023-06-23  Roger Sayle  <roger@nextmovesoftware.com>
29928         * simplify-rtx.cc (simplify_subreg):  Optimize lowpart SUBREGs
29929         of ASHIFT to const0_rtx with sufficiently large shift count.
29930         Optimize highpart SUBREGs of ASHIFT as the shift operand when
29931         the shift count is the correct offset.  Optimize SUBREGs of
29932         multi-word logic operations if the SUBREGs of both operands
29933         can be simplified.
29935 2023-06-23  Richard Biener  <rguenther@suse.de>
29937         * varasm.cc (initializer_constant_valid_p_1): Only
29938         allow conversions between scalar floating point types.
29940 2023-06-23  Richard Biener  <rguenther@suse.de>
29942         * tree-vect-stmts.cc (vectorizable_assignment):
29943         Properly handle non-integral operands when analyzing
29944         conversions.
29946 2023-06-23  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
29948         PR tree-optimization/110280
29949         * match.pd (vec_perm_expr(v, v, mask) -> v): Explicitly build vector
29950         using build_vector_from_val with the element of input operand, and
29951         mask's type if operand and mask's types don't match.
29953 2023-06-23  Richard Biener  <rguenther@suse.de>
29955         * fold-const.cc (tree_simple_nonnegative_warnv_p): Guard
29956         the truth_value_p case with !VECTOR_TYPE_P.
29958 2023-06-23  Richard Biener  <rguenther@suse.de>
29960         * tree-vect-patterns.cc (vect_look_through_possible_promotion):
29961         Exit early when the type isn't scalar integral.
29963 2023-06-23  Richard Biener  <rguenther@suse.de>
29965         * match.pd ((outertype)((innertype0)a+(innertype1)b)
29966         -> ((newtype)a+(newtype)b)): Use element_precision
29967         where appropriate.
29969 2023-06-23  Richard Biener  <rguenther@suse.de>
29971         * fold-const.cc (fold_binary_loc): Use element_precision
29972         when trying (double)float1 CMP (double)float2 to
29973         float1 CMP float2 simplification.
29974         * match.pd: Likewise.
29976 2023-06-23  Richard Biener  <rguenther@suse.de>
29978         * tree-vect-stmts.cc (vectorizable_load): Avoid useless
29979         copies of VMAT_INVARIANT vectorized stmts, fix SLP support.
29981 2023-06-23  Richard Biener  <rguenther@suse.de>
29983         * tree-vect-stmts.cc (vector_vector_composition_type):
29984         Handle composition of a vector from a number of elements that
29985         happens to match its number of lanes.
29987 2023-06-22  Marek Polacek  <polacek@redhat.com>
29989         * configure.ac (--enable-host-bind-now): New check.  Add
29990         -Wl,-z,now to LD_PICFLAG if --enable-host-bind-now.
29991         * configure: Regenerate.
29992         * doc/install.texi: Document --enable-host-bind-now.
29994 2023-06-22  Di Zhao OS  <dizhao@os.amperecomputing.com>
29996         * config/aarch64/aarch64.cc: Change fma_reassoc_width for ampere1.
29998 2023-06-22  Richard Biener  <rguenther@suse.de>
30000         PR tree-optimization/110332
30001         * tree-ssa-phiprop.cc (propagate_with_phi): Always
30002         check aliasing with edge inserted loads.
30004 2023-06-22  Roger Sayle  <roger@nextmovesoftware.com>
30005             Uros Bizjak  <ubizjak@gmail.com>
30007         * config/i386/i386-expand.cc (ix86_expand_sse_ptest): Recognize
30008         expansion of ptestc with equal operands as producing const1_rtx.
30009         * config/i386/i386.cc (ix86_rtx_costs): Provide accurate cost
30010         estimates of UNSPEC_PTEST, where the ptest performs the PAND
30011         or PAND of its operands.
30012         * config/i386/sse.md (define_split): Transform CCCmode UNSPEC_PTEST
30013         of reg_equal_p operands into an x86_stc instruction.
30014         (define_split): Split pandn/ptestz/set{n?}e into ptestc/set{n?}c.
30015         (define_split): Similar to above for strict_low_part destinations.
30016         (define_split): Split pandn/ptestz/j{n?}e into ptestc/j{n?}c.
30018 2023-06-22  David Malcolm  <dmalcolm@redhat.com>
30020         PR analyzer/106626
30021         * Makefile.in (ANALYZER_OBJS): Add analyzer/access-diagram.o.
30022         * doc/invoke.texi (Wanalyzer-out-of-bounds): Add description of
30023         text art.
30024         (fanalyzer-debug-text-art): New.
30026 2023-06-22  David Malcolm  <dmalcolm@redhat.com>
30028         * Makefile.in (OBJS-libcommon): Add text-art/box-drawing.o,
30029         text-art/canvas.o, text-art/ruler.o, text-art/selftests.o,
30030         text-art/style.o, text-art/styled-string.o, text-art/table.o,
30031         text-art/theme.o, and text-art/widget.o.
30032         * color-macros.h (COLOR_FG_BRIGHT_BLACK): New.
30033         (COLOR_FG_BRIGHT_RED): New.
30034         (COLOR_FG_BRIGHT_GREEN): New.
30035         (COLOR_FG_BRIGHT_YELLOW): New.
30036         (COLOR_FG_BRIGHT_BLUE): New.
30037         (COLOR_FG_BRIGHT_MAGENTA): New.
30038         (COLOR_FG_BRIGHT_CYAN): New.
30039         (COLOR_FG_BRIGHT_WHITE): New.
30040         (COLOR_BG_BRIGHT_BLACK): New.
30041         (COLOR_BG_BRIGHT_RED): New.
30042         (COLOR_BG_BRIGHT_GREEN): New.
30043         (COLOR_BG_BRIGHT_YELLOW): New.
30044         (COLOR_BG_BRIGHT_BLUE): New.
30045         (COLOR_BG_BRIGHT_MAGENTA): New.
30046         (COLOR_BG_BRIGHT_CYAN): New.
30047         (COLOR_BG_BRIGHT_WHITE): New.
30048         * common.opt (fdiagnostics-text-art-charset=): New option.
30049         (diagnostic-text-art.h): New SourceInclude.
30050         (diagnostic_text_art_charset) New Enum and EnumValues.
30051         * configure: Regenerate.
30052         * configure.ac (gccdepdir): Add text-art to loop.
30053         * diagnostic-diagram.h: New file.
30054         * diagnostic-format-json.cc (json_emit_diagram): New.
30055         (diagnostic_output_format_init_json): Wire it up to
30056         context->m_diagrams.m_emission_cb.
30057         * diagnostic-format-sarif.cc: Include "diagnostic-diagram.h" and
30058         "text-art/canvas.h".
30059         (sarif_result::on_nested_diagnostic): Move code to...
30060         (sarif_result::add_related_location): ...this new function.
30061         (sarif_result::on_diagram): New.
30062         (sarif_builder::emit_diagram): New.
30063         (sarif_builder::make_message_object_for_diagram): New.
30064         (sarif_emit_diagram): New.
30065         (diagnostic_output_format_init_sarif): Set
30066         context->m_diagrams.m_emission_cb to sarif_emit_diagram.
30067         * diagnostic-text-art.h: New file.
30068         * diagnostic.cc: Include "diagnostic-text-art.h",
30069         "diagnostic-diagram.h", and "text-art/theme.h".
30070         (diagnostic_initialize): Initialize context->m_diagrams and
30071         call diagnostics_text_art_charset_init.
30072         (diagnostic_finish): Clean up context->m_diagrams.m_theme.
30073         (diagnostic_emit_diagram): New.
30074         (diagnostics_text_art_charset_init): New.
30075         * diagnostic.h (text_art::theme): New forward decl.
30076         (class diagnostic_diagram): Likewise.
30077         (diagnostic_context::m_diagrams): New field.
30078         (diagnostic_emit_diagram): New decl.
30079         * doc/invoke.texi (Diagnostic Message Formatting Options): Add
30080         -fdiagnostics-text-art-charset=.
30081         (-fdiagnostics-plain-output): Add
30082         -fdiagnostics-text-art-charset=none.
30083         * gcc.cc: Include "diagnostic-text-art.h".
30084         (driver_handle_option): Handle OPT_fdiagnostics_text_art_charset_.
30085         * opts-common.cc (decode_cmdline_options_to_array): Add
30086         "-fdiagnostics-text-art-charset=none" to expanded_args for
30087         -fdiagnostics-plain-output.
30088         * opts.cc: Include "diagnostic-text-art.h".
30089         (common_handle_option): Handle OPT_fdiagnostics_text_art_charset_.
30090         * pretty-print.cc (pp_unicode_character): New.
30091         * pretty-print.h (pp_unicode_character): New decl.
30092         * selftest-run-tests.cc: Include "text-art/selftests.h".
30093         (selftest::run_tests): Call text_art_tests.
30094         * text-art/box-drawing-chars.inc: New file, generated by
30095         contrib/unicode/gen-box-drawing-chars.py.
30096         * text-art/box-drawing.cc: New file.
30097         * text-art/box-drawing.h: New file.
30098         * text-art/canvas.cc: New file.
30099         * text-art/canvas.h: New file.
30100         * text-art/ruler.cc: New file.
30101         * text-art/ruler.h: New file.
30102         * text-art/selftests.cc: New file.
30103         * text-art/selftests.h: New file.
30104         * text-art/style.cc: New file.
30105         * text-art/styled-string.cc: New file.
30106         * text-art/table.cc: New file.
30107         * text-art/table.h: New file.
30108         * text-art/theme.cc: New file.
30109         * text-art/theme.h: New file.
30110         * text-art/types.h: New file.
30111         * text-art/widget.cc: New file.
30112         * text-art/widget.h: New file.
30114 2023-06-21  Uros Bizjak  <ubizjak@gmail.com>
30116         * function.h (emit_initial_value_sets):
30117         Change return type from int to void.
30118         (aggregate_value_p): Change return type from int to bool.
30119         (prologue_contains): Ditto.
30120         (epilogue_contains): Ditto.
30121         (prologue_epilogue_contains): Ditto.
30122         * function.cc (temp_slot): Make "in_use" variable bool.
30123         (make_slot_available): Update for changed "in_use" variable.
30124         (assign_stack_temp_for_type): Ditto.
30125         (emit_initial_value_sets): Change return type from int to void
30126         and update function body accordingly.
30127         (instantiate_virtual_regs): Ditto.
30128         (rest_of_handle_thread_prologue_and_epilogue): Ditto.
30129         (safe_insn_predicate): Change return type from int to bool.
30130         (aggregate_value_p): Change return type from int to bool
30131         and update function body accordingly.
30132         (prologue_contains): Change return type from int to bool.
30133         (prologue_epilogue_contains): Ditto.
30135 2023-06-21  Alexander Monakov  <amonakov@ispras.ru>
30137         * common.opt (fp_contract_mode) [on]: Remove fallback.
30138         * config/sh/sh.md (*fmasf4): Correct flag_fp_contract_mode test.
30139         * doc/invoke.texi (-ffp-contract): Update.
30140         * trans-mem.cc (diagnose_tm_1): Skip internal function calls.
30142 2023-06-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
30144         * config/aarch64/aarch64-sve.md (mask_gather_load<mode><v_int_container>):
30145         Add alternatives to prefer to avoid same input and output Z register.
30146         (mask_gather_load<mode><v_int_container>): Likewise.
30147         (*mask_gather_load<mode><v_int_container>_<su>xtw_unpacked): Likewise.
30148         (*mask_gather_load<mode><v_int_container>_sxtw): Likewise.
30149         (*mask_gather_load<mode><v_int_container>_uxtw): Likewise.
30150         (@aarch64_gather_load_<ANY_EXTEND:optab><SVE_4HSI:mode><SVE_4BHI:mode>):
30151         Likewise.
30152         (@aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode><SVE_2BHSI:mode>):
30153         Likewise.
30154         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30155         <SVE_2BHSI:mode>_<ANY_EXTEND2:su>xtw_unpacked): Likewise.
30156         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30157         <SVE_2BHSI:mode>_sxtw): Likewise.
30158         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30159         <SVE_2BHSI:mode>_uxtw): Likewise.
30160         (@aarch64_ldff1_gather<mode>): Likewise.
30161         (@aarch64_ldff1_gather<mode>): Likewise.
30162         (*aarch64_ldff1_gather<mode>_sxtw): Likewise.
30163         (*aarch64_ldff1_gather<mode>_uxtw): Likewise.
30164         (@aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx4_WIDE:mode>
30165         <VNx4_NARROW:mode>): Likewise.
30166         (@aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30167         <VNx2_NARROW:mode>): Likewise.
30168         (*aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30169         <VNx2_NARROW:mode>_sxtw): Likewise.
30170         (*aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30171         <VNx2_NARROW:mode>_uxtw): Likewise.
30172         * config/aarch64/aarch64-sve2.md (@aarch64_gather_ldnt<mode>): Likewise.
30173         (@aarch64_gather_ldnt_<ANY_EXTEND:optab><SVE_FULL_SDI:mode>
30174         <SVE_PARTIAL_I:mode>): Likewise.
30176 2023-06-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
30178         * config/aarch64/aarch64-sve.md (mask_gather_load<mode><v_int_container>):
30179         Convert to compact alternatives syntax.
30180         (mask_gather_load<mode><v_int_container>): Likewise.
30181         (*mask_gather_load<mode><v_int_container>_<su>xtw_unpacked): Likewise.
30182         (*mask_gather_load<mode><v_int_container>_sxtw): Likewise.
30183         (*mask_gather_load<mode><v_int_container>_uxtw): Likewise.
30184         (@aarch64_gather_load_<ANY_EXTEND:optab><SVE_4HSI:mode><SVE_4BHI:mode>):
30185         Likewise.
30186         (@aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode><SVE_2BHSI:mode>):
30187         Likewise.
30188         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30189         <SVE_2BHSI:mode>_<ANY_EXTEND2:su>xtw_unpacked): Likewise.
30190         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30191         <SVE_2BHSI:mode>_sxtw): Likewise.
30192         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30193         <SVE_2BHSI:mode>_uxtw): Likewise.
30194         (@aarch64_ldff1_gather<mode>): Likewise.
30195         (@aarch64_ldff1_gather<mode>): Likewise.
30196         (*aarch64_ldff1_gather<mode>_sxtw): Likewise.
30197         (*aarch64_ldff1_gather<mode>_uxtw): Likewise.
30198         (@aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx4_WIDE:mode>
30199         <VNx4_NARROW:mode>): Likewise.
30200         (@aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30201         <VNx2_NARROW:mode>): Likewise.
30202         (*aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30203         <VNx2_NARROW:mode>_sxtw): Likewise.
30204         (*aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30205         <VNx2_NARROW:mode>_uxtw): Likewise.
30206         * config/aarch64/aarch64-sve2.md (@aarch64_gather_ldnt<mode>): Likewise.
30207         (@aarch64_gather_ldnt_<ANY_EXTEND:optab><SVE_FULL_SDI:mode>
30208         <SVE_PARTIAL_I:mode>): Likewise.
30210 2023-06-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
30212         Revert:
30213         2023-06-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
30215         * config/aarch64/aarch64-sve.md (mask_gather_load<mode><v_int_container>):
30216         Convert to compact alternatives syntax.
30217         (mask_gather_load<mode><v_int_container>): Likewise.
30218         (*mask_gather_load<mode><v_int_container>_<su>xtw_unpacked): Likewise.
30219         (*mask_gather_load<mode><v_int_container>_sxtw): Likewise.
30220         (*mask_gather_load<mode><v_int_container>_uxtw): Likewise.
30221         (@aarch64_gather_load_<ANY_EXTEND:optab><SVE_4HSI:mode><SVE_4BHI:mode>):
30222         Likewise.
30223         (@aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode><SVE_2BHSI:mode>):
30224         Likewise.
30225         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30226         <SVE_2BHSI:mode>_<ANY_EXTEND2:su>xtw_unpacked): Likewise.
30227         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30228         <SVE_2BHSI:mode>_sxtw): Likewise.
30229         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30230         <SVE_2BHSI:mode>_uxtw): Likewise.
30231         (@aarch64_ldff1_gather<mode>): Likewise.
30232         (@aarch64_ldff1_gather<mode>): Likewise.
30233         (*aarch64_ldff1_gather<mode>_sxtw): Likewise.
30234         (*aarch64_ldff1_gather<mode>_uxtw): Likewise.
30235         (@aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx4_WIDE:mode>
30236         <VNx4_NARROW:mode>): Likewise.
30237         (@aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30238         <VNx2_NARROW:mode>): Likewise.
30239         (*aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30240         <VNx2_NARROW:mode>_sxtw): Likewise.
30241         (*aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30242         <VNx2_NARROW:mode>_uxtw): Likewise.
30243         * config/aarch64/aarch64-sve2.md (@aarch64_gather_ldnt<mode>): Likewise.
30244         (@aarch64_gather_ldnt_<ANY_EXTEND:optab><SVE_FULL_SDI:mode>
30245         <SVE_PARTIAL_I:mode>): Likewise.
30247 2023-06-21  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
30249         * optabs-query.cc (can_vec_mask_load_store_p): Move to optabs-tree.cc.
30250         (get_len_load_store_mode): Ditto.
30251         * optabs-query.h (can_vec_mask_load_store_p): Move to optabs-tree.h.
30252         (get_len_load_store_mode): Ditto.
30253         * optabs-tree.cc (can_vec_mask_load_store_p): New function.
30254         (get_len_load_store_mode): Ditto.
30255         * optabs-tree.h (can_vec_mask_load_store_p): Ditto.
30256         (get_len_load_store_mode): Ditto.
30257         * tree-if-conv.cc: include optabs-tree instead of optabs-query
30259 2023-06-21  Richard Biener  <rguenther@suse.de>
30261         * tree-ssa-loop-ivopts.cc (add_iv_candidate_for_use): Use
30262         split_constant_offset for the POINTER_PLUS_EXPR case.
30264 2023-06-21  Richard Biener  <rguenther@suse.de>
30266         * tree-ssa-loop-ivopts.cc (record_group_use): Use
30267         split_constant_offset.
30269 2023-06-21  Richard Biener  <rguenther@suse.de>
30271         * tree-loop-distribution.cc (classify_builtin_st): Use
30272         split_constant_offset.
30273         * tree-ssa-loop-ivopts.h (strip_offset): Remove.
30274         * tree-ssa-loop-ivopts.cc (strip_offset): Make static.
30276 2023-06-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
30278         * config/aarch64/aarch64-sve.md (mask_gather_load<mode><v_int_container>):
30279         Convert to compact alternatives syntax.
30280         (mask_gather_load<mode><v_int_container>): Likewise.
30281         (*mask_gather_load<mode><v_int_container>_<su>xtw_unpacked): Likewise.
30282         (*mask_gather_load<mode><v_int_container>_sxtw): Likewise.
30283         (*mask_gather_load<mode><v_int_container>_uxtw): Likewise.
30284         (@aarch64_gather_load_<ANY_EXTEND:optab><SVE_4HSI:mode><SVE_4BHI:mode>):
30285         Likewise.
30286         (@aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode><SVE_2BHSI:mode>):
30287         Likewise.
30288         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30289         <SVE_2BHSI:mode>_<ANY_EXTEND2:su>xtw_unpacked): Likewise.
30290         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30291         <SVE_2BHSI:mode>_sxtw): Likewise.
30292         (*aarch64_gather_load_<ANY_EXTEND:optab><SVE_2HSDI:mode>
30293         <SVE_2BHSI:mode>_uxtw): Likewise.
30294         (@aarch64_ldff1_gather<mode>): Likewise.
30295         (@aarch64_ldff1_gather<mode>): Likewise.
30296         (*aarch64_ldff1_gather<mode>_sxtw): Likewise.
30297         (*aarch64_ldff1_gather<mode>_uxtw): Likewise.
30298         (@aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx4_WIDE:mode>
30299         <VNx4_NARROW:mode>): Likewise.
30300         (@aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30301         <VNx2_NARROW:mode>): Likewise.
30302         (*aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30303         <VNx2_NARROW:mode>_sxtw): Likewise.
30304         (*aarch64_ldff1_gather_<ANY_EXTEND:optab><VNx2_WIDE:mode>
30305         <VNx2_NARROW:mode>_uxtw): Likewise.
30306         * config/aarch64/aarch64-sve2.md (@aarch64_gather_ldnt<mode>): Likewise.
30307         (@aarch64_gather_ldnt_<ANY_EXTEND:optab><SVE_FULL_SDI:mode>
30308         <SVE_PARTIAL_I:mode>): Likewise.
30310 2023-06-21  Tamar Christina  <tamar.christina@arm.com>
30312         PR other/110329
30313         * doc/md.texi: Replace backslashchar.
30315 2023-06-21  Richard Biener  <rguenther@suse.de>
30317         * config/i386/i386.cc (ix86_vector_costs::finish_cost):
30318         Overload.  For masked main loops make sure the vectorization
30319         factor isn't more than double the number of iterations.
30321 2023-06-21  Jan Beulich  <jbeulich@suse.com>
30323         * config/i386/i386-expand.cc (ix86_expand_copysign): Request
30324         value duplication by ix86_build_signbit_mask() when AVX512F and
30325         not HFmode.
30326         * config/i386/sse.md (*<avx512>_vternlog<mode>_all): Convert to
30327         2-alternative form. Adjust "mode" attribute. Add "enabled"
30328         attribute.
30329         (*<avx512>_vpternlog<mode>_1): Also permit when TARGET_AVX512F
30330         && !TARGET_PREFER_AVX256.
30331         (*<avx512>_vpternlog<mode>_2): Likewise.
30332         (*<avx512>_vpternlog<mode>_3): Likewise.
30334 2023-06-21  liuhongt  <hongtao.liu@intel.com>
30336         PR target/110018
30337         * tree-vect-stmts.cc (vectorizable_conversion): Use
30338         intermiediate integer type for float_expr/fix_trunc_expr when
30339         direct optab is not existed.
30341 2023-06-20  Tamar Christina  <tamar.christina@arm.com>
30343         PR bootstrap/110324
30344         * gensupport.cc (convert_syntax): Explicitly check for RTX code.
30346 2023-06-20  Richard Sandiford  <richard.sandiford@arm.com>
30348         * config/aarch64/aarch64.md (stack_tie): Hard-code the first
30349         register operand to the stack pointer.  Require the second register
30350         operand to have the number specified in a separate const_int operand.
30351         * config/aarch64/aarch64.cc (aarch64_emit_stack_tie): New function.
30352         (aarch64_allocate_and_probe_stack_space): Use it.
30353         (aarch64_expand_prologue, aarch64_expand_epilogue): Likewise.
30354         (aarch64_expand_epilogue): Likewise.
30356 2023-06-20  Jakub Jelinek  <jakub@redhat.com>
30358         PR middle-end/79173
30359         * tree-ssa-math-opts.cc (match_uaddc_usubc): Remember lhs of
30360         IMAGPART_EXPR of arg2/arg3 and use that as arg3 if it has the right
30361         type.
30363 2023-06-20  Uros Bizjak  <ubizjak@gmail.com>
30365         * calls.h (setjmp_call_p): Change return type from int to bool.
30366         * calls.cc (struct arg_data): Change "pass_on_stack" to bool.
30367         (store_one_arg): Change return type from int to bool
30368         and adjust function body accordingly.  Change "sibcall_failure"
30369         variable to bool.
30370         (finalize_must_preallocate): Ditto.  Change *must_preallocate pointer
30371         argument  to bool.  Change "partial_seen" variable to bool.
30372         (load_register_parameters):  Change *sibcall_failure
30373         pointer argument to bool.
30374         (check_sibcall_argument_overlap_1): Change return type from int to bool
30375         and adjust function body accordingly.
30376         (check_sibcall_argument_overlap):  Ditto.  Change
30377         "mark_stored_args_map" argument to bool.
30378         (emit_call_1): Change "already_popped" variable to bool.
30379         (setjmp_call_p): Change return type from int to bool
30380         and adjust function body accordingly.
30381         (initialize_argument_information): Change *must_preallocate
30382         pointer argument to bool.
30383         (expand_call): Change "pcc_struct_value", "must_preallocate"
30384         and "sibcall_failure" variables to bool.
30385         (emit_library_call_value_1): Change "pcc_struct_value"
30386         variable to bool.
30388 2023-06-20  Martin Jambor  <mjambor@suse.cz>
30390         PR ipa/110276
30391         * ipa-sra.cc (struct caller_issues): New field there_is_one.
30392         (check_for_caller_issues): Set it.
30393         (check_all_callers_for_issues): Check it.
30395 2023-06-20  Martin Jambor  <mjambor@suse.cz>
30397         * ipa-prop.h (ipa_uid_to_idx_map_elt): New type.
30398         (struct ipcp_transformation): Rearrange members according to
30399         C++ class coding convention, add m_uid_to_idx,
30400         get_param_index and maybe_create_parm_idx_map.
30401         * ipa-cp.cc (ipcp_transformation::get_param_index): New function.
30402         (compare_uids): Likewise.
30403         (ipcp_transformation::maype_create_parm_idx_map): Likewise.
30404         * ipa-prop.cc (ipcp_get_parm_bits): Use get_param_index.
30405         (ipcp_update_bits): Accept TS as a parameter, assume it is not NULL.
30406         (ipcp_update_vr): Likewise.
30407         (ipcp_transform_function): Call, maybe_create_parm_idx_map of TS, bail
30408         out quickly if empty, pass it to ipcp_update_bits and ipcp_update_vr.
30410 2023-06-20  Carl Love  <cel@us.ibm.com>
30412         * config/rs6000/rs6000-builtin.cc (rs6000_expand_builtin):
30413         Rename CODE_FOR_xsxsigqp_tf to CODE_FOR_xsxsigqp_tf_ti.
30414         Rename CODE_FOR_xsxsigqp_kf to CODE_FOR_xsxsigqp_kf_ti.
30415         Rename CCDE_FOR_xsxexpqp_tf to CODE_FOR_xsxexpqp_tf_di.
30416         Rename CODE_FOR_xsxexpqp_kf to CODE_FOR_xsxexpqp_kf_di.
30417         (CODE_FOR_xsxexpqp_kf_v2di, CODE_FOR_xsxsigqp_kf_v1ti,
30418         CODE_FOR_xsiexpqp_kf_v2di): Add case statements.
30419         * config/rs6000/rs6000-builtins.def
30420         (__builtin_vsx_scalar_extract_exp_to_vec,
30421         __builtin_vsx_scalar_extract_sig_to_vec,
30422         __builtin_vsx_scalar_insert_exp_vqp): Add new builtin definitions.
30423         Rename xsxexpqp_kf, xsxsigqp_kf, xsiexpqp_kf to xsexpqp_kf_di,
30424         xsxsigqp_kf_ti, xsiexpqp_kf_di respectively.
30425         * config/rs6000/rs6000-c.cc (altivec_resolve_overloaded_builtin):
30426         Update case RS6000_OVLD_VEC_VSIE to handle MODE_VECTOR_INT for new
30427         overloaded instance. Update comments.
30428         * config/rs6000/rs6000-overload.def
30429         (__builtin_vec_scalar_insert_exp): Add new overload definition with
30430         vector arguments.
30431         (scalar_extract_exp_to_vec, scalar_extract_sig_to_vec): New
30432         overloaded definitions.
30433         * config/rs6000/vsx.md (V2DI_DI): New mode iterator.
30434         (DI_to_TI): New mode attribute.
30435         Rename xsxexpqp_<mode> to sxexpqp_<IEEE128:mode>_<V2DI_DI:mode>.
30436         Rename xsxsigqp_<mode> to xsxsigqp_<IEEE128:mode>_<VEC_TI:mode>.
30437         Rename xsiexpqp_<mode> to xsiexpqp_<IEEE128:mode>_<V2DI_DI:mode>.
30438         * doc/extend.texi (scalar_extract_exp_to_vec,
30439         scalar_extract_sig_to_vec): Add documentation for new builtins.
30440         (scalar_insert_exp): Add new overloaded builtin definition.
30442 2023-06-20  Li Xu  <xuli1@eswincomputing.com>
30444         * config/riscv/riscv.cc (riscv_regmode_natural_size): set the natural
30445         size of vector mask mode to one rvv register.
30447 2023-06-20  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
30449         * config/riscv/riscv-v.cc (expand_const_vector): Optimize codegen.
30451 2023-06-20  Lehua Ding  <lehua.ding@rivai.ai>
30453         * config/riscv/riscv.cc (riscv_arg_has_vector): Add default
30454         switch handler.
30456 2023-06-20  Richard Biener  <rguenther@suse.de>
30458         * tree-ssa-dse.cc (dse_classify_store): When we found
30459         no defs and the basic-block with the original definition
30460         ends in __builtin_unreachable[_trap] the store is dead.
30462 2023-06-20  Richard Biener  <rguenther@suse.de>
30464         * tree-ssa-phiprop.cc (phiprop_insert_phi): For simple loads
30465         keep the virtual SSA form up-to-date.
30467 2023-06-20  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
30469         * config/aarch64/aarch64-simd.md (*aarch64_addp_same_reg<mode>):
30470         New define_insn_and_split.
30472 2023-06-20  Tamar Christina  <tamar.christina@arm.com>
30474         * config/aarch64/aarch64.md (*mov<mode>_aarch64): Drop test comment.
30476 2023-06-20  Jan Beulich  <jbeulich@suse.com>
30478         * config/i386/sse.md (vec_dupv2di): Correct %vmovddup input
30479         constraint. Add new AVX512F alternative.
30481 2023-06-20  Richard Biener  <rguenther@suse.de>
30483         PR debug/110295
30484         * dwarf2out.cc (process_scope_var): Continue processing
30485         the decl after setting a parent in case the existing DIE
30486         was in limbo.
30488 2023-06-20  Lehua Ding  <lehua.ding@rivai.ai>
30490         * config/riscv/riscv.cc (riscv_scalable_vector_type_p): Delete.
30491         (riscv_arg_has_vector): Simplify.
30492         (riscv_pass_in_vector_p): Adjust warning message.
30494 2023-06-19  Jin Ma  <jinma@linux.alibaba.com>
30496         * config/riscv/riscv.cc (riscv_compute_frame_info): Allocate frame for FCSR.
30497         (riscv_for_each_saved_reg): Save and restore FCSR in interrupt functions.
30498         * config/riscv/riscv.md (riscv_frcsr): New patterns.
30499         (riscv_fscsr): Likewise.
30501 2023-06-19  Toru Kisuki  <tkisuki@tachyum.com>
30503         PR rtl-optimization/110305
30504         * simplify-rtx.cc (simplify_context::simplify_binary_operation_1):
30505         Handle HONOR_SNANS for x + 0.0.
30507 2023-06-19  Jan Hubicka  <jh@suse.cz>
30509         PR tree-optimization/109811
30510         PR tree-optimization/109849
30511         * passes.def: Add phiprop to early optimization passes.
30512         * tree-ssa-phiprop.cc: Allow clonning.
30514 2023-06-19  Tamar Christina  <tamar.christina@arm.com>
30516         * config/aarch64/aarch64.md (arches): Add nosimd.
30517         (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Rewrite to
30518         compact syntax.
30520 2023-06-19  Tamar Christina  <tamar.christina@arm.com>
30521             Omar Tahir  <Omar.Tahir2@arm.com>
30523         * gensupport.cc (class conlist, add_constraints, add_attributes,
30524         skip_spaces, expect_char, preprocess_compact_syntax,
30525         parse_section_layout, parse_section, convert_syntax): New.
30526         (process_rtx): Check for conversion.
30527         * genoutput.cc (process_template): Check for unresolved iterators.
30528         (class data): Add compact_syntax_p.
30529         (gen_insn): Use it.
30530         * gensupport.h (compact_syntax): New.
30531         (hash-set.h): Include.
30532         * doc/md.texi: Document it.
30534 2023-06-19  Uros Bizjak  <ubizjak@gmail.com>
30536         * recog.h (check_asm_operands): Change return type from int to bool.
30537         (insn_invalid_p): Ditto.
30538         (verify_changes): Ditto.
30539         (apply_change_group): Ditto.
30540         (constrain_operands): Ditto.
30541         (constrain_operands_cached): Ditto.
30542         (validate_replace_rtx_subexp): Ditto.
30543         (validate_replace_rtx): Ditto.
30544         (validate_replace_rtx_part): Ditto.
30545         (validate_replace_rtx_part_nosimplify): Ditto.
30546         (added_clobbers_hard_reg_p): Ditto.
30547         (peep2_regno_dead_p): Ditto.
30548         (peep2_reg_dead_p): Ditto.
30549         (store_data_bypass_p): Ditto.
30550         (if_test_bypass_p): Ditto.
30551         * rtl.h (split_all_insns_noflow): Change
30552         return type from unsigned int to void.
30553         * genemit.cc (output_added_clobbers_hard_reg_p): Change return type
30554         of generated added_clobbers_hard_reg_p from int to bool and adjust
30555         function body accordingly.  Change "used" variable type from
30556         int to bool.
30557         * recog.cc (check_asm_operands): Change return type
30558         from int to bool and adjust function body accordingly.
30559         (insn_invalid_p): Ditto.  Change "is_asm" variable to bool.
30560         (verify_changes): Change return type from int to bool.
30561         (apply_change_group): Change return type from int to bool
30562         and adjust function body accordingly.
30563         (validate_replace_rtx_subexp): Change return type from int to bool.
30564         (validate_replace_rtx): Ditto.
30565         (validate_replace_rtx_part): Ditto.
30566         (validate_replace_rtx_part_nosimplify): Ditto.
30567         (constrain_operands_cached): Ditto.
30568         (constrain_operands): Ditto.  Change "lose" and "win"
30569         variables type from int to bool.
30570         (split_all_insns_noflow): Change return type from unsigned int
30571         to void and adjust function body accordingly.
30572         (peep2_regno_dead_p): Change return type from int to bool.
30573         (peep2_reg_dead_p): Ditto.
30574         (peep2_find_free_register): Change "success"
30575         variable type from int to bool
30576         (store_data_bypass_p_1): Change return type from int to bool.
30577         (store_data_bypass_p): Ditto.
30579 2023-06-19  Li Xu  <xuli1@eswincomputing.com>
30581         * config/riscv/vector-iterators.md: zvfh/zvfhmin depends on the
30582         Zve32f extension.
30584 2023-06-19  Pan Li  <pan2.li@intel.com>
30586         PR target/110299
30587         * config/riscv/riscv-vector-builtins-bases.cc: Adjust expand for
30588         modes.
30589         * config/riscv/vector-iterators.md: Remove VWLMUL1, VWLMUL1_ZVE64,
30590         VWLMUL1_ZVE32, VI_ZVE64, VI_ZVE32, VWI, VWI_ZVE64, VWI_ZVE32,
30591         VF_ZVE63 and VF_ZVE32.
30592         * config/riscv/vector.md
30593         (@pred_widen_reduc_plus<v_su><mode><vwlmul1>): Removed.
30594         (@pred_widen_reduc_plus<v_su><mode><vwlmul1_zve64>): Ditto.
30595         (@pred_widen_reduc_plus<v_su><mode><vwlmul1_zve32>): Ditto.
30596         (@pred_widen_reduc_plus<order><mode><vwlmul1>): Ditto.
30597         (@pred_widen_reduc_plus<order><mode><vwlmul1_zve64>): Ditto.
30598         (@pred_widen_reduc_plus<v_su><VQI:mode><VHI_LMUL1:mode>): New pattern.
30599         (@pred_widen_reduc_plus<v_su><VHI:mode><VSI_LMUL1:mode>): Ditto.
30600         (@pred_widen_reduc_plus<v_su><VSI:mode><VDI_LMUL1:mode>): Ditto.
30601         (@pred_widen_reduc_plus<order><VHF:mode><VSF_LMUL1:mode>): Ditto.
30602         (@pred_widen_reduc_plus<order><VSF:mode><VDF_LMUL1:mode>): Ditto.
30604 2023-06-19  Pan Li  <pan2.li@intel.com>
30606         PR target/110277
30607         * config/riscv/riscv-vector-builtins-bases.cc: Adjust expand for
30608         ret_mode.
30609         * config/riscv/vector-iterators.md: Add VHF, VSF, VDF,
30610         VHF_LMUL1, VSF_LMUL1, VDF_LMUL1, and remove unused attr.
30611         * config/riscv/vector.md (@pred_reduc_<reduc><mode><vlmul1>): Removed.
30612         (@pred_reduc_<reduc><mode><vlmul1_zve64>): Ditto.
30613         (@pred_reduc_<reduc><mode><vlmul1_zve32>): Ditto.
30614         (@pred_reduc_plus<order><mode><vlmul1>): Ditto.
30615         (@pred_reduc_plus<order><mode><vlmul1_zve32>): Ditto.
30616         (@pred_reduc_plus<order><mode><vlmul1_zve64>): Ditto.
30617         (@pred_reduc_<reduc><VHF:mode><VHF_LMUL1:mode>): New pattern.
30618         (@pred_reduc_<reduc><VSF:mode><VSF_LMUL1:mode>): Ditto.
30619         (@pred_reduc_<reduc><VDF:mode><VDF_LMUL1:mode>): Ditto.
30620         (@pred_reduc_plus<order><VHF:mode><VHF_LMUL1:mode>): Ditto.
30621         (@pred_reduc_plus<order><VSF:mode><VSF_LMUL1:mode>): Ditto.
30622         (@pred_reduc_plus<order><VDF:mode><VDF_LMUL1:mode>): Ditto.
30624 2023-06-19  Andrew Stubbs  <ams@codesourcery.com>
30626         * config/gcn/gcn.cc (gcn_expand_divmod_libfunc): New function.
30627         (gcn_init_libfuncs): Add div and mod functions for all modes.
30628         Add placeholders for divmod functions.
30629         (TARGET_EXPAND_DIVMOD_LIBFUNC): Define.
30631 2023-06-19  Andrew Stubbs  <ams@codesourcery.com>
30633         * tree-vect-generic.cc: Include optabs-libfuncs.h.
30634         (get_compute_type): Check optab_libfunc.
30635         * tree-vect-stmts.cc: Include optabs-libfuncs.h.
30636         (vectorizable_operation): Check optab_libfunc.
30638 2023-06-19  Andrew Stubbs  <ams@codesourcery.com>
30640         * config/gcn/gcn-protos.h (vgpr_4reg_mode_p): New function.
30641         * config/gcn/gcn-valu.md (V_4REG, V_4REG_ALT): New iterators.
30642         (V_MOV, V_MOV_ALT): Likewise.
30643         (scalar_mode, SCALAR_MODE): Add TImode.
30644         (vnsi, VnSI, vndi, VnDI): Likewise.
30645         (vec_merge, vec_merge_with_clobber, vec_merge_with_vcc): Use V_MOV.
30646         (mov<mode>, mov<mode>_unspec): Use V_MOV.
30647         (*mov<mode>_4reg): New insn.
30648         (mov<mode>_exec): New 4reg variant.
30649         (mov<mode>_sgprbase): Likewise.
30650         (reload_in<mode>, reload_out<mode>): Use V_MOV.
30651         (vec_set<mode>): Likewise.
30652         (vec_duplicate<mode><exec>): New 4reg variant.
30653         (vec_extract<mode><scalar_mode>): Likewise.
30654         (vec_extract<V_ALL:mode><V_ALL_ALT:mode>): Rename to ...
30655         (vec_extract<V_MOV:mode><V_MOV_ALT:mode>): ... this, and use V_MOV.
30656         (vec_extract<V_4REG:mode><V_4REG_ALT:mode>_nop): New 4reg variant.
30657         (fold_extract_last_<mode>): Use V_MOV.
30658         (vec_init<V_ALL:mode><V_ALL_ALT:mode>): Rename to ...
30659         (vec_init<V_MOV:mode><V_MOV_ALT:mode>): ... this, and use V_MOV.
30660         (gather_load<mode><vnsi>, gather<mode>_expr<exec>,
30661         gather<mode>_insn_1offset<exec>, gather<mode>_insn_1offset_ds<exec>,
30662         gather<mode>_insn_2offsets<exec>): Use V_MOV.
30663         (scatter_store<mode><vnsi>, scatter<mode>_expr<exec_scatter>,
30664         scatter<mode>_insn_1offset<exec_scatter>,
30665         scatter<mode>_insn_1offset_ds<exec_scatter>,
30666         scatter<mode>_insn_2offsets<exec_scatter>): Likewise.
30667         (maskload<mode>di, maskstore<mode>di, mask_gather_load<mode><vnsi>,
30668         mask_scatter_store<mode><vnsi>): Likewise.
30669         * config/gcn/gcn.cc (gcn_class_max_nregs): Use vgpr_4reg_mode_p.
30670         (gcn_hard_regno_mode_ok): Likewise.
30671         (GEN_VNM): Add TImode support.
30672         (USE_TI): New macro. Separate TImode operations from non-TImode ones.
30673         (gcn_vector_mode_supported_p): Add V64TImode, V32TImode, V16TImode,
30674         V8TImode, and V2TImode.
30675         (print_operand):  Add 'J' and 'K' print codes.
30677 2023-06-19  Richard Biener  <rguenther@suse.de>
30679         PR tree-optimization/110298
30680         * tree-ssa-loop-ivcanon.cc (tree_unroll_loops_completely):
30681         Clear number of iterations info before cleaning up the CFG.
30683 2023-06-19  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
30685         * simplify-rtx.cc (simplify_context::simplify_binary_operation_1):
30686         Simplify vec_concat of lowpart subreg and high part vec_select.
30688 2023-06-19  Tobias Burnus  <tobias@codesourcery.com>
30690         * doc/invoke.texi (-foffload-options): Remove '-O3' from the examples.
30692 2023-06-19  Richard Sandiford  <richard.sandiford@arm.com>
30694         * tree-vect-loop-manip.cc (vect_set_loop_condition_partial_vectors):
30695         Handle null niters_skip.
30697 2023-06-19  Richard Biener  <rguenther@suse.de>
30699         * config/aarch64/aarch64.cc
30700         (aarch64_vector_costs::analyze_loop_vinfo): Fix reference
30701         to LOOP_VINFO_MASKS.
30703 2023-06-19  Senthil Kumar Selvaraj  <saaadhu@gcc.gnu.org>
30705         PR target/105523
30706         * common/config/avr/avr-common.cc: Remove setting
30707         of OPT_fdelete_null_pointer_checks.
30708         * config/avr/avr.cc (avr_option_override): Clear
30709         flag_delete_null_pointer_checks if zero_address_valid.
30710         (avr_addr_space_zero_address_valid): New function.
30711         (TARGET_ADDR_SPACE_ZERO_ADDRESS_VALID): Provide target
30712         hook.
30714 2023-06-19  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
30715             Robin Dapp  <rdapp.gcc@gmail.com>
30717         * doc/md.texi: Add len_mask{load,store}.
30718         * genopinit.cc (main): Ditto.
30719         (CMP_NAME): Ditto.
30720         * internal-fn.cc (len_maskload_direct): Ditto.
30721         (len_maskstore_direct): Ditto.
30722         (expand_call_mem_ref): Ditto.
30723         (expand_partial_load_optab_fn): Ditto.
30724         (expand_len_maskload_optab_fn): Ditto.
30725         (expand_partial_store_optab_fn): Ditto.
30726         (expand_len_maskstore_optab_fn): Ditto.
30727         (direct_len_maskload_optab_supported_p): Ditto.
30728         (direct_len_maskstore_optab_supported_p): Ditto.
30729         * internal-fn.def (LEN_MASK_LOAD): Ditto.
30730         (LEN_MASK_STORE): Ditto.
30731         * optabs.def (OPTAB_CD): Ditto.
30733 2023-06-19  Robin Dapp  <rdapp@ventanamicro.com>
30735         * config/riscv/autovec.md (<optab><mode>2): Add unop expanders.
30737 2023-06-19  Robin Dapp  <rdapp@ventanamicro.com>
30739         * config/riscv/autovec.md (<optab><mode>3): Implement binop
30740         expander.
30741         * config/riscv/riscv-protos.h (emit_vlmax_fp_insn): Declare.
30742         (enum vxrm_field_enum): Rename this...
30743         (enum fixed_point_rounding_mode): ...to this.
30744         (enum frm_field_enum): Rename this...
30745         (enum floating_point_rounding_mode): ...to this.
30746         * config/riscv/riscv-v.cc (emit_vlmax_fp_insn): New function
30747         * config/riscv/riscv.cc (riscv_const_insns): Clarify const
30748         vector handling.
30749         (riscv_libgcc_floating_mode_supported_p): Adjust comment.
30750         (riscv_excess_precision): Do not convert to float for ZVFH.
30751         * config/riscv/vector-iterators.md: Add VF_AUTO iterator.
30753 2023-06-19  Robin Dapp  <rdapp@ventanamicro.com>
30755         * config/riscv/vector-iterators.md: Add VI_QH iterator.
30756         * config/riscv/autovec-opt.md
30757         (@pred_extract_first_sextdi<mode>): New vmv.x.s pattern
30758         that includes sign extension.
30759         (@pred_extract_first_sextsi<mode>): Dito for SImode.
30761 2023-06-19  Robin Dapp  <rdapp@ventanamicro.com>
30763         * config/riscv/autovec.md (vec_set<mode>): Implement.
30764         (vec_extract<mode><vel>): Implement.
30765         * config/riscv/riscv-protos.h (enum insn_type): Add slide insn.
30766         (emit_vlmax_slide_insn): Declare.
30767         (emit_nonvlmax_slide_tu_insn): Declare.
30768         (emit_scalar_move_insn): Export.
30769         (emit_nonvlmax_integer_move_insn): Export.
30770         * config/riscv/riscv-v.cc (emit_vlmax_slide_insn): New function.
30771         (emit_nonvlmax_slide_tu_insn): New function.
30772         (emit_vlmax_masked_mu_insn): No change.
30773         (emit_vlmax_integer_move_insn): Export.
30775 2023-06-19  Richard Biener  <rguenther@suse.de>
30777         * tree-vectorizer.h (enum vect_partial_vector_style): New.
30778         (_loop_vec_info::partial_vector_style): Likewise.
30779         (LOOP_VINFO_PARTIAL_VECTORS_STYLE): Likewise.
30780         (rgroup_controls::compare_type): Add.
30781         (vec_loop_masks): Change from a typedef to auto_vec<>
30782         to a structure.
30783         * tree-vect-loop-manip.cc (vect_set_loop_condition_partial_vectors):
30784         Adjust.  Convert niters_skip to compare_type.
30785         (vect_set_loop_condition_partial_vectors_avx512): New function
30786         implementing the AVX512 partial vector codegen.
30787         (vect_set_loop_condition): Dispatch to the correct
30788         vect_set_loop_condition_partial_vectors_* function based on
30789         LOOP_VINFO_PARTIAL_VECTORS_STYLE.
30790         (vect_prepare_for_masked_peels): Compute LOOP_VINFO_MASK_SKIP_NITERS
30791         in the original niter type.
30792         * tree-vect-loop.cc (_loop_vec_info::_loop_vec_info): Initialize
30793         partial_vector_style.
30794         (can_produce_all_loop_masks_p): Adjust.
30795         (vect_verify_full_masking): Produce the rgroup_controls vector
30796         here.  Set LOOP_VINFO_PARTIAL_VECTORS_STYLE on success.
30797         (vect_verify_full_masking_avx512): New function implementing
30798         verification of AVX512 style masking.
30799         (vect_verify_loop_lens): Set LOOP_VINFO_PARTIAL_VECTORS_STYLE.
30800         (vect_analyze_loop_2): Also try AVX512 style masking.
30801         Adjust condition.
30802         (vect_estimate_min_profitable_iters): Implement AVX512 style
30803         mask producing cost.
30804         (vect_record_loop_mask): Do not build the rgroup_controls
30805         vector here but record masks in a hash-set.
30806         (vect_get_loop_mask): Implement AVX512 style mask query,
30807         complementing the existing while_ult style.
30809 2023-06-19  Richard Biener  <rguenther@suse.de>
30811         * tree-vectorizer.h (vect_get_loop_mask): Add loop_vec_info
30812         argument.
30813         * tree-vect-loop.cc (vect_get_loop_mask): Likewise.
30814         (vectorize_fold_left_reduction): Adjust.
30815         (vect_transform_reduction): Likewise.
30816         (vectorizable_live_operation): Likewise.
30817         * tree-vect-stmts.cc (vectorizable_call): Likewise.
30818         (vectorizable_operation): Likewise.
30819         (vectorizable_store): Likewise.
30820         (vectorizable_load): Likewise.
30821         (vectorizable_condition): Likewise.
30823 2023-06-19  Senthil Kumar Selvaraj  <saaadhu@gcc.gnu.org>
30825         PR target/110086
30826         * config/avr/avr.opt (mgas-isr-prologues, mmain-is-OS_task):
30827         Add Optimization option property.
30829 2023-06-19  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
30831         * config/xtensa/xtensa.cc (xtensa_constantsynth_2insn):
30832         Add new pattern for the abovementioned case.
30834 2023-06-19  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
30836         * config/xtensa/xtensa.cc
30837         (TARGET_MEMORY_MOVE_COST, xtensa_memory_move_cost): Remove.
30839 2023-06-19  Jiufu Guo  <guojiufu@linux.ibm.com>
30841         * config/rs6000/rs6000.cc (TARGET_CONST_ANCHOR): New define.
30843 2023-06-19  Jiufu Guo  <guojiufu@linux.ibm.com>
30845         * cse.cc (try_const_anchors): Check SCALAR_INT_MODE.
30847 2023-06-19  liuhongt  <hongtao.liu@intel.com>
30849         PR target/110235
30850         * config/i386/sse.md (<sse2_avx2>_packsswb<mask_name>):
30851         Substitute with ..
30852         (sse2_packsswb<mask_name>): .. this, ..
30853         (avx2_packsswb<mask_name>): .. this and ..
30854         (avx512bw_packsswb<mask_name>): .. this.
30855         (<sse2_avx2>_packssdw<mask_name>): Substitute with ..
30856         (sse2_packssdw<mask_name>): .. this, ..
30857         (avx2_packssdw<mask_name>): .. this and ..
30858         (avx512bw_packssdw<mask_name>): .. this.
30860 2023-06-19  liuhongt  <hongtao.liu@intel.com>
30862         PR target/110235
30863         * config/i386/i386-expand.cc (ix86_split_mmx_pack): Use
30864         UNSPEC_US_TRUNCATE instead of original us_truncate for
30865         packusdw/packuswb.
30866         * config/i386/mmx.md (mmx_pack<s_trunsuffix>swb): Substitute
30867         with ..
30868         (mmx_packsswb): .. this and ..
30869         (mmx_packuswb): .. this.
30870         (mmx_packusdw): Use UNSPEC_US_TRUNCATE instead of original
30871         us_truncate.
30872         (s_trunsuffix): Removed code iterator.
30873         (any_s_truncate): Ditto.
30874         * config/i386/sse.md (<sse2_avx2>_packuswb<mask_name>): Use
30875         UNSPEC_US_TRUNCATE instead of original us_truncate.
30876         (<sse4_1_avx2>_packusdw<mask_name>): Ditto.
30877         * config/i386/i386.md (UNSPEC_US_TRUNCATE): New unspec_c_enum.
30879 2023-06-18  Pan Li  <pan2.li@intel.com>
30881         * config/riscv/riscv-vector-builtins-bases.cc: Fix one typo.
30883 2023-06-18  Uros Bizjak  <ubizjak@gmail.com>
30885         * rtl.h (*rtx_equal_p_callback_function):
30886         Change return type from int to bool.
30887         (rtx_equal_p): Ditto.
30888         (*hash_rtx_callback_function): Ditto.
30889         * rtl.cc (rtx_equal_p): Change return type from int to bool
30890         and adjust function body accordingly.
30891         * early-remat.cc (scratch_equal): Ditto.
30892         * sel-sched-ir.cc (skip_unspecs_callback): Ditto.
30893         (hash_with_unspec_callback): Ditto.
30895 2023-06-18  Jeff Law  <jlaw@ventanamicro.com>
30897         * config/arc/arc.md (movqi_insn): Allow certain constants to
30898         be stored into memory in the pattern's condition.
30899         (movsf_insn): Similarly.
30901 2023-06-18  Honza  <jh@ryzen3.suse.cz>
30903         PR tree-optimization/109849
30904         * ipa-fnsummary.cc (evaluate_conditions_for_known_args): Add new parameter
30905         ES; handle ipa_predicate::not_sra_candidate.
30906         (evaluate_properties_for_edge): Pass es to
30907         evaluate_conditions_for_known_args.
30908         (ipa_fn_summary_t::duplicate): Handle sra candidates.
30909         (dump_ipa_call_summary): Dump points_to_possible_sra_candidate.
30910         (load_or_store_of_ptr_parameter): New function.
30911         (points_to_possible_sra_candidate_p): New function.
30912         (analyze_function_body): Initialize points_to_possible_sra_candidate;
30913         determine sra predicates.
30914         (estimate_ipcp_clone_size_and_time): Update call of
30915         evaluate_conditions_for_known_args.
30916         (remap_edge_params): Update points_to_possible_sra_candidate.
30917         (read_ipa_call_summary): Stream points_to_possible_sra_candidate
30918         (write_ipa_call_summary): Likewise.
30919         * ipa-predicate.cc (ipa_predicate::add_clause): Handle not_sra_candidate.
30920         (dump_condition): Dump it.
30921         * ipa-predicate.h (struct inline_param_summary): Add
30922         points_to_possible_sra_candidate.
30924 2023-06-18  Roger Sayle  <roger@nextmovesoftware.com>
30926         * config/i386/i386-expand.cc (ix86_expand_carry): New helper
30927         function for setting the carry flag.
30928         (ix86_expand_builtin) <handlecarry>: Use it here.
30929         * config/i386/i386-protos.h (ix86_expand_carry): Prototype here.
30930         * config/i386/i386.md (uaddc<mode>5): Use ix86_expand_carry.
30931         (usubc<mode>5): Likewise.
30933 2023-06-18  Roger Sayle  <roger@nextmovesoftware.com>
30935         * config/i386/i386.md (*concat<mode><dwi>3_1): Use QImode
30936         for the immediate constant shift count.
30937         (*concat<mode><dwi>3_2): Likewise.
30938         (*concat<mode><dwi>3_3): Likewise.
30939         (*concat<mode><dwi>3_4): Likewise.
30940         (*concat<mode><dwi>3_5): Likewise.
30941         (*concat<mode><dwi>3_6): Likewise.
30943 2023-06-18  Uros Bizjak  <ubizjak@gmail.com>
30945         * cse.cc (hash_rtx_cb): Rename to hash_rtx.
30946         (hash_rtx): Remove.
30947         * early-remat.cc (remat_candidate_hasher::equal): Update
30948         to call rtx_equal_p with rtx_equal_p_callback_function argument.
30949         * rtl.cc (rtx_equal_p_cb): Rename to rtx_equal_p.
30950         (rtx_equal_p): Remove.
30951         * rtl.h (rtx_equal_p): Add rtx_equal_p_callback_function
30952         argument with NULL default value.
30953         (rtx_equal_p_cb): Remove function declaration.
30954         (hash_rtx_cb): Ditto.
30955         (hash_rtx): Add hash_rtx_callback_function argument
30956         with NULL default value.
30957         * sel-sched-ir.cc (free_nop_pool): Update function comment.
30958         (skip_unspecs_callback): Ditto.
30959         (vinsn_init): Update to call hash_rtx with
30960         hash_rtx_callback_function argument.
30961         (vinsn_equal_p): Ditto.
30963 2023-06-18  yulong  <shiyulong@iscas.ac.cn>
30965         * config/riscv/genrvv-type-indexer.cc (valid_type): Enable FP16 tuple.
30966         * config/riscv/riscv-modes.def (RVV_TUPLE_MODES): New macro.
30967         (ADJUST_ALIGNMENT): Ditto.
30968         (RVV_TUPLE_PARTIAL_MODES): Ditto.
30969         (ADJUST_NUNITS): Ditto.
30970         * config/riscv/riscv-vector-builtins-types.def (vfloat16mf4x2_t):
30971         New types.
30972         (vfloat16mf4x3_t): Ditto.
30973         (vfloat16mf4x4_t): Ditto.
30974         (vfloat16mf4x5_t): Ditto.
30975         (vfloat16mf4x6_t): Ditto.
30976         (vfloat16mf4x7_t): Ditto.
30977         (vfloat16mf4x8_t): Ditto.
30978         (vfloat16mf2x2_t): Ditto.
30979         (vfloat16mf2x3_t): Ditto.
30980         (vfloat16mf2x4_t): Ditto.
30981         (vfloat16mf2x5_t): Ditto.
30982         (vfloat16mf2x6_t): Ditto.
30983         (vfloat16mf2x7_t): Ditto.
30984         (vfloat16mf2x8_t): Ditto.
30985         (vfloat16m1x2_t): Ditto.
30986         (vfloat16m1x3_t): Ditto.
30987         (vfloat16m1x4_t): Ditto.
30988         (vfloat16m1x5_t): Ditto.
30989         (vfloat16m1x6_t): Ditto.
30990         (vfloat16m1x7_t): Ditto.
30991         (vfloat16m1x8_t): Ditto.
30992         (vfloat16m2x2_t): Ditto.
30993         (vfloat16m2x3_t): Ditto.
30994         (vfloat16m2x4_t): Ditto.
30995         (vfloat16m4x2_t): Ditto.
30996         * config/riscv/riscv-vector-builtins.def (vfloat16mf4x2_t): New macro.
30997         (vfloat16mf4x3_t): Ditto.
30998         (vfloat16mf4x4_t): Ditto.
30999         (vfloat16mf4x5_t): Ditto.
31000         (vfloat16mf4x6_t): Ditto.
31001         (vfloat16mf4x7_t): Ditto.
31002         (vfloat16mf4x8_t): Ditto.
31003         (vfloat16mf2x2_t): Ditto.
31004         (vfloat16mf2x3_t): Ditto.
31005         (vfloat16mf2x4_t): Ditto.
31006         (vfloat16mf2x5_t): Ditto.
31007         (vfloat16mf2x6_t): Ditto.
31008         (vfloat16mf2x7_t): Ditto.
31009         (vfloat16mf2x8_t): Ditto.
31010         (vfloat16m1x2_t): Ditto.
31011         (vfloat16m1x3_t): Ditto.
31012         (vfloat16m1x4_t): Ditto.
31013         (vfloat16m1x5_t): Ditto.
31014         (vfloat16m1x6_t): Ditto.
31015         (vfloat16m1x7_t): Ditto.
31016         (vfloat16m1x8_t): Ditto.
31017         (vfloat16m2x2_t): Ditto.
31018         (vfloat16m2x3_t): Ditto.
31019         (vfloat16m2x4_t): Ditto.
31020         (vfloat16m4x2_t): Ditto.
31021         * config/riscv/riscv-vector-switch.def (TUPLE_ENTRY): New.
31022         * config/riscv/riscv.md: New.
31023         * config/riscv/vector-iterators.md: New.
31025 2023-06-17  Roger Sayle  <roger@nextmovesoftware.com>
31027         * config/i386/i386-expand.cc (ix86_expand_move): Check that OP1 is
31028         CONST_WIDE_INT_P before calling ix86_convert_wide_int_to_broadcast.
31029         Generalize special case for converting TImode to V1TImode to handle
31030         all 128-bit vector conversions.
31032 2023-06-17  Costas Argyris  <costas.argyris@gmail.com>
31034         * gcc-ar.cc (main): Refactor to slightly reduce code
31035         duplication.  Avoid unnecessary elements in nargv.
31037 2023-06-16  Pan Li  <pan2.li@intel.com>
31039         PR target/110265
31040         * config/riscv/riscv-vector-builtins-bases.cc: Add ret_mode for
31041         integer reduction expand.
31042         * config/riscv/vector-iterators.md: Add VQI, VHI, VSI and VDI,
31043         and the LMUL1 attr respectively.
31044         * config/riscv/vector.md
31045         (@pred_reduc_<reduc><mode><vlmul1>): Removed.
31046         (@pred_reduc_<reduc><mode><vlmul1_zve64>): Likewise.
31047         (@pred_reduc_<reduc><mode><vlmul1_zve32>): Likewise.
31048         (@pred_reduc_<reduc><VQI:mode><VQI_LMUL1:mode>): New pattern.
31049         (@pred_reduc_<reduc><VHI:mode><VHI_LMUL1:mode>): Likewise.
31050         (@pred_reduc_<reduc><VSI:mode><VSI_LMUL1:mode>): Likewise.
31051         (@pred_reduc_<reduc><VDI:mode><VDI_LMUL1:mode>): Likewise.
31053 2023-06-16  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
31055         PR target/110264
31056         * config/riscv/riscv-vsetvl.cc (insert_vsetvl): Fix bug.
31058 2023-06-16  Jakub Jelinek  <jakub@redhat.com>
31060         PR middle-end/79173
31061         * builtin-types.def (BT_FN_UINT_UINT_UINT_UINT_UINTPTR,
31062         BT_FN_ULONG_ULONG_ULONG_ULONG_ULONGPTR,
31063         BT_FN_ULONGLONG_ULONGLONG_ULONGLONG_ULONGLONG_ULONGLONGPTR): New
31064         types.
31065         * builtins.def (BUILT_IN_ADDC, BUILT_IN_ADDCL, BUILT_IN_ADDCLL,
31066         BUILT_IN_SUBC, BUILT_IN_SUBCL, BUILT_IN_SUBCLL): New builtins.
31067         * builtins.cc (fold_builtin_addc_subc): New function.
31068         (fold_builtin_varargs): Handle BUILT_IN_{ADD,SUB}C{,L,LL}.
31069         * doc/extend.texi (__builtin_addc, __builtin_subc): Document.
31071 2023-06-16  Jakub Jelinek  <jakub@redhat.com>
31073         PR tree-optimization/110271
31074         * tree-ssa-math-opts.cc (math_opts_dom_walker::after_dom_children)
31075         <case PLUS_EXPR>: Ignore return value from match_arith_overflow,
31076         instead call match_uaddc_usubc only if gsi_stmt (gsi) is still stmt.
31078 2023-06-16  Martin Jambor  <mjambor@suse.cz>
31080         * configure: Regenerate.
31082 2023-06-16  Roger Sayle  <roger@nextmovesoftware.com>
31083             Uros Bizjak  <ubizjak@gmail.com>
31085         PR target/31985
31086         * config/i386/i386.md (*add<dwi>3_doubleword_concat): New
31087         define_insn_and_split combine *add<dwi>3_doubleword with
31088         a *concat<mode><dwi>3 for more efficient lowering after reload.
31090 2023-06-16  Vladimir N. Makarov  <vmakarov@redhat.com>
31092         * ira-lives.cc: Include except.h.
31093         (process_bb_node_lives): Ignore conflicts from cleanup exceptions
31094         when the pseudo does not live at the exception landing pad.
31096 2023-06-16  Alex Coplan  <alex.coplan@arm.com>
31098         * doc/invoke.texi: Document -Welaborated-enum-base.
31100 2023-06-16  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31102         * config/aarch64/aarch64-simd-builtins.def (shrn2_n): Rename builtins to...
31103         (ushrn2_n): ... This.
31104         (sqshrn2_n): Rename builtins to...
31105         (ssqshrn2_n): ... This.
31106         (uqshrn2_n): Rename builtins to...
31107         (uqushrn2_n): ... This.
31108         * config/aarch64/arm_neon.h (vqshrn_high_n_s16): Adjust for the above.
31109         (vqshrn_high_n_s32): Likewise.
31110         (vqshrn_high_n_s64): Likewise.
31111         (vqshrn_high_n_u16): Likewise.
31112         (vqshrn_high_n_u32): Likewise.
31113         (vqshrn_high_n_u64): Likewise.
31114         (vshrn_high_n_s16): Likewise.
31115         (vshrn_high_n_s32): Likewise.
31116         (vshrn_high_n_s64): Likewise.
31117         (vshrn_high_n_u16): Likewise.
31118         (vshrn_high_n_u32): Likewise.
31119         (vshrn_high_n_u64): Likewise.
31120         * config/aarch64/aarch64-simd.md (aarch64_<shrn_op>shrn2_n<mode>_insn_le):
31121         Rename to...
31122         (aarch64_<shrn_op><sra_op>shrn2_n<mode>_insn_le): ... This.
31123         Use SHIFTRT iterator and AARCH64_VALID_SHRN_OP check.
31124         (aarch64_<shrn_op>shrn2_n<mode>_insn_be): Rename to...
31125         (aarch64_<shrn_op><sra_op>shrn2_n<mode>_insn_be): ... This.
31126         Use SHIFTRT iterator and AARCH64_VALID_SHRN_OP check.
31127         (aarch64_<shrn_op>shrn2_n<mode>): Rename to...
31128         (aarch64_<shrn_op><sra_op>shrn2_n<mode>): ... This.
31129         Update expander for the above.
31131 2023-06-16  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31133         * config/aarch64/aarch64-simd-builtins.def (shrn2): Rename builtins to...
31134         (shrn2_n): ... This.
31135         (rshrn2): Rename builtins to...
31136         (rshrn2_n): ... This.
31137         * config/aarch64/arm_neon.h (vrshrn_high_n_s16): Adjust for the above.
31138         (vrshrn_high_n_s32): Likewise.
31139         (vrshrn_high_n_s64): Likewise.
31140         (vrshrn_high_n_u16): Likewise.
31141         (vrshrn_high_n_u32): Likewise.
31142         (vrshrn_high_n_u64): Likewise.
31143         (vshrn_high_n_s16): Likewise.
31144         (vshrn_high_n_s32): Likewise.
31145         (vshrn_high_n_s64): Likewise.
31146         (vshrn_high_n_u16): Likewise.
31147         (vshrn_high_n_u32): Likewise.
31148         (vshrn_high_n_u64): Likewise.
31149         * config/aarch64/aarch64-simd.md (*aarch64_<srn_op>shrn<mode>2_vect_le):
31150         Delete.
31151         (*aarch64_<srn_op>shrn<mode>2_vect_be): Likewise.
31152         (aarch64_shrn2<mode>_insn_le): Likewise.
31153         (aarch64_shrn2<mode>_insn_be): Likewise.
31154         (aarch64_shrn2<mode>): Likewise.
31155         (aarch64_rshrn2<mode>_insn_le): Likewise.
31156         (aarch64_rshrn2<mode>_insn_be): Likewise.
31157         (aarch64_rshrn2<mode>): Likewise.
31158         (aarch64_<sur>q<r>shr<u>n2_n<mode>_insn_le): Likewise.
31159         (aarch64_<shrn_op>shrn2_n<mode>_insn_le): New define_insn.
31160         (aarch64_<sur>q<r>shr<u>n2_n<mode>_insn_be): Delete.
31161         (aarch64_<shrn_op>shrn2_n<mode>_insn_be): New define_insn.
31162         (aarch64_<sur>q<r>shr<u>n2_n<mode>): Delete.
31163         (aarch64_<shrn_op>shrn2_n<mode>): New define_expand.
31164         (aarch64_<shrn_op>rshrn2_n<mode>_insn_le): New define_insn.
31165         (aarch64_<shrn_op>rshrn2_n<mode>_insn_be): New define_insn.
31166         (aarch64_<shrn_op>rshrn2_n<mode>): New define_expand.
31167         (aarch64_sqshrun2_n<mode>_insn_le): New define_insn.
31168         (aarch64_sqshrun2_n<mode>_insn_be): New define_insn.
31169         (aarch64_sqshrun2_n<mode>): New define_expand.
31170         (aarch64_sqrshrun2_n<mode>_insn_le): New define_insn.
31171         (aarch64_sqrshrun2_n<mode>_insn_be): New define_insn.
31172         (aarch64_sqrshrun2_n<mode>): New define_expand.
31173         * config/aarch64/iterators.md (UNSPEC_SQSHRUN, UNSPEC_SQRSHRUN,
31174         UNSPEC_SQSHRN, UNSPEC_UQSHRN, UNSPEC_SQRSHRN, UNSPEC_UQRSHRN):
31175         Delete unspec values.
31176         (VQSHRN_N): Delete int iterator.
31178 2023-06-16  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31180         * config/aarch64/aarch64.h (AARCH64_VALID_SHRN_OP): Define.
31181         * config/aarch64/aarch64-simd.md
31182         (*aarch64_<shrn_op>shrn_n<mode>_insn<vczle><vczbe>): Rename to...
31183         (*aarch64_<shrn_op><shrn_s>shrn_n<mode>_insn<vczle><vczbe>): ... This.
31184         Use SHIFTRT iterator and add AARCH64_VALID_SHRN_OP to condition.
31185         * config/aarch64/iterators.md (shrn_s): New code attribute.
31187 2023-06-16  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31189         * config/aarch64/aarch64-simd.md (aarch64_<sur>q<r>shr<u>n_n<mode>):
31190         Rename to...
31191         (aarch64_<shrn_op>shrn_n<mode>): ... This.  Reimplement with RTL codes.
31192         (*aarch64_<shrn_op>rshrn_n<mode>_insn): New define_insn.
31193         (aarch64_sqrshrun_n<mode>_insn): Likewise.
31194         (aarch64_sqshrun_n<mode>_insn): Likewise.
31195         (aarch64_<shrn_op>rshrn_n<mode>): New define_expand.
31196         (aarch64_sqshrun_n<mode>): Likewise.
31197         (aarch64_sqrshrun_n<mode>): Likewise.
31198         * config/aarch64/iterators.md (V2XWIDE): Add HI and SI modes.
31200 2023-06-16  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31202         * config/aarch64/aarch64-simd-builtins.def (shrn): Rename builtins to...
31203         (shrn_n): ... This.
31204         (rshrn): Rename builtins to...
31205         (rshrn_n): ... This.
31206         * config/aarch64/arm_neon.h (vshrn_n_s16): Adjust for the above.
31207         (vshrn_n_s32): Likewise.
31208         (vshrn_n_s64): Likewise.
31209         (vshrn_n_u16): Likewise.
31210         (vshrn_n_u32): Likewise.
31211         (vshrn_n_u64): Likewise.
31212         (vrshrn_n_s16): Likewise.
31213         (vrshrn_n_s32): Likewise.
31214         (vrshrn_n_s64): Likewise.
31215         (vrshrn_n_u16): Likewise.
31216         (vrshrn_n_u32): Likewise.
31217         (vrshrn_n_u64): Likewise.
31218         * config/aarch64/aarch64-simd.md
31219         (*aarch64_<srn_op>shrn<mode><vczle><vczbe>): Delete.
31220         (aarch64_shrn<mode>): Likewise.
31221         (aarch64_rshrn<mode><vczle><vczbe>_insn): Likewise.
31222         (aarch64_rshrn<mode>): Likewise.
31223         (aarch64_<sur>q<r>shr<u>n_n<mode>_insn<vczle><vczbe>): Likewise.
31224         (aarch64_<sur>q<r>shr<u>n_n<mode>): Likewise.
31225         (*aarch64_<shrn_op>shrn_n<mode>_insn<vczle><vczbe>): New define_insn.
31226         (*aarch64_<shrn_op>rshrn_n<mode>_insn<vczle><vczbe>): Likewise.
31227         (*aarch64_sqshrun_n<mode>_insn<vczle><vczbe>): Likewise.
31228         (*aarch64_sqrshrun_n<mode>_insn<vczle><vczbe>): Likewise.
31229         (aarch64_<shrn_op>shrn_n<mode>): New define_expand.
31230         (aarch64_<shrn_op>rshrn_n<mode>): Likewise.
31231         (aarch64_sqshrun_n<mode>): Likewise.
31232         (aarch64_sqrshrun_n<mode>): Likewise.
31233         * config/aarch64/iterators.md (ALL_TRUNC): New code iterator.
31234         (TRUNCEXTEND): New code attribute.
31235         (TRUNC_SHIFT): Likewise.
31236         (shrn_op): Likewise.
31237         * config/aarch64/predicates.md (aarch64_simd_umax_quarter_mode):
31238         New predicate.
31240 2023-06-16  Pan Li  <pan2.li@intel.com>
31242         * config/riscv/riscv-vsetvl.cc
31243         (pass_vsetvl::global_eliminate_vsetvl_insn): Initialize var by NULL.
31245 2023-06-16  Richard Biener  <rguenther@suse.de>
31247         PR tree-optimization/110278
31248         * match.pd (uns < (typeof uns)(uns != 0) -> false): New.
31249         (x != (typeof x)(x == 0) -> true): Likewise.
31251 2023-06-16  Pali Rohár  <pali@kernel.org>
31253         * config/i386/mingw-w64.h (CPP_SPEC): Adjust for -mcrtdll=.
31254         (REAL_LIBGCC_SPEC): New define.
31255         * config/i386/mingw.opt: Add mcrtdll=
31256         * config/i386/mingw32.h (CPP_SPEC): Adjust for -mcrtdll=.
31257         (REAL_LIBGCC_SPEC): Adjust for -mcrtdll=.
31258         (STARTFILE_SPEC): Adjust for -mcrtdll=.
31259         * doc/invoke.texi: Add mcrtdll= documentation.
31261 2023-06-16  Simon Dardis  <simon.dardis@imgtec.com>
31263         * config/mips/mips.cc (enum mips_code_readable_setting):New enmu.
31264         (mips_handle_code_readable_attr):New static function.
31265         (mips_get_code_readable_attr):New static enum function.
31266         (mips_set_current_function):Set the code_readable mode.
31267         (mips_option_override):Same as above.
31268         * doc/extend.texi:Document code_readable.
31270 2023-06-16  Richard Biener  <rguenther@suse.de>
31272         PR tree-optimization/110269
31273         * fold-const.cc (fold_binary_loc): Merge x != 0 folding
31274         with tree_expr_nonzero_p ...
31275         * match.pd (cmp (convert? addr@0) integer_zerop): With this
31276         pattern.
31278 2023-06-15  Marek Polacek  <polacek@redhat.com>
31280         * Makefile.in: Set LD_PICFLAG.  Use it.  Set enable_host_pie.
31281         Remove NO_PIE_CFLAGS and NO_PIE_FLAG.  Pass LD_PICFLAG to
31282         ALL_LINKERFLAGS.  Use the "pic" build of libiberty if --enable-host-pie.
31283         * configure.ac (--enable-host-shared): Don't set PICFLAG here.
31284         (--enable-host-pie): New check.  Set PICFLAG and LD_PICFLAG after this
31285         check.
31286         * configure: Regenerate.
31287         * doc/install.texi: Document --enable-host-pie.
31289 2023-06-15  Manolis Tsamis  <manolis.tsamis@vrull.eu>
31291         * regcprop.cc (maybe_mode_change): Enable stack pointer
31292         propagation.
31294 2023-06-15  Andrew MacLeod  <amacleod@redhat.com>
31296         PR tree-optimization/110266
31297         * gimple-range-fold.cc (adjust_imagpart_expr): Check for integer
31298         complex type.
31299         (adjust_realpart_expr): Ditto.
31301 2023-06-15  Jan Beulich  <jbeulich@suse.com>
31303         * config/i386/sse.md (<avx512>_vec_dup<mode><mask_name>): Use
31304         vmovddup.
31306 2023-06-15  Jan Beulich  <jbeulich@suse.com>
31308         * config/i386/constraints.md: Mention k and r for B.
31310 2023-06-15  Lulu Cheng  <chenglulu@loongson.cn>
31311             Andrew Pinski  <apinski@marvell.com>
31313         PR target/110136
31314         * config/loongarch/loongarch.md: Modify the register constraints for template
31315         "jumptable" and "indirect_jump" from "r" to "e".
31317 2023-06-15  Xi Ruoyao  <xry111@xry111.site>
31319         * config/loongarch/loongarch-tune.h (loongarch_align): New
31320         struct.
31321         * config/loongarch/loongarch-def.h (loongarch_cpu_align): New
31322         array.
31323         * config/loongarch/loongarch-def.c (loongarch_cpu_align): Define
31324         the array.
31325         * config/loongarch/loongarch.cc
31326         (loongarch_option_override_internal): Set the value of
31327         -falign-functions= if -falign-functions is enabled but no value
31328         is given.  Likewise for -falign-labels=.
31330 2023-06-15  Jakub Jelinek  <jakub@redhat.com>
31332         PR middle-end/79173
31333         * internal-fn.def (UADDC, USUBC): New internal functions.
31334         * internal-fn.cc (expand_UADDC, expand_USUBC): New functions.
31335         (commutative_ternary_fn_p): Return true also for IFN_UADDC.
31336         * optabs.def (uaddc5_optab, usubc5_optab): New optabs.
31337         * tree-ssa-math-opts.cc (uaddc_cast, uaddc_ne0, uaddc_is_cplxpart,
31338         match_uaddc_usubc): New functions.
31339         (math_opts_dom_walker::after_dom_children): Call match_uaddc_usubc
31340         for PLUS_EXPR, MINUS_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR unless
31341         other optimizations have been successful for those.
31342         * gimple-fold.cc (gimple_fold_call): Handle IFN_UADDC and IFN_USUBC.
31343         * fold-const-call.cc (fold_const_call): Likewise.
31344         * gimple-range-fold.cc (adjust_imagpart_expr): Likewise.
31345         * tree-ssa-dce.cc (eliminate_unnecessary_stmts): Likewise.
31346         * doc/md.texi (uaddc<mode>5, usubc<mode>5): Document new named
31347         patterns.
31348         * config/i386/i386.md (uaddc<mode>5, usubc<mode>5): New
31349         define_expand patterns.
31350         (*setcc_qi_addqi3_cconly_overflow_1_<mode>, *setccc): Split
31351         into NOTE_INSN_DELETED note rather than nop instruction.
31352         (*setcc_qi_negqi_ccc_1_<mode>, *setcc_qi_negqi_ccc_2_<mode>):
31353         Likewise.
31355 2023-06-15  Jakub Jelinek  <jakub@redhat.com>
31357         PR middle-end/79173
31358         * config/i386/i386.md (subborrow<mode>): Add alternative with
31359         memory destination and add for it define_peephole2
31360         TARGET_READ_MODIFY_WRITE/-Os patterns to prefer using memory
31361         destination in these patterns.
31363 2023-06-15  Jakub Jelinek  <jakub@redhat.com>
31365         PR middle-end/79173
31366         * config/i386/i386.md (*sub<mode>_3, @add<mode>3_carry,
31367         addcarry<mode>, @sub<mode>3_carry, *add<mode>3_cc_overflow_1): Add
31368         define_peephole2 TARGET_READ_MODIFY_WRITE/-Os patterns to prefer
31369         using memory destination in these patterns.
31371 2023-06-15  Jakub Jelinek  <jakub@redhat.com>
31373         * gimple-fold.cc (gimple_fold_call): Move handling of arg0
31374         as well as arg1 INTEGER_CSTs for .UBSAN_CHECK_{ADD,SUB,MUL}
31375         and .{ADD,SUB,MUL}_OVERFLOW calls from here...
31376         * fold-const-call.cc (fold_const_call): ... here.
31378 2023-06-15  Oluwatamilore Adebayo  <oluwatamilore.adebayo@arm.com>
31380         * config/aarch64/aarch64-simd.md (aarch64_<su>abd<mode>):
31381         Rename to <su>abd<mode>3.
31382         * config/aarch64/aarch64-sve.md (<su>abd<mode>_3): Rename
31383         to <su>abd<mode>3.
31385 2023-06-15  Oluwatamilore Adebayo  <oluwatamilore.adebayo@arm.com>
31387         * doc/md.texi (sabd, uabd): Document them.
31388         * internal-fn.def (ABD): Use new optab.
31389         * optabs.def (sabd_optab, uabd_optab): New optabs,
31390         * tree-vect-patterns.cc (vect_recog_absolute_difference):
31391         Recognize the following idiom abs (a - b).
31392         (vect_recog_sad_pattern): Refactor to use
31393         vect_recog_absolute_difference.
31394         (vect_recog_abd_pattern): Use patterns found by
31395         vect_recog_absolute_difference to build a new ABD
31396         internal call.
31398 2023-06-15  chenxiaolong  <chenxl04200420@163.com>
31400         * config/loongarch/loongarch.h (LARCH_CALL_RATIO): Modify the value
31401         of macro LARCH_CALL_RATIO on LoongArch to make it perform optimally.
31403 2023-06-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
31405         * config/riscv/riscv-v.cc (shuffle_merge_patterns): New pattern.
31406         (expand_vec_perm_const_1): Add merge optmization.
31408 2023-06-15  Lehua Ding  <lehua.ding@rivai.ai>
31410         PR target/110119
31411         * config/riscv/riscv.cc (riscv_get_arg_info): Return NULL_RTX for vector mode
31412         (riscv_pass_by_reference): Return true for vector mode
31414 2023-06-15  Pan Li  <pan2.li@intel.com>
31416         * config/riscv/autovec-opt.md: Align the predictor sytle.
31417         * config/riscv/autovec.md: Ditto.
31419 2023-06-15  Pan Li  <pan2.li@intel.com>
31421         * config/riscv/riscv-v.cc (rvv_builder::get_merge_scalar_mask):
31422         Take elen instead of scalar BITS_PER_WORD.
31423         (expand_vector_init_merge_repeating_sequence): Use inner_bits_size
31424         instead of scaler BITS_PER_WORD.
31426 2023-06-14  Jivan Hakobyan  <jivanhakobyan9@gmail.com>
31428         * config/moxie/uclinux.h (MFWRAP_SPEC): Remove
31430 2023-06-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31432         * config/aarch64/aarch64-sve-builtins-base.cc (svlast_impl::fold):
31433         Fix signed comparison warning in loop from npats to enelts.
31435 2023-06-14  Thomas Schwinge  <thomas@codesourcery.com>
31437         * gcc.cc (driver_handle_option): Forward host '-lgfortran', '-lm'
31438         to offloading compilation.
31439         * config/gcn/mkoffload.cc (main): Adjust.
31440         * config/nvptx/mkoffload.cc (main): Likewise.
31441         * doc/invoke.texi (foffload-options): Update example.
31443 2023-06-14  liuhongt  <hongtao.liu@intel.com>
31445         PR target/110227
31446         * config/i386/sse.md (mov<mode>_internal>): Use x instead of v
31447         for alternative 2 since there's no evex version for vpcmpeqd
31448         ymm, ymm, ymm.
31450 2023-06-13  Jeff Law  <jlaw@ventanamicro.com>
31452         * gcc.cc (LINK_COMMAND_SPEC): Remove mudflap spec handling.
31454 2023-06-13  Jeff Law  <jlaw@ventanamicro.com>
31456         * config/sh/divtab.cc: Remove.
31458 2023-06-13  Jakub Jelinek  <jakub@redhat.com>
31460         * config/i386/i386.cc (standard_sse_constant_opcode): Remove
31461         superfluous spaces around \t for vpcmpeqd.
31463 2023-06-13  Roger Sayle  <roger@nextmovesoftware.com>
31465         * expr.cc (store_constructor) <case VECTOR_TYPE>: Don't bother
31466         clearing vectors with only a single element.  Set CLEARED if the
31467         vector was initialized to zero.
31469 2023-06-13  Lehua Ding  <lehua.ding@rivai.ai>
31471         * config/riscv/riscv-v.cc (struct mode_vtype_group): Remove duplicate
31472         #include.
31473         (ENTRY): Undef.
31474         (TUPLE_ENTRY): Undef.
31476 2023-06-13  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
31478         * config/riscv/riscv-v.cc (rvv_builder::single_step_npatterns_p): Add comment.
31479         (shuffle_generic_patterns): Ditto.
31480         (expand_vec_perm_const_1): Ditto.
31482 2023-06-13  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
31484         * config/riscv/riscv-v.cc (emit_vlmax_decompress_insn): Fix bug.
31485         (shuffle_decompress_patterns): Ditto.
31487 2023-06-13  Richard Biener  <rguenther@suse.de>
31489         * tree-ssa-loop-ch.cc (ch_base::copy_headers): Free loop BBs.
31491 2023-06-13  Yanzhang Wang  <yanzhang.wang@intel.com>
31492             Kito Cheng  <kito.cheng@sifive.com>
31494         * config/riscv/riscv-protos.h (riscv_init_cumulative_args): Set
31495         warning flag if func is not builtin
31496         * config/riscv/riscv.cc
31497         (riscv_scalable_vector_type_p): Determine whether the type is scalable vector.
31498         (riscv_arg_has_vector): Determine whether the arg is vector type.
31499         (riscv_pass_in_vector_p): Check the vector type param is passed by value.
31500         (riscv_init_cumulative_args): The same as header.
31501         (riscv_get_arg_info): Add the checking.
31502         (riscv_function_value): Check the func return and set warning flag
31503         * config/riscv/riscv.h (INIT_CUMULATIVE_ARGS): Add a flag to
31504         determine whether warning psabi or not.
31506 2023-06-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31508         * config/arm/arm-opts.h (enum arm_tp_type): Remove TP_CP15.
31509         Add TP_TPIDRURW, TP_TPIDRURO, TP_TPIDRPRW values.
31510         * config/arm/arm-protos.h (arm_output_load_tpidr): Declare prototype.
31511         * config/arm/arm.cc (arm_option_reconfigure_globals): Replace TP_CP15
31512         with TP_TPIDRURO.
31513         (arm_output_load_tpidr): Define.
31514         * config/arm/arm.h (TARGET_HARD_TP): Define in terms of TARGET_SOFT_TP.
31515         * config/arm/arm.md (load_tp_hard): Call arm_output_load_tpidr to output
31516         assembly.
31517         (reload_tp_hard): Likewise.
31518         * config/arm/arm.opt (tpidrurw, tpidruro, tpidrprw): New values for
31519         arm_tp_type.
31520         * doc/invoke.texi (Arm Options, mtp): Document new values.
31522 2023-06-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31524         PR target/108779
31525         * config/aarch64/aarch64-opts.h (enum aarch64_tp_reg): Add
31526         AARCH64_TPIDRRO_EL0 value.
31527         * config/aarch64/aarch64.cc (aarch64_output_load_tp): Define.
31528         * config/aarch64/aarch64.opt (tpidr_el0, tpidr_el1, tpidr_el2,
31529         tpidr_el3, tpidrro_el3): New accepted values to -mtp=.
31530         * doc/invoke.texi (AArch64 Options): Document new -mtp= options.
31532 2023-06-13  Alexandre Oliva  <oliva@adacore.com>
31534         * range-op-float.cc (frange_nextafter): Drop inline.
31535         (frelop_early_resolve): Add static.
31536         (frange_float): Likewise.
31538 2023-06-13  Richard Biener  <rguenther@suse.de>
31540         PR middle-end/110232
31541         * fold-const.cc (native_interpret_vector): Use TYPE_SIZE_UNIT
31542         to check whether the buffer covers the whole vector.
31544 2023-06-13  Richard Biener  <rguenther@suse.de>
31546         * tree-ssa-alias.cc (ref_maybe_used_by_call_p_1): For
31547         .MASK_LOAD and friends set the size of the access to unknown.
31549 2023-06-13  Tejas Belagod  <tbelagod@arm.com>
31551         PR target/96339
31552         * config/aarch64/aarch64-sve-builtins-base.cc (svlast_impl::fold): Fold sve
31553         calls that have a constant input predicate vector.
31554         (svlast_impl::is_lasta): Query to check if intrinsic is svlasta.
31555         (svlast_impl::is_lastb): Query to check if intrinsic is svlastb.
31556         (svlast_impl::vect_all_same): Check if all vector elements are equal.
31558 2023-06-13  Andi Kleen  <ak@linux.intel.com>
31560         * config/i386/gcc-auto-profile: Regenerate.
31562 2023-06-13  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
31564         * config/riscv/vector-iterators.md: Fix requirement.
31566 2023-06-13  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
31568         * config/riscv/riscv-v.cc (emit_vlmax_decompress_insn): New function.
31569         (shuffle_decompress_patterns): New function.
31570         (expand_vec_perm_const_1): Add decompress optimization.
31572 2023-06-12  Jeff Law  <jlaw@ventanamicro.com>
31574         PR rtl-optimization/101188
31575         * postreload.cc (reload_cse_move2add_invalidate): New function,
31576         extracted from...
31577         (reload_cse_move2add): Call reload_cse_move2add_invalidate.
31579 2023-06-12  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
31581         * config/aarch64/aarch64.cc (aarch64_expand_vector_init): Tweak condition
31582         if (n_var == n_elts && n_elts <= 16) to allow a single constant,
31583         and if maxv == 1, use constant element for duplicating into register.
31585 2023-06-12  Tobias Burnus  <tobias@codesourcery.com>
31587         * gimplify.cc (gimplify_adjust_omp_clauses_1): Use
31588         GOMP_MAP_FORCE_PRESENT for 'present alloc' implicit mapping.
31589         (gimplify_adjust_omp_clauses): Change
31590         GOMP_MAP_PRESENT_{TO,TOFROM,FROM,ALLOC} to the equivalent
31591         GOMP_MAP_FORCE_PRESENT.
31592         * omp-low.cc (lower_omp_target): Remove handling of no-longer valid
31593         GOMP_MAP_PRESENT_{TO,TOFROM,FROM,ALLOC}; update map kinds used for
31594         to/from clauses with present modifier.
31596 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31598         PR tree-optimization/110205
31599         * range-op-float.cc (range_operator::fold_range): Add default FII
31600         fold routine.
31601         * range-op-mixed.h (class operator_gt): Add missing final overrides.
31602         * range-op.cc (range_op_handler::fold_range): Add RO_FII case.
31603         (operator_lshift ::update_bitmask): Add final override.
31604         (operator_rshift ::update_bitmask): Add final override.
31605         * range-op.h (range_operator::fold_range): Add FII prototype.
31607 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31609         * gimple-range-op.cc (gimple_range_op_handler::maybe_non_standard):
31610         Use range_op_handler directly.
31611         * range-op.cc (range_op_handler::range_op_handler): Unsigned
31612         param instead of tree-code.
31613         (ptr_op_widen_plus_signed): Delete.
31614         (ptr_op_widen_plus_unsigned): Delete.
31615         (ptr_op_widen_mult_signed): Delete.
31616         (ptr_op_widen_mult_unsigned): Delete.
31617         (range_op_table::initialize_integral_ops): Add new opcodes.
31618         * range-op.h (range_op_handler): Use unsigned.
31619         (OP_WIDEN_MULT_SIGNED): New.
31620         (OP_WIDEN_MULT_UNSIGNED): New.
31621         (OP_WIDEN_PLUS_SIGNED): New.
31622         (OP_WIDEN_PLUS_UNSIGNED): New.
31623         (RANGE_OP_TABLE_SIZE): New.
31624         (range_op_table::operator []): Use unsigned.
31625         (range_op_table::set): Use unsigned.
31626         (m_range_tree): Make unsigned.
31627         (ptr_op_widen_mult_signed): Remove.
31628         (ptr_op_widen_mult_unsigned): Remove.
31629         (ptr_op_widen_plus_signed): Remove.
31630         (ptr_op_widen_plus_unsigned): Remove.
31632 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31634         * gimple-range-op.cc (gimple_range_op_handler): Set m_operator
31635         manually as there is no access to the default operator.
31636         (cfn_copysign::fold_range): Don't check for validity.
31637         (cfn_ubsan::fold_range): Ditto.
31638         (gimple_range_op_handler::maybe_builtin_call): Don't set to NULL.
31639         * range-op.cc (default_operator): New.
31640         (range_op_handler::range_op_handler): Use default_operator
31641         instead of NULL.
31642         (range_op_handler::operator bool): Move from header, compare
31643         against default operator.
31644         (range_op_handler::range_op): New.
31645         * range-op.h (range_op_handler::operator bool): Move.
31647 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31649         * range-op.cc (unified_table): Delete.
31650         (range_op_table operator_table): Instantiate.
31651         (range_op_table::range_op_table): Rename from unified_table.
31652         (range_op_handler::range_op_handler): Use range_op_table.
31653         * range-op.h (range_op_table::operator []): Inline.
31654         (range_op_table::set): Inline.
31656 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31658         * gimple-range-gori.cc (gori_compute::condexpr_adjust): Do not
31659         pass type.
31660         * gimple-range-op.cc (get_code): Rename from get_code_and_type
31661         and simplify.
31662         (gimple_range_op_handler::supported_p): No need for type.
31663         (gimple_range_op_handler::gimple_range_op_handler): Ditto.
31664         (cfn_copysign::fold_range): Ditto.
31665         (cfn_ubsan::fold_range): Ditto.
31666         * ipa-cp.cc (ipa_vr_operation_and_type_effects): Ditto.
31667         * ipa-fnsummary.cc (evaluate_conditions_for_known_args): Ditto.
31668         * range-op-float.cc (operator_plus::op1_range): Ditto.
31669         (operator_mult::op1_range): Ditto.
31670         (range_op_float_tests): Ditto.
31671         * range-op.cc (get_op_handler): Remove.
31672         (range_op_handler::set_op_handler): Remove.
31673         (operator_plus::op1_range): No need for type.
31674         (operator_minus::op1_range): Ditto.
31675         (operator_mult::op1_range): Ditto.
31676         (operator_exact_divide::op1_range): Ditto.
31677         (operator_cast::op1_range): Ditto.
31678         (perator_bitwise_not::fold_range): Ditto.
31679         (operator_negate::fold_range): Ditto.
31680         * range-op.h (range_op_handler::range_op_handler): Remove type param.
31681         (range_cast): No need for type.
31682         (range_op_table::operator[]): Check for enum_code >= 0.
31683         * tree-data-ref.cc (compute_distributive_range): No need for type.
31684         * tree-ssa-loop-unswitch.cc (unswitch_predicate): Ditto.
31685         * value-query.cc (range_query::get_tree_range): Ditto.
31686         * value-relation.cc (relation_oracle::validate_relation): Ditto.
31687         * vr-values.cc (range_of_var_in_loop): Ditto.
31688         (simplify_using_ranges::fold_cond_with_ops): Ditto.
31690 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31692         * range-op-mixed.h (operator_max): Remove final.
31693         * range-op-ptr.cc (pointer_table::pointer_table): Remove MAX_EXPR.
31694         (pointer_table::pointer_table): Remove.
31695         (class hybrid_max_operator): New.
31696         (range_op_table::initialize_pointer_ops): Add hybrid_max_operator.
31697         * range-op.cc (pointer_tree_table): Remove.
31698         (unified_table::unified_table): Comment out MAX_EXPR.
31699         (get_op_handler): Remove check of pointer table.
31700         * range-op.h (class pointer_table): Remove.
31702 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31704         * range-op-mixed.h (operator_min): Remove final.
31705         * range-op-ptr.cc (pointer_table::pointer_table): Remove MIN_EXPR.
31706         (class hybrid_min_operator): New.
31707         (range_op_table::initialize_pointer_ops): Add hybrid_min_operator.
31708         * range-op.cc (unified_table::unified_table): Comment out MIN_EXPR.
31710 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31712         * range-op-mixed.h (operator_bitwise_or): Remove final.
31713         * range-op-ptr.cc (pointer_table::pointer_table): Remove BIT_IOR_EXPR.
31714         (class hybrid_or_operator): New.
31715         (range_op_table::initialize_pointer_ops): Add hybrid_or_operator.
31716         * range-op.cc (unified_table::unified_table): Comment out BIT_IOR_EXPR.
31718 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31720         * range-op-mixed.h (operator_bitwise_and): Remove final.
31721         * range-op-ptr.cc (pointer_table::pointer_table): Remove BIT_AND_EXPR.
31722         (class hybrid_and_operator): New.
31723         (range_op_table::initialize_pointer_ops): Add hybrid_and_operator.
31724         * range-op.cc (unified_table::unified_table): Comment out BIT_AND_EXPR.
31726 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31728         * Makefile.in (OBJS): Add range-op-ptr.o.
31729         * range-op-mixed.h (update_known_bitmask): Move prototype here.
31730         (minus_op1_op2_relation_effect): Move prototype here.
31731         (wi_includes_zero_p): Move function to here.
31732         (wi_zero_p): Ditto.
31733         * range-op.cc (update_known_bitmask): Remove static.
31734         (wi_includes_zero_p): Move to header.
31735         (wi_zero_p): Move to header.
31736         (minus_op1_op2_relation_effect): Remove static.
31737         (operator_pointer_diff): Move class and routines to range-op-ptr.cc.
31738         (pointer_plus_operator): Ditto.
31739         (pointer_min_max_operator): Ditto.
31740         (pointer_and_operator): Ditto.
31741         (pointer_or_operator): Ditto.
31742         (pointer_table): Ditto.
31743         (range_op_table::initialize_pointer_ops): Ditto.
31744         * range-op-ptr.cc: New.
31746 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31748         * range-op-mixed.h (class operator_max): Move from...
31749         * range-op.cc (unified_table::unified_table): Add MAX_EXPR.
31750         (get_op_handler): Remove the integral table.
31751         (class operator_max): Move from here.
31752         (integral_table::integral_table): Delete.
31753         * range-op.h (class integral_table): Delete.
31755 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31757         * range-op-mixed.h (class operator_min): Move from...
31758         * range-op.cc (unified_table::unified_table): Add MIN_EXPR.
31759         (class operator_min): Move from here.
31760         (integral_table::integral_table): Remove MIN_EXPR.
31762 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31764         * range-op-mixed.h (class operator_bitwise_or): Move from...
31765         * range-op.cc (unified_table::unified_table): Add BIT_IOR_EXPR.
31766         (class operator_bitwise_or): Move from here.
31767         (integral_table::integral_table): Remove BIT_IOR_EXPR.
31769 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31771         * range-op-mixed.h (class operator_bitwise_and): Move from...
31772         * range-op.cc (unified_table::unified_table): Add BIT_AND_EXPR.
31773         (get_op_handler): Check for a pointer table entry first.
31774         (class operator_bitwise_and): Move from here.
31775         (integral_table::integral_table): Remove BIT_AND_EXPR.
31777 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31779         * range-op-mixed.h (class operator_bitwise_xor): Move from...
31780         * range-op.cc (unified_table::unified_table): Add BIT_XOR_EXPR.
31781         (class operator_bitwise_xor): Move from here.
31782         (integral_table::integral_table): Remove BIT_XOR_EXPR.
31783         (pointer_table::pointer_table): Remove BIT_XOR_EXPR.
31785 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31787         * range-op-mixed.h (class operator_bitwise_not): Move from...
31788         * range-op.cc (unified_table::unified_table): Add BIT_NOT_EXPR.
31789         (class operator_bitwise_not): Move from here.
31790         (integral_table::integral_table): Remove BIT_NOT_EXPR.
31791         (pointer_table::pointer_table): Remove BIT_NOT_EXPR.
31793 2023-06-12  Andrew MacLeod  <amacleod@redhat.com>
31795         * range-op-mixed.h (class operator_addr_expr): Move from...
31796         * range-op.cc (unified_table::unified_table): Add ADDR_EXPR.
31797         (class operator_addr_expr): Move from here.
31798         (integral_table::integral_table): Remove ADDR_EXPR.
31799         (pointer_table::pointer_table): Remove ADDR_EXPR.
31801 2023-06-12  Pan Li  <pan2.li@intel.com>
31803         * config/riscv/riscv-vector-builtins-types.def
31804         (vfloat16m1_t): Add type to lmul1 ops.
31805         (vfloat16m2_t): Likewise.
31806         (vfloat16m4_t): Likewise.
31808 2023-06-12  Richard Biener  <rguenther@suse.de>
31810         * tree-ssa-alias.cc (call_may_clobber_ref_p_1): For
31811         .MASK_STORE and friend set the size of the access to
31812         unknown.
31814 2023-06-12  Tamar Christina  <tamar.christina@arm.com>
31816         * config.in: Regenerate.
31817         * configure: Regenerate.
31818         * configure.ac: Remove DEFAULT_MATCHPD_PARTITIONS.
31820 2023-06-12  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
31822         * config/riscv/autovec-opt.md
31823         (*v<any_shiftrt:optab><any_extend:optab>trunc<mode>): New pattern.
31824         (*<any_shiftrt:optab>trunc<mode>): Ditto.
31825         * config/riscv/autovec.md (<optab><mode>3): Change to
31826         define_insn_and_split.
31827         (v<optab><mode>3): Ditto.
31828         (trunc<mode><v_double_trunc>2): Ditto.
31830 2023-06-12  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31832         * simplify-rtx.cc (simplify_const_unary_operation):
31833         Handle US_TRUNCATE, SS_TRUNCATE.
31835 2023-06-12  Eric Botcazou  <ebotcazou@adacore.com>
31837         PR modula2/109952
31838         * doc/gm2.texi (Standard procedures): Fix Next link.
31840 2023-06-12  Tamar Christina  <tamar.christina@arm.com>
31842         * config.in: Regenerate.
31844 2023-06-12  Andre Vieira  <andre.simoesdiasvieira@arm.com>
31846         PR middle-end/110142
31847         * tree-vect-patterns.cc (vect_recog_widen_op_pattern): Don't pass
31848         subtype to vect_widened_op_tree and remove subtype parameter, also
31849         remove superfluous overloaded function definition.
31850         (vect_recog_widen_plus_pattern): Remove subtype parameter and dont pass
31851         to call to vect_recog_widen_op_pattern.
31852         (vect_recog_widen_minus_pattern): Likewise.
31854 2023-06-12  liuhongt  <hongtao.liu@intel.com>
31856         * config/i386/sse.md (vec_pack<floatprefix>_float_<mode>): New expander.
31857         (vec_unpack_<fixprefix>fix_trunc_lo_<mode>): Ditto.
31858         (vec_unpack_<fixprefix>fix_trunc_hi_<mode>): Ditto.
31859         (vec_unpacks_lo_<mode>): Ditto.
31860         (vec_unpacks_hi_<mode>): Ditto.
31861         (sse_movlhps_<mode>): New define_insn.
31862         (ssse3_palignr<mode>_perm): Extend to V_128H.
31863         (V_128H): New mode iterator.
31864         (ssepackPHmode): New mode attribute.
31865         (vunpck_extract_mode): Ditto.
31866         (vpckfloat_concat_mode): Extend to VxSI/VxSF for _Float16.
31867         (vpckfloat_temp_mode): Ditto.
31868         (vpckfloat_op_mode): Ditto.
31869         (vunpckfixt_mode): Extend to VxHF.
31870         (vunpckfixt_model): Ditto.
31871         (vunpckfixt_extract_mode): Ditto.
31873 2023-06-12  Richard Biener  <rguenther@suse.de>
31875         PR middle-end/110200
31876         * genmatch.cc (expr::gen_transform): Put braces around
31877         the if arm for the (convert ...) short-cut.
31879 2023-06-12  Kewen Lin  <linkw@linux.ibm.com>
31881         PR target/109932
31882         * config/rs6000/rs6000-builtins.def (__builtin_pack_vector_int128,
31883         __builtin_unpack_vector_int128): Move from stanza power7 to vsx.
31885 2023-06-12  Kewen Lin  <linkw@linux.ibm.com>
31887         PR target/110011
31888         * config/rs6000/rs6000.cc (output_toc): Use the mode of the 128-bit
31889         floating constant itself for real_to_target call.
31891 2023-06-12  Pan Li  <pan2.li@intel.com>
31893         * config/riscv/riscv-vector-builtins-types.def
31894         (vfloat16mf4_t): Add type to X2/X4/X8/X16/X32 vlmul ext ops.
31895         (vfloat16mf2_t): Ditto.
31896         (vfloat16m1_t): Ditto.
31897         (vfloat16m2_t): Ditto.
31898         (vfloat16m4_t): Ditto.
31900 2023-06-12  David Edelsohn  <dje.gcc@gmail.com>
31902         * config/rs6000/rs6000-logue.cc (rs6000_stack_info):
31903         Do not require a stack frame when debugging is enabled for AIX.
31905 2023-06-11  Georg-Johann Lay  <avr@gjlay.de>
31907         * config/avr/avr.md (adjust_len) [insv_notbit_0, insv_notbit_7]:
31908         Remove attribute values.
31909         (insv_notbit): New post-reload insn.
31910         (*insv.not-shiftrt_split, *insv.xor1-bit.0_split)
31911         (*insv.not-bit.0_split, *insv.not-bit.7_split)
31912         (*insv.xor-extract_split): Split to insv_notbit.
31913         (*insv.not-shiftrt, *insv.xor1-bit.0, *insv.not-bit.0, *insv.not-bit.7)
31914         (*insv.xor-extract): Remove post-reload insns.
31915         * config/avr/avr.cc (avr_out_insert_notbit) [bitno]: Remove parameter.
31916         (avr_adjust_insn_length): Adjust call of avr_out_insert_notbit.
31917         [ADJUST_LEN_INSV_NOTBIT_0, ADJUST_LEN_INSV_NOTBIT_7]: Remove cases.
31918         * config/avr/avr-protos.h (avr_out_insert_notbit): Adjust prototype.
31920 2023-06-11  Georg-Johann Lay  <avr@gjlay.de>
31922         PR target/109907
31923         * config/avr/avr.md (adjust_len) [extr, extr_not]: New elements.
31924         (MSB, SIZE): New mode attributes.
31925         (any_shift): New code iterator.
31926         (*lshr<mode>3_split, *lshr<mode>3, lshr<mode>3)
31927         (*lshr<mode>3_const_split): Add constraint alternative for
31928         the case of shift-offset = MSB.  Ditch "length" attribute.
31929         (extzv<mode): New. replaces extzv.  Adjust following patterns.
31930         Use avr_out_extr, avr_out_extr_not to print asm.
31931         (*extzv.subreg.<mode>, *extzv.<mode>.subreg, *extzv.xor)
31932         (*extzv<mode>.ge, *neg.ashiftrt<mode>.msb, *extzv.io.lsr7): New.
31933         * config/avr/constraints.md (C15, C23, C31, Yil): New
31934         * config/avr/predicates.md (reg_or_low_io_operand)
31935         (const7_operand, reg_or_low_io_operand)
31936         (const15_operand, const_0_to_15_operand)
31937         (const23_operand, const_0_to_23_operand)
31938         (const31_operand, const_0_to_31_operand): New.
31939         * config/avr/avr-protos.h (avr_out_extr, avr_out_extr_not): New.
31940         * config/avr/avr.cc (avr_out_extr, avr_out_extr_not): New funcs.
31941         (lshrqi3_out, lshrhi3_out, lshrpsi3_out, lshrsi3_out): Adjust
31942         MSB case to new insn constraint "r" for operands[1].
31943         (avr_adjust_insn_length) [ADJUST_LEN_EXTR_NOT, ADJUST_LEN_EXTR]:
31944         Handle these cases.
31945         (avr_rtx_costs_1): Adjust cost for a new pattern.
31947 2023-06-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
31949         * config/riscv/riscv-vsetvl.cc (available_occurrence_p): Enhance user vsetvl optimization.
31950         (vector_insn_info::parse_insn): Add rtx_insn parse.
31951         (pass_vsetvl::local_eliminate_vsetvl_insn): Enhance user vsetvl optimization.
31952         (get_first_vsetvl): New function.
31953         (pass_vsetvl::global_eliminate_vsetvl_insn): Ditto.
31954         (pass_vsetvl::cleanup_insns): Remove it.
31955         (pass_vsetvl::ssa_post_optimization): New function.
31956         (has_no_uses): Ditto.
31957         (pass_vsetvl::propagate_avl): Remove it.
31958         (pass_vsetvl::df_post_optimization): New function.
31959         (pass_vsetvl::lazy_vsetvl): Rework Phase 5 && Phase 6.
31960         * config/riscv/riscv-vsetvl.h: Adapt declaration.
31962 2023-06-10  Aldy Hernandez  <aldyh@redhat.com>
31964         * ipa-cp.cc (ipcp_vr_lattice::init): Take type argument.
31965         (ipcp_vr_lattice::print): Call dump method.
31966         (ipcp_vr_lattice::meet_with): Adjust for m_vr being a
31967         Value_Range.
31968         (ipcp_vr_lattice::meet_with_1): Make argument a reference.
31969         (ipcp_vr_lattice::set_to_bottom): Set varying for an unsupported
31970         range.
31971         (initialize_node_lattices): Pass type when appropriate.
31972         (ipa_vr_operation_and_type_effects): Make type agnostic.
31973         (ipa_value_range_from_jfunc): Same.
31974         (propagate_vr_across_jump_function): Same.
31975         * ipa-fnsummary.cc (evaluate_conditions_for_known_args): Same.
31976         (evaluate_properties_for_edge): Same.
31977         * ipa-prop.cc (ipa_vr::get_vrange): Same.
31978         (ipcp_update_vr): Same.
31979         * ipa-prop.h (ipa_value_range_from_jfunc): Same.
31980         (ipa_range_set_and_normalize): Same.
31982 2023-06-10  Georg-Johann Lay  <avr@gjlay.de>
31984         PR target/109650
31985         PR target/92729
31986         * config/avr/avr-passes.def (avr_pass_ifelse): Insert new pass.
31987         * config/avr/avr.cc (avr_pass_ifelse): New RTL pass.
31988         (avr_pass_data_ifelse): New pass_data for it.
31989         (make_avr_pass_ifelse, avr_redundant_compare, avr_cbranch_cost)
31990         (avr_canonicalize_comparison, avr_out_plus_set_ZN)
31991         (avr_out_cmp_ext): New functions.
31992         (compare_condtition): Make sure REG_CC dies in the branch insn.
31993         (avr_rtx_costs_1): Add computation of cbranch costs.
31994         (avr_adjust_insn_length) [ADJUST_LEN_ADD_SET_ZN, ADJUST_LEN_CMP_ZEXT]:
31995         [ADJUST_LEN_CMP_SEXT]Handle them.
31996         (TARGET_CANONICALIZE_COMPARISON): New define.
31997         (avr_simplify_comparison_p, compare_diff_p, avr_compare_pattern)
31998         (avr_reorg_remove_redundant_compare, avr_reorg): Remove functions.
31999         (TARGET_MACHINE_DEPENDENT_REORG): Remove define.
32000         * config/avr/avr-protos.h (avr_simplify_comparison_p): Remove proto.
32001         (make_avr_pass_ifelse, avr_out_plus_set_ZN, cc_reg_rtx)
32002         (avr_out_cmp_zext): New Protos
32003         * config/avr/avr.md (branch, difficult_branch): Don't split insns.
32004         (*cbranchhi.zero-extend.0", *cbranchhi.zero-extend.1")
32005         (*swapped_tst<mode>, *add.for.eqne.<mode>): New insns.
32006         (*cbranch<mode>4): Rename to cbranch<mode>4_insn.
32007         (define_peephole): Add dead_or_set_regno_p(insn,REG_CC) as needed.
32008         (define_deephole2): Add peep2_regno_dead_p(*,REG_CC) as needed.
32009         Add new RTL peepholes for decrement-and-branch and *swapped_tst<mode>.
32010         Rework signtest-and-branch peepholes for *sbrx_branch<mode>.
32011         (adjust_len) [add_set_ZN, cmp_zext]: New.
32012         (QIPSI): New mode iterator.
32013         (ALLs1, ALLs2, ALLs4, ALLs234): New mode iterators.
32014         (gelt): New code iterator.
32015         (gelt_eqne): New code attribute.
32016         (rvbranch, *rvbranch, difficult_rvbranch, *difficult_rvbranch)
32017         (branch_unspec, *negated_tst<mode>, *reversed_tst<mode>)
32018         (*cmpqi_sign_extend): Remove insns.
32019         (define_c_enum "unspec") [UNSPEC_IDENTITY]: Remove.
32020         * config/avr/avr-dimode.md (cbranch<mode>4): Canonicalize comparisons.
32021         * config/avr/predicates.md (scratch_or_d_register_operand): New.
32022         * config/avr/constraints.md (Yxx): New constraint.
32024 2023-06-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
32026         * config/riscv/autovec.md (select_vl<mode>): New pattern.
32027         * config/riscv/riscv-protos.h (expand_select_vl): New function.
32028         * config/riscv/riscv-v.cc (expand_select_vl): Ditto.
32030 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32032         * range-op-float.cc (foperator_mult_div_base): Delete.
32033         (foperator_mult_div_base::find_range): Make static local function.
32034         (foperator_mult): Remove.  Move prototypes to range-op-mixed.h
32035         (operator_mult::op1_range): Rename from foperator_mult.
32036         (operator_mult::op2_range): Ditto.
32037         (operator_mult::rv_fold): Ditto.
32038         (float_table::float_table): Remove MULT_EXPR.
32039         (class foperator_div): Inherit from range_operator.
32040         (float_table::float_table): Delete.
32041         * range-op-mixed.h (class operator_mult): Combined from integer
32042         and float files.
32043         * range-op.cc (float_tree_table): Delete.
32044         (op_mult): New object.
32045         (unified_table::unified_table): Add MULT_EXPR.
32046         (get_op_handler): Do not check float table any longer.
32047         (class cross_product_operator): Move to range-op-mixed.h.
32048         (class operator_mult): Move to range-op-mixed.h.
32049         (integral_table::integral_table): Remove MULT_EXPR.
32050         (pointer_table::pointer_table): Remove MULT_EXPR.
32051         * range-op.h (float_table): Remove.
32053 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32055         * range-op-float.cc (foperator_negate): Remove.  Move prototypes
32056         to range-op-mixed.h
32057         (operator_negate::fold_range): Rename from foperator_negate.
32058         (operator_negate::op1_range): Ditto.
32059         (float_table::float_table): Remove NEGATE_EXPR.
32060         * range-op-mixed.h (class operator_negate): Combined from integer
32061         and float files.
32062         * range-op.cc (op_negate): New object.
32063         (unified_table::unified_table): Add NEGATE_EXPR.
32064         (class operator_negate): Move to range-op-mixed.h.
32065         (integral_table::integral_table): Remove NEGATE_EXPR.
32066         (pointer_table::pointer_table): Remove NEGATE_EXPR.
32068 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32070         * range-op-float.cc (foperator_minus): Remove.  Move prototypes
32071         to range-op-mixed.h
32072         (operator_minus::fold_range): Rename from foperator_minus.
32073         (operator_minus::op1_range): Ditto.
32074         (operator_minus::op2_range): Ditto.
32075         (operator_minus::rv_fold): Ditto.
32076         (float_table::float_table): Remove MINUS_EXPR.
32077         * range-op-mixed.h (class operator_minus): Combined from integer
32078         and float files.
32079         * range-op.cc (op_minus): New object.
32080         (unified_table::unified_table): Add MINUS_EXPR.
32081         (class operator_minus): Move to range-op-mixed.h.
32082         (integral_table::integral_table): Remove MINUS_EXPR.
32083         (pointer_table::pointer_table): Remove MINUS_EXPR.
32085 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32087         * range-op-float.cc (foperator_abs): Remove.  Move prototypes
32088         to range-op-mixed.h
32089         (operator_abs::fold_range): Rename from foperator_abs.
32090         (operator_abs::op1_range): Ditto.
32091         (float_table::float_table): Remove ABS_EXPR.
32092         * range-op-mixed.h (class operator_abs): Combined from integer
32093         and float files.
32094         * range-op.cc (op_abs): New object.
32095         (unified_table::unified_table): Add ABS_EXPR.
32096         (class operator_abs): Move to range-op-mixed.h.
32097         (integral_table::integral_table): Remove ABS_EXPR.
32098         (pointer_table::pointer_table): Remove ABS_EXPR.
32100 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32102         * range-op-float.cc (foperator_plus): Remove.  Move prototypes
32103         to range-op-mixed.h
32104         (operator_plus::fold_range): Rename from foperator_plus.
32105         (operator_plus::op1_range): Ditto.
32106         (operator_plus::op2_range): Ditto.
32107         (operator_plus::rv_fold): Ditto.
32108         (float_table::float_table): Remove PLUS_EXPR.
32109         * range-op-mixed.h (class operator_plus): Combined from integer
32110         and float files.
32111         * range-op.cc (op_plus): New object.
32112         (unified_table::unified_table): Add PLUS_EXPR.
32113         (class operator_plus): Move to range-op-mixed.h.
32114         (integral_table::integral_table): Remove PLUS_EXPR.
32115         (pointer_table::pointer_table): Remove PLUS_EXPR.
32117 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32119         * range-op-mixed.h (class operator_cast): Combined from integer
32120         and float files.
32121         * range-op.cc (op_cast): New object.
32122         (unified_table::unified_table): Add op_cast
32123         (class operator_cast): Move to range-op-mixed.h.
32124         (integral_table::integral_table): Remove op_cast
32125         (pointer_table::pointer_table): Remove op_cast.
32127 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32129         * range-op-float.cc (operator_cst::fold_range): New.
32130         * range-op-mixed.h (class operator_cst): Move from integer file.
32131         * range-op.cc (op_cst): New object.
32132         (unified_table::unified_table): Add op_cst. Also use for REAL_CST.
32133         (class operator_cst): Move to range-op-mixed.h.
32134         (integral_table::integral_table): Remove op_cst.
32135         (pointer_table::pointer_table): Remove op_cst.
32137 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32139         * range-op-float.cc (foperator_identity): Remove.  Move prototypes
32140         to range-op-mixed.h
32141         (operator_identity::fold_range): Rename from foperator_identity.
32142         (operator_identity::op1_range): Ditto.
32143         (float_table::float_table): Remove fop_identity.
32144         * range-op-mixed.h (class operator_identity): Combined from integer
32145         and float files.
32146         * range-op.cc (op_identity): New object.
32147         (unified_table::unified_table): Add op_identity.
32148         (class operator_identity): Move to range-op-mixed.h.
32149         (integral_table::integral_table): Remove identity.
32150         (pointer_table::pointer_table): Remove identity.
32152 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32154         * range-op-float.cc (foperator_ge): Remove.  Move prototypes
32155         to range-op-mixed.h
32156         (operator_ge::fold_range): Rename from foperator_ge.
32157         (operator_ge::op1_range): Ditto.
32158         (float_table::float_table): Remove GE_EXPR.
32159         * range-op-mixed.h (class operator_ge): Combined from integer
32160         and float files.
32161         * range-op.cc (op_ge): New object.
32162         (unified_table::unified_table): Add GE_EXPR.
32163         (class operator_ge): Move to range-op-mixed.h.
32164         (ge_op1_op2_relation): Fold into
32165         operator_ge::op1_op2_relation.
32166         (integral_table::integral_table): Remove GE_EXPR.
32167         (pointer_table::pointer_table): Remove GE_EXPR.
32168         * range-op.h (ge_op1_op2_relation): Delete.
32170 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32172         * range-op-float.cc (foperator_gt): Remove.  Move prototypes
32173         to range-op-mixed.h
32174         (operator_gt::fold_range): Rename from foperator_gt.
32175         (operator_gt::op1_range): Ditto.
32176         (float_table::float_table): Remove GT_EXPR.
32177         * range-op-mixed.h (class operator_gt): Combined from integer
32178         and float files.
32179         * range-op.cc (op_gt): New object.
32180         (unified_table::unified_table): Add GT_EXPR.
32181         (class operator_gt): Move to range-op-mixed.h.
32182         (gt_op1_op2_relation): Fold into
32183         operator_gt::op1_op2_relation.
32184         (integral_table::integral_table): Remove GT_EXPR.
32185         (pointer_table::pointer_table): Remove GT_EXPR.
32186         * range-op.h (gt_op1_op2_relation): Delete.
32188 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32190         * range-op-float.cc (foperator_le): Remove.  Move prototypes
32191         to range-op-mixed.h
32192         (operator_le::fold_range): Rename from foperator_le.
32193         (operator_le::op1_range): Ditto.
32194         (float_table::float_table): Remove LE_EXPR.
32195         * range-op-mixed.h (class operator_le): Combined from integer
32196         and float files.
32197         * range-op.cc (op_le): New object.
32198         (unified_table::unified_table): Add LE_EXPR.
32199         (class operator_le): Move to range-op-mixed.h.
32200         (le_op1_op2_relation): Fold into
32201         operator_le::op1_op2_relation.
32202         (integral_table::integral_table): Remove LE_EXPR.
32203         (pointer_table::pointer_table): Remove LE_EXPR.
32204         * range-op.h (le_op1_op2_relation): Delete.
32206 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32208         * range-op-float.cc (foperator_lt): Remove.  Move prototypes
32209         to range-op-mixed.h
32210         (operator_lt::fold_range): Rename from foperator_lt.
32211         (operator_lt::op1_range): Ditto.
32212         (float_table::float_table): Remove LT_EXPR.
32213         * range-op-mixed.h (class operator_lt): Combined from integer
32214         and float files.
32215         * range-op.cc (op_lt): New object.
32216         (unified_table::unified_table): Add LT_EXPR.
32217         (class operator_lt): Move to range-op-mixed.h.
32218         (lt_op1_op2_relation): Fold into
32219         operator_lt::op1_op2_relation.
32220         (integral_table::integral_table): Remove LT_EXPR.
32221         (pointer_table::pointer_table): Remove LT_EXPR.
32222         * range-op.h (lt_op1_op2_relation): Delete.
32224 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32226         * range-op-float.cc (foperator_not_equal): Remove.  Move prototypes
32227         to range-op-mixed.h
32228         (operator_equal::fold_range): Rename from foperator_not_equal.
32229         (operator_equal::op1_range): Ditto.
32230         (float_table::float_table): Remove NE_EXPR.
32231         * range-op-mixed.h (class operator_not_equal): Combined from integer
32232         and float files.
32233         * range-op.cc (op_equal): New object.
32234         (unified_table::unified_table): Add NE_EXPR.
32235         (class operator_not_equal): Move to range-op-mixed.h.
32236         (not_equal_op1_op2_relation): Fold into
32237         operator_not_equal::op1_op2_relation.
32238         (integral_table::integral_table): Remove NE_EXPR.
32239         (pointer_table::pointer_table): Remove NE_EXPR.
32240         * range-op.h (not_equal_op1_op2_relation): Delete.
32242 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32244         * range-op-float.cc (foperator_equal): Remove.  Move prototypes
32245         to range-op-mixed.h
32246         (operator_equal::fold_range): Rename from foperator_equal.
32247         (operator_equal::op1_range): Ditto.
32248         (float_table::float_table): Remove EQ_EXPR.
32249         * range-op-mixed.h (class operator_equal): Combined from integer
32250         and float files.
32251         * range-op.cc (op_equal): New object.
32252         (unified_table::unified_table): Add EQ_EXPR.
32253         (class operator_equal): Move to range-op-mixed.h.
32254         (equal_op1_op2_relation): Fold into
32255         operator_equal::op1_op2_relation.
32256         (integral_table::integral_table): Remove EQ_EXPR.
32257         (pointer_table::pointer_table): Remove EQ_EXPR.
32258         * range-op.h (equal_op1_op2_relation): Delete.
32260 2023-06-10  Andrew MacLeod  <amacleod@redhat.com>
32262         * range-op-float.cc (class float_table): Move to header.
32263         (float_table::float_table): Move float only operators to...
32264         (range_op_table::initialize_float_ops): Here.
32265         * range-op-mixed.h: New.
32266         * range-op.cc (integral_tree_table, pointer_tree_table): Moved
32267         to top of file.
32268         (float_tree_table): Moved from range-op-float.cc.
32269         (unified_tree_table): New.
32270         (unified_table::unified_table): New.  Call initialize routines.
32271         (get_op_handler): Check unified table first.
32272         (range_op_handler::range_op_handler): Handle no type constructor.
32273         (integral_table::integral_table): Move integral only operators to...
32274         (range_op_table::initialize_integral_ops): Here.
32275         (pointer_table::pointer_table): Move pointer only operators to...
32276         (range_op_table::initialize_pointer_ops): Here.
32277         * range-op.h (enum bool_range_state): Move to range-op-mixed.h.
32278         (get_bool_state): Ditto.
32279         (empty_range_varying): Ditto.
32280         (relop_early_resolve): Ditto.
32281         (class range_op_table): Add new init methods for range types.
32282         (class integral_table): Move declaration to here.
32283         (class pointer_table): Move declaration to here.
32284         (class float_table): Move declaration to here.
32286 2023-06-09  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
32287             Richard Sandiford <richard.sandiford@arm.com>
32288             Richard Biener  <rguenther@suse.de>
32290         * doc/md.texi: Add SELECT_VL support.
32291         * internal-fn.def (SELECT_VL): Ditto.
32292         * optabs.def (OPTAB_D): Ditto.
32293         * tree-vect-loop-manip.cc (vect_set_loop_controls_directly): Ditto.
32294         * tree-vect-loop.cc (_loop_vec_info::_loop_vec_info): Ditto.
32295         * tree-vect-stmts.cc (get_select_vl_data_ref_ptr): Ditto.
32296         (vectorizable_store): Ditto.
32297         (vectorizable_load): Ditto.
32298         * tree-vectorizer.h (LOOP_VINFO_USING_SELECT_VL_P): Ditto.
32300 2023-06-09  Andrew MacLeod  <amacleod@redhat.com>
32302         PR ipa/109886
32303         * ipa-prop.cc (ipa_compute_jump_functions_for_edge): Check param
32304         type as well.
32306 2023-06-09  Andrew MacLeod  <amacleod@redhat.com>
32308         * range-op.cc (range_cast): Move to...
32309         * range-op.h (range_cast): Here and add generic a version.
32311 2023-06-09  Marek Polacek  <polacek@redhat.com>
32313         PR c/39589
32314         PR c++/96868
32315         * doc/invoke.texi: Clarify that -Wmissing-field-initializers doesn't
32316         warn about designated initializers in C only.
32318 2023-06-09  Andrew Pinski  <apinski@marvell.com>
32320         PR tree-optimization/97711
32321         PR tree-optimization/110155
32322         * match.pd ((zero_one == 0) ? y : z <op> y): Add plus to the op.
32323         ((zero_one != 0) ? z <op> y : y): Likewise.
32325 2023-06-09  Andrew Pinski  <apinski@marvell.com>
32327         * match.pd ((zero_one ==/!= 0) ? y : z <op> y): Use
32328         multiply rather than negation/bit_and.
32330 2023-06-09  Andrew Pinski  <apinski@marvell.com>
32332         * match.pd (`X & -Y -> X * Y`): Allow for truncation
32333         and the same type for unsigned types.
32335 2023-06-09  Andrew Pinski  <apinski@marvell.com>
32337         PR tree-optimization/110165
32338         PR tree-optimization/110166
32339         * match.pd (zero_one_valued_p): Don't accept
32340         signed 1-bit integers.
32342 2023-06-09  Richard Biener  <rguenther@suse.de>
32344         * match.pd (two conversions in a row): Use element_precision
32345         to DTRT for VECTOR_TYPE.
32347 2023-06-09  Pan Li  <pan2.li@intel.com>
32349         * config/riscv/riscv.md (enabled): Move to another place, and
32350         add fp_vector_disabled to the cond.
32351         (fp_vector_disabled): New attr defined for disabling fp.
32352         * config/riscv/vector-iterators.md: Fix V_WHOLE and V_FRACT.
32354 2023-06-09  Pan Li  <pan2.li@intel.com>
32356         * config/riscv/riscv-protos.h (enum frm_field_enum): Adjust
32357         literal to int.
32359 2023-06-09  liuhongt  <hongtao.liu@intel.com>
32361         PR target/110108
32362         * config/i386/i386.cc (ix86_gimple_fold_builtin): Explicitly
32363         view_convert_expr mask to signed type when folding pblendvb
32364         builtins.
32366 2023-06-09  liuhongt  <hongtao.liu@intel.com>
32368         PR target/110108
32369         * config/i386/i386.cc (ix86_gimple_fold_builtin): Fold
32370         _mm{,256,512}_abs_{epi8,epi16,epi32,epi64} into gimple
32371         ABSU_EXPR + VCE, don't fold _mm_abs_{pi8,pi16,pi32} w/o
32372         TARGET_64BIT.
32373         * config/i386/i386-builtin.def: Replace CODE_FOR_nothing with
32374         real codename for __builtin_ia32_pabs{b,w,d}.
32376 2023-06-08  Andrew MacLeod  <amacleod@redhat.com>
32378         * gimple-range-op.cc
32379         (gimple_range_op_handler::gimple_range_op_handler): Adjust.
32380         (gimple_range_op_handler::maybe_builtin_call): Adjust.
32381         * gimple-range-op.h (operand1, operand2): Use m_operator.
32382         * range-op.cc (integral_table, pointer_table): Relocate.
32383         (get_op_handler): Rename from get_handler and handle all types.
32384         (range_op_handler::range_op_handler): Relocate.
32385         (range_op_handler::set_op_handler): Relocate and adjust.
32386         (range_op_handler::range_op_handler): Relocate.
32387         (dispatch_trio): New.
32388         (RO_III, RO_IFI, RO_IFF, RO_FFF, RO_FIF, RO_FII): New consts.
32389         (range_op_handler::dispatch_kind): New.
32390         (range_op_handler::fold_range): Relocate and Use new dispatch value.
32391         (range_op_handler::op1_range): Ditto.
32392         (range_op_handler::op2_range): Ditto.
32393         (range_op_handler::lhs_op1_relation): Ditto.
32394         (range_op_handler::lhs_op2_relation): Ditto.
32395         (range_op_handler::op1_op2_relation): Ditto.
32396         (range_op_handler::set_op_handler): Use m_operator member.
32397         * range-op.h (range_op_handler::operator bool): Use m_operator.
32398         (range_op_handler::dispatch_kind): New.
32399         (range_op_handler::m_valid): Delete.
32400         (range_op_handler::m_int): Delete
32401         (range_op_handler::m_float): Delete
32402         (range_op_handler::m_operator): New.
32403         (range_op_table::operator[]): Relocate from .cc file.
32404         (range_op_table::set): Ditto.
32405         * value-range.h (class vrange): Make range_op_handler a friend.
32407 2023-06-08  Andrew MacLeod  <amacleod@redhat.com>
32409         * gimple-range-op.cc (cfn_constant_float_p): Change base class.
32410         (cfn_pass_through_arg1): Adjust using statemenmt.
32411         (cfn_signbit): Change base class, adjust using statement.
32412         (cfn_copysign): Ditto.
32413         (cfn_sqrt): Ditto.
32414         (cfn_sincos): Ditto.
32415         * range-op-float.cc (fold_range): Change class to range_operator.
32416         (rv_fold): Ditto.
32417         (op1_range): Ditto
32418         (op2_range): Ditto
32419         (lhs_op1_relation): Ditto.
32420         (lhs_op2_relation): Ditto.
32421         (op1_op2_relation): Ditto.
32422         (foperator_*): Ditto.
32423         (class float_table): New.  Inherit from range_op_table.
32424         (floating_tree_table) Change to range_op_table pointer.
32425         (class floating_op_table): Delete.
32426         * range-op.cc (operator_equal): Adjust using statement.
32427         (operator_not_equal): Ditto.
32428         (operator_lt, operator_le, operator_gt, operator_ge): Ditto.
32429         (operator_minus, operator_cast): Ditto.
32430         (operator_bitwise_and, pointer_plus_operator): Ditto.
32431         (get_float_handle): Change return type.
32432         * range-op.h (range_operator_float): Delete.  Relocate all methods
32433         into class range_operator.
32434         (range_op_handler::m_float): Change type to range_operator.
32435         (floating_op_table): Delete.
32436         (floating_tree_table): Change type.
32438 2023-06-08  Andrew MacLeod  <amacleod@redhat.com>
32440         * range-op.cc (range_operator::fold_range): Call virtual routine.
32441         (range_operator::update_bitmask): New.
32442         (operator_equal::update_bitmask): New.
32443         (operator_not_equal::update_bitmask): New.
32444         (operator_lt::update_bitmask): New.
32445         (operator_le::update_bitmask): New.
32446         (operator_gt::update_bitmask): New.
32447         (operator_ge::update_bitmask): New.
32448         (operator_ge::update_bitmask): New.
32449         (operator_plus::update_bitmask): New.
32450         (operator_minus::update_bitmask): New.
32451         (operator_pointer_diff::update_bitmask): New.
32452         (operator_min::update_bitmask): New.
32453         (operator_max::update_bitmask): New.
32454         (operator_mult::update_bitmask): New.
32455         (operator_div:operator_div):New.
32456         (operator_div::update_bitmask): New.
32457         (operator_div::m_code): New member.
32458         (operator_exact_divide::operator_exact_divide): New constructor.
32459         (operator_lshift::update_bitmask): New.
32460         (operator_rshift::update_bitmask): New.
32461         (operator_bitwise_and::update_bitmask): New.
32462         (operator_bitwise_or::update_bitmask): New.
32463         (operator_bitwise_xor::update_bitmask): New.
32464         (operator_trunc_mod::update_bitmask): New.
32465         (op_ident, op_unknown, op_ptr_min_max): New.
32466         (op_nop, op_convert): Delete.
32467         (op_ssa, op_paren, op_obj_type): Delete.
32468         (op_realpart, op_imagpart): Delete.
32469         (op_ptr_min, op_ptr_max): Delete.
32470         (pointer_plus_operator:update_bitmask): New.
32471         (range_op_table::set): Do not use m_code.
32472         (integral_table::integral_table): Adjust to single instances.
32473         * range-op.h (range_operator::range_operator): Delete.
32474         (range_operator::m_code): Delete.
32475         (range_operator::update_bitmask): New.
32477 2023-06-08  Andrew MacLeod  <amacleod@redhat.com>
32479         * range-op-float.cc (range_operator_float::fold_range): Return
32480         NAN of the result type.
32482 2023-06-08  Jakub Jelinek  <jakub@redhat.com>
32484         * optabs.cc (expand_ffs): Add forward declaration.
32485         (expand_doubleword_clz): Rename to ...
32486         (expand_doubleword_clz_ctz_ffs): ... this.  Add UNOPTAB argument,
32487         handle also doubleword CTZ and FFS in addition to CLZ.
32488         (expand_unop): Adjust caller.  Also call it for doubleword
32489         ctz_optab and ffs_optab.
32491 2023-06-08  Jakub Jelinek  <jakub@redhat.com>
32493         PR target/110152
32494         * config/i386/i386-expand.cc (ix86_expand_vector_init_general): For
32495         n_words == 2 recurse with mmx_ok as first argument rather than false.
32497 2023-06-07  Roger Sayle  <roger@nextmovesoftware.com>
32499         * wide-int.cc (wi::bitreverse_large): Use HOST_WIDE_INT_1U to
32500         avoid sign extension/undefined behaviour when setting each bit.
32502 2023-06-07  Roger Sayle  <roger@nextmovesoftware.com>
32503             Uros Bizjak  <ubizjak@gmail.com>
32505         * config/i386/i386-expand.cc (ix86_expand_builtin) <handlecarry>:
32506         Use new x86_stc instruction when the carry flag must be set.
32507         * config/i386/i386.cc (ix86_cc_mode): Use CCCmode for *x86_cmc.
32508         (ix86_rtx_costs): Provide accurate rtx_costs for *x86_cmc.
32509         * config/i386/i386.h (TARGET_SLOW_STC): New define.
32510         * config/i386/i386.md (UNSPEC_STC): New UNSPEC for stc.
32511         (x86_stc): New define_insn.
32512         (define_peephole2): Convert x86_stc into alternate implementation
32513         on pentium4 without -Os when a QImode register is available.
32514         (*x86_cmc): New define_insn.
32515         (define_peephole2): Convert *x86_cmc into alternate implementation
32516         on pentium4 without -Os when a QImode register is available.
32517         (*setccc): New define_insn_and_split for a no-op CCCmode move.
32518         (*setcc_qi_negqi_ccc_1_<mode>): New define_insn_and_split to
32519         recognize (and eliminate) the carry flag being copied to itself.
32520         (*setcc_qi_negqi_ccc_2_<mode>): Likewise.
32521         * config/i386/x86-tune.def (X86_TUNE_SLOW_STC): New tuning flag.
32523 2023-06-07  Andrew Pinski  <apinski@marvell.com>
32525         * match.pd: Fix comment for the
32526         `(zero_one ==/!= 0) ? y : z <op> y` patterns.
32528 2023-06-07  Jeff Law  <jlaw@ventanamicro.com>
32529             Jeff Law   <jlaw@ventanamicro.com>
32531         * config/riscv/bitmanip.md (rotrdi3, rotrsi3, rotlsi3): New expanders.
32532         (rotrsi3_sext): Expose generator.
32533         (rotlsi3 pattern): Hide generator.
32534         * config/riscv/riscv-protos.h (riscv_emit_binary): New function
32535         declaration.
32536         * config/riscv/riscv.cc (riscv_emit_binary): Removed static
32537         * config/riscv/riscv.md (addsi3, subsi3, negsi2): Hide generator.
32538         (mulsi3, <optab>si3): Likewise.
32539         (addsi3, subsi3, negsi2, mulsi3, <optab>si3): New expanders.
32540         (addv<mode>4, subv<mode>4, mulv<mode>4): Use riscv_emit_binary.
32541         (<u>mulsidi3): Likewise.
32542         (addsi3_extended, subsi3_extended, negsi2_extended): Expose generator.
32543         (mulsi3_extended, <optab>si3_extended): Likewise.
32544         (splitter for shadd feeding divison): Update RTL pattern to account
32545         for changes in how 32 bit ops are expanded for TARGET_64BIT.
32546         * loop-iv.cc (get_biv_step_1): Process src of extension when it PLUS.
32548 2023-06-07  Dimitar Dimitrov  <dimitar@dinux.eu>
32550         PR target/109725
32551         * config/riscv/riscv.cc (riscv_print_operand): Calculate
32552         memmodel only when it is valid.
32554 2023-06-07  Dimitar Dimitrov  <dimitar@dinux.eu>
32556         * config/riscv/riscv.cc (riscv_const_insns): Recursively call
32557         for constant element of a vector.
32559 2023-06-07  Jakub Jelinek  <jakub@redhat.com>
32561         * match.pd (zero_one_valued_p): Don't handle integer_zerop specially,
32562         instead compare tree_nonzero_bits <= 1U rather than just == 1.
32564 2023-06-07  Alex Coplan  <alex.coplan@arm.com>
32566         PR target/110132
32567         * config/aarch64/aarch64-builtins.cc (aarch64_general_simulate_builtin):
32568         New. Use it ...
32569         (aarch64_init_ls64_builtins): ... here. Switch to declaring public ACLE
32570         names for builtins.
32571         (aarch64_general_init_builtins): Ensure we invoke the arm_acle.h
32572         setup if in_lto_p, just like we do for SVE.
32573         * config/aarch64/arm_acle.h: (__arm_ld64b): Delete.
32574         (__arm_st64b): Delete.
32575         (__arm_st64bv): Delete.
32576         (__arm_st64bv0): Delete.
32578 2023-06-07  Alex Coplan  <alex.coplan@arm.com>
32580         PR target/110100
32581         * config/aarch64/aarch64-builtins.cc (aarch64_expand_builtin_ls64):
32582         Use input operand for the destination address.
32583         * config/aarch64/aarch64.md (st64b): Fix constraint on address
32584         operand.
32586 2023-06-07  Alex Coplan  <alex.coplan@arm.com>
32588         PR target/110100
32589         * config/aarch64/aarch64-builtins.cc (aarch64_init_ls64_builtins_types):
32590         Replace eight consecutive spaces with tabs.
32591         (aarch64_init_ls64_builtins): Likewise.
32592         (aarch64_expand_builtin_ls64): Likewise.
32593         * config/aarch64/aarch64.md (ld64b): Likewise.
32594         (st64b): Likewise.
32595         (st64bv): Likewise
32596         (st64bv0): Likewise.
32598 2023-06-07  Vladimir N. Makarov  <vmakarov@redhat.com>
32600         * ira-costs.cc: (find_costs_and_classes): Constrain classes of pic
32601         offset table pseudo to a general reg subset.
32603 2023-06-07  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
32605         * config/aarch64/aarch64-simd.md (aarch64_sqmovun<mode><vczle><vczbe>):
32606         Rename to...
32607         (*aarch64_sqmovun<mode>_insn<vczle><vczbe>): ... This.  Reimplement
32608         with RTL codes.
32609         (aarch64_sqmovun<mode> [SD_HSDI]): Reimplement with RTL codes.
32610         (aarch64_sqxtun2<mode>_le): Likewise.
32611         (aarch64_sqxtun2<mode>_be): Likewise.
32612         (aarch64_sqxtun2<mode>): Adjust for the above.
32613         (aarch64_sqmovun<mode>): New define_expand.
32614         * config/aarch64/iterators.md (UNSPEC_SQXTUN): Delete.
32615         (half_mask): New mode attribute.
32616         * config/aarch64/predicates.md (aarch64_simd_umax_half_mode):
32617         New predicate.
32619 2023-06-07  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
32621         * config/aarch64/aarch64-simd.md (aarch64_addp<mode><vczle><vczbe>):
32622         Reimplement as...
32623         (aarch64_addp<mode>_insn): ... This...
32624         (aarch64_addp<mode><vczle><vczbe>_insn): ... And this.
32625         (aarch64_addp<mode>): New define_expand.
32627 2023-06-07  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
32629         * config/riscv/riscv-protos.h (expand_vec_perm_const): New function.
32630         * config/riscv/riscv-v.cc
32631         (rvv_builder::can_duplicate_repeating_sequence_p): Support POLY
32632         handling.
32633         (rvv_builder::single_step_npatterns_p): New function.
32634         (rvv_builder::npatterns_all_equal_p): Ditto.
32635         (const_vec_all_in_range_p): Support POLY handling.
32636         (gen_const_vector_dup): Ditto.
32637         (emit_vlmax_gather_insn): Add vrgatherei16.
32638         (emit_vlmax_masked_gather_mu_insn): Ditto.
32639         (expand_const_vector): Add VLA SLP const vector support.
32640         (expand_vec_perm): Support POLY.
32641         (struct expand_vec_perm_d): New struct.
32642         (shuffle_generic_patterns): New function.
32643         (expand_vec_perm_const_1): Ditto.
32644         (expand_vec_perm_const): Ditto.
32645         * config/riscv/riscv.cc (riscv_vectorize_vec_perm_const): Ditto.
32646         (TARGET_VECTORIZE_VEC_PERM_CONST): New targethook.
32648 2023-06-07  Andrew Pinski  <apinski@marvell.com>
32650         PR middle-end/110117
32651         * expr.cc (expand_single_bit_test): Handle
32652         const_int from expand_expr.
32654 2023-06-07  Andrew Pinski  <apinski@marvell.com>
32656         * expr.cc (do_store_flag): Rearrange the
32657         TER code so that it overrides the nonzero bits
32658         info if we had `a & POW2`.
32660 2023-06-07  Andrew Pinski  <apinski@marvell.com>
32662         PR tree-optimization/110134
32663         * match.pd (-A CMP -B -> B CMP A): Allow EQ/NE for all integer
32664         types.
32665         (-A CMP CST -> B CMP (-CST)): Likewise.
32667 2023-06-07  Andrew Pinski  <apinski@marvell.com>
32669         PR tree-optimization/89263
32670         PR tree-optimization/99069
32671         PR tree-optimization/20083
32672         PR tree-optimization/94898
32673         * match.pd: Add patterns to optimize `a ? onezero : onezero` with
32674         one of the operands are constant.
32676 2023-06-07  Andrew Pinski  <apinski@marvell.com>
32678         * match.pd (zero_one_valued_p): Match 0 integer constant
32679         too.
32681 2023-06-07  Pan Li  <pan2.li@intel.com>
32683         * config/riscv/riscv-vector-builtins-types.def
32684         (vfloat32mf2_t): Take RVV_REQUIRE_ELEN_FP_16 as requirement.
32685         (vfloat32m1_t): Ditto.
32686         (vfloat32m2_t): Ditto.
32687         (vfloat32m4_t): Ditto.
32688         (vfloat32m8_t): Ditto.
32689         (vint16mf4_t): Ditto.
32690         (vint16mf2_t): Ditto.
32691         (vint16m1_t): Ditto.
32692         (vint16m2_t): Ditto.
32693         (vint16m4_t): Ditto.
32694         (vint16m8_t): Ditto.
32695         (vuint16mf4_t): Ditto.
32696         (vuint16mf2_t): Ditto.
32697         (vuint16m1_t): Ditto.
32698         (vuint16m2_t): Ditto.
32699         (vuint16m4_t): Ditto.
32700         (vuint16m8_t): Ditto.
32701         (vint32mf2_t): Ditto.
32702         (vint32m1_t): Ditto.
32703         (vint32m2_t): Ditto.
32704         (vint32m4_t): Ditto.
32705         (vint32m8_t): Ditto.
32706         (vuint32mf2_t): Ditto.
32707         (vuint32m1_t): Ditto.
32708         (vuint32m2_t): Ditto.
32709         (vuint32m4_t): Ditto.
32710         (vuint32m8_t): Ditto.
32712 2023-06-07  Jason Merrill  <jason@redhat.com>
32714         PR c++/58487
32715         * doc/invoke.texi: Document it.
32717 2023-06-06  Roger Sayle  <roger@nextmovesoftware.com>
32719         * doc/rtl.texi (bitreverse, copysign): Document new RTX codes.
32720         * rtl.def (BITREVERSE, COPYSIGN): Define new RTX codes.
32721         * simplify-rtx.cc (simplify_unary_operation_1): Optimize
32722         NOT (BITREVERSE x) as BITREVERSE (NOT x).
32723         Optimize POPCOUNT (BITREVERSE x) as POPCOUNT x.
32724         Optimize PARITY (BITREVERSE x) as PARITY x.
32725         Optimize BITREVERSE (BITREVERSE x) as x.
32726         (simplify_const_unary_operation) <case BITREVERSE>: Evaluate
32727         BITREVERSE of a constant integer at compile-time.
32728         (simplify_binary_operation_1) <case COPYSIGN>:  Optimize
32729         COPY_SIGN (x, x) as x.  Optimize COPYSIGN (x, C) as ABS x
32730         or NEG (ABS x) for constant C.  Optimize COPYSIGN (ABS x, y)
32731         and COPYSIGN (NEG x, y) as COPYSIGN (x, y).
32732         Optimize COPYSIGN (x, ABS y) as ABS x.
32733         Optimize COPYSIGN (COPYSIGN (x, y), z) as COPYSIGN (x, z).
32734         Optimize COPYSIGN (x, COPYSIGN (y, z)) as COPYSIGN (x, z).
32735         (simplify_const_binary_operation): Evaluate COPYSIGN of constant
32736         arguments at compile-time.
32738 2023-06-06  Uros Bizjak  <ubizjak@gmail.com>
32740         * rtl.h (function_invariant_p): Change return type from int to bool.
32741         * reload1.cc (function_invariant_p): Change return type from
32742         int to bool and adjust function body accordingly.
32744 2023-06-06  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
32746         * config/riscv/autovec-opt.md (*<optab>_fma<mode>): New pattern.
32747         (*single_<optab>mult_plus<mode>): Ditto.
32748         (*double_<optab>mult_plus<mode>): Ditto.
32749         (*sign_zero_extend_fma): Ditto.
32750         (*zero_sign_extend_fma): Ditto.
32751         * config/riscv/riscv-protos.h (enum insn_type): New enum.
32753 2023-06-06  Kwok Cheung Yeung  <kcy@codesourcery.com>
32754             Tobias Burnus  <tobias@codesourcery.com>
32756         * gimplify.cc (omp_notice_variable): Apply GOVD_MAP_ALLOC_ONLY flag
32757         and defaultmap flags if the defaultmap has GOVD_MAP_FORCE_PRESENT flag
32758         set.
32759         (omp_get_attachment): Handle map clauses with 'present' modifier.
32760         (omp_group_base): Likewise.
32761         (gimplify_scan_omp_clauses): Reorder present maps to come first.
32762         Set GOVD flags for present defaultmaps.
32763         (gimplify_adjust_omp_clauses_1): Set map kind for present defaultmaps.
32764         * omp-low.cc (scan_sharing_clauses): Handle 'always, present' map
32765         clauses.
32766         (lower_omp_target): Handle map clauses with 'present' modifier.
32767         Handle 'to' and 'from' clauses with 'present'.
32768         * tree-core.h (enum omp_clause_defaultmap_kind): Add
32769         OMP_CLAUSE_DEFAULTMAP_PRESENT defaultmap kind.
32770         * tree-pretty-print.cc (dump_omp_clause): Handle 'map', 'to' and
32771         'from' clauses with 'present' modifier.  Handle present defaultmap.
32772         * tree.h (OMP_CLAUSE_MOTION_PRESENT): New #define.
32774 2023-06-06  Segher Boessenkool  <segher@kernel.crashing.org>
32776         * config/rs6000/genfusion.pl: Delete some dead code.
32778 2023-06-06  Segher Boessenkool  <segher@kernel.crashing.org>
32780         * config/rs6000/genfusion.pl (gen_ld_cmpi_p10_one): New, rewritten and
32781         split out from...
32782         (gen_ld_cmpi_p10): ... this.
32784 2023-06-06  Jeevitha Palanisamy  <jeevitha@linux.ibm.com>
32786         PR target/106907
32787         * config/rs6000/rs6000.cc (vec_const_128bit_to_bytes): Remove
32788         duplicate expression.
32790 2023-06-06  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
32792         * config/aarch64/aarch64-builtins.cc (aarch64_general_gimple_fold_builtin):
32793         Handle unsigned reduc_plus_scal_ builtins.
32794         * config/aarch64/aarch64-simd-builtins.def (addp): Delete DImode instances.
32795         * config/aarch64/aarch64-simd.md (aarch64_addpdi): Delete.
32796         * config/aarch64/arm_neon.h (vpaddd_s64): Reimplement with
32797         __builtin_aarch64_reduc_plus_scal_v2di.
32798         (vpaddd_u64): Reimplement with __builtin_aarch64_reduc_plus_scal_v2di_uu.
32800 2023-06-06  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
32802         * config/aarch64/aarch64-simd.md (aarch64_<sur>shr_n<mode>): Delete.
32803         (aarch64_<sra_op>rshr_n<mode><vczle><vczbe>_insn): New define_insn.
32804         (aarch64_<sra_op>rshr_n<mode>): New define_expand.
32806 2023-06-06  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
32808         * config/aarch64/aarch64-simd.md (aarch64_shrn<mode>_insn_le): Delete.
32809         (aarch64_shrn<mode>_insn_be): Delete.
32810         (*aarch64_<srn_op>shrn<mode>_vect):  Rename to...
32811         (*aarch64_<srn_op>shrn<mode><vczle><vczbe>): ... This.
32812         (aarch64_shrn<mode>): Remove reference to the above deleted patterns.
32813         (aarch64_rshrn<mode>_insn_le): Delete.
32814         (aarch64_rshrn<mode>_insn_be): Delete.
32815         (aarch64_rshrn<mode><vczle><vczbe>_insn): New define_insn.
32816         (aarch64_rshrn<mode>): Remove references to the above deleted patterns.
32818 2023-06-06  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
32820         * config/aarch64/aarch64-protos.h (aarch64_parallel_select_half_p):
32821         Define prototype.
32822         (aarch64_pars_overlap_p): Likewise.
32823         * config/aarch64/aarch64-simd.md (aarch64_<su>addlv<mode>):
32824         Express in terms of UNSPEC_ADDV.
32825         (*aarch64_<su>addlv<VDQV_L:mode>_ze<GPI:mode>): Likewise.
32826         (*aarch64_<su>addlv<mode>_reduction): Define.
32827         (*aarch64_uaddlv<mode>_reduction_2): Likewise.
32828         * config/aarch64/aarch64.cc     (aarch64_parallel_select_half_p): Define.
32829         (aarch64_pars_overlap_p): Likewise.
32830         * config/aarch64/iterators.md (UNSPEC_SADDLV, UNSPEC_UADDLV): Delete.
32831         (VQUADW): New mode attribute.
32832         (VWIDE2X_S): Likewise.
32833         (USADDLV): Delete.
32834         (su): Delete handling of UNSPEC_SADDLV, UNSPEC_UADDLV.
32835         * config/aarch64/predicates.md (vect_par_cnst_select_half): Define.
32837 2023-06-06  Richard Biener  <rguenther@suse.de>
32839         PR middle-end/110055
32840         * gimplify.cc (gimplify_target_expr): Do not emit
32841         CLOBBERs for variables which have static storage duration
32842         after gimplifying their initializers.
32844 2023-06-06  Richard Biener  <rguenther@suse.de>
32846         PR tree-optimization/109143
32847         * tree-ssa-structalias.cc (solution_set_expand): Avoid
32848         one bitmap iteration and optimize bit range setting.
32850 2023-06-06  Hans-Peter Nilsson  <hp@axis.com>
32852         PR bootstrap/110120
32853         * postreload.cc (reload_cse_move2add, move2add_use_add2_insn): Use
32854         XVECEXP, not XEXP, to access first item of a PARALLEL.
32856 2023-06-06  Pan Li  <pan2.li@intel.com>
32858         * config/riscv/riscv-vector-builtins-types.def
32859         (vfloat16mf4_t): Add vfloat16mf4_t to WF operations.
32860         (vfloat16mf2_t): Likewise.
32861         (vfloat16m1_t): Likewise.
32862         (vfloat16m2_t): Likewise.
32863         (vfloat16m4_t): Likewise.
32864         (vfloat16m8_t): Likewise.
32865         * config/riscv/vector-iterators.md: Add FP=16 to VWF, VWF_ZVE64,
32866         VWLMUL1, VWLMUL1_ZVE64, vwlmul1 and vwlmul1_zve64.
32868 2023-06-06  Fei Gao  <gaofei@eswincomputing.com>
32870         * config/riscv/riscv.cc (riscv_adjust_libcall_cfi_prologue): Use Pmode
32871         for cfi reg/mem machmode
32872         (riscv_adjust_libcall_cfi_epilogue): Use Pmode for cfi reg machmode
32874 2023-06-06  Li Xu  <xuli1@eswincomputing.com>
32876         * config/riscv/vector-iterators.md:
32877         Fix 'REQUIREMENT' for machine_mode 'MODE'.
32878         * config/riscv/vector.md (@pred_indexed_<order>store<VNX16_QHS:mode>
32879         <VNX16_QHSI:mode>): change VNX16_QHSI to VNX16_QHSDI.
32880         (@pred_indexed_<order>store<VNX16_QHS:mode><VNX16_QHSDI:mode>): Ditto.
32882 2023-06-06  Pan Li  <pan2.li@intel.com>
32884         * config/riscv/vector-iterators.md: Fix typo in mode attr.
32886 2023-06-05  Andre Vieira  <andre.simoesdiasvieira@arm.com>
32887             Joel Hutton  <joel.hutton@arm.com>
32889         * doc/generic.texi: Remove old tree codes.
32890         * expr.cc (expand_expr_real_2): Remove old tree code cases.
32891         * gimple-pretty-print.cc (dump_binary_rhs): Likewise.
32892         * optabs-tree.cc (optab_for_tree_code): Likewise.
32893         (supportable_half_widening_operation): Likewise.
32894         * tree-cfg.cc (verify_gimple_assign_binary): Likewise.
32895         * tree-inline.cc (estimate_operator_cost): Likewise.
32896         (op_symbol_code): Likewise.
32897         * tree-vect-data-refs.cc (vect_get_smallest_scalar_type): Likewise.
32898         (vect_analyze_data_ref_accesses): Likewise.
32899         * tree-vect-generic.cc (expand_vector_operations_1): Likewise.
32900         * cfgexpand.cc (expand_debug_expr): Likewise.
32901         * tree-vect-stmts.cc (vectorizable_conversion): Likewise.
32902         (supportable_widening_operation): Likewise.
32903         * gimple-range-op.cc (gimple_range_op_handler::maybe_non_standard):
32904         Likewise.
32905         * optabs.def (vec_widen_ssubl_hi_optab, vec_widen_ssubl_lo_optab,
32906         vec_widen_saddl_hi_optab, vec_widen_saddl_lo_optab,
32907         vec_widen_usubl_hi_optab, vec_widen_usubl_lo_optab,
32908         vec_widen_uaddl_hi_optab, vec_widen_uaddl_lo_optab): Remove optabs.
32909         * tree-pretty-print.cc (dump_generic_node): Remove tree code definition.
32910         * tree.def (WIDEN_PLUS_EXPR, WIDEN_MINUS_EXPR, VEC_WIDEN_PLUS_HI_EXPR,
32911         VEC_WIDEN_PLUS_LO_EXPR, VEC_WIDEN_MINUS_HI_EXPR,
32912         VEC_WIDEN_MINUS_LO_EXPR): Likewise.
32914 2023-06-05  Andre Vieira  <andre.simoesdiasvieira@arm.com>
32915             Joel Hutton  <joel.hutton@arm.com>
32916             Tamar Christina  <tamar.christina@arm.com>
32918         * config/aarch64/aarch64-simd.md (vec_widen_<su>addl_lo_<mode>): Rename
32919         this ...
32920         (vec_widen_<su>add_lo_<mode>): ... to this.
32921         (vec_widen_<su>addl_hi_<mode>): Rename this ...
32922         (vec_widen_<su>add_hi_<mode>): ... to this.
32923         (vec_widen_<su>subl_lo_<mode>): Rename this ...
32924         (vec_widen_<su>sub_lo_<mode>): ... to this.
32925         (vec_widen_<su>subl_hi_<mode>): Rename this ...
32926         (vec_widen_<su>sub_hi_<mode>): ...to this.
32927         * doc/generic.texi: Document new IFN codes.
32928         * internal-fn.cc (lookup_hilo_internal_fn): Add lookup function.
32929         (commutative_binary_fn_p): Add widen_plus fn's.
32930         (widening_fn_p): New function.
32931         (narrowing_fn_p): New function.
32932         (direct_internal_fn_optab): Change visibility.
32933         * internal-fn.def (DEF_INTERNAL_WIDENING_OPTAB_FN): Macro to define an
32934         internal_fn that expands into multiple internal_fns for widening.
32935         (IFN_VEC_WIDEN_PLUS, IFN_VEC_WIDEN_PLUS_HI, IFN_VEC_WIDEN_PLUS_LO,
32936         IFN_VEC_WIDEN_PLUS_EVEN, IFN_VEC_WIDEN_PLUS_ODD,
32937         IFN_VEC_WIDEN_MINUS, IFN_VEC_WIDEN_MINUS_HI,
32938         IFN_VEC_WIDEN_MINUS_LO, IFN_VEC_WIDEN_MINUS_ODD,
32939         IFN_VEC_WIDEN_MINUS_EVEN): Define widening  plus,minus functions.
32940         * internal-fn.h (direct_internal_fn_optab): Declare new prototype.
32941         (lookup_hilo_internal_fn): Likewise.
32942         (widening_fn_p): Likewise.
32943         (Narrowing_fn_p): Likewise.
32944         * optabs.cc (commutative_optab_p): Add widening plus optabs.
32945         * optabs.def (OPTAB_D): Define widen add, sub optabs.
32946         * tree-vect-patterns.cc (vect_recog_widen_op_pattern): Support
32947         patterns with a hi/lo or even/odd split.
32948         (vect_recog_sad_pattern): Refactor to use new IFN codes.
32949         (vect_recog_widen_plus_pattern): Likewise.
32950         (vect_recog_widen_minus_pattern): Likewise.
32951         (vect_recog_average_pattern): Likewise.
32952         * tree-vect-stmts.cc (vectorizable_conversion): Add support for
32953         _HILO IFNs.
32954         (supportable_widening_operation): Likewise.
32955         * tree.def (WIDEN_SUM_EXPR): Update example to use new IFNs.
32957 2023-06-05  Andre Vieira  <andre.simoesdiasvieira@arm.com>
32958             Joel Hutton  <joel.hutton@arm.com>
32960         * tree-vect-patterns.cc: Add include for gimple-iterator.
32961         (vect_recog_widen_op_pattern): Refactor to use code_helper.
32962         (vect_gimple_build): New function.
32963         * tree-vect-stmts.cc (simple_integer_narrowing): Refactor to use
32964         code_helper.
32965         (vectorizable_call): Likewise.
32966         (vect_gen_widened_results_half): Likewise.
32967         (vect_create_vectorized_demotion_stmts): Likewise.
32968         (vect_create_vectorized_promotion_stmts): Likewise.
32969         (vect_create_half_widening_stmts): Likewise.
32970         (vectorizable_conversion): Likewise.
32971         (supportable_widening_operation): Likewise.
32972         (supportable_narrowing_operation): Likewise.
32973         * tree-vectorizer.h (supportable_widening_operation): Change
32974         prototype to use code_helper.
32975         (supportable_narrowing_operation): Likewise.
32976         (vect_gimple_build): New function prototype.
32977         * tree.h (code_helper::safe_as_tree_code): New function.
32978         (code_helper::safe_as_fn_code): New function.
32980 2023-06-05  Roger Sayle  <roger@nextmovesoftware.com>
32982         * wide-int.cc (wi::bitreverse_large): New function implementing
32983         bit reversal of an integer.
32984         * wide-int.h (wi::bitreverse): New (template) function prototype.
32985         (bitreverse_large): Prototype helper function/implementation.
32986         (wi::bitreverse): New template wrapper around bitreverse_large.
32988 2023-06-05  Uros Bizjak  <ubizjak@gmail.com>
32990         * rtl.h (print_rtl_single): Change return type from int to void.
32991         (print_rtl_single_with_indent): Ditto.
32992         * print-rtl.h (class rtx_writer): Ditto.  Change m_sawclose to bool.
32993         * print-rtl.cc (rtx_writer::rtx_writer): Update for m_sawclose change.
32994         (rtx_writer::print_rtx_operand_code_0): Ditto.
32995         (rtx_writer::print_rtx_operand_codes_E_and_V): Ditto.
32996         (rtx_writer::print_rtx_operand_code_i): Ditto.
32997         (rtx_writer::print_rtx_operand_code_u): Ditto.
32998         (rtx_writer::print_rtx_operand): Ditto.
32999         (rtx_writer::print_rtx): Ditto.
33000         (rtx_writer::finish_directive): Ditto.
33001         (print_rtl_single): Change return type from int to void
33002         and adjust function body accordingly.
33003         (rtx_writer::print_rtl_single_with_indent): Ditto.
33005 2023-06-05  Uros Bizjak  <ubizjak@gmail.com>
33007         * rtl.h (reg_classes_intersect_p): Change return type from int to bool.
33008         (reg_class_subset_p): Ditto.
33009         * reginfo.cc (reg_classes_intersect_p): Ditto.
33010         (reg_class_subset_p): Ditto.
33012 2023-06-05  Pan Li  <pan2.li@intel.com>
33014         * config/riscv/riscv-vector-builtins-types.def
33015         (vfloat32mf2_t): New type for DEF_RVV_WEXTF_OPS.
33016         (vfloat32m1_t): Ditto.
33017         (vfloat32m2_t): Ditto.
33018         (vfloat32m4_t): Ditto.
33019         (vfloat32m8_t): Ditto.
33020         (vint16mf4_t): New type for DEF_RVV_CONVERT_I_OPS.
33021         (vint16mf2_t): Ditto.
33022         (vint16m1_t): Ditto.
33023         (vint16m2_t): Ditto.
33024         (vint16m4_t): Ditto.
33025         (vint16m8_t): Ditto.
33026         (vuint16mf4_t): New type for DEF_RVV_CONVERT_U_OPS.
33027         (vuint16mf2_t): Ditto.
33028         (vuint16m1_t): Ditto.
33029         (vuint16m2_t): Ditto.
33030         (vuint16m4_t): Ditto.
33031         (vuint16m8_t): Ditto.
33032         (vint32mf2_t): New type for DEF_RVV_WCONVERT_I_OPS.
33033         (vint32m1_t): Ditto.
33034         (vint32m2_t): Ditto.
33035         (vint32m4_t): Ditto.
33036         (vint32m8_t): Ditto.
33037         (vuint32mf2_t): New type for DEF_RVV_WCONVERT_U_OPS.
33038         (vuint32m1_t): Ditto.
33039         (vuint32m2_t): Ditto.
33040         (vuint32m4_t): Ditto.
33041         (vuint32m8_t): Ditto.
33042         * config/riscv/vector-iterators.md: Add FP=16 support for V,
33043         VWCONVERTI, VCONVERT, VNCONVERT, VMUL1 and vlmul1.
33045 2023-06-05  Andrew Pinski  <apinski@marvell.com>
33047         PR bootstrap/110085
33048         * Makefile.in (clean): Remove the removing of
33049         MULTILIB_DIR/MULTILIB_OPTIONS directories.
33051 2023-06-05  YunQiang Su  <yunqiang.su@cipunited.com>
33053         * config/mips/mips-protos.h (mips_emit_speculation_barrier): New
33054         prototype.
33055         * config/mips/mips.cc (speculation_barrier_libfunc): New static
33056         variable.
33057         (mips_init_libfuncs): Initialize it.
33058         (mips_emit_speculation_barrier): New function.
33059         * config/mips/mips.md (speculation_barrier): Call
33060         mips_emit_speculation_barrier.
33062 2023-06-05  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33064         * config/riscv/riscv-v.cc (class rvv_builder): Reorganize functions.
33065         (rvv_builder::can_duplicate_repeating_sequence_p): Ditto.
33066         (rvv_builder::repeating_sequence_use_merge_profitable_p): Ditto.
33067         (rvv_builder::get_merged_repeating_sequence): Ditto.
33068         (rvv_builder::get_merge_scalar_mask): Ditto.
33069         (emit_scalar_move_insn): Ditto.
33070         (emit_vlmax_integer_move_insn): Ditto.
33071         (emit_nonvlmax_integer_move_insn): Ditto.
33072         (emit_vlmax_gather_insn): Ditto.
33073         (emit_vlmax_masked_gather_mu_insn): Ditto.
33074         (get_repeating_sequence_dup_machine_mode): Ditto.
33076 2023-06-05  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33078         * config/riscv/autovec.md: Split arguments.
33079         * config/riscv/riscv-protos.h (expand_vec_perm): Ditto.
33080         * config/riscv/riscv-v.cc (expand_vec_perm): Ditto.
33082 2023-06-04  Andrew Pinski  <apinski@marvell.com>
33084         * expr.cc (do_store_flag): Improve for single bit testing
33085         not against zero but against that single bit.
33087 2023-06-04  Andrew Pinski  <apinski@marvell.com>
33089         * expr.cc (do_store_flag): Extend the one bit checking case
33090         to handle the case where we don't have an and but rather still
33091         one bit is known to be non-zero.
33093 2023-06-04  Jeff Law  <jlaw@ventanamicro.com>
33095         * config/h8300/constraints.md (Zz): Make this a normal
33096         constraint.
33097         * config/h8300/h8300.cc (TARGET_LRA_P): Remove.
33098         * config/h8300/logical.md (H8/SX bit patterns): Remove.
33100 2023-06-04  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
33102         * config/xtensa/xtensa.md (*btrue_INT_MIN, *eqne_INT_MIN):
33103         New insn_and_split patterns.
33105 2023-06-04  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33107         PR target/110109
33108         * config/riscv/riscv-vector-builtins-bases.cc: Change expand approach.
33109         * config/riscv/vector.md (@vlmul_extx2<mode>): Remove it.
33110         (@vlmul_extx4<mode>): Ditto.
33111         (@vlmul_extx8<mode>): Ditto.
33112         (@vlmul_extx16<mode>): Ditto.
33113         (@vlmul_extx32<mode>): Ditto.
33114         (@vlmul_extx64<mode>): Ditto.
33115         (*vlmul_extx2<mode>): Ditto.
33116         (*vlmul_extx4<mode>): Ditto.
33117         (*vlmul_extx8<mode>): Ditto.
33118         (*vlmul_extx16<mode>): Ditto.
33119         (*vlmul_extx32<mode>): Ditto.
33120         (*vlmul_extx64<mode>): Ditto.
33122 2023-06-04  Pan Li  <pan2.li@intel.com>
33124         * config/riscv/riscv-vector-builtins-types.def
33125         (vfloat32mf2_t): Add vfloat32mf2_t type to vfncvt.f.f.w operations.
33126         (vfloat32m1_t): Likewise.
33127         (vfloat32m2_t): Likewise.
33128         (vfloat32m4_t): Likewise.
33129         (vfloat32m8_t): Likewise.
33130         * config/riscv/riscv-vector-builtins.def: Fix typo in comments.
33131         * config/riscv/vector-iterators.md: Add single to half machine
33132         mode conversion.
33134 2023-06-04  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33136         * config/riscv/autovec-opt.md (*<optab>not<mode>): Move to autovec-opt.md.
33137         (*n<optab><mode>): Ditto.
33138         * config/riscv/autovec.md (*<optab>not<mode>): Ditto.
33139         (*n<optab><mode>): Ditto.
33140         * config/riscv/vector.md: Ditto.
33142 2023-06-04  Roger Sayle  <roger@nextmovesoftware.com>
33144         PR target/110083
33145         * config/i386/i386-features.cc (scalar_chain::convert_compare):
33146         Update or delete REG_EQUAL notes, converting CONST_INT and
33147         CONST_WIDE_INT immediate operands to a suitable CONST_VECTOR.
33149 2023-06-04  Jason Merrill  <jason@redhat.com>
33151         PR c++/97720
33152         * tree-eh.cc (lower_resx): Pass the exception pointer to the
33153         failure_decl.
33154         * except.h: Tweak comment.
33156 2023-06-04  Hans-Peter Nilsson  <hp@axis.com>
33158         * postreload.cc (move2add_use_add2_insn): Handle
33159         trivial single_sets.  Rename variable PAT to SET.
33160         (move2add_use_add3_insn, reload_cse_move2add): Similar.
33162 2023-06-04  Pan Li  <pan2.li@intel.com>
33164         * config/riscv/riscv-vector-builtins-types.def
33165         (vfloat16mf4_t): Add the float16 type to DEF_RVV_F_OPS.
33166         (vfloat16mf2_t): Likewise.
33167         (vfloat16m1_t): Likewise.
33168         (vfloat16m2_t): Likewise.
33169         (vfloat16m4_t): Likewise.
33170         (vfloat16m8_t): Likewise.
33171         * config/riscv/riscv.md: Add vfloat16*_t to attr mode.
33172         * config/riscv/vector-iterators.md: Add vfloat16*_t machine mode
33173         to V, V_WHOLE, V_FRACT, VINDEX, VM, VEL and sew.
33174         * config/riscv/vector.md: Add vfloat16*_t machine mode to sew,
33175         vlmul and ratio.
33177 2023-06-03  Fei Gao  <gaofei@eswincomputing.com>
33179         * config/riscv/riscv.cc (riscv_expand_epilogue): fix cfi issue with
33180         correct offset.
33182 2023-06-03  Die Li  <lidie@eswincomputing.com>
33184         * config/riscv/thead.md (*th_cond_gpr_mov<GPR:mode><GPR2:mode>): Delete.
33186 2023-06-03  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33188         * config/riscv/predicates.md: Change INTVAL into UINTVAL.
33190 2023-06-03  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33192         * config/riscv/vector.md: Add vector-opt.md.
33193         * config/riscv/autovec-opt.md: New file.
33195 2023-06-03  liuhongt  <hongtao.liu@intel.com>
33197         PR tree-optimization/110067
33198         * gimple-ssa-store-merging.cc (find_bswap_or_nop): Don't try
33199         bswap + rotate when TYPE_PRECISION(n->type) > n->range.
33201 2023-06-03  liuhongt  <hongtao.liu@intel.com>
33203         PR target/92658
33204         * config/i386/mmx.md (truncv2hiv2qi2): New define_insn.
33205         (truncv2si<mode>2): Ditto.
33207 2023-06-02  Andrew Pinski  <apinski@marvell.com>
33209         PR rtl-optimization/102733
33210         * dse.cc (store_info): Add addrspace field.
33211         (record_store): Record the address space
33212         and check to make sure they are the same.
33214 2023-06-02  Andrew Pinski  <apinski@marvell.com>
33216         PR rtl-optimization/110042
33217         * ifcvt.cc (bbs_ok_for_cmove_arith): Allow paradoxical subregs.
33218         (bb_valid_for_noce_process_p): Strip the subreg for the SET_DEST.
33220 2023-06-02  Iain Sandoe  <iain@sandoe.co.uk>
33222         PR target/110044
33223         * config/rs6000/rs6000.cc (darwin_rs6000_special_round_type_align):
33224         Make sure that we do not have a cap on field alignment before altering
33225         the struct layout based on the type alignment of the first entry.
33227 2023-06-02  David Faust  <david.faust@oracle.com>
33229         PR debug/110073
33230         * btfout.cc (btf_absolute_func_id): New function.
33231         (btf_asm_func_type): Call it here.  Change index parameter from
33232         size_t to ctf_id_t.  Use PRIu64 formatter.
33234 2023-06-02  Alex Coplan  <alex.coplan@arm.com>
33236         * btfout.cc (btf_asm_type): Use PRIu64 instead of %lu for uint64_t.
33237         (btf_asm_datasec_type): Likewise.
33239 2023-06-02  Carl Love  <cel@us.ibm.com>
33241         * config/rs6000/rs6000-builtins.def (__builtin_altivec_tr_stxvrhx,
33242         __builtin_altivec_tr_stxvrwx): Fix type of third argument.
33244 2023-06-02  Jason Merrill  <jason@redhat.com>
33246         PR c++/110070
33247         PR c++/105838
33248         * tree.h (DECL_MERGEABLE): New.
33249         * tree-core.h (struct tree_decl_common): Mention it.
33250         * gimplify.cc (gimplify_init_constructor): Check it.
33251         * cgraph.cc (symtab_node::address_can_be_compared_p): Likewise.
33252         * varasm.cc (categorize_decl_for_section): Likewise.
33254 2023-06-02  Uros Bizjak  <ubizjak@gmail.com>
33256         * rtl.h (stack_regs_mentioned): Change return type from int to bool.
33257         * reg-stack.cc (struct_block_info_def): Change "done" to bool.
33258         (stack_regs_mentioned_p): Change return type from int to bool
33259         and adjust function body accordingly.
33260         (stack_regs_mentioned): Ditto.
33261         (check_asm_stack_operands): Ditto.  Change "malformed_asm"
33262         variable to bool.
33263         (move_for_stack_reg): Recode handling of control_flow_insn_deleted.
33264         (swap_rtx_condition_1): Change return type from int to bool
33265         and adjust function body accordingly.  Change "r" variable to bool.
33266         (swap_rtx_condition): Change return type from int to bool
33267         and adjust function body accordingly.
33268         (subst_stack_regs_pat): Recode handling of control_flow_insn_deleted.
33269         (subst_stack_regs): Ditto.
33270         (convert_regs_entry): Change return type from int to bool and adjust
33271         function body accordingly.  Change "inserted" variable to bool.
33272         (convert_regs_1): Recode handling of control_flow_insn_deleted.
33273         (convert_regs_2): Recode handling of cfg_altered.
33274         (convert_regs): Ditto.  Change "inserted" variable to bool.
33276 2023-06-02  Jason Merrill  <jason@redhat.com>
33278         PR c++/95226
33279         * varasm.cc (output_constant) [REAL_TYPE]: Check that sizes match.
33280         (initializer_constant_valid_p_1): Compare float precision.
33282 2023-06-02  Alexander Monakov  <amonakov@ispras.ru>
33284         * doc/extend.texi (Vector Extensions): Clarify bitwise shift
33285         semantics.
33287 2023-06-02  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
33289         * tree-vect-loop-manip.cc (vect_set_loop_controls_directly): Change decrement IV flow.
33290         (vect_set_loop_condition_partial_vectors): Ditto.
33292 2023-06-02  Georg-Johann Lay  <avr@gjlay.de>
33294         PR target/110088
33295         * config/avr/avr.md: Add an RTL peephole to optimize operations on
33296         non-LD_REGS after a move from LD_REGS.
33297         (piaop): New code iterator.
33299 2023-06-02  Thomas Schwinge  <thomas@codesourcery.com>
33301         PR testsuite/66005
33302         * doc/install.texi: Document (optional) Perl usage for parallel
33303         testing of libgomp.
33305 2023-06-02  Thomas Schwinge  <thomas@codesourcery.com>
33307         PR bootstrap/82856
33308         * doc/install.texi (Perl): Back to requiring "Perl version 5.6.1 (or
33309         later)".
33311 2023-06-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33312             KuanLin Chen  <best124612@gmail.com>
33314         * config/riscv/riscv-vector-builtins-bases.cc: Add _mu overloaded intrinsics.
33315         * config/riscv/riscv-vector-builtins-shapes.cc (struct fault_load_def): Ditto.
33317 2023-06-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33319         * config/riscv/riscv-v.cc (expand_vec_series): Optimize reverse series index vector.
33321 2023-06-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33323         * config/riscv/predicates.md: Change INTVAL into UINTVAL.
33325 2023-06-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33327         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_VXRM_ENUM): Add
33328         __RISCV_ prefix.
33329         (DEF_RVV_FRM_ENUM): Ditto.
33331 2023-06-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33333         * config/riscv/riscv-vector-builtins-bases.cc: Change vwadd.wv/vwsub.wv
33334         intrinsic API expander
33335         * config/riscv/vector.md
33336         (@pred_single_widen_<plus_minus:optab><any_extend:su><mode>): Remove it.
33337         (@pred_single_widen_sub<any_extend:su><mode>): New pattern.
33338         (@pred_single_widen_add<any_extend:su><mode>): New pattern.
33340 2023-06-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33342         * config/riscv/autovec.md (vec_perm<mode>): New pattern.
33343         * config/riscv/predicates.md (vector_perm_operand): New predicate.
33344         * config/riscv/riscv-protos.h (enum insn_type): New enum.
33345         (expand_vec_perm): New function.
33346         * config/riscv/riscv-v.cc (const_vec_all_in_range_p): Ditto.
33347         (gen_const_vector_dup): Ditto.
33348         (emit_vlmax_gather_insn): Ditto.
33349         (emit_vlmax_masked_gather_mu_insn): Ditto.
33350         (expand_vec_perm): Ditto.
33352 2023-06-01  Jason Merrill  <jason@redhat.com>
33354         * doc/invoke.texi (-Wpedantic): Improve clarity.
33356 2023-06-01  Uros Bizjak  <ubizjak@gmail.com>
33358         * rtl.h (exp_equiv_p): Change return type from int to bool.
33359         * cse.cc (mention_regs): Change return type from int to bool
33360         and adjust function body accordingly.
33361         (exp_equiv_p): Ditto.
33362         (insert_regs): Ditto. Change "modified" function argument to bool
33363         and update usage accordingly.
33364         (record_jump_cond): Remove always zero "reversed_nonequality"
33365         function argument and update usage accordingly.
33366         (fold_rtx): Change "changed" variable to bool.
33367         (record_jump_equiv): Remove unneeded "reversed_nonequality" variable.
33368         (is_dead_reg): Change return type from int to bool.
33370 2023-06-01  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
33372         * config/xtensa/xtensa.md (adddi3, subdi3):
33373         New RTL generation patterns implemented according to the instruc-
33374         tion idioms described in the Xtensa ISA reference manual (p. 600).
33376 2023-06-01  Roger Sayle  <roger@nextmovesoftware.com>
33377             Uros Bizjak  <ubizjak@gmail.com>
33379         PR target/109973
33380         * config/i386/i386-builtin.def (__builtin_ia32_ptestz128): Use new
33381         CODE_for_sse4_1_ptestzv2di.
33382         (__builtin_ia32_ptestc128): Use new CODE_for_sse4_1_ptestcv2di.
33383         (__builtin_ia32_ptestz256): Use new CODE_for_avx_ptestzv4di.
33384         (__builtin_ia32_ptestc256): Use new CODE_for_avx_ptestcv4di.
33385         * config/i386/i386-expand.cc (ix86_expand_branch): Use CCZmode
33386         when expanding UNSPEC_PTEST to compare against zero.
33387         * config/i386/i386-features.cc (scalar_chain::convert_compare):
33388         Likewise generate CCZmode UNSPEC_PTESTs when converting comparisons.
33389         (general_scalar_chain::convert_insn): Use CCZmode for COMPARE result.
33390         (timode_scalar_chain::convert_insn): Use CCZmode for COMPARE result.
33391         * config/i386/i386-protos.h (ix86_match_ptest_ccmode): Prototype.
33392         * config/i386/i386.cc (ix86_match_ptest_ccmode): New predicate to
33393         check for suitable matching modes for the UNSPEC_PTEST pattern.
33394         * config/i386/sse.md (define_split): When splitting UNSPEC_MOVMSK
33395         to UNSPEC_PTEST, preserve the FLAG_REG mode as CCZ.
33396         (*<sse4_1>_ptest<mode>): Add asterisk to hide define_insn.  Remove
33397         ":CC" mode of FLAGS_REG, instead use ix86_match_ptest_ccmode.
33398         (<sse4_1>_ptestz<mode>): New define_expand to specify CCZ.
33399         (<sse4_1>_ptestc<mode>): New define_expand to specify CCC.
33400         (<sse4_1>_ptest<mode>): A define_expand using CC to preserve the
33401         current behavior.
33402         (*ptest<mode>_and): Specify CCZ to only perform this optimization
33403         when only the Z flag is required.
33405 2023-06-01  Jonathan Wakely  <jwakely@redhat.com>
33407         PR target/109954
33408         * doc/invoke.texi (x86 Options): Fix description of -m32 option.
33410 2023-06-01  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
33412         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<VDMOV:mode>):
33413         Add =r,m and =r,m alternatives.
33414         (load_pair<DREG:mode><DREG2:mode>): Likewise.
33415         (vec_store_pair<DREG:mode><DREG2:mode>): Likewise.
33417 2023-06-01  Pan Li  <pan2.li@intel.com>
33419         * common/config/riscv/riscv-common.cc: Add FP_16 mask to zvfhmin
33420         and zvfh.
33421         * config/riscv/genrvv-type-indexer.cc (valid_type): Allow FP16.
33422         (main): Disable FP16 tuple.
33423         * config/riscv/riscv-opts.h (MASK_VECTOR_ELEN_FP_16): New macro.
33424         (TARGET_VECTOR_ELEN_FP_16): Ditto.
33425         * config/riscv/riscv-vector-builtins.cc (check_required_extensions):
33426         Add FP16.
33427         * config/riscv/riscv-vector-builtins.def (vfloat16mf4_t): New type.
33428         (vfloat16mf2_t): Ditto.
33429         (vfloat16m1_t): Ditto.
33430         (vfloat16m2_t): Ditto.
33431         (vfloat16m4_t): Ditto.
33432         (vfloat16m8_t): Ditto.
33433         * config/riscv/riscv-vector-builtins.h (RVV_REQUIRE_ELEN_FP_16):
33434         New macro.
33435         * config/riscv/riscv-vector-switch.def (ENTRY): Allow FP16
33436         machine mode based on TARGET_VECTOR_ELEN_FP_16.
33438 2023-06-01  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33440         * config/riscv/riscv-vector-builtins.cc (register_frm): New function.
33441         (DEF_RVV_FRM_ENUM): New macro.
33442         (handle_pragma_vector): Add FRM enum
33443         * config/riscv/riscv-vector-builtins.def (DEF_RVV_FRM_ENUM): New macro.
33444         (RNE): Ditto.
33445         (RTZ): Ditto.
33446         (RDN): Ditto.
33447         (RUP): Ditto.
33448         (RMM): Ditto.
33450 2023-05-31  Roger Sayle  <roger@nextmovesoftware.com>
33451             Richard Sandiford  <richard.sandiford@arm.com>
33453         * fold-const-call.cc (fold_const_call_ss) <CFN_BUILT_IN_BSWAP*>:
33454         Update call to wi::bswap.
33455         * simplify-rtx.cc (simplify_const_unary_operation) <case BSWAP>:
33456         Update call to wi::bswap.
33457         * tree-ssa-ccp.cc (evaluate_stmt) <case BUILT_IN_BSWAP*>:
33458         Update calls to wi::bswap.
33459         * wide-int.cc (wide_int_storage::bswap): Remove/rename to...
33460         (wi::bswap_large): New function, with revised API.
33461         * wide-int.h (wi::bswap): New (template) function prototype.
33462         (wide_int_storage::bswap): Remove method.
33463         (sext_large, zext_large): Consistent indentation/line wrapping.
33464         (bswap_large): Prototype helper function containing implementation.
33465         (wi::bswap): New template wrapper around bswap_large.
33467 2023-05-31  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
33469         PR target/99195
33470         * config/aarch64/aarch64-simd.md (<sur>dot_prod<vsi2qi>): Rename to...
33471         (<sur>dot_prod<vsi2qi><vczle><vczbe>): ... This.
33472         (usdot_prod<vsi2qi>): Rename to...
33473         (usdot_prod<vsi2qi><vczle><vczbe>): ... This.
33474         (aarch64_<sur>dot_lane<vsi2qi>): Rename to...
33475         (aarch64_<sur>dot_lane<vsi2qi><vczle><vczbe>): ... This.
33476         (aarch64_<sur>dot_laneq<vsi2qi>): Rename to...
33477         (aarch64_<sur>dot_laneq<vsi2qi><vczle><vczbe>): ... This.
33478         (aarch64_<DOTPROD_I8MM:sur>dot_lane<VB:isquadop><VS:vsi2qi>): Rename to...
33479         (aarch64_<DOTPROD_I8MM:sur>dot_lane<VB:isquadop><VS:vsi2qi><vczle><vczbe>):
33480         ... This.
33482 2023-05-31  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
33484         PR target/99195
33485         * config/aarch64/aarch64-simd.md (aarch64_sq<r>dmulh<mode>): Rename to...
33486         (aarch64_sq<r>dmulh<mode><vczle><vczbe>): ... This.
33487         (aarch64_sq<r>dmulh_n<mode>): Rename to...
33488         (aarch64_sq<r>dmulh_n<mode><vczle><vczbe>): ... This.
33489         (aarch64_sq<r>dmulh_lane<mode>): Rename to...
33490         (aarch64_sq<r>dmulh_lane<mode><vczle><vczbe>): ... This.
33491         (aarch64_sq<r>dmulh_laneq<mode>): Rename to...
33492         (aarch64_sq<r>dmulh_laneq<mode><vczle><vczbe>): ... This.
33493         (aarch64_sqrdml<SQRDMLH_AS:rdma_as>h<mode>): Rename to...
33494         (aarch64_sqrdml<SQRDMLH_AS:rdma_as>h<mode><vczle><vczbe>): ... This.
33495         (aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_lane<mode>): Rename to...
33496         (aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_lane<mode><vczle><vczbe>): ... This.
33497         (aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_laneq<mode>): Rename to...
33498         (aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_laneq<mode><vczle><vczbe>): ... This.
33500 2023-05-31  David Faust  <david.faust@oracle.com>
33502         * btfout.cc (btf_kind_names): New.
33503         (btf_kind_name): New.
33504         (btf_absolute_var_id): New utility function.
33505         (btf_relative_var_id): Likewise.
33506         (btf_relative_func_id): Likewise.
33507         (btf_absolute_datasec_id): Likewise.
33508         (btf_asm_type_ref): New.
33509         (btf_asm_type): Update asm comments and use btf_asm_type_ref ().
33510         (btf_asm_array): Likewise. Accept ctf_container_ref parameter.
33511         (btf_asm_varent): Likewise.
33512         (btf_asm_func_arg): Likewise.
33513         (btf_asm_datasec_entry): Likewise.
33514         (btf_asm_datasec_type): Likewise.
33515         (btf_asm_func_type): Likewise. Add index parameter.
33516         (btf_asm_enum_const): Likewise.
33517         (btf_asm_sou_member): Likewise.
33518         (output_btf_vars): Update btf_asm_* call accordingly.
33519         (output_asm_btf_sou_fields): Likewise.
33520         (output_asm_btf_enum_list): Likewise.
33521         (output_asm_btf_func_args_list): Likewise.
33522         (output_asm_btf_vlen_bytes): Likewise.
33523         (output_btf_func_types): Add ctf_container_ref parameter.
33524         Pass it to btf_asm_func_type.
33525         (output_btf_datasec_types): Update btf_asm_datsec_type call similarly.
33526         (btf_output): Update output_btf_func_types call similarly.
33528 2023-05-31  David Faust  <david.faust@oracle.com>
33530         * btfout.cc (btf_asm_type): Add dedicated cases for BTF_KIND_ARRAY
33531         and BTF_KIND_FWD which do not use the size/type field at all.
33533 2023-05-31  Uros Bizjak  <ubizjak@gmail.com>
33535         * rtl.h (subreg_lowpart_p): Change return type from int to bool.
33536         (active_insn_p): Ditto.
33537         (in_sequence_p): Ditto.
33538         (unshare_all_rtl): Change return type from int to void.
33539         * emit-rtl.h (mem_expr_equal_p): Change return type from int to bool.
33540         * emit-rtl.cc (subreg_lowpart_p): Change return type from int to bool
33541         and adjust function body accordingly.
33542         (mem_expr_equal_p): Ditto.
33543         (unshare_all_rtl): Change return type from int to void
33544         and adjust function body accordingly.
33545         (verify_rtx_sharing): Remove unneeded return.
33546         (active_insn_p): Change return type from int to bool
33547         and adjust function body accordingly.
33548         (in_sequence_p): Ditto.
33550 2023-05-31  Uros Bizjak  <ubizjak@gmail.com>
33552         * rtl.h (true_dependence): Change return type from int to bool.
33553         (canon_true_dependence): Ditto.
33554         (read_dependence): Ditto.
33555         (anti_dependence): Ditto.
33556         (canon_anti_dependence): Ditto.
33557         (output_dependence): Ditto.
33558         (canon_output_dependence): Ditto.
33559         (may_alias_p): Ditto.
33560         * alias.h (alias_sets_conflict_p): Ditto.
33561         (alias_sets_must_conflict_p): Ditto.
33562         (objects_must_conflict_p): Ditto.
33563         (nonoverlapping_memrefs_p): Ditto.
33564         * alias.cc (rtx_equal_for_memref_p): Remove forward declaration.
33565         (record_set): Ditto.
33566         (base_alias_check): Ditto.
33567         (find_base_value): Ditto.
33568         (mems_in_disjoint_alias_sets_p): Ditto.
33569         (get_alias_set_entry): Ditto.
33570         (decl_for_component_ref): Ditto.
33571         (write_dependence_p): Ditto.
33572         (memory_modified_1): Ditto.
33573         (mems_in_disjoint_alias_set_p): Change return type from int to bool
33574         and adjust function body accordingly.
33575         (alias_sets_conflict_p): Ditto.
33576         (alias_sets_must_conflict_p): Ditto.
33577         (objects_must_conflict_p): Ditto.
33578         (rtx_equal_for_memref_p): Ditto.
33579         (base_alias_check): Ditto.
33580         (read_dependence): Ditto.
33581         (nonoverlapping_memrefs_p): Ditto.
33582         (true_dependence_1): Ditto.
33583         (true_dependence): Ditto.
33584         (canon_true_dependence): Ditto.
33585         (write_dependence_p): Ditto.
33586         (anti_dependence): Ditto.
33587         (canon_anti_dependence): Ditto.
33588         (output_dependence): Ditto.
33589         (canon_output_dependence): Ditto.
33590         (may_alias_p): Ditto.
33591         (init_alias_analysis): Change "changed" variable to bool.
33593 2023-05-31  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33595         * config/riscv/autovec.md (<optab><v_double_trunc><mode>2): Change
33596         expand into define_insn_and_split.
33598 2023-05-31  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33600         * config/riscv/vector.md: Remove FRM.
33602 2023-05-31  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33604         * config/riscv/vector.md: Remove FRM.
33606 2023-05-31  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33608         * config/riscv/vector.md: Remove FRM.
33610 2023-05-31  Christophe Lyon  <christophe.lyon@linaro.org>
33612         PR target/110039
33613         * config/aarch64/aarch64.md (aarch64_rev16si2_alt3): New
33614         pattern.
33616 2023-05-31  Richard Biener  <rguenther@suse.de>
33618         PR ipa/109983
33619         PR tree-optimization/109143
33620         * tree-ssa-structalias.cc (struct topo_info): Remove.
33621         (init_topo_info): Likewise.
33622         (free_topo_info): Likewise.
33623         (compute_topo_order): Simplify API, put the component
33624         with ESCAPED last so it's processed first.
33625         (topo_visit): Adjust.
33626         (solve_graph): Likewise.
33628 2023-05-31  Richard Biener  <rguenther@suse.de>
33630         * tree-ssa-structalias.cc (constraint_stats::num_avoided_edges):
33631         New.
33632         (add_graph_edge): Count redundant edges we avoid to create.
33633         (dump_sa_stats): Dump them.
33634         (ipa_pta_execute): Do not dump generating constraints when
33635         we are not dumping them.
33637 2023-05-31  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
33639         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<VDMOV:mode>): Rewrite
33640         output template to avoid explicit switch on which_alternative.
33641         (*aarch64_simd_mov<VQMOV:mode>): Likewise.
33642         (and<mode>3): Likewise.
33643         (ior<mode>3): Likewise.
33644         * config/aarch64/aarch64.md (*mov<mode>_aarch64): Likewise.
33646 2023-05-31  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
33648         * config/xtensa/predicates.md (xtensa_bit_join_operator):
33649         New predicate.
33650         * config/xtensa/xtensa.md (ior_op): Remove.
33651         (*shlrd_reg): Rename from "*shlrd_reg_<code>", and add the
33652         insn_and_split pattern of the same name to express and capture
33653         the bit-combining operation with both sides swapped.
33654         In addition, replace use of code iterator with new operator
33655         predicate.
33656         (*shlrd_const, *shlrd_per_byte):
33657         Likewise regarding the code iterator.
33659 2023-05-31  Cui, Lili  <lili.cui@intel.com>
33661         PR tree-optimization/110038
33662         * params.opt: Add a limit on tree-reassoc-width.
33663         * tree-ssa-reassoc.cc
33664         (rewrite_expr_tree_parallel): Add width limit.
33666 2023-05-31  Pan Li  <pan2.li@intel.com>
33668         * common/config/riscv/riscv-common.cc:
33669         (riscv_implied_info): Add zvfh item.
33670         (riscv_ext_version_table): Ditto.
33671         (riscv_ext_flag_table): Ditto.
33672         * config/riscv/riscv-opts.h (MASK_ZVFH): New macro.
33673         (TARGET_ZVFH): Ditto.
33675 2023-05-30  liuhongt  <hongtao.liu@intel.com>
33677         PR tree-optimization/108804
33678         * tree-vect-patterns.cc (vect_get_range_info): Remove static.
33679         * tree-vect-stmts.cc (vect_create_vectorized_demotion_stmts):
33680         Add new parameter narrow_src_p.
33681         (vectorizable_conversion): Enhance NARROW FLOAT_EXPR
33682         vectorization by truncating to lower precision.
33683         * tree-vectorizer.h (vect_get_range_info): New declare.
33685 2023-05-30  Vladimir N. Makarov  <vmakarov@redhat.com>
33687         * lra-int.h (lra_update_sp_offset): Add the prototype.
33688         * lra.cc (setup_sp_offset): Change the return type.  Use
33689         lra_update_sp_offset.
33690         * lra-eliminations.cc (lra_update_sp_offset): New function.
33691         (lra_process_new_insns): Push the current insn to reprocess if the
33692         input reload changes sp offset.
33694 2023-05-30  Uros Bizjak  <ubizjak@gmail.com>
33696         PR target/110041
33697         * config/i386/i386-expand.cc (ix86_expand_vecop_qihi2):
33698         Fix misleading identation.
33700 2023-05-30  Uros Bizjak  <ubizjak@gmail.com>
33702         * rtl.h (comparison_dominates_p): Change return type from int to bool.
33703         (condjump_p): Ditto.
33704         (any_condjump_p): Ditto.
33705         (any_uncondjump_p): Ditto.
33706         (simplejump_p): Ditto.
33707         (returnjump_p): Ditto.
33708         (eh_returnjump_p): Ditto.
33709         (onlyjump_p): Ditto.
33710         (invert_jump_1): Ditto.
33711         (invert_jump): Ditto.
33712         (rtx_renumbered_equal_p): Ditto.
33713         (redirect_jump_1): Ditto.
33714         (redirect_jump): Ditto.
33715         (condjump_in_parallel_p): Ditto.
33716         * jump.cc (invert_exp_1): Adjust forward declaration.
33717         (comparison_dominates_p): Change return type from int to bool
33718         and adjust function body accordingly.
33719         (simplejump_p): Ditto.
33720         (condjump_p): Ditto.
33721         (condjump_in_parallel_p): Ditto.
33722         (any_uncondjump_p): Ditto.
33723         (any_condjump_p): Ditto.
33724         (returnjump_p): Ditto.
33725         (eh_returnjump_p): Ditto.
33726         (onlyjump_p): Ditto.
33727         (redirect_jump_1): Ditto.
33728         (redirect_jump): Ditto.
33729         (invert_exp_1): Ditto.
33730         (invert_jump_1): Ditto.
33731         (invert_jump): Ditto.
33732         (rtx_renumbered_equal_p): Ditto.
33734 2023-05-30  Andrew Pinski  <apinski@marvell.com>
33736         * fold-const.cc (minmax_from_comparison): Add support for NE_EXPR.
33737         * match.pd ((cond (cmp (convert1? x) c1) (convert2? x) c2) pattern):
33738         Add ne as a possible cmp.
33739         ((a CMP b) ? minmax<a, c> : minmax<b, c> pattern): Likewise.
33741 2023-05-30  Andrew Pinski  <apinski@marvell.com>
33743         * match.pd (`(a CMP CST1) ? max<a,CST2> : a`): New
33744         pattern.
33746 2023-05-30  Roger Sayle  <roger@nextmovesoftware.com>
33748         * simplify-rtx.cc (simplify_binary_operation_1) <AND>: Use wide-int
33749         instead of HWI_COMPUTABLE_MODE_P and UINTVAL in transformation of
33750         (and (extend X) C) as (zero_extend (and X C)), to also optimize
33751         modes wider than HOST_WIDE_INT.
33753 2023-05-30  Roger Sayle  <roger@nextmovesoftware.com>
33755         PR target/107172
33756         * simplify-rtx.cc (simplify_const_relational_operation): Return
33757         early if we have a MODE_CC comparison that isn't a COMPARE against
33758         const0_rtx.
33760 2023-05-30  Robin Dapp  <rdapp@ventanamicro.com>
33762         * config/riscv/riscv.cc (riscv_const_insns): Allow
33763         const_vec_duplicates.
33765 2023-05-30  liuhongt  <hongtao.liu@intel.com>
33767         PR middle-end/108938
33768         * gimple-ssa-store-merging.cc (is_bswap_or_nop_p): New
33769         function, cut from original find_bswap_or_nop function.
33770         (find_bswap_or_nop): Add a new parameter, detect bswap +
33771         rotate and save rotate result in the new parameter.
33772         (bswap_replace): Add a new parameter to indicate rotate and
33773         generate rotate stmt if needed.
33774         (maybe_optimize_vector_constructor): Adjust for new rotate
33775         parameter in the upper 2 functions.
33776         (pass_optimize_bswap::execute): Ditto.
33777         (imm_store_chain_info::output_merged_store): Ditto.
33779 2023-05-30  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
33781         * config/aarch64/aarch64-simd.md (aarch64_<sur>adalp<mode>): Delete.
33782         (aarch64_<su>adalp<mode>): New define_expand.
33783         (*aarch64_<su>adalp<mode><vczle><vczbe>_insn): New define_insn.
33784         (aarch64_<su>addlp<mode>): Convert to define_expand.
33785         (*aarch64_<su>addlp<mode><vczle><vczbe>_insn): New define_insn.
33786         * config/aarch64/iterators.md (UNSPEC_SADDLP, UNSPEC_UADDLP): Delete.
33787         (ADALP): Likewise.
33788         (USADDLP): Likewise.
33789         * config/aarch64/predicates.md (vect_par_cnst_even_or_odd_half): Define.
33791 2023-05-30  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
33793         * config/aarch64/aarch64-builtins.cc (VAR1): Move to after inclusion of
33794         aarch64-builtin-iterators.h.  Add definition to remap shadd, uhadd,
33795         srhadd, urhadd builtin codes for standard optab ones.
33796         * config/aarch64/aarch64-simd.md (<u>avg<mode>3_floor): Rename to...
33797         (<su_optab>avg<mode>3_floor): ... This.  Expand to RTL codes rather than
33798         unspec.
33799         (<u>avg<mode>3_ceil): Rename to...
33800         (<su_optab>avg<mode>3_ceil): ... This.  Expand to RTL codes rather than
33801         unspec.
33802         (aarch64_<su>hsub<mode>): New define_expand.
33803         (aarch64_<sur>h<addsub><mode><vczle><vczbe>): Split into...
33804         (*aarch64_<su>h<ADDSUB:optab><mode><vczle><vczbe>_insn): ... This...
33805         (*aarch64_<su>rhadd<mode><vczle><vczbe>_insn): ... And this.
33807 2023-05-30  Andreas Schwab  <schwab@suse.de>
33809         PR target/110036
33810         * config/riscv/riscv.cc (riscv_asan_shadow_offset): Update to
33811         match libsanitizer.
33813 2023-05-30  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
33815         * config/aarch64/aarch64-modes.def (V16HI, V8SI, V4DI, V2TI): New modes.
33816         * config/aarch64/aarch64-protos.h (aarch64_const_vec_rnd_cst_p):
33817         Declare prototype.
33818         (aarch64_const_vec_rsra_rnd_imm_p): Likewise.
33819         * config/aarch64/aarch64-simd.md (*aarch64_simd_sra<mode>): Rename to...
33820         (aarch64_<sra_op>sra_n<mode>_insn): ... This.
33821         (aarch64_<sra_op>rsra_n<mode>_insn): New define_insn.
33822         (aarch64_<sra_op>sra_n<mode>): New define_expand.
33823         (aarch64_<sra_op>rsra_n<mode>): Likewise.
33824         (aarch64_<sur>sra_n<mode>): Rename to...
33825         (aarch64_<sur>sra_ndi): ... This.
33826         * config/aarch64/aarch64.cc (aarch64_classify_vector_mode): Add
33827         any_target_p argument.
33828         (aarch64_extract_vec_duplicate_wide_int): Define.
33829         (aarch64_const_vec_rsra_rnd_imm_p): Likewise.
33830         (aarch64_const_vec_rnd_cst_p): Likewise.
33831         (aarch64_vector_mode_supported_any_target_p): Likewise.
33832         (TARGET_VECTOR_MODE_SUPPORTED_ANY_TARGET_P): Likewise.
33833         * config/aarch64/iterators.md (UNSPEC_SRSRA, UNSPEC_URSRA): Delete.
33834         (VSRA): Adjust for the above.
33835         (sur): Likewise.
33836         (V2XWIDE): New mode_attr.
33837         (vec_or_offset): Likewise.
33838         (SHIFTEXTEND): Likewise.
33839         * config/aarch64/predicates.md (aarch64_simd_rsra_rnd_imm_vec): New
33840         predicate.
33841         * doc/tm.texi (TARGET_VECTOR_MODE_SUPPORTED_P): Adjust description to
33842         clarify that it applies to current target options.
33843         (TARGET_VECTOR_MODE_SUPPORTED_ANY_TARGET_P): Document.
33844         * doc/tm.texi.in: Regenerate.
33845         * stor-layout.cc (mode_for_vector): Check
33846         vector_mode_supported_any_target_p when iterating through vector modes.
33847         * target.def (TARGET_VECTOR_MODE_SUPPORTED_P): Adjust description to
33848         clarify that it applies to current target options.
33849         (TARGET_VECTOR_MODE_SUPPORTED_ANY_TARGET_P): Define.
33851 2023-05-30  Lili Cui  <lili.cui@intel.com>
33853         PR tree-optimization/98350
33854         * tree-ssa-reassoc.cc
33855         (rewrite_expr_tree_parallel): Rewrite this function.
33856         (rank_ops_for_fma): New.
33857         (reassociate_bb): Handle new function.
33859 2023-05-30  Uros Bizjak  <ubizjak@gmail.com>
33861         * rtl.h (rtx_addr_can_trap_p): Change return type from int to bool.
33862         (rtx_unstable_p): Ditto.
33863         (reg_mentioned_p): Ditto.
33864         (reg_referenced_p): Ditto.
33865         (reg_used_between_p): Ditto.
33866         (reg_set_between_p): Ditto.
33867         (modified_between_p): Ditto.
33868         (no_labels_between_p): Ditto.
33869         (modified_in_p): Ditto.
33870         (reg_set_p): Ditto.
33871         (multiple_sets): Ditto.
33872         (set_noop_p): Ditto.
33873         (noop_move_p): Ditto.
33874         (reg_overlap_mentioned_p): Ditto.
33875         (dead_or_set_p): Ditto.
33876         (dead_or_set_regno_p): Ditto.
33877         (find_reg_fusage): Ditto.
33878         (find_regno_fusage): Ditto.
33879         (side_effects_p): Ditto.
33880         (volatile_refs_p): Ditto.
33881         (volatile_insn_p): Ditto.
33882         (may_trap_p_1): Ditto.
33883         (may_trap_p): Ditto.
33884         (may_trap_or_fault_p): Ditto.
33885         (computed_jump_p): Ditto.
33886         (auto_inc_p): Ditto.
33887         (loc_mentioned_in_p): Ditto.
33888         * rtlanal.cc (computed_jump_p_1): Adjust forward declaration.
33889         (rtx_unstable_p): Change return type from int to bool
33890         and adjust function body accordingly.
33891         (rtx_addr_can_trap_p): Ditto.
33892         (reg_mentioned_p): Ditto.
33893         (no_labels_between_p): Ditto.
33894         (reg_used_between_p): Ditto.
33895         (reg_referenced_p): Ditto.
33896         (reg_set_between_p): Ditto.
33897         (reg_set_p): Ditto.
33898         (modified_between_p): Ditto.
33899         (modified_in_p): Ditto.
33900         (multiple_sets): Ditto.
33901         (set_noop_p): Ditto.
33902         (noop_move_p): Ditto.
33903         (reg_overlap_mentioned_p): Ditto.
33904         (dead_or_set_p): Ditto.
33905         (dead_or_set_regno_p): Ditto.
33906         (find_reg_fusage): Ditto.
33907         (find_regno_fusage): Ditto.
33908         (remove_node_from_insn_list): Ditto.
33909         (volatile_insn_p): Ditto.
33910         (volatile_refs_p): Ditto.
33911         (side_effects_p): Ditto.
33912         (may_trap_p_1): Ditto.
33913         (may_trap_p): Ditto.
33914         (may_trap_or_fault_p): Ditto.
33915         (computed_jump_p): Ditto.
33916         (auto_inc_p): Ditto.
33917         (loc_mentioned_in_p): Ditto.
33918         * combine.cc (can_combine_p): Update indirect function.
33920 2023-05-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33922         * config/riscv/autovec.md (<optab><mode><vconvert>2): New pattern.
33923         * config/riscv/iterators.md: New attribute.
33924         * config/riscv/vector-iterators.md: New attribute.
33926 2023-05-30  From: Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33928         * config/riscv/riscv.md: Fix signed and unsigned comparison
33929         warning.
33931 2023-05-30  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
33933         * config/riscv/autovec.md (fnma<mode>4): New pattern.
33934         (*fnma<mode>): Ditto.
33936 2023-05-29  Die Li  <lidie@eswincomputing.com>
33938         * config/riscv/riscv.cc (riscv_expand_conditional_move_onesided):
33939         Delete.
33940         (riscv_expand_conditional_move):  Reuse the TARGET_SFB_ALU expand
33941         process for TARGET_XTHEADCONDMOV
33943 2023-05-29  Uros Bizjak  <ubizjak@gmail.com>
33945         PR target/110021
33946         * config/i386/i386-expand.cc (ix86_expand_vecop_qihi2): Also require
33947         TARGET_AVX512BW to generate truncv16hiv16qi2.
33949 2023-05-29  Jivan Hakobyan  <jivanhakobyan9@gmail.com>
33951         * config/riscv/riscv.md (and<mode>3): New expander.
33952         (*and<mode>3) New pattern.
33953         * config/riscv/predicates.md (arith_operand_or_mode_mask): New
33954         predicate.
33956 2023-05-29  Pan Li  <pan2.li@intel.com>
33958         * config/riscv/riscv-v.cc (emit_vlmax_insn): Remove unnecessary
33959         comments and rename local variables.
33960         (emit_nonvlmax_insn): Diito.
33961         (emit_vlmax_merge_insn): Ditto.
33962         (emit_vlmax_cmp_insn): Ditto.
33963         (emit_vlmax_cmp_mu_insn): Ditto.
33964         (emit_scalar_move_insn): Ditto.
33966 2023-05-29  Pan Li  <pan2.li@intel.com>
33968         * config/riscv/riscv-v.cc (emit_vlmax_insn): Eliminate the
33969         magic number.
33970         (emit_nonvlmax_insn): Ditto.
33971         (emit_vlmax_merge_insn): Ditto.
33972         (emit_vlmax_cmp_insn): Ditto.
33973         (emit_vlmax_cmp_mu_insn): Ditto.
33974         (expand_vec_series): Ditto.
33976 2023-05-29  Pan Li  <pan2.li@intel.com>
33978         * config/riscv/riscv-protos.h (enum insn_type): New type.
33979         * config/riscv/riscv-v.cc (RVV_INSN_OPERANDS_MAX): New macro.
33980         (rvv_builder::can_duplicate_repeating_sequence_p): Align the referenced
33981         class member.
33982         (rvv_builder::get_merged_repeating_sequence): Ditto.
33983         (rvv_builder::repeating_sequence_use_merge_profitable_p): New function
33984         to evaluate the optimization cost.
33985         (rvv_builder::get_merge_scalar_mask): New function to get the merge
33986         mask.
33987         (emit_scalar_move_insn): New function to emit vmv.s.x.
33988         (emit_vlmax_integer_move_insn): New function to emit vlmax vmv.v.x.
33989         (emit_nonvlmax_integer_move_insn): New function to emit nonvlmax
33990         vmv.v.x.
33991         (get_repeating_sequence_dup_machine_mode): New function to get the dup
33992         machine mode.
33993         (expand_vector_init_merge_repeating_sequence): New function to perform
33994         the optimization.
33995         (expand_vec_init): Add this vector init optimization.
33996         * config/riscv/riscv.h (BITS_PER_WORD): New macro.
33998 2023-05-29  Eric Botcazou  <ebotcazou@adacore.com>
34000         * tree-ssa-loop-manip.cc (create_iv): Try harder to find a SLOC to
34001         put onto the increment when it is inserted after the position.
34003 2023-05-29  Eric Botcazou  <ebotcazou@adacore.com>
34005         * match.pd ((T)P - (T)(P + A) -> -(T) A): Avoid artificial overflow
34006         on constants.
34008 2023-05-29  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34010         * config/riscv/riscv-vsetvl.cc (source_equal_p): Fix ICE.
34012 2023-05-29  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34014         * config/riscv/autovec.md (fma<mode>4): New pattern.
34015         (*fma<mode>): Ditto.
34016         * config/riscv/riscv-protos.h (enum insn_type): New enum.
34017         (emit_vlmax_ternary_insn): New function.
34018         * config/riscv/riscv-v.cc (emit_vlmax_ternary_insn): Ditto.
34020 2023-05-29  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34022         * config/riscv/vector.md: Fix vimuladd instruction bug.
34024 2023-05-29  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34026         * config/riscv/riscv.cc (global_state_unknown_p): New function.
34027         (riscv_mode_after): Fix incorrect VXM.
34029 2023-05-29  Pan Li  <pan2.li@intel.com>
34031         * common/config/riscv/riscv-common.cc:
34032         (riscv_implied_info): Add zvfhmin item.
34033         (riscv_ext_version_table): Ditto.
34034         (riscv_ext_flag_table): Ditto.
34035         * config/riscv/riscv-opts.h (MASK_ZVFHMIN): New macro.
34036         (TARGET_ZFHMIN): Align indent.
34037         (TARGET_ZFH): Ditto.
34038         (TARGET_ZVFHMIN): New macro.
34040 2023-05-27  liuhongt  <hongtao.liu@intel.com>
34042         PR target/100711
34043         * config/i386/sse.md (*andnot<mode>3): Extend below splitter
34044         to VI_AVX2 to cover more modes.
34046 2023-05-27  liuhongt  <hongtao.liu@intel.com>
34048         * config/i386/x86-tune.def (X86_TUNE_AVOID_FALSE_DEP_FOR_BMI):
34049         Remove ATOM and ICELAKE(and later) core processors.
34051 2023-05-26  Robin Dapp  <rdapp@ventanamicro.com>
34053         * config/riscv/autovec.md (<optab><mode>2): Add vneg/vnot.
34054         (abs<mode>2): Add.
34055         * config/riscv/riscv-protos.h (emit_vlmax_masked_mu_insn):
34056         Declare.
34057         * config/riscv/riscv-v.cc (emit_vlmax_masked_mu_insn): New
34058         function.
34060 2023-05-26  Robin Dapp  <rdapp@ventanamicro.com>
34061             Juzhe Zhong  <juzhe.zhong@rivai.ai>
34063         * config/riscv/autovec.md (<optab><v_double_trunc><mode>2): New
34064         expander.
34065         (<optab><v_quad_trunc><mode>2): Dito.
34066         (<optab><v_oct_trunc><mode>2): Dito.
34067         (trunc<mode><v_double_trunc>2): Dito.
34068         (trunc<mode><v_quad_trunc>2): Dito.
34069         (trunc<mode><v_oct_trunc>2): Dito.
34070         * config/riscv/riscv-protos.h (vectorize_related_mode): Define.
34071         (autovectorize_vector_modes): Define.
34072         * config/riscv/riscv-v.cc (vectorize_related_mode): Implement
34073         hook.
34074         (autovectorize_vector_modes): Implement hook.
34075         * config/riscv/riscv.cc (riscv_autovectorize_vector_modes):
34076         Implement target hook.
34077         (riscv_vectorize_related_mode): Implement target hook.
34078         (TARGET_VECTORIZE_AUTOVECTORIZE_VECTOR_MODES): Define.
34079         (TARGET_VECTORIZE_RELATED_MODE): Define.
34080         * config/riscv/vector-iterators.md: Add lowercase versions of
34081         mode_attr iterators.
34083 2023-05-26  Andrew Stubbs  <ams@codesourcery.com>
34084             Tobias Burnus  <tobias@codesourcery.com>
34086         * config/gcn/gcn-hsa.h (XNACKOPT): New macro.
34087         (ASM_SPEC): Use XNACKOPT.
34088         * config/gcn/gcn-opts.h (enum sram_ecc_type): Rename to ...
34089         (enum hsaco_attr_type): ... this, and generalize the names.
34090         (TARGET_XNACK): New macro.
34091         * config/gcn/gcn.cc (gcn_option_override): Update to sorry for all
34092         but -mxnack=off.
34093         (output_file_start): Update xnack handling.
34094         (gcn_hsa_declare_function_name): Use TARGET_XNACK.
34095         * config/gcn/gcn.opt (-mxnack): Add the "on/off/any" syntax.
34096         (sram_ecc_type): Rename to ...
34097         (hsaco_attr_type: ... this.)
34098         * config/gcn/mkoffload.cc (SET_XNACK_ANY): New macro.
34099         (TEST_XNACK): Delete.
34100         (TEST_XNACK_ANY): New macro.
34101         (TEST_XNACK_ON): New macro.
34102         (main): Support the new -mxnack=on/off/any syntax.
34103         * doc/invoke.texi (-mxnack): Update for new syntax.
34105 2023-05-26  Andrew Pinski  <apinski@marvell.com>
34107         * genmatch.cc (emit_debug_printf): New function.
34108         (dt_simplify::gen_1): Emit printf into the code
34109         before the `return true` or returning the folded result
34110         instead of emitting it always.
34112 2023-05-26  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
34114         * config/xtensa/xtensa-protos.h
34115         (xtensa_expand_block_set_unrolled_loop,
34116         xtensa_expand_block_set_small_loop): Remove.
34117         (xtensa_expand_block_set): New prototype.
34118         * config/xtensa/xtensa.cc
34119         (xtensa_expand_block_set_libcall): New subfunction.
34120         (xtensa_expand_block_set_unrolled_loop,
34121         xtensa_expand_block_set_small_loop): Rewrite as subfunctions.
34122         (xtensa_expand_block_set): New function that calls the above
34123         subfunctions.
34124         * config/xtensa/xtensa.md (memsetsi): Change to invoke only
34125         xtensa_expand_block_set().
34127 2023-05-26  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
34129         * config/xtensa/xtensa-protos.h (xtensa_m1_or_1_thru_15):
34130         New prototype.
34131         * config/xtensa/xtensa.cc (xtensa_m1_or_1_thru_15):
34132         New function.
34133         * config/xtensa/constraints.md (O):
34134         Change to use the above function.
34135         * config/xtensa/xtensa.md (*subsi3_from_const):
34136         New insn_and_split pattern.
34138 2023-05-26  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
34140         * config/xtensa/xtensa.md (*extzvsi-1bit_ashlsi3):
34141         Retract excessive line folding, and correct the value of
34142         the "length" insn attribute related to TARGET_DENSITY.
34143         (*extzvsi-1bit_addsubx): Ditto.
34145 2023-05-26  Uros Bizjak  <ubizjak@gmail.com>
34147         * config/i386/i386-expand.cc (ix86_expand_vecop_qihi):
34148         Do not disable call to ix86_expand_vecop_qihi2.
34150 2023-05-26  liuhongt  <hongtao.liu@intel.com>
34152         PR target/109610
34153         PR target/109858
34154         * ira-costs.cc (scan_one_insn): Only use NO_REGS in cost
34155         calculation when !hard_regno_mode_ok for GENERAL_REGS and
34156         mode, otherwise still use GENERAL_REGS.
34158 2023-05-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34160         * config/riscv/riscv.cc (vector_zero_call_used_regs): Add
34161         explict VL and drop VL in ops.
34163 2023-05-25  Jin Ma  <jinma@linux.alibaba.com>
34165         * sched-deps.cc (sched_macro_fuse_insns): Insns should not be fusion
34166         in different BB blocks.
34168 2023-05-25  Uros Bizjak  <ubizjak@gmail.com>
34170         * config/i386/i386-expand.cc (ix86_expand_vecop_qihi2):
34171         Rewrite to expand to 2x-wider (e.g. V16QI -> V16HImode)
34172         instructions when available.  Emulate truncation via
34173         ix86_expand_vec_perm_const_1 when native truncate insn
34174         is not available.
34175         (ix86_expand_vecop_qihi_partial) <case MULT>: Use pmovzx
34176         when available.  Trivially rename some variables.
34177         (ix86_expand_vecop_qihi): Unconditionally call ix86_expand_vecop_qihi2.
34178         * config/i386/i386.cc (ix86_multiplication_cost): Rewrite cost
34179         calculation of V*QImode emulations to account for generation of
34180         2x-wider mode instructions.
34181         (ix86_shift_rotate_cost): Update cost calculation of V*QImode
34182         emulations to account for generation of 2x-wider mode instructions.
34184 2023-05-25  Georg-Johann Lay  <avr@gjlay.de>
34186         PR target/104327
34187         * config/avr/avr.cc (avr_can_inline_p): New static function.
34188         (TARGET_CAN_INLINE_P): Define to that function.
34190 2023-05-25  Georg-Johann Lay  <avr@gjlay.de>
34192         PR target/82931
34193         * config/avr/avr.md (*movbitqi.0): Rename to *movbit<mode>.0-6.
34194         Handle any bit position and use mode QISI.
34195         * config/avr/avr.cc (avr_rtx_costs_1) [IOR]: Return a cost
34196         of 2 insns for bit-transfer of respective style.
34198 2023-05-25  Christophe Lyon  <christophe.lyon@linaro.org>
34200         * config/arm/iterators.md (MVE_6): Remove.
34201         * config/arm/mve.md: Replace MVE_6 with MVE_5.
34203 2023-05-25  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
34204             Richard Sandiford  <richard.sandiford@arm.com>
34206         * tree-vect-loop-manip.cc (vect_adjust_loop_lens_control): New
34207         function.
34208         (vect_set_loop_controls_directly): Add decrement IV support.
34209         (vect_set_loop_condition_partial_vectors): Ditto.
34210         * tree-vect-loop.cc (_loop_vec_info::_loop_vec_info): New
34211         variable.
34212         * tree-vectorizer.h (LOOP_VINFO_USING_DECREMENTING_IV_P): New
34213         macro.
34215 2023-05-25  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
34217         PR target/99195
34218         * config/aarch64/aarch64-simd.md (aarch64_fcadd<rot><mode>): Rename to...
34219         (aarch64_fcadd<rot><mode><vczle><vczbe>): ... This.
34220         Fix canonicalization of PLUS operands.
34221         (aarch64_fcmla<rot><mode>): Rename to...
34222         (aarch64_fcmla<rot><mode><vczle><vczbe>): ... This.
34223         Fix canonicalization of PLUS operands.
34224         (aarch64_fcmla_lane<rot><mode>): Rename to...
34225         (aarch64_fcmla_lane<rot><mode><vczle><vczbe>): ... This.
34226         Fix canonicalization of PLUS operands.
34227         (aarch64_fcmla_laneq<rot>v4hf): Rename to...
34228         (aarch64_fcmla_laneq<rot>v4hf<vczle><vczbe>): ... This.
34229         Fix canonicalization of PLUS operands.
34230         (aarch64_fcmlaq_lane<rot><mode>): Fix canonicalization of PLUS operands.
34232 2023-05-25  Chris Sidebottom  <chris.sidebottom@arm.com>
34234         * config/arm/arm.md (rbitsi2): Rename to...
34235         (arm_rbit): ... This.
34236         (ctzsi2): Adjust for the above.
34237         (arm_rev16si2): Convert to define_expand.
34238         (arm_rev16si2_alt1): New pattern.
34239         (arm_rev16si2_alt): Rename to...
34240         (*arm_rev16si2_alt2): ... This.
34241         * config/arm/arm_acle.h (__ror, __rorl, __rorll, __clz, __clzl, __clzll,
34242         __cls, __clsl, __clsll, __revsh, __rev, __revl, __revll, __rev16,
34243         __rev16l, __rev16ll, __rbit, __rbitl, __rbitll): Define intrinsics.
34244         * config/arm/arm_acle_builtins.def (rbit, rev16si2): Define builtins.
34246 2023-05-25  Alex Coplan  <alex.coplan@arm.com>
34248         PR target/109800
34249         * config/arm/arm.md (movdf): Generate temporary pseudo in DImode
34250         instead of DFmode.
34251         * config/arm/vfp.md (no_literal_pool_df_immediate): Rather than punning an
34252         lvalue DFmode pseudo into DImode, use a DImode pseudo and pun it into
34253         DFmode as an rvalue.
34255 2023-05-25  Richard Biener  <rguenther@suse.de>
34257         PR target/109955
34258         * tree-vect-stmts.cc (vectorizable_condition): For
34259         embedded comparisons also handle the case when the target
34260         only provides vec_cmp and vcond_mask.
34262 2023-05-25  Claudiu Zissulescu  <claziss@gmail.com>
34264         * config/arc/arc.cc (arc_call_tls_get_addr): Simplify access using
34265         TLS Local Dynamic.
34267 2023-05-25  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
34269         * config/aarch64/aarch64.cc (scalar_move_insn_p): New function.
34270         (seq_cost_ignoring_scalar_moves): Likewise.
34271         (aarch64_expand_vector_init): Call seq_cost_ignoring_scalar_moves.
34273 2023-05-25  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
34275         * config/aarch64/arm_neon.h (vcage_f64): Reimplement with builtins.
34276         (vcage_f32): Likewise.
34277         (vcages_f32): Likewise.
34278         (vcageq_f32): Likewise.
34279         (vcaged_f64): Likewise.
34280         (vcageq_f64): Likewise.
34281         (vcagts_f32): Likewise.
34282         (vcagt_f32): Likewise.
34283         (vcagt_f64): Likewise.
34284         (vcagtq_f32): Likewise.
34285         (vcagtd_f64): Likewise.
34286         (vcagtq_f64): Likewise.
34287         (vcale_f32): Likewise.
34288         (vcale_f64): Likewise.
34289         (vcaled_f64): Likewise.
34290         (vcales_f32): Likewise.
34291         (vcaleq_f32): Likewise.
34292         (vcaleq_f64): Likewise.
34293         (vcalt_f32): Likewise.
34294         (vcalt_f64): Likewise.
34295         (vcaltd_f64): Likewise.
34296         (vcaltq_f32): Likewise.
34297         (vcaltq_f64): Likewise.
34298         (vcalts_f32): Likewise.
34300 2023-05-25  Hu, Lin1  <lin1.hu@intel.com>
34302         PR target/109173
34303         PR target/109174
34304         * config/i386/avx512bwintrin.h (_mm512_srli_epi16): Change type from
34305         int to const int or const int to const unsigned int.
34306         (_mm512_mask_srli_epi16): Ditto.
34307         (_mm512_slli_epi16): Ditto.
34308         (_mm512_mask_slli_epi16): Ditto.
34309         (_mm512_maskz_slli_epi16): Ditto.
34310         (_mm512_srai_epi16): Ditto.
34311         (_mm512_mask_srai_epi16): Ditto.
34312         (_mm512_maskz_srai_epi16): Ditto.
34313         * config/i386/avx512fintrin.h (_mm512_slli_epi64): Ditto.
34314         (_mm512_mask_slli_epi64): Ditto.
34315         (_mm512_maskz_slli_epi64): Ditto.
34316         (_mm512_srli_epi64): Ditto.
34317         (_mm512_mask_srli_epi64): Ditto.
34318         (_mm512_maskz_srli_epi64): Ditto.
34319         (_mm512_srai_epi64): Ditto.
34320         (_mm512_mask_srai_epi64): Ditto.
34321         (_mm512_maskz_srai_epi64): Ditto.
34322         (_mm512_slli_epi32): Ditto.
34323         (_mm512_mask_slli_epi32): Ditto.
34324         (_mm512_maskz_slli_epi32): Ditto.
34325         (_mm512_srli_epi32): Ditto.
34326         (_mm512_mask_srli_epi32): Ditto.
34327         (_mm512_maskz_srli_epi32): Ditto.
34328         (_mm512_srai_epi32): Ditto.
34329         (_mm512_mask_srai_epi32): Ditto.
34330         (_mm512_maskz_srai_epi32): Ditto.
34331         * config/i386/avx512vlbwintrin.h (_mm256_mask_srai_epi16): Ditto.
34332         (_mm256_maskz_srai_epi16): Ditto.
34333         (_mm_mask_srai_epi16): Ditto.
34334         (_mm_maskz_srai_epi16): Ditto.
34335         (_mm256_mask_slli_epi16): Ditto.
34336         (_mm256_maskz_slli_epi16): Ditto.
34337         (_mm_mask_slli_epi16): Ditto.
34338         (_mm_maskz_slli_epi16): Ditto.
34339         (_mm_maskz_srli_epi16): Ditto.
34340         * config/i386/avx512vlintrin.h (_mm256_mask_srli_epi32): Ditto.
34341         (_mm256_maskz_srli_epi32): Ditto.
34342         (_mm_mask_srli_epi32): Ditto.
34343         (_mm_maskz_srli_epi32): Ditto.
34344         (_mm256_mask_srli_epi64): Ditto.
34345         (_mm256_maskz_srli_epi64): Ditto.
34346         (_mm_mask_srli_epi64): Ditto.
34347         (_mm_maskz_srli_epi64): Ditto.
34348         (_mm256_mask_srai_epi32): Ditto.
34349         (_mm256_maskz_srai_epi32): Ditto.
34350         (_mm_mask_srai_epi32): Ditto.
34351         (_mm_maskz_srai_epi32): Ditto.
34352         (_mm256_srai_epi64): Ditto.
34353         (_mm256_mask_srai_epi64): Ditto.
34354         (_mm256_maskz_srai_epi64): Ditto.
34355         (_mm_srai_epi64): Ditto.
34356         (_mm_mask_srai_epi64): Ditto.
34357         (_mm_maskz_srai_epi64): Ditto.
34358         (_mm_mask_slli_epi32): Ditto.
34359         (_mm_maskz_slli_epi32): Ditto.
34360         (_mm_mask_slli_epi64): Ditto.
34361         (_mm_maskz_slli_epi64): Ditto.
34362         (_mm256_mask_slli_epi32): Ditto.
34363         (_mm256_maskz_slli_epi32): Ditto.
34364         (_mm256_mask_slli_epi64): Ditto.
34365         (_mm256_maskz_slli_epi64): Ditto.
34367 2023-05-25  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34369         * config/riscv/vector.md: Remove FRM_REGNUM dependency in rtz
34370         instructions.
34372 2023-05-25  Aldy Hernandez  <aldyh@redhat.com>
34374         * data-streamer-in.cc (streamer_read_value_range): Handle NANs.
34375         * data-streamer-out.cc (streamer_write_vrange): Same.
34376         * value-range.h (class vrange): Make streamer_write_vrange a friend.
34378 2023-05-25  Aldy Hernandez  <aldyh@redhat.com>
34380         * value-query.cc (range_query::get_tree_range): Set NAN directly
34381         if necessary.
34382         * value-range.cc (frange::set): Assert that bounds are not NAN.
34384 2023-05-25  Aldy Hernandez  <aldyh@redhat.com>
34386         * value-range.cc (add_vrange): Handle known NANs.
34388 2023-05-25  Aldy Hernandez  <aldyh@redhat.com>
34390         * value-range.h (frange::set_nan): New.
34392 2023-05-25  Alexandre Oliva  <oliva@adacore.com>
34394         PR target/100106
34395         * emit-rtl.cc (validate_subreg): Reject a SUBREG of a MEM that
34396         requires stricter alignment than MEM's.
34398 2023-05-24  Andrew MacLeod  <amacleod@redhat.com>
34400         PR tree-optimization/107822
34401         PR tree-optimization/107986
34402         * Makefile.in (OBJS): Add gimple-range-phi.o.
34403         * gimple-range-cache.h (ranger_cache::m_estimate): New
34404         phi_analyzer pointer member.
34405         * gimple-range-fold.cc (fold_using_range::range_of_phi): Use
34406         phi_analyzer if no loop info is available.
34407         * gimple-range-phi.cc: New file.
34408         * gimple-range-phi.h: New file.
34409         * tree-vrp.cc (execute_ranger_vrp): Utililze a phi_analyzer.
34411 2023-05-24  Andrew MacLeod  <amacleod@redhat.com>
34413         * gimple-range-fold.cc (fur_list::fur_list): Add range_query param
34414         to contructors.
34415         (fold_range): Add range_query parameter.
34416         (fur_relation::fur_relation): New.
34417         (fur_relation::trio): New.
34418         (fur_relation::register_relation): New.
34419         (fold_relations): New.
34420         * gimple-range-fold.h (fold_range): Adjust prototypes.
34421         (fold_relations): New.
34423 2023-05-24  Andrew MacLeod  <amacleod@redhat.com>
34425         * gimple-range-cache.cc (ssa_cache::range_of_expr): New.
34426         * gimple-range-cache.h (class ssa_cache): Inherit from range_query.
34427         (ranger_cache::const_query): New.
34428         * gimple-range.cc (gimple_ranger::const_query): New.
34429         * gimple-range.h (gimple_ranger::const_query): New prototype.
34431 2023-05-24  Andrew MacLeod  <amacleod@redhat.com>
34433         * gimple-range-cache.cc (ssa_cache::dump): Use get_range.
34434         (ssa_cache::dump_range_query): Delete.
34435         (ssa_lazy_cache::dump_range_query): Delete.
34436         (ssa_lazy_cache::get_range): Move from header file.
34437         (ssa_lazy_cache::clear_range): ditto.
34438         (ssa_lazy_cache::clear): Ditto.
34439         * gimple-range-cache.h (class ssa_cache): Virtualize.
34440         (class ssa_lazy_cache): Inherit and virtualize.
34442 2023-05-24  Aldy Hernandez  <aldyh@redhat.com>
34444         * value-range.h (vrange::kind): Remove.
34446 2023-05-24  Roger Sayle  <roger@nextmovesoftware.com>
34448         PR middle-end/109840
34449         * match.pd <popcount optimizations>: Preserve zero-extension when
34450         optimizing popcount((T)bswap(x)) and popcount((T)rotate(x,y)) as
34451         popcount((T)x), so the popcount's argument keeps the same type.
34452         <parity optimizations>:  Likewise preserve extensions when
34453         simplifying parity((T)bswap(x)) and parity((T)rotate(x,y)) as
34454         parity((T)x), so that the parity's argument type is the same.
34456 2023-05-24  Aldy Hernandez  <aldyh@redhat.com>
34458         * ipa-cp.cc (ipa_value_range_from_jfunc): Use new ipa_vr API.
34459         (ipcp_store_vr_results): Same.
34460         * ipa-prop.cc (ipa_vr::ipa_vr): New.
34461         (ipa_vr::get_vrange): New.
34462         (ipa_vr::set_unknown): New.
34463         (ipa_vr::streamer_read): New.
34464         (ipa_vr::streamer_write): New.
34465         (write_ipcp_transformation_info): Use new ipa_vr API.
34466         (read_ipcp_transformation_info): Same.
34467         (ipa_vr::nonzero_p): Delete.
34468         (ipcp_update_vr): Use new ipa_vr API.
34469         * ipa-prop.h (class ipa_vr): Provide an API and hide internals.
34470         * ipa-sra.cc (zap_useless_ipcp_results): Use new ipa_vr API.
34472 2023-05-24  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
34474         * config/mcore/mcore.cc (output_inline_const) Make buffer smaller to
34475         silence overflow warnings later on.
34477 2023-05-24  Uros Bizjak  <ubizjak@gmail.com>
34479         * config/i386/i386-expand.cc (ix86_expand_vecop_qihi2):
34480         Remove handling of V8QImode.
34481         * config/i386/mmx.md (v<insn>v8qi3): Move from sse.md.
34482         Call ix86_expand_vecop_qihi_partial.  Enable for TARGET_MMX_WITH_SSE.
34483         (v<insn>v4qi3): Ditto.
34484         * config/i386/sse.md (v<insn>v8qi3): Remove.
34486 2023-05-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
34488         PR target/99195
34489         * config/aarch64/aarch64-simd.md (aarch64_simd_lshr<mode>): Rename to...
34490         (aarch64_simd_lshr<mode><vczle><vczbe>): ... This.
34491         (aarch64_simd_ashr<mode>): Rename to...
34492         (aarch64_simd_ashr<mode><vczle><vczbe>): ... This.
34493         (aarch64_simd_imm_shl<mode>): Rename to...
34494         (aarch64_simd_imm_shl<mode><vczle><vczbe>): ... This.
34495         (aarch64_simd_reg_sshl<mode>): Rename to...
34496         (aarch64_simd_reg_sshl<mode><vczle><vczbe>): ... This.
34497         (aarch64_simd_reg_shl<mode>_unsigned): Rename to...
34498         (aarch64_simd_reg_shl<mode>_unsigned<vczle><vczbe>): ... This.
34499         (aarch64_simd_reg_shl<mode>_signed): Rename to...
34500         (aarch64_simd_reg_shl<mode>_signed<vczle><vczbe>): ... This.
34501         (vec_shr_<mode>): Rename to...
34502         (vec_shr_<mode><vczle><vczbe>): ... This.
34503         (aarch64_<sur>shl<mode>): Rename to...
34504         (aarch64_<sur>shl<mode><vczle><vczbe>): ... This.
34505         (aarch64_<sur>q<r>shl<mode>): Rename to...
34506         (aarch64_<sur>q<r>shl<mode><vczle><vczbe>): ... This.
34508 2023-05-24  Richard Biener  <rguenther@suse.de>
34510         PR target/109944
34511         * config/i386/i386-expand.cc (ix86_expand_vector_init_general):
34512         Perform final vector composition using
34513         ix86_expand_vector_init_general instead of setting
34514         the highpart and lowpart which causes spilling.
34516 2023-05-24  Andrew MacLeod  <amacleod@redhat.com>
34518         PR tree-optimization/109695
34519         * gimple-range-cache.cc (ranger_cache::get_global_range): Add
34520         changed param.
34521         * gimple-range-cache.h (ranger_cache::get_global_range): Ditto.
34522         * gimple-range.cc (gimple_ranger::range_of_stmt): Pass changed
34523         flag to set_global_range.
34524         (gimple_ranger::prefill_stmt_dependencies): Ditto.
34526 2023-05-24  Andrew MacLeod  <amacleod@redhat.com>
34528         PR tree-optimization/109695
34529         * gimple-range-cache.cc (temporal_cache::temporal_value): Return
34530         a positive int.
34531         (temporal_cache::current_p): Check always_current method.
34532         (temporal_cache::set_always_current): Add param and set value
34533         appropriately.
34534         (temporal_cache::always_current_p): New.
34535         (ranger_cache::get_global_range): Adjust.
34536         (ranger_cache::set_global_range): set always current first.
34538 2023-05-24  Andrew MacLeod  <amacleod@redhat.com>
34540         PR tree-optimization/109695
34541         * gimple-range-cache.cc (ranger_cache::get_global_range): Call
34542         fold_range with global query to choose an initial value.
34544 2023-05-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34546         * config/riscv/riscv-protos.h (enum frm_field_enum): Add FRM_
34547         prefix.
34549 2023-05-24  Richard Biener  <rguenther@suse.de>
34551         PR tree-optimization/109849
34552         * tree-ssa-pre.cc (do_hoist_insertion): Do not intersect
34553         expressions but take the first sets.
34555 2023-05-24  Gaius Mulley  <gaiusmod2@gmail.com>
34557         PR modula2/109952
34558         * doc/gm2.texi (High procedure function): New node.
34559         (Using): New menu entry for High procedure function.
34561 2023-05-24  Richard Sandiford  <richard.sandiford@arm.com>
34563         PR rtl-optimization/109940
34564         * early-remat.cc (postorder_index): Rename to...
34565         (rpo_index): ...this.
34566         (compare_candidates): Sort by decreasing rpo_index rather than
34567         increasing postorder_index.
34568         (early_remat::sort_candidates): Calculate the forward RPO from
34569         DF_FORWARD.
34570         (early_remat::local_phase): Follow forward RPO using DF_FORWARD,
34571         rather than DF_BACKWARD in reverse.
34573 2023-05-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
34575         PR target/109939
34576         * config/arm/arm-builtins.cc (SAT_BINOP_UNSIGNED_IMM_QUALIFIERS): Use
34577         qualifier_none for the return operand.
34579 2023-05-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34581         * config/riscv/autovec.md (<optab><mode>3): New pattern.
34582         (one_cmpl<mode>2): Ditto.
34583         (*<optab>not<mode>): Ditto.
34584         (*n<optab><mode>): Ditto.
34585         * config/riscv/riscv-v.cc (expand_vec_cmp_float): Change to
34586         one_cmpl.
34588 2023-05-24  Kewen Lin  <linkw@linux.ibm.com>
34590         * tree-vect-slp.cc (vect_transform_slp_perm_load_1): Adjust the
34591         calculation on n_perms by considering nvectors_per_build.
34593 2023-05-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34594             Richard Sandiford  <richard.sandiford@arm.com>
34596         * config/riscv/autovec.md (@vcond_mask_<mode><vm>): New pattern.
34597         (vec_cmp<mode><vm>): New pattern.
34598         (vec_cmpu<mode><vm>): New pattern.
34599         (vcond<V:mode><VI:mode>): New pattern.
34600         (vcondu<V:mode><VI:mode>): New pattern.
34601         * config/riscv/riscv-protos.h (enum insn_type): Add new enum.
34602         (emit_vlmax_merge_insn): New function.
34603         (emit_vlmax_cmp_insn): Ditto.
34604         (emit_vlmax_cmp_mu_insn): Ditto.
34605         (expand_vec_cmp): Ditto.
34606         (expand_vec_cmp_float): Ditto.
34607         (expand_vcond): Ditto.
34608         * config/riscv/riscv-v.cc (emit_vlmax_merge_insn): Ditto.
34609         (emit_vlmax_cmp_insn): Ditto.
34610         (emit_vlmax_cmp_mu_insn): Ditto.
34611         (get_cmp_insn_code): Ditto.
34612         (expand_vec_cmp): Ditto.
34613         (expand_vec_cmp_float): Ditto.
34614         (expand_vcond): Ditto.
34616 2023-05-24  Pan Li  <pan2.li@intel.com>
34618         * config/riscv/genrvv-type-indexer.cc (main): Add
34619         unsigned_eew*_lmul1_interpret for indexer.
34620         * config/riscv/riscv-vector-builtins-functions.def (vreinterpret):
34621         Register vuint*m1_t interpret function.
34622         * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_UNSIGNED_EEW8_LMUL1_INTERPRET_OPS):
34623         New macro for vuint8m1_t.
34624         (DEF_RVV_UNSIGNED_EEW16_LMUL1_INTERPRET_OPS): Likewise.
34625         (DEF_RVV_UNSIGNED_EEW32_LMUL1_INTERPRET_OPS): Likewise.
34626         (DEF_RVV_UNSIGNED_EEW64_LMUL1_INTERPRET_OPS): Likewise.
34627         (vbool1_t): Add to unsigned_eew*_interpret_ops.
34628         (vbool2_t): Likewise.
34629         (vbool4_t): Likewise.
34630         (vbool8_t): Likewise.
34631         (vbool16_t): Likewise.
34632         (vbool32_t): Likewise.
34633         (vbool64_t): Likewise.
34634         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_UNSIGNED_EEW8_LMUL1_INTERPRET_OPS):
34635         New macro for vuint*m1_t.
34636         (DEF_RVV_UNSIGNED_EEW16_LMUL1_INTERPRET_OPS): Likewise.
34637         (DEF_RVV_UNSIGNED_EEW32_LMUL1_INTERPRET_OPS): Likewise.
34638         (DEF_RVV_UNSIGNED_EEW64_LMUL1_INTERPRET_OPS): Likewise.
34639         (required_extensions_p): Add vuint*m1_t interpret case.
34640         * config/riscv/riscv-vector-builtins.def (unsigned_eew8_lmul1_interpret):
34641         Add vuint*m1_t interpret to base type.
34642         (unsigned_eew16_lmul1_interpret): Likewise.
34643         (unsigned_eew32_lmul1_interpret): Likewise.
34644         (unsigned_eew64_lmul1_interpret): Likewise.
34646 2023-05-24  Pan Li  <pan2.li@intel.com>
34648         * config/riscv/genrvv-type-indexer.cc (EEW_SIZE_LIST): New macro
34649         for the eew size list.
34650         (LMUL1_LOG2): New macro for the log2 value of lmul=1.
34651         (main): Add signed_eew*_lmul1_interpret for indexer.
34652         * config/riscv/riscv-vector-builtins-functions.def (vreinterpret):
34653         Register vint*m1_t interpret function.
34654         * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_SIGNED_EEW8_LMUL1_INTERPRET_OPS):
34655         New macro for vint8m1_t.
34656         (DEF_RVV_SIGNED_EEW16_LMUL1_INTERPRET_OPS): Likewise.
34657         (DEF_RVV_SIGNED_EEW32_LMUL1_INTERPRET_OPS): Likewise.
34658         (DEF_RVV_SIGNED_EEW64_LMUL1_INTERPRET_OPS): Likewise.
34659         (vbool1_t): Add to signed_eew*_interpret_ops.
34660         (vbool2_t): Likewise.
34661         (vbool4_t): Likewise.
34662         (vbool8_t): Likewise.
34663         (vbool16_t): Likewise.
34664         (vbool32_t): Likewise.
34665         (vbool64_t): Likewise.
34666         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_SIGNED_EEW8_LMUL1_INTERPRET_OPS):
34667         New macro for vint*m1_t.
34668         (DEF_RVV_SIGNED_EEW16_LMUL1_INTERPRET_OPS): Likewise.
34669         (DEF_RVV_SIGNED_EEW32_LMUL1_INTERPRET_OPS): Likewise.
34670         (DEF_RVV_SIGNED_EEW64_LMUL1_INTERPRET_OPS): Likewise.
34671         (required_extensions_p): Add vint8m1_t interpret case.
34672         * config/riscv/riscv-vector-builtins.def (signed_eew8_lmul1_interpret):
34673         Add vint*m1_t interpret to base type.
34674         (signed_eew16_lmul1_interpret): Likewise.
34675         (signed_eew32_lmul1_interpret): Likewise.
34676         (signed_eew64_lmul1_interpret): Likewise.
34678 2023-05-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34680         * config/riscv/autovec.md: Adjust for new interface.
34681         * config/riscv/riscv-protos.h (emit_vlmax_insn): Add VL operand.
34682         (emit_nonvlmax_insn): Add AVL operand.
34683         * config/riscv/riscv-v.cc (emit_vlmax_insn): Add VL operand.
34684         (emit_nonvlmax_insn): Add AVL operand.
34685         (sew64_scalar_helper): Adjust for new interface.
34686         (expand_tuple_move): Ditto.
34687         * config/riscv/vector.md: Ditto.
34689 2023-05-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34691         * config/riscv/riscv-v.cc (expand_vec_series): Remove magic number.
34692         (expand_const_vector): Ditto.
34693         (legitimize_move): Ditto.
34694         (sew64_scalar_helper): Ditto.
34695         (expand_tuple_move): Ditto.
34696         (expand_vector_init_insert_elems): Ditto.
34697         * config/riscv/riscv.cc (vector_zero_call_used_regs): Ditto.
34699 2023-05-24  liuhongt  <hongtao.liu@intel.com>
34701         PR target/109900
34702         * config/i386/i386.cc (ix86_gimple_fold_builtin): Fold
34703         _mm{,256,512}_abs_{epi8,epi16,epi32,epi64} and
34704         _mm_abs_{pi8,pi16,pi32} into gimple ABS_EXPR.
34705         (ix86_masked_all_ones): Handle 64-bit mask.
34706         * config/i386/i386-builtin.def: Replace icode of related
34707         non-mask simd abs builtins with CODE_FOR_nothing.
34709 2023-05-23  Martin Uecker  <uecker@tugraz.at>
34711         PR c/109450
34712         * function.cc (gimplify_parm_type): Remove function.
34713         (gimplify_parameters): Call gimplify_type_sizes.
34715 2023-05-23  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
34717         * config/xtensa/xtensa.md (*addsubx): Rename from '*addx',
34718         and change to also accept '*subx' pattern.
34719         (*subx): Remove.
34721 2023-05-23  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
34723         * config/xtensa/predicates.md (addsub_operator): New.
34724         * config/xtensa/xtensa.md (*extzvsi-1bit_ashlsi3,
34725         *extzvsi-1bit_addsubx): New insn_and_split patterns.
34726         * config/xtensa/xtensa.cc (xtensa_rtx_costs):
34727         Add a special case about ifcvt 'noce_try_cmove()' to handle
34728         constant loads that do not fit into signed 12 bits in the
34729         patterns added above.
34731 2023-05-23  Richard Biener  <rguenther@suse.de>
34733         PR tree-optimization/109747
34734         * tree-vect-slp.cc (vect_prologue_cost_for_slp): Pass down
34735         the SLP node only once to the cost hook.
34737 2023-05-23  Georg-Johann Lay  <avr@gjlay.de>
34739         * config/avr/avr.cc (avr_insn_cost): New static function.
34740         (TARGET_INSN_COST): Define to that function.
34742 2023-05-23  Richard Biener  <rguenther@suse.de>
34744         PR target/109944
34745         * config/i386/i386.cc (ix86_vector_costs::add_stmt_cost):
34746         For vector construction or splats apply GPR->XMM move
34747         costing.  QImode memory can be handled directly only
34748         with SSE4.1 pinsrb.
34750 2023-05-23  Richard Biener  <rguenther@suse.de>
34752         PR tree-optimization/108752
34753         * tree-vect-stmts.cc (vectorizable_operation): For bit
34754         operations with generic word_mode vectors do not cost
34755         an extra stmt.  For plus, minus and negate also cost the
34756         constant materialization.
34758 2023-05-23  Uros Bizjak  <ubizjak@gmail.com>
34760         * config/i386/i386-expand.cc (ix86_expand_vecop_qihi_partial):
34761         Call ix86_expand_vec_shift_qihi_constant for shifts
34762         with constant count operand.
34763         * config/i386/i386.cc (ix86_shift_rotate_cost):
34764         Handle V4QImode and V8QImode.
34765         * config/i386/mmx.md (<insn>v8qi3): New insn pattern.
34766         (<insn>v4qi3): Ditto.
34768 2023-05-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34770         * config/riscv/vector.md: Add mode.
34772 2023-05-23  Aldy Hernandez  <aldyh@redhat.com>
34774         PR tree-optimization/109934
34775         * value-range.cc (irange::invert): Remove buggy special case.
34777 2023-05-23  Richard Biener  <rguenther@suse.de>
34779         * tree-ssa-pre.cc (compute_antic_aux): Dump the correct
34780         ANTIC_OUT.
34782 2023-05-23  Richard Sandiford  <richard.sandiford@arm.com>
34784         PR target/109632
34785         * config/aarch64/aarch64.cc (aarch64_modes_tieable_p): Allow
34786         subregs between any scalars that are 64 bits or smaller.
34787         * config/aarch64/iterators.md (SUBDI_BITS): New int iterator.
34788         (bits_etype): New int attribute.
34789         * config/aarch64/aarch64.md (*insv_reg<mode>_<SUBDI_BITS>)
34790         (*aarch64_bfi<GPI:mode><ALLX:mode>_<SUBDI_BITS>): New patterns.
34791         (*aarch64_bfidi<ALLX:mode>_subreg_<SUBDI_BITS>): Likewise.
34793 2023-05-23  Richard Sandiford  <richard.sandiford@arm.com>
34795         * doc/md.texi: Document that <FOO> can be used to refer to the
34796         numerical value of an int iterator FOO.  Tweak other parts of
34797         the int iterator documentation.
34798         * read-rtl.cc (iterator_group::has_self_attr): New field.
34799         (map_attr_string): When has_self_attr is true, make <FOO>
34800         expand to the current value of iterator FOO.
34801         (initialize_iterators): Set has_self_attr for int iterators.
34803 2023-05-23  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34805         * config/riscv/autovec.md: Refactor the framework of RVV auto-vectorization.
34806         * config/riscv/riscv-protos.h (RVV_MISC_OP_NUM): Ditto.
34807         (RVV_UNOP_NUM): New macro.
34808         (RVV_BINOP_NUM): Ditto.
34809         (legitimize_move): Refactor the framework of RVV auto-vectorization.
34810         (emit_vlmax_op): Ditto.
34811         (emit_vlmax_reg_op): Ditto.
34812         (emit_len_op): Ditto.
34813         (emit_len_binop): Ditto.
34814         (emit_vlmax_tany_many): Ditto.
34815         (emit_nonvlmax_tany_many): Ditto.
34816         (sew64_scalar_helper): Ditto.
34817         (expand_tuple_move): Ditto.
34818         * config/riscv/riscv-v.cc (emit_pred_op): Ditto.
34819         (emit_pred_binop): Ditto.
34820         (emit_vlmax_op): Ditto.
34821         (emit_vlmax_tany_many): New function.
34822         (emit_len_op): Remove.
34823         (emit_nonvlmax_tany_many): New function.
34824         (emit_vlmax_reg_op): Remove.
34825         (emit_len_binop): Ditto.
34826         (emit_index_op): Ditto.
34827         (expand_vec_series): Refactor the framework of RVV auto-vectorization.
34828         (expand_const_vector): Ditto.
34829         (legitimize_move): Ditto.
34830         (sew64_scalar_helper): Ditto.
34831         (expand_tuple_move): Ditto.
34832         (expand_vector_init_insert_elems): Ditto.
34833         * config/riscv/riscv.cc (vector_zero_call_used_regs): Ditto.
34834         * config/riscv/vector.md: Ditto.
34836 2023-05-23  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
34838         PR target/109855
34839         * config/aarch64/aarch64-simd.md (add_vec_concat_subst_le): Add predicate
34840         and constraint for operand 0.
34841         (add_vec_concat_subst_be): Likewise.
34843 2023-05-23  Richard Biener  <rguenther@suse.de>
34845         PR tree-optimization/109849
34846         * tree-ssa-pre.cc (do_hoist_insertion): Compute ANTIC_OUT
34847         and use that to determine what to hoist.
34849 2023-05-23  Eric Botcazou  <ebotcazou@adacore.com>
34851         * fold-const.cc (native_encode_initializer) <CONSTRUCTOR>: Apply the
34852         specific treatment for bit-fields only if they have an integral type
34853         and filter out non-integral bit-fields that do not start and end on
34854         a byte boundary.
34856 2023-05-23  Aldy Hernandez  <aldyh@redhat.com>
34858         PR tree-optimization/109920
34859         * value-range.h (RESIZABLE>::~int_range): Use delete[].
34861 2023-05-22  Uros Bizjak  <ubizjak@gmail.com>
34863         * config/i386/i386.cc (ix86_shift_rotate_cost): Correct
34864         calcuation of integer vector mode costs to reflect generated
34865         instruction sequences of different integer vector modes and
34866         different target ABIs.  Remove "speed" function argument.
34867         (ix86_rtx_costs): Update call for removed function argument.
34868         (ix86_vector_costs::add_stmt_cost): Ditto.
34870 2023-05-22  Aldy Hernandez  <aldyh@redhat.com>
34872         * value-range.h (class Value_Range): Implement set_zero,
34873         set_nonzero, and nonzero_p.
34875 2023-05-22  Uros Bizjak  <ubizjak@gmail.com>
34877         * config/i386/i386.cc (ix86_multiplication_cost): Add
34878         the cost of a memory read to the cost of V?QImode sequences.
34880 2023-05-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34882         * config/riscv/riscv-v.cc: Add "m_" prefix.
34884 2023-05-22  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
34886         * tree-vect-loop.cc (vect_get_loop_len): Fix issue for
34887         multiple-rgroup of length.
34888         * tree-vect-stmts.cc (vectorizable_store): Ditto.
34889         (vectorizable_load): Ditto.
34890         * tree-vectorizer.h (vect_get_loop_len): Ditto.
34892 2023-05-22  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
34894         * config/riscv/riscv.cc (riscv_const_insns): Reorganize the
34895         codes.
34897 2023-05-22  Kewen Lin  <linkw@linux.ibm.com>
34899         * tree-vect-slp.cc (vect_transform_slp_perm_load_1): Refactor the
34900         handling for the case index == count.
34902 2023-05-21  Georg-Johann Lay  <avr@gjlay.de>
34904         PR target/90622
34905         * config/avr/avr.cc (avr_fold_builtin) [AVR_BUILTIN_INSERT_BITS]:
34906         Don't fold to XOR / AND / XOR if just one bit is copied to the
34907         same position.
34909 2023-05-21  Roger Sayle  <roger@nextmovesoftware.com>
34911         * config/nvptx/nvptx.cc (nvptx_expand_brev): Expand target
34912         builtin for bit reversal using brev instruction.
34913         (enum nvptx_builtins): Add NVPTX_BUILTIN_BREV and
34914         NVPTX_BUILTIN_BREVLL.
34915         (nvptx_init_builtins): Define "brev" and "brevll".
34916         (nvptx_expand_builtin): Expand NVPTX_BUILTIN_BREV and
34917         NVPTX_BUILTIN_BREVLL via nvptx_expand_brev function.
34918         * doc/extend.texi (Nvidia PTX Builtin-in Functions): New
34919         section, document __builtin_nvptx_brev{,ll}.
34921 2023-05-21  Jakub Jelinek  <jakub@redhat.com>
34923         PR tree-optimization/109505
34924         * match.pd ((x | CST1) & CST2 -> (x & CST2) | (CST1 & CST2),
34925         Combine successive equal operations with constants,
34926         (A +- CST1) +- CST2 -> A + CST3, (CST1 - A) +- CST2 -> CST3 - A,
34927         CST1 - (CST2 - A) -> CST3 + A): Use ! on ops with 2 CONSTANT_CLASS_P
34928         operands.
34930 2023-05-21  Andrew Pinski  <apinski@marvell.com>
34932         * expr.cc (expand_single_bit_test): Correct bitpos for big-endian.
34934 2023-05-21  Pan Li  <pan2.li@intel.com>
34936         * config/riscv/genrvv-type-indexer.cc (BOOL_SIZE_LIST): Add the
34937         rest bool size, aka 2, 4, 8, 16, 32, 64.
34938         * config/riscv/riscv-vector-builtins-functions.def (vreinterpret):
34939         Register vbool[2|4|8|16|32|64] interpret function.
34940         * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_BOOL2_INTERPRET_OPS):
34941         New macro for vbool2_t.
34942         (DEF_RVV_BOOL4_INTERPRET_OPS): Likewise.
34943         (DEF_RVV_BOOL8_INTERPRET_OPS): Likewise.
34944         (DEF_RVV_BOOL16_INTERPRET_OPS): Likewise.
34945         (DEF_RVV_BOOL32_INTERPRET_OPS): Likewise.
34946         (DEF_RVV_BOOL64_INTERPRET_OPS): Likewise.
34947         (vint8m1_t): Add the type to bool[2|4|8|16|32|64]_interpret_ops.
34948         (vint16m1_t): Likewise.
34949         (vint32m1_t): Likewise.
34950         (vint64m1_t): Likewise.
34951         (vuint8m1_t): Likewise.
34952         (vuint16m1_t): Likewise.
34953         (vuint32m1_t): Likewise.
34954         (vuint64m1_t): Likewise.
34955         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_BOOL2_INTERPRET_OPS):
34956         New macro for vbool2_t.
34957         (DEF_RVV_BOOL4_INTERPRET_OPS): Likewise.
34958         (DEF_RVV_BOOL8_INTERPRET_OPS): Likewise.
34959         (DEF_RVV_BOOL16_INTERPRET_OPS): Likewise.
34960         (DEF_RVV_BOOL32_INTERPRET_OPS): Likewise.
34961         (DEF_RVV_BOOL64_INTERPRET_OPS): Likewise.
34962         (required_extensions_p): Add vbool[2|4|8|16|32|64] interpret case.
34963         * config/riscv/riscv-vector-builtins.def (bool2_interpret): Add
34964         vbool2_t interprect to base type.
34965         (bool4_interpret): Likewise.
34966         (bool8_interpret): Likewise.
34967         (bool16_interpret): Likewise.
34968         (bool32_interpret): Likewise.
34969         (bool64_interpret): Likewise.
34971 2023-05-21  Andrew Pinski  <apinski@marvell.com>
34973         PR middle-end/109919
34974         * expr.cc (expand_single_bit_test): Don't use the
34975         target for expand_expr.
34977 2023-05-20  Gerald Pfeifer  <gerald@pfeifer.com>
34979         * doc/install.texi (Specific): Remove de facto empty alpha*-*-*
34980         section.
34982 2023-05-20  Pan Li  <pan2.li@intel.com>
34984         * mode-switching.cc (entity_map): Initialize the array to zero.
34985         (bb_info): Ditto.
34987 2023-05-20  Triffid Hunter  <triffid.hunter@gmail.com>
34989         PR target/105753
34990         * config/avr/avr.md (divmodpsi, udivmodpsi, divmodsi, udivmodsi):
34991         Remove superfluous "parallel" in insn pattern.
34992         ([u]divmod<mode>4): Tidy code.  Use gcc_unreachable() instead of
34993         printing error text to assembly.
34995 2023-05-20  Andrew Pinski  <apinski@marvell.com>
34997         * expr.cc (fold_single_bit_test): Rename to ...
34998         (expand_single_bit_test): This and expand directly.
34999         (do_store_flag): Update for the rename function.
35001 2023-05-20  Andrew Pinski  <apinski@marvell.com>
35003         * expr.cc (fold_single_bit_test): Use BIT_FIELD_REF
35004         instead of shift/and.
35006 2023-05-20  Andrew Pinski  <apinski@marvell.com>
35008         * expr.cc (fold_single_bit_test): Add an assert
35009         and simplify based on code being NE_EXPR or EQ_EXPR.
35011 2023-05-20  Andrew Pinski  <apinski@marvell.com>
35013         * expr.cc (fold_single_bit_test): Take inner and bitnum
35014         instead of arg0 and arg1. Update the code.
35015         (do_store_flag): Don't create a tree when calling
35016         fold_single_bit_test instead just call it with the bitnum
35017         and the inner tree.
35019 2023-05-20  Andrew Pinski  <apinski@marvell.com>
35021         * expr.cc (fold_single_bit_test): Use get_def_for_expr
35022         instead of checking the inner's code.
35024 2023-05-20  Andrew Pinski  <apinski@marvell.com>
35026         * expr.cc (fold_single_bit_test_into_sign_test): Inline into ...
35027         (fold_single_bit_test): This and simplify.
35029 2023-05-20  Andrew Pinski  <apinski@marvell.com>
35031         * fold-const.cc (fold_single_bit_test_into_sign_test): Move to
35032         expr.cc.
35033         (fold_single_bit_test): Likewise.
35034         * expr.cc (fold_single_bit_test_into_sign_test): Move from fold-const.cc
35035         (fold_single_bit_test): Likewise and make static.
35036         * fold-const.h (fold_single_bit_test): Remove declaration.
35038 2023-05-20  Die Li  <lidie@eswincomputing.com>
35040         * config/riscv/riscv.cc (riscv_expand_conditional_move): Fix mode
35041         checking.
35043 2023-05-20  Raphael Moreira Zinsly  <rzinsly@ventanamicro.com>
35045         * config/riscv/bitmanip.md (branch<X:mode>_bext): New split pattern.
35047 2023-05-20  Raphael Moreira Zinsly  <rzinsly@ventanamicro.com>
35049         PR target/106888
35050         * config/riscv/bitmanip.md
35051         (<bitmanip_optab>disi2): Match with any_extend.
35052         (<bitmanip_optab>disi2_sext): New pattern to match
35053         with sign extend using an ANDI instruction.
35055 2023-05-19  Nathan Sidwell  <nathan@acm.org>
35057         PR other/99451
35058         * opts.h (handle_deferred_dump_options): Declare.
35059         * opts-global.cc (handle_common_deferred_options): Do not handle
35060         dump options here.
35061         (handle_deferred_dump_options): New.
35062         * toplev.cc (toplev::main): Call it after plugin init.
35064 2023-05-19  Joern Rennecke  <joern.rennecke@embecosm.com>
35066         * config/riscv/constraints.md (DsS, DsD): Restore agreement
35067         with shiftm1 mode attribute.
35069 2023-05-19  Andrew Pinski  <apinski@marvell.com>
35071         PR driver/33980
35072         * gcc.cc (default_compilers["@c-header"]): Add %w
35073         after the --output-pch.
35075 2023-05-19  Vineet Gupta  <vineetg@rivosinc.com>
35077         * config/riscv/riscv.cc (riscv_split_integer): if loval is equal
35078         to hival, ASHIFT the corresponding regs.
35080 2023-05-19  Robin Dapp  <rdapp@ventanamicro.com>
35082         * config/riscv/riscv.cc (riscv_const_insns): Remove else.
35084 2023-05-19  Jakub Jelinek  <jakub@redhat.com>
35086         PR tree-optimization/105776
35087         * tree-ssa-math-opts.cc (arith_overflow_check_p): If cast_stmt is
35088         non-NULL, allow division statement to have a cast as single imm use
35089         rather than comparison/condition.
35090         (match_arith_overflow): In that case remove the cast stmt in addition
35091         to the division statement.
35093 2023-05-19  Jakub Jelinek  <jakub@redhat.com>
35095         PR tree-optimization/101856
35096         * tree-ssa-math-opts.cc (match_arith_overflow): Pattern detect
35097         unsigned __builtin_mul_overflow_p even when umulv4_optab doesn't
35098         support it but umul_highpart_optab does.
35100 2023-05-19  Eric Botcazou  <ebotcazou@adacore.com>
35102         * varasm.cc (output_constructor_bitfield): Call tree_to_uhwi instead
35103         of tree_to_shwi on array indices.  Minor tweaks.
35105 2023-05-18  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
35107         * alias.cc (ref_all_alias_ptr_type_p): Use _P() defines from tree.h.
35108         * attribs.cc (diag_attr_exclusions): Ditto.
35109         (decl_attributes): Ditto.
35110         (build_type_attribute_qual_variant): Ditto.
35111         * builtins.cc (fold_builtin_carg): Ditto.
35112         (fold_builtin_next_arg): Ditto.
35113         (do_mpc_arg2): Ditto.
35114         * cfgexpand.cc (expand_return): Ditto.
35115         * cgraph.h (decl_in_symtab_p): Ditto.
35116         (symtab_node::get_create): Ditto.
35117         * dwarf2out.cc (base_type_die): Ditto.
35118         (implicit_ptr_descriptor): Ditto.
35119         (gen_array_type_die): Ditto.
35120         (gen_type_die_with_usage): Ditto.
35121         (optimize_location_into_implicit_ptr): Ditto.
35122         * expr.cc (do_store_flag): Ditto.
35123         * fold-const.cc (negate_expr_p): Ditto.
35124         (fold_negate_expr_1): Ditto.
35125         (fold_convert_const): Ditto.
35126         (fold_convert_loc): Ditto.
35127         (constant_boolean_node): Ditto.
35128         (fold_binary_op_with_conditional_arg): Ditto.
35129         (build_fold_addr_expr_with_type_loc): Ditto.
35130         (fold_comparison): Ditto.
35131         (fold_checksum_tree): Ditto.
35132         (tree_unary_nonnegative_warnv_p): Ditto.
35133         (integer_valued_real_unary_p): Ditto.
35134         (fold_read_from_constant_string): Ditto.
35135         * gcc-rich-location.cc (maybe_range_label_for_tree_type_mismatch::get_text): Ditto.
35136         * gimple-expr.cc (useless_type_conversion_p): Ditto.
35137         (is_gimple_reg): Ditto.
35138         (is_gimple_asm_val): Ditto.
35139         (mark_addressable): Ditto.
35140         * gimple-expr.h (is_gimple_variable): Ditto.
35141         (virtual_operand_p): Ditto.
35142         * gimple-ssa-warn-access.cc (pass_waccess::check_dangling_stores): Ditto.
35143         * gimplify.cc (gimplify_bind_expr): Ditto.
35144         (gimplify_return_expr): Ditto.
35145         (gimple_add_padding_init_for_auto_var): Ditto.
35146         (gimplify_addr_expr): Ditto.
35147         (omp_add_variable): Ditto.
35148         (omp_notice_variable): Ditto.
35149         (omp_get_base_pointer): Ditto.
35150         (omp_strip_components_and_deref): Ditto.
35151         (omp_strip_indirections): Ditto.
35152         (omp_accumulate_sibling_list): Ditto.
35153         (omp_build_struct_sibling_lists): Ditto.
35154         (gimplify_adjust_omp_clauses_1): Ditto.
35155         (gimplify_adjust_omp_clauses): Ditto.
35156         (gimplify_omp_for): Ditto.
35157         (goa_lhs_expr_p): Ditto.
35158         (gimplify_one_sizepos): Ditto.
35159         * graphite-scop-detection.cc (scop_detection::graphite_can_represent_scev): Ditto.
35160         * ipa-devirt.cc (odr_types_equivalent_p): Ditto.
35161         * ipa-prop.cc (ipa_set_jf_constant): Ditto.
35162         (propagate_controlled_uses): Ditto.
35163         * ipa-sra.cc (type_prevails_p): Ditto.
35164         (scan_expr_access): Ditto.
35165         * optabs-tree.cc (optab_for_tree_code): Ditto.
35166         * toplev.cc (wrapup_global_declaration_1): Ditto.
35167         * trans-mem.cc (transaction_invariant_address_p): Ditto.
35168         * tree-cfg.cc (verify_types_in_gimple_reference): Ditto.
35169         (verify_gimple_comparison): Ditto.
35170         (verify_gimple_assign_binary): Ditto.
35171         (verify_gimple_assign_single): Ditto.
35172         * tree-complex.cc (get_component_ssa_name): Ditto.
35173         * tree-emutls.cc (lower_emutls_2): Ditto.
35174         * tree-inline.cc (copy_tree_body_r): Ditto.
35175         (estimate_move_cost): Ditto.
35176         (copy_decl_for_dup_finish): Ditto.
35177         * tree-nested.cc (convert_nonlocal_omp_clauses): Ditto.
35178         (note_nonlocal_vla_type): Ditto.
35179         (convert_local_omp_clauses): Ditto.
35180         (remap_vla_decls): Ditto.
35181         (fixup_vla_decls): Ditto.
35182         * tree-parloops.cc (loop_has_vector_phi_nodes): Ditto.
35183         * tree-pretty-print.cc (print_declaration): Ditto.
35184         (print_call_name): Ditto.
35185         * tree-sra.cc (compare_access_positions): Ditto.
35186         * tree-ssa-alias.cc (compare_type_sizes): Ditto.
35187         * tree-ssa-ccp.cc (get_default_value): Ditto.
35188         * tree-ssa-coalesce.cc (populate_coalesce_list_for_outofssa): Ditto.
35189         * tree-ssa-dom.cc (reduce_vector_comparison_to_scalar_comparison): Ditto.
35190         * tree-ssa-forwprop.cc (can_propagate_from): Ditto.
35191         * tree-ssa-propagate.cc (may_propagate_copy): Ditto.
35192         * tree-ssa-sccvn.cc (fully_constant_vn_reference_p): Ditto.
35193         * tree-ssa-sink.cc (statement_sink_location): Ditto.
35194         * tree-ssa-structalias.cc (type_must_have_pointers): Ditto.
35195         * tree-ssa-ter.cc (find_replaceable_in_bb): Ditto.
35196         * tree-ssa-uninit.cc (warn_uninit): Ditto.
35197         * tree-ssa.cc (maybe_rewrite_mem_ref_base): Ditto.
35198         (non_rewritable_mem_ref_base): Ditto.
35199         * tree-streamer-in.cc (lto_input_ts_type_non_common_tree_pointers): Ditto.
35200         * tree-streamer-out.cc (write_ts_type_non_common_tree_pointers): Ditto.
35201         * tree-vect-generic.cc (do_binop): Ditto.
35202         (do_cond): Ditto.
35203         * tree-vect-stmts.cc (vect_init_vector): Ditto.
35204         * tree-vector-builder.h (tree_vector_builder::note_representative): Ditto.
35205         * tree.cc (sign_mask_for): Ditto.
35206         (verify_type_variant): Ditto.
35207         (gimple_canonical_types_compatible_p): Ditto.
35208         (verify_type): Ditto.
35209         * ubsan.cc (get_ubsan_type_info_for_type): Ditto.
35210         * var-tracking.cc (prepare_call_arguments): Ditto.
35211         (vt_add_function_parameters): Ditto.
35212         * varasm.cc (decode_addr_const): Ditto.
35214 2023-05-18  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
35216         * omp-low.cc (scan_sharing_clauses): Use _P() defines from tree.h.
35217         (lower_reduction_clauses): Ditto.
35218         (lower_send_clauses): Ditto.
35219         (lower_omp_task_reductions): Ditto.
35220         * omp-oacc-neuter-broadcast.cc (install_var_field): Ditto.
35221         (worker_single_copy): Ditto.
35222         * omp-offload.cc (oacc_rewrite_var_decl): Ditto.
35223         * omp-simd-clone.cc (plausible_type_for_simd_clone): Ditto.
35225 2023-05-18  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
35227         * lto-streamer-in.cc (lto_input_var_decl_ref): Use _P defines from
35228         tree.h.
35229         (lto_read_body_or_constructor): Ditto.
35230         * lto-streamer-out.cc (tree_is_indexable): Ditto.
35231         (lto_output_var_decl_ref): Ditto.
35232         (DFS::DFS_write_tree_body): Ditto.
35233         (wrap_refs): Ditto.
35234         (write_symbol_extension_info): Ditto.
35236 2023-05-18  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
35238         * config/aarch64/aarch64.cc (aarch64_short_vector_p): Use _P
35239         defines from tree.h.
35240         (aarch64_mangle_type): Ditto.
35241         * config/alpha/alpha.cc (alpha_in_small_data_p): Ditto.
35242         (alpha_gimplify_va_arg_1): Ditto.
35243         * config/arc/arc.cc (arc_encode_section_info): Ditto.
35244         (arc_is_aux_reg_p): Ditto.
35245         (arc_is_uncached_mem_p): Ditto.
35246         (arc_handle_aux_attribute): Ditto.
35247         * config/arm/arm.cc (arm_handle_isr_attribute): Ditto.
35248         (arm_handle_cmse_nonsecure_call): Ditto.
35249         (arm_set_default_type_attributes): Ditto.
35250         (arm_is_segment_info_known): Ditto.
35251         (arm_mangle_type): Ditto.
35252         * config/arm/unknown-elf.h (IN_NAMED_SECTION_P): Ditto.
35253         * config/avr/avr.cc (avr_lookup_function_attribute1): Ditto.
35254         (avr_decl_absdata_p): Ditto.
35255         (avr_insert_attributes): Ditto.
35256         (avr_section_type_flags): Ditto.
35257         (avr_encode_section_info): Ditto.
35258         * config/bfin/bfin.cc (bfin_handle_l2_attribute): Ditto.
35259         * config/bpf/bpf.cc (bpf_core_compute): Ditto.
35260         * config/c6x/c6x.cc (c6x_in_small_data_p): Ditto.
35261         * config/csky/csky.cc (csky_handle_isr_attribute): Ditto.
35262         (csky_mangle_type): Ditto.
35263         * config/darwin-c.cc (darwin_pragma_unused): Ditto.
35264         * config/darwin.cc (is_objc_metadata): Ditto.
35265         * config/epiphany/epiphany.cc (epiphany_function_ok_for_sibcall): Ditto.
35266         * config/epiphany/epiphany.h (ROUND_TYPE_ALIGN): Ditto.
35267         * config/frv/frv.cc (frv_emit_movsi): Ditto.
35268         * config/gcn/gcn-tree.cc (gcn_lockless_update): Ditto.
35269         * config/gcn/gcn.cc (gcn_asm_output_symbol_ref): Ditto.
35270         * config/h8300/h8300.cc (h8300_encode_section_info): Ditto.
35271         * config/i386/i386-expand.cc: Ditto.
35272         * config/i386/i386.cc (type_natural_mode): Ditto.
35273         (ix86_function_arg): Ditto.
35274         (ix86_data_alignment): Ditto.
35275         (ix86_local_alignment): Ditto.
35276         (ix86_simd_clone_compute_vecsize_and_simdlen): Ditto.
35277         * config/i386/winnt-cxx.cc (i386_pe_type_dllimport_p): Ditto.
35278         (i386_pe_type_dllexport_p): Ditto.
35279         (i386_pe_adjust_class_at_definition): Ditto.
35280         * config/i386/winnt.cc (i386_pe_determine_dllimport_p): Ditto.
35281         (i386_pe_binds_local_p): Ditto.
35282         (i386_pe_section_type_flags): Ditto.
35283         * config/ia64/ia64.cc (ia64_encode_section_info): Ditto.
35284         (ia64_gimplify_va_arg): Ditto.
35285         (ia64_in_small_data_p): Ditto.
35286         * config/iq2000/iq2000.cc (iq2000_function_arg): Ditto.
35287         * config/lm32/lm32.cc (lm32_in_small_data_p): Ditto.
35288         * config/loongarch/loongarch.cc (loongarch_handle_model_attribute): Ditto.
35289         * config/m32c/m32c.cc (m32c_insert_attributes): Ditto.
35290         * config/mcore/mcore.cc (mcore_mark_dllimport): Ditto.
35291         (mcore_encode_section_info): Ditto.
35292         * config/microblaze/microblaze.cc (microblaze_elf_in_small_data_p): Ditto.
35293         * config/mips/mips.cc (mips_output_aligned_decl_common): Ditto.
35294         * config/mmix/mmix.cc (mmix_encode_section_info): Ditto.
35295         * config/nvptx/nvptx.cc (nvptx_encode_section_info): Ditto.
35296         (pass_in_memory): Ditto.
35297         (nvptx_generate_vector_shuffle): Ditto.
35298         (nvptx_lockless_update): Ditto.
35299         * config/pa/pa.cc (pa_function_arg_padding): Ditto.
35300         (pa_function_value): Ditto.
35301         (pa_function_arg): Ditto.
35302         * config/pa/pa.h (IN_NAMED_SECTION_P): Ditto.
35303         (TEXT_SPACE_P): Ditto.
35304         * config/pa/som.h (MAKE_DECL_ONE_ONLY): Ditto.
35305         * config/pdp11/pdp11.cc (pdp11_return_in_memory): Ditto.
35306         * config/riscv/riscv.cc (riscv_in_small_data_p): Ditto.
35307         (riscv_mangle_type): Ditto.
35308         * config/rl78/rl78.cc (rl78_insert_attributes): Ditto.
35309         (rl78_addsi3_internal): Ditto.
35310         * config/rs6000/aix.h (ROUND_TYPE_ALIGN): Ditto.
35311         * config/rs6000/darwin.h (ROUND_TYPE_ALIGN): Ditto.
35312         * config/rs6000/freebsd64.h (ROUND_TYPE_ALIGN): Ditto.
35313         * config/rs6000/linux64.h (ROUND_TYPE_ALIGN): Ditto.
35314         * config/rs6000/rs6000-call.cc (rs6000_function_arg_boundary): Ditto.
35315         (rs6000_function_arg_advance_1): Ditto.
35316         (rs6000_function_arg): Ditto.
35317         (rs6000_pass_by_reference): Ditto.
35318         * config/rs6000/rs6000-logue.cc (rs6000_function_ok_for_sibcall): Ditto.
35319         * config/rs6000/rs6000.cc (rs6000_data_alignment): Ditto.
35320         (rs6000_set_default_type_attributes): Ditto.
35321         (rs6000_elf_in_small_data_p): Ditto.
35322         (IN_NAMED_SECTION): Ditto.
35323         (rs6000_xcoff_encode_section_info): Ditto.
35324         (rs6000_function_value): Ditto.
35325         (invalid_arg_for_unprototyped_fn): Ditto.
35326         * config/s390/s390-c.cc (s390_fn_types_compatible): Ditto.
35327         (s390_vec_n_elem): Ditto.
35328         * config/s390/s390.cc (s390_check_type_for_vector_abi): Ditto.
35329         (s390_function_arg_integer): Ditto.
35330         (s390_return_in_memory): Ditto.
35331         (s390_encode_section_info): Ditto.
35332         * config/sh/sh.cc (sh_gimplify_va_arg_expr): Ditto.
35333         (sh_function_value): Ditto.
35334         * config/sol2.cc (solaris_insert_attributes): Ditto.
35335         * config/sparc/sparc.cc (function_arg_slotno): Ditto.
35336         * config/sparc/sparc.h (ROUND_TYPE_ALIGN): Ditto.
35337         * config/stormy16/stormy16.cc (xstormy16_encode_section_info): Ditto.
35338         (xstormy16_handle_below100_attribute): Ditto.
35339         * config/v850/v850.cc (v850_encode_section_info): Ditto.
35340         (v850_insert_attributes): Ditto.
35341         * config/visium/visium.cc (visium_pass_by_reference): Ditto.
35342         (visium_return_in_memory): Ditto.
35343         * config/xtensa/xtensa.cc (xtensa_multibss_section_type_flags): Ditto.
35345 2023-05-18  Uros Bizjak  <ubizjak@gmail.com>
35347         * config/i386/i386-expand.cc (ix86_expand_vecop_qihi_partial): New.
35348         (ix86_expand_vecop_qihi): Add op2vec bool variable.
35349         Do not set REG_EQUAL note.
35350         * config/i386/i386-protos.h (ix86_expand_vecop_qihi_partial):
35351         Add prototype.
35352         * config/i386/i386.cc (ix86_multiplication_cost): Handle
35353         V4QImode and V8QImode.
35354         * config/i386/mmx.md (mulv8qi3): New expander.
35355         (mulv4qi3): Ditto.
35356         * config/i386/sse.md (mulv8qi3): Remove.
35358 2023-05-18  Georg-Johann Lay  <avr@gjlay.de>
35360         * config/avr/gen-avr-mmcu-specs.cc: Remove stale */ after // comment.
35362 2023-05-18  Jonathan Wakely  <jwakely@redhat.com>
35364         PR bootstrap/105831
35365         * config.gcc: Use = operator instead of ==.
35367 2023-05-18  Michael Bäuerle  <micha@NetBSD.org>
35369         PR bootstrap/105831
35370         * config/nvptx/gen-opt.sh: Use = operator instead of ==.
35371         * configure.ac: Likewise.
35372         * configure: Regenerate.
35374 2023-05-18  Stam Markianos-Wright  <stam.markianos-wright@arm.com>
35376         * config/arm/arm_mve.h: (__ARM_mve_typeid): Add more pointer types.
35377         (__ARM_mve_coerce1): Remove.
35378         (__ARM_mve_coerce2): Remove.
35379         (__ARM_mve_coerce3): Remove.
35380         (__ARM_mve_coerce_i_scalar): New.
35381         (__ARM_mve_coerce_s8_ptr): New.
35382         (__ARM_mve_coerce_u8_ptr): New.
35383         (__ARM_mve_coerce_s16_ptr): New.
35384         (__ARM_mve_coerce_u16_ptr): New.
35385         (__ARM_mve_coerce_s32_ptr): New.
35386         (__ARM_mve_coerce_u32_ptr): New.
35387         (__ARM_mve_coerce_s64_ptr): New.
35388         (__ARM_mve_coerce_u64_ptr): New.
35389         (__ARM_mve_coerce_f_scalar): New.
35390         (__ARM_mve_coerce_f16_ptr): New.
35391         (__ARM_mve_coerce_f32_ptr): New.
35392         (__arm_vst4q): Change _coerce_ overloads.
35393         (__arm_vbicq): Change _coerce_ overloads.
35394         (__arm_vld1q): Change _coerce_ overloads.
35395         (__arm_vld1q_z): Change _coerce_ overloads.
35396         (__arm_vld2q): Change _coerce_ overloads.
35397         (__arm_vld4q): Change _coerce_ overloads.
35398         (__arm_vldrhq_gather_offset): Change _coerce_ overloads.
35399         (__arm_vldrhq_gather_offset_z): Change _coerce_ overloads.
35400         (__arm_vldrhq_gather_shifted_offset): Change _coerce_ overloads.
35401         (__arm_vldrhq_gather_shifted_offset_z): Change _coerce_ overloads.
35402         (__arm_vldrwq_gather_offset): Change _coerce_ overloads.
35403         (__arm_vldrwq_gather_offset_z): Change _coerce_ overloads.
35404         (__arm_vldrwq_gather_shifted_offset): Change _coerce_ overloads.
35405         (__arm_vldrwq_gather_shifted_offset_z): Change _coerce_ overloads.
35406         (__arm_vst1q_p): Change _coerce_ overloads.
35407         (__arm_vst2q): Change _coerce_ overloads.
35408         (__arm_vst1q): Change _coerce_ overloads.
35409         (__arm_vstrhq): Change _coerce_ overloads.
35410         (__arm_vstrhq_p): Change _coerce_ overloads.
35411         (__arm_vstrhq_scatter_offset_p): Change _coerce_ overloads.
35412         (__arm_vstrhq_scatter_offset): Change _coerce_ overloads.
35413         (__arm_vstrhq_scatter_shifted_offset_p): Change _coerce_ overloads.
35414         (__arm_vstrhq_scatter_shifted_offset): Change _coerce_ overloads.
35415         (__arm_vstrwq_p): Change _coerce_ overloads.
35416         (__arm_vstrwq): Change _coerce_ overloads.
35417         (__arm_vstrwq_scatter_offset): Change _coerce_ overloads.
35418         (__arm_vstrwq_scatter_offset_p): Change _coerce_ overloads.
35419         (__arm_vstrwq_scatter_shifted_offset): Change _coerce_ overloads.
35420         (__arm_vstrwq_scatter_shifted_offset_p): Change _coerce_ overloads.
35421         (__arm_vsetq_lane): Change _coerce_ overloads.
35422         (__arm_vldrbq_gather_offset): Change _coerce_ overloads.
35423         (__arm_vdwdupq_x_u8): Change _coerce_ overloads.
35424         (__arm_vdwdupq_x_u16): Change _coerce_ overloads.
35425         (__arm_vdwdupq_x_u32): Change _coerce_ overloads.
35426         (__arm_viwdupq_x_u8): Change _coerce_ overloads.
35427         (__arm_viwdupq_x_u16): Change _coerce_ overloads.
35428         (__arm_viwdupq_x_u32): Change _coerce_ overloads.
35429         (__arm_vidupq_x_u8): Change _coerce_ overloads.
35430         (__arm_vddupq_x_u8): Change _coerce_ overloads.
35431         (__arm_vidupq_x_u16): Change _coerce_ overloads.
35432         (__arm_vddupq_x_u16): Change _coerce_ overloads.
35433         (__arm_vidupq_x_u32): Change _coerce_ overloads.
35434         (__arm_vddupq_x_u32): Change _coerce_ overloads.
35435         (__arm_vldrdq_gather_offset): Change _coerce_ overloads.
35436         (__arm_vldrdq_gather_offset_z): Change _coerce_ overloads.
35437         (__arm_vldrdq_gather_shifted_offset): Change _coerce_ overloads.
35438         (__arm_vldrdq_gather_shifted_offset_z): Change _coerce_ overloads.
35439         (__arm_vldrbq_gather_offset_z): Change _coerce_ overloads.
35440         (__arm_vidupq_u16): Change _coerce_ overloads.
35441         (__arm_vidupq_u32): Change _coerce_ overloads.
35442         (__arm_vidupq_u8): Change _coerce_ overloads.
35443         (__arm_vddupq_u16): Change _coerce_ overloads.
35444         (__arm_vddupq_u32): Change _coerce_ overloads.
35445         (__arm_vddupq_u8): Change _coerce_ overloads.
35446         (__arm_viwdupq_m): Change _coerce_ overloads.
35447         (__arm_viwdupq_u16): Change _coerce_ overloads.
35448         (__arm_viwdupq_u32): Change _coerce_ overloads.
35449         (__arm_viwdupq_u8): Change _coerce_ overloads.
35450         (__arm_vdwdupq_m): Change _coerce_ overloads.
35451         (__arm_vdwdupq_u16): Change _coerce_ overloads.
35452         (__arm_vdwdupq_u32): Change _coerce_ overloads.
35453         (__arm_vdwdupq_u8): Change _coerce_ overloads.
35454         (__arm_vstrbq): Change _coerce_ overloads.
35455         (__arm_vstrbq_p): Change _coerce_ overloads.
35456         (__arm_vstrbq_scatter_offset_p): Change _coerce_ overloads.
35457         (__arm_vstrdq_scatter_offset_p): Change _coerce_ overloads.
35458         (__arm_vstrdq_scatter_offset): Change _coerce_ overloads.
35459         (__arm_vstrdq_scatter_shifted_offset_p): Change _coerce_ overloads.
35460         (__arm_vstrdq_scatter_shifted_offset): Change _coerce_ overloads.
35462 2023-05-18  Stam Markianos-Wright  <stam.markianos-wright@arm.com>
35464         * config/arm/arm_mve.h (__arm_vbicq): Change coerce on
35465         scalar constant.
35467 2023-05-18  Stam Markianos-Wright  <stam.markianos-wright@arm.com>
35469         * config/arm/arm_mve.h (__arm_vadcq_s32): Fix arithmetic.
35470         (__arm_vadcq_u32): Likewise.
35471         (__arm_vadcq_m_s32): Likewise.
35472         (__arm_vadcq_m_u32): Likewise.
35473         (__arm_vsbcq_s32): Likewise.
35474         (__arm_vsbcq_u32): Likewise.
35475         (__arm_vsbcq_m_s32): Likewise.
35476         (__arm_vsbcq_m_u32): Likewise.
35477         * config/arm/mve.md (get_fpscr_nzcvqc): Make unspec_volatile.
35479 2023-05-18  Andrea Corallo  <andrea.corallo@arm.com>
35481         * config/arm/mve.md (mve_vrndq_m_f<mode>, mve_vrev64q_f<mode>)
35482         (mve_vrev32q_fv8hf, mve_vcvttq_f32_f16v4sf)
35483         (mve_vcvtbq_f32_f16v4sf, mve_vcvtq_to_f_<supf><mode>)
35484         (mve_vrev64q_<supf><mode>, mve_vcvtq_from_f_<supf><mode>)
35485         (mve_vmovltq_<supf><mode>, mve_vmovlbq_<supf><mode>)
35486         (mve_vcvtpq_<supf><mode>, mve_vcvtnq_<supf><mode>)
35487         (mve_vcvtmq_<supf><mode>, mve_vcvtaq_<supf><mode>)
35488         (mve_vmvnq_n_<supf><mode>, mve_vrev16q_<supf>v16qi)
35489         (mve_vctp<MVE_vctp>q<MVE_vpred>, mve_vbrsrq_n_f<mode>)
35490         (mve_vbrsrq_n_<supf><mode>, mve_vandq_f<mode>, mve_vbicq_f<mode>)
35491         (mve_vctp<MVE_vctp>q_m<MVE_vpred>, mve_vcvtbq_f16_f32v8hf)
35492         (mve_vcvttq_f16_f32v8hf, mve_veorq_f<mode>)
35493         (mve_vmlaldavxq_s<mode>, mve_vmlsldavq_s<mode>)
35494         (mve_vmlsldavxq_s<mode>, mve_vornq_f<mode>, mve_vorrq_f<mode>)
35495         (mve_vrmlaldavhxq_sv4si, mve_vcvtq_m_to_f_<supf><mode>)
35496         (mve_vshlcq_<supf><mode>, mve_vmvnq_m_<supf><mode>)
35497         (mve_vpselq_<supf><mode>, mve_vcvtbq_m_f16_f32v8hf)
35498         (mve_vcvtbq_m_f32_f16v4sf, mve_vcvttq_m_f16_f32v8hf)
35499         (mve_vcvttq_m_f32_f16v4sf, mve_vmlaldavq_p_<supf><mode>)
35500         (mve_vmlsldavaq_s<mode>, mve_vmlsldavaxq_s<mode>)
35501         (mve_vmlsldavq_p_s<mode>, mve_vmlsldavxq_p_s<mode>)
35502         (mve_vmvnq_m_n_<supf><mode>, mve_vorrq_m_n_<supf><mode>)
35503         (mve_vpselq_f<mode>, mve_vrev32q_m_fv8hf)
35504         (mve_vrev32q_m_<supf><mode>, mve_vrev64q_m_f<mode>)
35505         (mve_vrmlaldavhaxq_sv4si, mve_vrmlaldavhxq_p_sv4si)
35506         (mve_vrmlsldavhaxq_sv4si, mve_vrmlsldavhq_p_sv4si)
35507         (mve_vrmlsldavhxq_p_sv4si, mve_vrev16q_m_<supf>v16qi)
35508         (mve_vrmlaldavhq_p_<supf>v4si, mve_vrmlsldavhaq_sv4si)
35509         (mve_vandq_m_<supf><mode>, mve_vbicq_m_<supf><mode>)
35510         (mve_veorq_m_<supf><mode>, mve_vornq_m_<supf><mode>)
35511         (mve_vorrq_m_<supf><mode>, mve_vandq_m_f<mode>)
35512         (mve_vbicq_m_f<mode>, mve_veorq_m_f<mode>, mve_vornq_m_f<mode>)
35513         (mve_vorrq_m_f<mode>)
35514         (mve_vstrdq_scatter_shifted_offset_p_<supf>v2di_insn)
35515         (mve_vstrdq_scatter_shifted_offset_<supf>v2di_insn)
35516         (mve_vstrdq_scatter_base_wb_p_<supf>v2di) : Fix spacing and
35517         capitalization in the emitted asm.
35519 2023-05-18  Andrea Corallo  <andrea.corallo@arm.com>
35521         * config/arm/constraints.md (mve_vldrd_immediate): Move it to
35522         predicates.md.
35523         (Ri): Move constraint definition from predicates.md.
35524         (Rl): Define new constraint.
35525         * config/arm/mve.md (mve_vstrwq_scatter_base_wb_p_<supf>v4si): Add
35526         missing constraint.
35527         (mve_vstrwq_scatter_base_wb_p_fv4sf): Add missing Up constraint
35528         for op 1, use mve_vstrw_immediate predicate and Rl constraint for
35529         op 2. Fix asm output spacing.
35530         (mve_vstrdq_scatter_base_wb_p_<supf>v2di): Add missing constraint.
35531         * config/arm/predicates.md (Ri) Move constraint to constraints.md
35532         (mve_vldrd_immediate): Move it from
35533         constraints.md.
35534         (mve_vstrw_immediate): New predicate.
35536 2023-05-18  Pan Li  <pan2.li@intel.com>
35537             Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
35538             Kito Cheng  <kito.cheng@sifive.com>
35539             Richard Biener  <rguenther@suse.de>
35540             Richard Sandiford  <richard.sandiford@arm.com>
35542         * combine.cc (struct reg_stat_type): Extend machine_mode to 16 bits.
35543         * cse.cc (struct qty_table_elem): Extend machine_mode to 16 bits
35544         (struct table_elt): Extend machine_mode to 16 bits.
35545         (struct set): Ditto.
35546         * genmodes.cc (emit_mode_wider): Extend type from char to short.
35547         (emit_mode_complex): Ditto.
35548         (emit_mode_inner): Ditto.
35549         (emit_class_narrowest_mode): Ditto.
35550         * genopinit.cc (main): Extend the machine_mode limit.
35551         * ira-int.h (struct ira_allocno): Extend machine_mode to 16 bits and
35552         re-ordered the struct fields for padding.
35553         * machmode.h (MACHINE_MODE_BITSIZE): New macro.
35554         (GET_MODE_2XWIDER_MODE): Extend type from char to short.
35555         (get_mode_alignment): Extend type from char to short.
35556         * ree.cc (struct ext_modified): Extend machine_mode to 16 bits and
35557         removed the ATTRIBUTE_PACKED.
35558         * rtl-ssa/accesses.h: Extend machine_mode to 16 bits, narrow
35559         * rtl-ssa/internals.inl (rtl_ssa::access_info): Adjust the assignment.
35560         m_kind to 2 bits and remove m_spare.
35561         * rtl.h (RTX_CODE_BITSIZE): New macro.
35562         (struct rtx_def): Swap both the bit size and location between the
35563         rtx_code and the machine_mode.
35564         (subreg_shape::unique_id): Extend the machine_mode limit.
35565         * rtlanal.h: Extend machine_mode to 16 bits.
35566         * tree-core.h (struct tree_type_common): Extend machine_mode to 16
35567         bits and re-ordered the struct fields for padding.
35568         (struct tree_decl_common): Extend machine_mode to 16 bits.
35570 2023-05-17  Jin Ma  <jinma@linux.alibaba.com>
35572         * genrecog.cc (print_nonbool_test): Fix type error of
35573         switch (SUBREG_BYTE (op))'.
35575 2023-05-17  Jin Ma  <jinma@linux.alibaba.com>
35577         * common/config/riscv/riscv-common.cc: Remove
35578         trailing spaces on lines.
35579         * config/riscv/riscv.cc (riscv_legitimize_move): Likewise.
35580         * config/riscv/riscv.h (enum reg_class): Likewise.
35581         * config/riscv/riscv.md: Likewise.
35583 2023-05-17  John David Anglin  <danglin@gcc.gnu.org>
35585         * config/pa/pa.md (clear_cache): New.
35587 2023-05-17  Arsen Arsenović  <arsen@aarsen.me>
35589         * doc/extend.texi (C++ Concepts) <forall>: Remove extraneous
35590         parenthesis.  Fix misnamed index entry.
35591         <concept>: Fix misnamed index entry.
35593 2023-05-17  Jivan Hakobyan  <jivanhakobyan9@gmail.com>
35595         * config/riscv/riscv.md (*<optab><GPR:mode>3_mask): New pattern,
35596         combined from ...
35597         (*<optab>si3_mask, *<optab>di3_mask): Here.
35598         (*<optab>si3_mask_1, *<optab>di3_mask_1): And here.
35599         * config/riscv/bitmanip.md (*<bitmanip_optab><GPR:mode>3_mask): New
35600         pattern.
35601         (*<bitmanip_optab>si3_sext_mask): Likewise.
35602         * config/riscv/iterators.md (shiftm1): Use const_si_mask_operand
35603         and const_di_mask_operand.
35604         (bitmanip_rotate): New iterator.
35605         (bitmanip_optab): Add rotates.
35606         * config/riscv/predicates.md (const_si_mask_operand): Renamed
35607         from const31_operand.  Generalize to handle more mask constants.
35608         (const_di_mask_operand): Similarly.
35610 2023-05-17  Jakub Jelinek  <jakub@redhat.com>
35612         PR c++/109884
35613         * config/i386/i386-builtin-types.def (FLOAT128): Use
35614         float128t_type_node rather than float128_type_node.
35616 2023-05-17  Alexander Monakov  <amonakov@ispras.ru>
35618         * tree-ssa-math-opts.cc (convert_mult_to_fma): Enable only for
35619         FP_CONTRACT_FAST (no functional change).
35621 2023-05-17  Uros Bizjak  <ubizjak@gmail.com>
35623         * config/i386/i386.cc (ix86_multiplication_cost): Correct
35624         calcuation of integer vector mode costs to reflect generated
35625         instruction sequences of different integer vector modes and
35626         different target ABIs.
35628 2023-05-17  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
35630         * config/riscv/riscv-opts.h (enum riscv_entity): New enum.
35631         * config/riscv/riscv.cc (riscv_emit_mode_set): New function.
35632         (riscv_mode_needed): Ditto.
35633         (riscv_mode_after): Ditto.
35634         (riscv_mode_entry): Ditto.
35635         (riscv_mode_exit): Ditto.
35636         (riscv_mode_priority): Ditto.
35637         (TARGET_MODE_EMIT): New target hook.
35638         (TARGET_MODE_NEEDED): Ditto.
35639         (TARGET_MODE_AFTER): Ditto.
35640         (TARGET_MODE_ENTRY): Ditto.
35641         (TARGET_MODE_EXIT): Ditto.
35642         (TARGET_MODE_PRIORITY): Ditto.
35643         * config/riscv/riscv.h (OPTIMIZE_MODE_SWITCHING): Ditto.
35644         (NUM_MODES_FOR_MODE_SWITCHING): Ditto.
35645         * config/riscv/riscv.md: Add csrwvxrm.
35646         * config/riscv/vector.md (rnu,rne,rdn,rod,none): New attribute.
35647         (vxrmsi): New pattern.
35649 2023-05-17  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
35651         * config/riscv/riscv-vector-builtins-bases.cc: Introduce rounding mode.
35652         * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_def): Ditto.
35653         (struct narrow_alu_def): Ditto.
35654         * config/riscv/riscv-vector-builtins.cc (function_builder::apply_predication): Ditto.
35655         (function_expander::use_exact_insn): Ditto.
35656         * config/riscv/riscv-vector-builtins.h (function_checker::arg_num): New function.
35657         (function_base::has_rounding_mode_operand_p): New function.
35659 2023-05-17  Andrew Pinski  <apinski@marvell.com>
35661         * tree-ssa-forwprop.cc (simplify_builtin_call): Check
35662         against 0 instead of calling integer_zerop.
35664 2023-05-17  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
35666         * config/riscv/riscv-vector-builtins.cc (register_vxrm): New function.
35667         (DEF_RVV_VXRM_ENUM): New macro.
35668         (handle_pragma_vector): Add vxrm enum register.
35669         * config/riscv/riscv-vector-builtins.def (DEF_RVV_VXRM_ENUM): New macro.
35670         (RNU): Ditto.
35671         (RNE): Ditto.
35672         (RDN): Ditto.
35673         (ROD): Ditto.
35675 2023-05-17  Aldy Hernandez  <aldyh@redhat.com>
35677         * value-range.h (Value_Range::operator=): New.
35679 2023-05-17  Aldy Hernandez  <aldyh@redhat.com>
35681         * value-range.cc (vrange::operator=): Add a stub to copy
35682         unsupported ranges.
35683         * value-range.h (is_a <unsupported_range>): New.
35684         (Value_Range::operator=): Support copying unsupported ranges.
35686 2023-05-17  Aldy Hernandez  <aldyh@redhat.com>
35688         * data-streamer-in.cc (streamer_read_real_value): New.
35689         (streamer_read_value_range): New.
35690         * data-streamer-out.cc (streamer_write_real_value): New.
35691         (streamer_write_vrange): New.
35692         * data-streamer.h (streamer_write_vrange): New.
35693         (streamer_read_value_range): New.
35695 2023-05-17  Jonathan Wakely  <jwakely@redhat.com>
35697         PR c++/109532
35698         * doc/invoke.texi (Code Gen Options): Note that -fshort-enums
35699         is ignored for a fixed underlying type.
35700         (C++ Dialect Options): Likewise for -fstrict-enums.
35702 2023-05-17  Tobias Burnus  <tobias@codesourcery.com>
35704         * gimplify.cc (gimplify_scan_omp_clauses): Remove Fortran
35705         special case.
35707 2023-05-17  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
35709         * config/s390/s390.cc (TARGET_ATOMIC_ALIGN_FOR_MODE):
35710         New.
35711         (s390_atomic_align_for_mode): New.
35713 2023-05-17  Jakub Jelinek  <jakub@redhat.com>
35715         * wide-int.cc (wi::from_array): Add missing closing paren in function
35716         comment.
35718 2023-05-17  Kewen Lin  <linkw@linux.ibm.com>
35720         * tree-vect-loop.cc (vect_analyze_loop_1): Don't retry analysis with
35721         suggested unroll factor once the previous analysis fails.
35723 2023-05-17  Pan Li  <pan2.li@intel.com>
35725         * config/riscv/genrvv-type-indexer.cc (BOOL_SIZE_LIST): New
35726         macro.
35727         (main): Add bool1 to the type indexer.
35728         * config/riscv/riscv-vector-builtins-functions.def
35729         (vreinterpret): Register vbool1 interpret function.
35730         * config/riscv/riscv-vector-builtins-types.def
35731         (DEF_RVV_BOOL1_INTERPRET_OPS): New macro.
35732         (vint8m1_t): Add the type to bool1_interpret_ops.
35733         (vint16m1_t): Ditto.
35734         (vint32m1_t): Ditto.
35735         (vint64m1_t): Ditto.
35736         (vuint8m1_t): Ditto.
35737         (vuint16m1_t): Ditto.
35738         (vuint32m1_t): Ditto.
35739         (vuint64m1_t): Ditto.
35740         * config/riscv/riscv-vector-builtins.cc
35741         (DEF_RVV_BOOL1_INTERPRET_OPS): New macro.
35742         (required_extensions_p): Add bool1 interpret case.
35743         * config/riscv/riscv-vector-builtins.def
35744         (bool1_interpret): Add bool1 interpret to base type.
35745         * config/riscv/vector.md (@vreinterpret<mode>): Add new expand
35746         with VB dest for vreinterpret.
35748 2023-05-17  Jiufu Guo  <guojiufu@linux.ibm.com>
35750         PR target/106708
35751         * config/rs6000/rs6000.cc (rs6000_emit_set_long_const): Support building
35752         constants through "lis; xoris".
35754 2023-05-16  Ajit Kumar Agarwal  <aagarwa1@linux.ibm.com>
35756         * common/config/rs6000/rs6000-common.cc: Add REE pass as a
35757         default rs6000 target pass for O2 and above.
35758         * doc/invoke.texi: Document -free
35760 2023-05-16  Kito Cheng  <kito.cheng@sifive.com>
35762         * common/config/riscv/riscv-common.cc (riscv_compute_multilib):
35763         Fix wrong select_kind...
35765 2023-05-16  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
35767         * config/s390/s390-protos.h (s390_expand_setmem): Change
35768         function signature.
35769         * config/s390/s390.cc (s390_expand_setmem): For memset's less
35770         than or equal to 256 byte do not perform a libc call.
35771         * config/s390/s390.md: Change expander into a version which
35772         takes 8 operands.
35774 2023-05-16  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
35776         * config/s390/s390-protos.h (s390_expand_movmem): New.
35777         * config/s390/s390.cc (s390_expand_movmem): New.
35778         * config/s390/s390.md (movmem<mode>): New.
35779         (*mvcrl): New.
35780         (mvcrl): New.
35782 2023-05-16  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
35784         * config/s390/s390-protos.h (s390_expand_cpymem): Change
35785         function signature.
35786         * config/s390/s390.cc (s390_expand_cpymem): For memcpy's less
35787         than or equal to 256 byte do not perform a libc call.
35788         (s390_expand_insv): Adapt new function signature of
35789         s390_expand_cpymem.
35790         * config/s390/s390.md: Change expander into a version which
35791         takes 8 operands.
35793 2023-05-16  Andrew Pinski  <apinski@marvell.com>
35795         PR tree-optimization/109424
35796         * match.pd: Add patterns for min/max of zero_one_valued
35797         values to `&`/`|`.
35799 2023-05-16  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
35801         * config/riscv/riscv-protos.h (enum frm_field_enum): New enum.
35802         * config/riscv/riscv-vector-builtins.cc
35803         (function_expander::use_ternop_insn): Add default rounding mode.
35804         (function_expander::use_widen_ternop_insn): Ditto.
35805         * config/riscv/riscv.cc (riscv_hard_regno_nregs): Add FRM REGNUM.
35806         (riscv_hard_regno_mode_ok): Ditto.
35807         (riscv_conditional_register_usage): Ditto.
35808         * config/riscv/riscv.h (DWARF_FRAME_REGNUM): Ditto.
35809         (FRM_REG_P): Ditto.
35810         (RISCV_DWARF_FRM): Ditto.
35811         * config/riscv/riscv.md: Ditto.
35812         * config/riscv/vector-iterators.md: split no frm and has frm operations.
35813         * config/riscv/vector.md (@pred_<optab><mode>_scalar): New pattern.
35814         (@pred_<optab><mode>): Ditto.
35816 2023-05-15  Aldy Hernandez  <aldyh@redhat.com>
35818         PR tree-optimization/109695
35819         * value-range.cc (irange::operator=): Resize range.
35820         (irange::union_): Same.
35821         (irange::intersect): Same.
35822         (irange::invert): Same.
35823         (int_range_max): Default to 3 sub-ranges and resize as needed.
35824         * value-range.h (irange::maybe_resize): New.
35825         (~int_range): New.
35826         (int_range::int_range): Adjust for resizing.
35827         (int_range::operator=): Same.
35829 2023-05-15  Aldy Hernandez  <aldyh@redhat.com>
35831         * ipa-cp.cc (ipcp_vr_lattice::meet_with_1): Avoid unnecessary
35832         range copying
35833         * value-range.cc (irange::union_nonzero_bits): Return TRUE only
35834         when range changed.
35836 2023-05-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
35838         * config/riscv/riscv-protos.h (enum vxrm_field_enum): New enum.
35839         * config/riscv/riscv-vector-builtins.cc
35840         (function_expander::use_exact_insn): Add default rounding mode operand.
35841         * config/riscv/riscv.cc (riscv_hard_regno_nregs): Add VXRM_REGNUM.
35842         (riscv_hard_regno_mode_ok): Ditto.
35843         (riscv_conditional_register_usage): Ditto.
35844         * config/riscv/riscv.h (DWARF_FRAME_REGNUM): Ditto.
35845         (VXRM_REG_P): Ditto.
35846         (RISCV_DWARF_VXRM): Ditto.
35847         * config/riscv/riscv.md: Ditto.
35848         * config/riscv/vector.md: Ditto
35850 2023-05-15  Pan Li  <pan2.li@intel.com>
35852         * optabs.cc (maybe_gen_insn): Add case to generate instruction
35853         that has 11 operands.
35855 2023-05-15  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
35857         * config/aarch64/aarch64.cc (aarch64_rtx_costs, NEG case): Add costing
35858         logic for vector modes.
35860 2023-05-15  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
35862         PR target/99195
35863         * config/aarch64/aarch64-simd.md (aarch64_cm<optab><mode>): Rename to...
35864         (aarch64_cm<optab><mode><vczle><vczbe>): ... This.
35865         (aarch64_cmtst<mode>): Rename to...
35866         (aarch64_cmtst<mode><vczle><vczbe>): ... This.
35867         (*aarch64_cmtst_same_<mode>): Rename to...
35868         (*aarch64_cmtst_same_<mode><vczle><vczbe>): ... This.
35869         (*aarch64_cmtstdi): Rename to...
35870         (*aarch64_cmtstdi<vczle><vczbe>): ... This.
35871         (aarch64_fac<optab><mode>): Rename to...
35872         (aarch64_fac<optab><mode><vczle><vczbe>): ... This.
35874 2023-05-15  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
35876         PR target/99195
35877         * config/aarch64/aarch64-simd.md (aarch64_s<optab><mode>): Rename to...
35878         (aarch64_s<optab><mode><vczle><vczbe>): ... This.
35880 2023-05-15  Pan Li  <pan2.li@intel.com>
35881             Juzhe-Zhong  <juzhe.zhong@rivai.ai>
35882             kito-cheng  <kito.cheng@sifive.com>
35884         * config/riscv/riscv-v.cc (const_vlmax_p): New function for
35885         deciding the mode is constant or not.
35886         (set_len_and_policy): Optimize VLS-VLMAX code gen to vsetivli.
35888 2023-05-15  Richard Biener  <rguenther@suse.de>
35890         PR tree-optimization/109848
35891         * tree-ssa-forwprop.cc (pass_forwprop::execute): Put the
35892         TARGET_MEM_REF address preparation before the store, not
35893         before the CTOR.
35895 2023-05-15  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
35897         * config/riscv/riscv.cc
35898         (riscv_vectorize_preferred_vector_alignment): New function.
35899         (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): New target hook.
35901 2023-05-14  Andrew Pinski  <apinski@marvell.com>
35903         PR tree-optimization/109829
35904         * match.pd: Add pattern for `signbit(x) !=/== 0 ? x : -x`.
35906 2023-05-14  Uros Bizjak  <ubizjak@gmail.com>
35908         PR target/109807
35909         * config/i386/i386.cc: Revert the 2023-05-11 change.
35910         (ix86_widen_mult_cost): Return high value instead of
35911         ICEing for unsupported modes.
35913 2023-05-14  Ard Biesheuvel  <ardb@kernel.org>
35915         * config/i386/i386.cc (x86_function_profiler): Take
35916         ix86_direct_extern_access into account when generating calls
35917         to __fentry__()
35919 2023-05-14  Pan Li  <pan2.li@intel.com>
35921         * config/riscv/riscv-vector-builtins.cc (required_extensions_p):
35922         Refactor the or pattern to switch cases.
35924 2023-05-13  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
35926         * config/aarch64/aarch64.cc (aarch64_expand_vector_init_fallback): Rename
35927         aarch64_expand_vector_init to this, and remove  interleaving case.
35928         Recursively call aarch64_expand_vector_init_fallback, instead of
35929         aarch64_expand_vector_init.
35930         (aarch64_unzip_vector_init): New function.
35931         (aarch64_expand_vector_init): Likewise.
35933 2023-05-13  Kito Cheng  <kito.cheng@sifive.com>
35935         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::cleanup_insns):
35936         Pull out function call from the gcc_assert.
35938 2023-05-13  Kito Cheng  <kito.cheng@sifive.com>
35940         * config/riscv/riscv-vsetvl.cc (vlmul_to_str): New.
35941         (policy_to_str): New.
35942         (vector_insn_info::dump): Use vlmul_to_str and policy_to_str.
35944 2023-05-13  Andrew Pinski  <apinski@marvell.com>
35946         PR tree-optimization/109834
35947         * match.pd (popcount(bswap(x))->popcount(x)): Fix up unsigned type checking.
35948         (popcount(rotate(x,y))->popcount(x)): Likewise.
35950 2023-05-12  Uros Bizjak  <ubizjak@gmail.com>
35952         * config/i386/i386-expand.cc (ix86_expand_vecop_qihi2): Also
35953         reject ymm instructions for TARGET_PREFER_AVX128.  Use generic
35954         gen_extend_insn to generate zero/sign extension instructions.
35955         Fix comments.
35956         (ix86_expand_vecop_qihi): Initialize interleave functions
35957         for MULT code only.  Fix comments.
35959 2023-05-12  Uros Bizjak  <ubizjak@gmail.com>
35961         PR target/109797
35962         * config/i386/mmx.md (mulv2si3): Remove expander.
35963         (mulv2si3): Rename insn pattern from *mulv2si.
35965 2023-05-12  Tobias Burnus  <tobias@codesourcery.com>
35967         PR libstdc++/109816
35968         * lto-cgraph.cc (output_symtab): Guard lto_output_toplevel_asms by
35969         '!lto_stream_offload_p'.
35971 2023-05-12  Kito Cheng  <kito.cheng@sifive.com>
35972             Juzhe-Zhong  <juzhe.zhong@rivai.ai>
35974         PR target/109743
35975         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::get_vsetvl_at_end): New.
35976         (local_avl_compatible_p): New.
35977         (pass_vsetvl::local_eliminate_vsetvl_insn): Enhance local optimizations
35978         for LCM, rewrite as a backward algorithm.
35979         (pass_vsetvl::cleanup_insns): Use new local_eliminate_vsetvl_insn
35980         interface, handle a BB at once.
35982 2023-05-12  Richard Biener  <rguenther@suse.de>
35984         PR tree-optimization/64731
35985         * tree-ssa-forwprop.cc (pass_forwprop::execute): Also
35986         handle TARGET_MEM_REF destinations of stores from vector
35987         CTORs.
35989 2023-05-12  Richard Biener  <rguenther@suse.de>
35991         PR tree-optimization/109791
35992         * match.pd (minus (convert ADDR_EXPR@0) (convert (pointer_plus @1 @2))):
35993         New pattern.
35994         (minus (convert (pointer_plus @1 @2)) (convert ADDR_EXPR@0)):
35995         Likewise.
35997 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
35999         * config/arm/arm-mve-builtins-base.cc (vsriq): New.
36000         * config/arm/arm-mve-builtins-base.def (vsriq): New.
36001         * config/arm/arm-mve-builtins-base.h (vsriq): New.
36002         * config/arm/arm-mve-builtins.cc
36003         (function_instance::has_inactive_argument): Handle vsriq.
36004         * config/arm/arm_mve.h (vsriq): Remove.
36005         (vsriq_m): Remove.
36006         (vsriq_n_u8): Remove.
36007         (vsriq_n_s8): Remove.
36008         (vsriq_n_u16): Remove.
36009         (vsriq_n_s16): Remove.
36010         (vsriq_n_u32): Remove.
36011         (vsriq_n_s32): Remove.
36012         (vsriq_m_n_s8): Remove.
36013         (vsriq_m_n_u8): Remove.
36014         (vsriq_m_n_s16): Remove.
36015         (vsriq_m_n_u16): Remove.
36016         (vsriq_m_n_s32): Remove.
36017         (vsriq_m_n_u32): Remove.
36018         (__arm_vsriq_n_u8): Remove.
36019         (__arm_vsriq_n_s8): Remove.
36020         (__arm_vsriq_n_u16): Remove.
36021         (__arm_vsriq_n_s16): Remove.
36022         (__arm_vsriq_n_u32): Remove.
36023         (__arm_vsriq_n_s32): Remove.
36024         (__arm_vsriq_m_n_s8): Remove.
36025         (__arm_vsriq_m_n_u8): Remove.
36026         (__arm_vsriq_m_n_s16): Remove.
36027         (__arm_vsriq_m_n_u16): Remove.
36028         (__arm_vsriq_m_n_s32): Remove.
36029         (__arm_vsriq_m_n_u32): Remove.
36030         (__arm_vsriq): Remove.
36031         (__arm_vsriq_m): Remove.
36033 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36035         * config/arm/iterators.md (mve_insn): Add vsri.
36036         * config/arm/mve.md (mve_vsriq_n_<supf><mode>): Rename into ...
36037         (@mve_<mve_insn>q_n_<supf><mode>): .,. this.
36038         (mve_vsriq_m_n_<supf><mode>): Rename into ...
36039         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
36041 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36043         * config/arm/arm-mve-builtins-shapes.cc (ternary_rshift): New.
36044         * config/arm/arm-mve-builtins-shapes.h (ternary_rshift): New.
36046 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36048         * config/arm/arm-mve-builtins-base.cc (vsliq): New.
36049         * config/arm/arm-mve-builtins-base.def (vsliq): New.
36050         * config/arm/arm-mve-builtins-base.h (vsliq): New.
36051         * config/arm/arm-mve-builtins.cc
36052         (function_instance::has_inactive_argument): Handle vsliq.
36053         * config/arm/arm_mve.h (vsliq): Remove.
36054         (vsliq_m): Remove.
36055         (vsliq_n_u8): Remove.
36056         (vsliq_n_s8): Remove.
36057         (vsliq_n_u16): Remove.
36058         (vsliq_n_s16): Remove.
36059         (vsliq_n_u32): Remove.
36060         (vsliq_n_s32): Remove.
36061         (vsliq_m_n_s8): Remove.
36062         (vsliq_m_n_s32): Remove.
36063         (vsliq_m_n_s16): Remove.
36064         (vsliq_m_n_u8): Remove.
36065         (vsliq_m_n_u32): Remove.
36066         (vsliq_m_n_u16): Remove.
36067         (__arm_vsliq_n_u8): Remove.
36068         (__arm_vsliq_n_s8): Remove.
36069         (__arm_vsliq_n_u16): Remove.
36070         (__arm_vsliq_n_s16): Remove.
36071         (__arm_vsliq_n_u32): Remove.
36072         (__arm_vsliq_n_s32): Remove.
36073         (__arm_vsliq_m_n_s8): Remove.
36074         (__arm_vsliq_m_n_s32): Remove.
36075         (__arm_vsliq_m_n_s16): Remove.
36076         (__arm_vsliq_m_n_u8): Remove.
36077         (__arm_vsliq_m_n_u32): Remove.
36078         (__arm_vsliq_m_n_u16): Remove.
36079         (__arm_vsliq): Remove.
36080         (__arm_vsliq_m): Remove.
36082 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36084         * config/arm/iterators.md (mve_insn>): Add vsli.
36085         * config/arm/mve.md (mve_vsliq_n_<supf><mode>): Rename into ...
36086         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
36087         (mve_vsliq_m_n_<supf><mode>): Rename into ...
36088         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
36090 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36092         * config/arm/arm-mve-builtins-shapes.cc (ternary_lshift): New.
36093         * config/arm/arm-mve-builtins-shapes.h (ternary_lshift): New.
36095 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36097         * config/arm/arm-mve-builtins-base.cc (vpselq): New.
36098         * config/arm/arm-mve-builtins-base.def (vpselq): New.
36099         * config/arm/arm-mve-builtins-base.h (vpselq): New.
36100         * config/arm/arm_mve.h (vpselq): Remove.
36101         (vpselq_u8): Remove.
36102         (vpselq_s8): Remove.
36103         (vpselq_u16): Remove.
36104         (vpselq_s16): Remove.
36105         (vpselq_u32): Remove.
36106         (vpselq_s32): Remove.
36107         (vpselq_u64): Remove.
36108         (vpselq_s64): Remove.
36109         (vpselq_f16): Remove.
36110         (vpselq_f32): Remove.
36111         (__arm_vpselq_u8): Remove.
36112         (__arm_vpselq_s8): Remove.
36113         (__arm_vpselq_u16): Remove.
36114         (__arm_vpselq_s16): Remove.
36115         (__arm_vpselq_u32): Remove.
36116         (__arm_vpselq_s32): Remove.
36117         (__arm_vpselq_u64): Remove.
36118         (__arm_vpselq_s64): Remove.
36119         (__arm_vpselq_f16): Remove.
36120         (__arm_vpselq_f32): Remove.
36121         (__arm_vpselq): Remove.
36123 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36125         * config/arm/arm-mve-builtins-shapes.cc (vpsel): New.
36126         * config/arm/arm-mve-builtins-shapes.h (vpsel): New.
36128 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36130         * config/arm/arm.cc (arm_expand_vcond): Use gen_mve_q instead of
36131         gen_mve_vpselq.
36132         * config/arm/iterators.md (MVE_VPSELQ_F): New.
36133         (mve_insn): Add vpsel.
36134         * config/arm/mve.md (@mve_vpselq_<supf><mode>): Rename into ...
36135         (@mve_<mve_insn>q_<supf><mode>): ... this.
36136         (@mve_vpselq_f<mode>): Rename into ...
36137         (@mve_<mve_insn>q_f<mode>): ... this.
36139 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36141         * config/arm/arm-mve-builtins-base.cc (vfmaq, vfmasq, vfmsq): New.
36142         * config/arm/arm-mve-builtins-base.def (vfmaq, vfmasq, vfmsq): New.
36143         * config/arm/arm-mve-builtins-base.h (vfmaq, vfmasq, vfmsq): New.
36144         * config/arm/arm-mve-builtins.cc
36145         (function_instance::has_inactive_argument): Handle vfmaq, vfmasq,
36146         vfmsq.
36147         * config/arm/arm_mve.h (vfmaq): Remove.
36148         (vfmasq): Remove.
36149         (vfmsq): Remove.
36150         (vfmaq_m): Remove.
36151         (vfmasq_m): Remove.
36152         (vfmsq_m): Remove.
36153         (vfmaq_f16): Remove.
36154         (vfmaq_n_f16): Remove.
36155         (vfmasq_n_f16): Remove.
36156         (vfmsq_f16): Remove.
36157         (vfmaq_f32): Remove.
36158         (vfmaq_n_f32): Remove.
36159         (vfmasq_n_f32): Remove.
36160         (vfmsq_f32): Remove.
36161         (vfmaq_m_f32): Remove.
36162         (vfmaq_m_f16): Remove.
36163         (vfmaq_m_n_f32): Remove.
36164         (vfmaq_m_n_f16): Remove.
36165         (vfmasq_m_n_f32): Remove.
36166         (vfmasq_m_n_f16): Remove.
36167         (vfmsq_m_f32): Remove.
36168         (vfmsq_m_f16): Remove.
36169         (__arm_vfmaq_f16): Remove.
36170         (__arm_vfmaq_n_f16): Remove.
36171         (__arm_vfmasq_n_f16): Remove.
36172         (__arm_vfmsq_f16): Remove.
36173         (__arm_vfmaq_f32): Remove.
36174         (__arm_vfmaq_n_f32): Remove.
36175         (__arm_vfmasq_n_f32): Remove.
36176         (__arm_vfmsq_f32): Remove.
36177         (__arm_vfmaq_m_f32): Remove.
36178         (__arm_vfmaq_m_f16): Remove.
36179         (__arm_vfmaq_m_n_f32): Remove.
36180         (__arm_vfmaq_m_n_f16): Remove.
36181         (__arm_vfmasq_m_n_f32): Remove.
36182         (__arm_vfmasq_m_n_f16): Remove.
36183         (__arm_vfmsq_m_f32): Remove.
36184         (__arm_vfmsq_m_f16): Remove.
36185         (__arm_vfmaq): Remove.
36186         (__arm_vfmasq): Remove.
36187         (__arm_vfmsq): Remove.
36188         (__arm_vfmaq_m): Remove.
36189         (__arm_vfmasq_m): Remove.
36190         (__arm_vfmsq_m): Remove.
36192 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36194         * config/arm/iterators.md (MVE_FP_M_BINARY): Add VFMAQ_M_F,
36195         VFMSQ_M_F.
36196         (MVE_FP_M_N_BINARY): Add VFMAQ_M_N_F, VFMASQ_M_N_F.
36197         (MVE_VFMxQ_F, MVE_VFMAxQ_N_F): New.
36198         (mve_insn): Add vfma, vfmas, vfms.
36199         * config/arm/mve.md (mve_vfmaq_f<mode>, mve_vfmsq_f<mode>): Merge
36200         into ...
36201         (@mve_<mve_insn>q_f<mode>): ... this.
36202         (mve_vfmaq_n_f<mode>, mve_vfmasq_n_f<mode>): Merge into ...
36203         (@mve_<mve_insn>q_n_f<mode>): ... this.
36204         (mve_vfmaq_m_f<mode>, mve_vfmsq_m_f<mode>): Merge into
36205         @mve_<mve_insn>q_m_f<mode>.
36206         (mve_vfmaq_m_n_f<mode>, mve_vfmasq_m_n_f<mode>): Merge into
36207         @mve_<mve_insn>q_m_n_f<mode>.
36209 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36211         * config/arm/arm-mve-builtins-shapes.cc (ternary_opt_n): New.
36212         * config/arm/arm-mve-builtins-shapes.h (ternary_opt_n): New.
36214 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36216         * config/arm/arm-mve-builtins-base.cc
36217         (FUNCTION_WITH_RTX_M_N_NO_F): New.
36218         (vmvnq): New.
36219         * config/arm/arm-mve-builtins-base.def (vmvnq): New.
36220         * config/arm/arm-mve-builtins-base.h (vmvnq): New.
36221         * config/arm/arm_mve.h (vmvnq): Remove.
36222         (vmvnq_m): Remove.
36223         (vmvnq_x): Remove.
36224         (vmvnq_s8): Remove.
36225         (vmvnq_s16): Remove.
36226         (vmvnq_s32): Remove.
36227         (vmvnq_n_s16): Remove.
36228         (vmvnq_n_s32): Remove.
36229         (vmvnq_u8): Remove.
36230         (vmvnq_u16): Remove.
36231         (vmvnq_u32): Remove.
36232         (vmvnq_n_u16): Remove.
36233         (vmvnq_n_u32): Remove.
36234         (vmvnq_m_u8): Remove.
36235         (vmvnq_m_s8): Remove.
36236         (vmvnq_m_u16): Remove.
36237         (vmvnq_m_s16): Remove.
36238         (vmvnq_m_u32): Remove.
36239         (vmvnq_m_s32): Remove.
36240         (vmvnq_m_n_s16): Remove.
36241         (vmvnq_m_n_u16): Remove.
36242         (vmvnq_m_n_s32): Remove.
36243         (vmvnq_m_n_u32): Remove.
36244         (vmvnq_x_s8): Remove.
36245         (vmvnq_x_s16): Remove.
36246         (vmvnq_x_s32): Remove.
36247         (vmvnq_x_u8): Remove.
36248         (vmvnq_x_u16): Remove.
36249         (vmvnq_x_u32): Remove.
36250         (vmvnq_x_n_s16): Remove.
36251         (vmvnq_x_n_s32): Remove.
36252         (vmvnq_x_n_u16): Remove.
36253         (vmvnq_x_n_u32): Remove.
36254         (__arm_vmvnq_s8): Remove.
36255         (__arm_vmvnq_s16): Remove.
36256         (__arm_vmvnq_s32): Remove.
36257         (__arm_vmvnq_n_s16): Remove.
36258         (__arm_vmvnq_n_s32): Remove.
36259         (__arm_vmvnq_u8): Remove.
36260         (__arm_vmvnq_u16): Remove.
36261         (__arm_vmvnq_u32): Remove.
36262         (__arm_vmvnq_n_u16): Remove.
36263         (__arm_vmvnq_n_u32): Remove.
36264         (__arm_vmvnq_m_u8): Remove.
36265         (__arm_vmvnq_m_s8): Remove.
36266         (__arm_vmvnq_m_u16): Remove.
36267         (__arm_vmvnq_m_s16): Remove.
36268         (__arm_vmvnq_m_u32): Remove.
36269         (__arm_vmvnq_m_s32): Remove.
36270         (__arm_vmvnq_m_n_s16): Remove.
36271         (__arm_vmvnq_m_n_u16): Remove.
36272         (__arm_vmvnq_m_n_s32): Remove.
36273         (__arm_vmvnq_m_n_u32): Remove.
36274         (__arm_vmvnq_x_s8): Remove.
36275         (__arm_vmvnq_x_s16): Remove.
36276         (__arm_vmvnq_x_s32): Remove.
36277         (__arm_vmvnq_x_u8): Remove.
36278         (__arm_vmvnq_x_u16): Remove.
36279         (__arm_vmvnq_x_u32): Remove.
36280         (__arm_vmvnq_x_n_s16): Remove.
36281         (__arm_vmvnq_x_n_s32): Remove.
36282         (__arm_vmvnq_x_n_u16): Remove.
36283         (__arm_vmvnq_x_n_u32): Remove.
36284         (__arm_vmvnq): Remove.
36285         (__arm_vmvnq_m): Remove.
36286         (__arm_vmvnq_x): Remove.
36288 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36290         * config/arm/iterators.md (mve_insn): Add vmvn.
36291         * config/arm/mve.md (mve_vmvnq_n_<supf><mode>): Rename into ...
36292         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
36293         (mve_vmvnq_m_<supf><mode>): Rename into ...
36294         (@mve_<mve_insn>q_m_<supf><mode>): ... this.
36295         (mve_vmvnq_m_n_<supf><mode>): Rename into ...
36296         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
36298 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36300         * config/arm/arm-mve-builtins-shapes.cc (mvn): New.
36301         * config/arm/arm-mve-builtins-shapes.h (mvn): New.
36303 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36305         * config/arm/arm-mve-builtins-base.cc (vbrsrq): New.
36306         * config/arm/arm-mve-builtins-base.def (vbrsrq): New.
36307         * config/arm/arm-mve-builtins-base.h (vbrsrq): New.
36308         * config/arm/arm_mve.h (vbrsrq): Remove.
36309         (vbrsrq_m): Remove.
36310         (vbrsrq_x): Remove.
36311         (vbrsrq_n_f16): Remove.
36312         (vbrsrq_n_f32): Remove.
36313         (vbrsrq_n_u8): Remove.
36314         (vbrsrq_n_s8): Remove.
36315         (vbrsrq_n_u16): Remove.
36316         (vbrsrq_n_s16): Remove.
36317         (vbrsrq_n_u32): Remove.
36318         (vbrsrq_n_s32): Remove.
36319         (vbrsrq_m_n_s8): Remove.
36320         (vbrsrq_m_n_s32): Remove.
36321         (vbrsrq_m_n_s16): Remove.
36322         (vbrsrq_m_n_u8): Remove.
36323         (vbrsrq_m_n_u32): Remove.
36324         (vbrsrq_m_n_u16): Remove.
36325         (vbrsrq_m_n_f32): Remove.
36326         (vbrsrq_m_n_f16): Remove.
36327         (vbrsrq_x_n_s8): Remove.
36328         (vbrsrq_x_n_s16): Remove.
36329         (vbrsrq_x_n_s32): Remove.
36330         (vbrsrq_x_n_u8): Remove.
36331         (vbrsrq_x_n_u16): Remove.
36332         (vbrsrq_x_n_u32): Remove.
36333         (vbrsrq_x_n_f16): Remove.
36334         (vbrsrq_x_n_f32): Remove.
36335         (__arm_vbrsrq_n_u8): Remove.
36336         (__arm_vbrsrq_n_s8): Remove.
36337         (__arm_vbrsrq_n_u16): Remove.
36338         (__arm_vbrsrq_n_s16): Remove.
36339         (__arm_vbrsrq_n_u32): Remove.
36340         (__arm_vbrsrq_n_s32): Remove.
36341         (__arm_vbrsrq_m_n_s8): Remove.
36342         (__arm_vbrsrq_m_n_s32): Remove.
36343         (__arm_vbrsrq_m_n_s16): Remove.
36344         (__arm_vbrsrq_m_n_u8): Remove.
36345         (__arm_vbrsrq_m_n_u32): Remove.
36346         (__arm_vbrsrq_m_n_u16): Remove.
36347         (__arm_vbrsrq_x_n_s8): Remove.
36348         (__arm_vbrsrq_x_n_s16): Remove.
36349         (__arm_vbrsrq_x_n_s32): Remove.
36350         (__arm_vbrsrq_x_n_u8): Remove.
36351         (__arm_vbrsrq_x_n_u16): Remove.
36352         (__arm_vbrsrq_x_n_u32): Remove.
36353         (__arm_vbrsrq_n_f16): Remove.
36354         (__arm_vbrsrq_n_f32): Remove.
36355         (__arm_vbrsrq_m_n_f32): Remove.
36356         (__arm_vbrsrq_m_n_f16): Remove.
36357         (__arm_vbrsrq_x_n_f16): Remove.
36358         (__arm_vbrsrq_x_n_f32): Remove.
36359         (__arm_vbrsrq): Remove.
36360         (__arm_vbrsrq_m): Remove.
36361         (__arm_vbrsrq_x): Remove.
36363 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36365         * config/arm/iterators.md (MVE_VBRSR_M_N_FP, MVE_VBRSR_N_FP): New.
36366         (mve_insn): Add vbrsr.
36367         * config/arm/mve.md (mve_vbrsrq_n_f<mode>): Rename into ...
36368         (@mve_<mve_insn>q_n_f<mode>): ... this.
36369         (mve_vbrsrq_n_<supf><mode>): Rename into ...
36370         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
36371         (mve_vbrsrq_m_n_<supf><mode>): Rename into ...
36372         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
36373         (mve_vbrsrq_m_n_f<mode>): Rename into ...
36374         (@mve_<mve_insn>q_m_n_f<mode>): ... this.
36376 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36378         * config/arm/arm-mve-builtins-shapes.cc (binary_imm32): New.
36379         * config/arm/arm-mve-builtins-shapes.h (binary_imm32): New.
36381 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36383         * config/arm/arm-mve-builtins-base.cc (vqshluq): New.
36384         * config/arm/arm-mve-builtins-base.def (vqshluq): New.
36385         * config/arm/arm-mve-builtins-base.h (vqshluq): New.
36386         * config/arm/arm_mve.h (vqshluq): Remove.
36387         (vqshluq_m): Remove.
36388         (vqshluq_n_s8): Remove.
36389         (vqshluq_n_s16): Remove.
36390         (vqshluq_n_s32): Remove.
36391         (vqshluq_m_n_s8): Remove.
36392         (vqshluq_m_n_s16): Remove.
36393         (vqshluq_m_n_s32): Remove.
36394         (__arm_vqshluq_n_s8): Remove.
36395         (__arm_vqshluq_n_s16): Remove.
36396         (__arm_vqshluq_n_s32): Remove.
36397         (__arm_vqshluq_m_n_s8): Remove.
36398         (__arm_vqshluq_m_n_s16): Remove.
36399         (__arm_vqshluq_m_n_s32): Remove.
36400         (__arm_vqshluq): Remove.
36401         (__arm_vqshluq_m): Remove.
36403 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36405         * config/arm/iterators.md (mve_insn): Add vqshlu.
36406         (supf): Add VQSHLUQ_M_N_S, VQSHLUQ_N_S.
36407         (VQSHLUQ_M_N, VQSHLUQ_N): New.
36408         * config/arm/mve.md (mve_vqshluq_n_s<mode>): Change name into ...
36409         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
36410         (mve_vqshluq_m_n_s<mode>): Change name into ...
36411         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
36413 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36415         * config/arm/arm-mve-builtins-shapes.cc
36416         (binary_lshift_unsigned): New.
36417         * config/arm/arm-mve-builtins-shapes.h
36418         (binary_lshift_unsigned): New.
36420 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36422         * config/arm/arm-mve-builtins-base.cc (vrmlaldavhaq)
36423         (vrmlaldavhaxq, vrmlsldavhaq, vrmlsldavhaxq): New.
36424         * config/arm/arm-mve-builtins-base.def (vrmlaldavhaq)
36425         (vrmlaldavhaxq, vrmlsldavhaq, vrmlsldavhaxq): New.
36426         * config/arm/arm-mve-builtins-base.h (vrmlaldavhaq)
36427         (vrmlaldavhaxq, vrmlsldavhaq, vrmlsldavhaxq): New.
36428         * config/arm/arm-mve-builtins-functions.h: Handle vrmlaldavhaq,
36429         vrmlaldavhaxq, vrmlsldavhaq, vrmlsldavhaxq.
36430         * config/arm/arm_mve.h (vrmlaldavhaq): Remove.
36431         (vrmlaldavhaxq): Remove.
36432         (vrmlsldavhaq): Remove.
36433         (vrmlsldavhaxq): Remove.
36434         (vrmlaldavhaq_p): Remove.
36435         (vrmlaldavhaxq_p): Remove.
36436         (vrmlsldavhaq_p): Remove.
36437         (vrmlsldavhaxq_p): Remove.
36438         (vrmlaldavhaq_s32): Remove.
36439         (vrmlaldavhaq_u32): Remove.
36440         (vrmlaldavhaxq_s32): Remove.
36441         (vrmlsldavhaq_s32): Remove.
36442         (vrmlsldavhaxq_s32): Remove.
36443         (vrmlaldavhaq_p_s32): Remove.
36444         (vrmlaldavhaq_p_u32): Remove.
36445         (vrmlaldavhaxq_p_s32): Remove.
36446         (vrmlsldavhaq_p_s32): Remove.
36447         (vrmlsldavhaxq_p_s32): Remove.
36448         (__arm_vrmlaldavhaq_s32): Remove.
36449         (__arm_vrmlaldavhaq_u32): Remove.
36450         (__arm_vrmlaldavhaxq_s32): Remove.
36451         (__arm_vrmlsldavhaq_s32): Remove.
36452         (__arm_vrmlsldavhaxq_s32): Remove.
36453         (__arm_vrmlaldavhaq_p_s32): Remove.
36454         (__arm_vrmlaldavhaq_p_u32): Remove.
36455         (__arm_vrmlaldavhaxq_p_s32): Remove.
36456         (__arm_vrmlsldavhaq_p_s32): Remove.
36457         (__arm_vrmlsldavhaxq_p_s32): Remove.
36458         (__arm_vrmlaldavhaq): Remove.
36459         (__arm_vrmlaldavhaxq): Remove.
36460         (__arm_vrmlsldavhaq): Remove.
36461         (__arm_vrmlsldavhaxq): Remove.
36462         (__arm_vrmlaldavhaq_p): Remove.
36463         (__arm_vrmlaldavhaxq_p): Remove.
36464         (__arm_vrmlsldavhaq_p): Remove.
36465         (__arm_vrmlsldavhaxq_p): Remove.
36467 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36469         * config/arm/iterators.md (MVE_VRMLxLDAVHAxQ)
36470         (MVE_VRMLxLDAVHAxQ_P): New.
36471         (mve_insn): Add vrmlaldavha, vrmlaldavhax, vrmlsldavha,
36472         vrmlsldavhax.
36473         (supf): Add VRMLALDAVHAXQ_P_S, VRMLALDAVHAXQ_S, VRMLSLDAVHAQ_P_S,
36474         VRMLSLDAVHAQ_S, VRMLSLDAVHAXQ_P_S, VRMLSLDAVHAXQ_S,
36475         VRMLALDAVHAQ_P_S.
36476         * config/arm/mve.md (mve_vrmlaldavhaq_<supf>v4si)
36477         (mve_vrmlaldavhaxq_sv4si, mve_vrmlsldavhaxq_sv4si)
36478         (mve_vrmlsldavhaq_sv4si): Merge into ...
36479         (@mve_<mve_insn>q_<supf>v4si): ... this.
36480         (mve_vrmlaldavhaq_p_sv4si, mve_vrmlaldavhaq_p_uv4si)
36481         (mve_vrmlaldavhaxq_p_sv4si, mve_vrmlsldavhaq_p_sv4si)
36482         (mve_vrmlsldavhaxq_p_sv4si): Merge into ...
36483         (@mve_<mve_insn>q_p_<supf>v4si): ... this.
36485 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36487         * config/arm/arm-mve-builtins-base.cc (vqdmullbq, vqdmulltq): New.
36488         * config/arm/arm-mve-builtins-base.def (vqdmullbq, vqdmulltq):
36489         New.
36490         * config/arm/arm-mve-builtins-base.h (vqdmullbq, vqdmulltq): New.
36491         * config/arm/arm_mve.h (vqdmulltq): Remove.
36492         (vqdmullbq): Remove.
36493         (vqdmullbq_m): Remove.
36494         (vqdmulltq_m): Remove.
36495         (vqdmulltq_s16): Remove.
36496         (vqdmulltq_n_s16): Remove.
36497         (vqdmullbq_s16): Remove.
36498         (vqdmullbq_n_s16): Remove.
36499         (vqdmulltq_s32): Remove.
36500         (vqdmulltq_n_s32): Remove.
36501         (vqdmullbq_s32): Remove.
36502         (vqdmullbq_n_s32): Remove.
36503         (vqdmullbq_m_n_s32): Remove.
36504         (vqdmullbq_m_n_s16): Remove.
36505         (vqdmullbq_m_s32): Remove.
36506         (vqdmullbq_m_s16): Remove.
36507         (vqdmulltq_m_n_s32): Remove.
36508         (vqdmulltq_m_n_s16): Remove.
36509         (vqdmulltq_m_s32): Remove.
36510         (vqdmulltq_m_s16): Remove.
36511         (__arm_vqdmulltq_s16): Remove.
36512         (__arm_vqdmulltq_n_s16): Remove.
36513         (__arm_vqdmullbq_s16): Remove.
36514         (__arm_vqdmullbq_n_s16): Remove.
36515         (__arm_vqdmulltq_s32): Remove.
36516         (__arm_vqdmulltq_n_s32): Remove.
36517         (__arm_vqdmullbq_s32): Remove.
36518         (__arm_vqdmullbq_n_s32): Remove.
36519         (__arm_vqdmullbq_m_n_s32): Remove.
36520         (__arm_vqdmullbq_m_n_s16): Remove.
36521         (__arm_vqdmullbq_m_s32): Remove.
36522         (__arm_vqdmullbq_m_s16): Remove.
36523         (__arm_vqdmulltq_m_n_s32): Remove.
36524         (__arm_vqdmulltq_m_n_s16): Remove.
36525         (__arm_vqdmulltq_m_s32): Remove.
36526         (__arm_vqdmulltq_m_s16): Remove.
36527         (__arm_vqdmulltq): Remove.
36528         (__arm_vqdmullbq): Remove.
36529         (__arm_vqdmullbq_m): Remove.
36530         (__arm_vqdmulltq_m): Remove.
36532 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36534         * config/arm/iterators.md (MVE_VQDMULLxQ, MVE_VQDMULLxQ_M)
36535         (MVE_VQDMULLxQ_M_N, MVE_VQDMULLxQ_N): New.
36536         (mve_insn): Add vqdmullb, vqdmullt.
36537         (supf): Add VQDMULLBQ_S, VQDMULLBQ_M_S, VQDMULLBQ_M_N_S,
36538         VQDMULLBQ_N_S, VQDMULLTQ_S, VQDMULLTQ_M_S, VQDMULLTQ_M_N_S,
36539         VQDMULLTQ_N_S.
36540         * config/arm/mve.md (mve_vqdmullbq_n_s<mode>)
36541         (mve_vqdmulltq_n_s<mode>): Merge into ...
36542         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
36543         (mve_vqdmullbq_s<mode>, mve_vqdmulltq_s<mode>): Merge into ...
36544         (@mve_<mve_insn>q_<supf><mode>): ... this.
36545         (mve_vqdmullbq_m_n_s<mode>, mve_vqdmulltq_m_n_s<mode>): Merge into
36546         ...
36547         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
36548         (mve_vqdmullbq_m_s<mode>, mve_vqdmulltq_m_s<mode>): Merge into ...
36549         (@mve_<mve_insn>q_m_<supf><mode>): ... this.
36551 2023-05-12  Christophe Lyon  <christophe.lyon@arm.com>
36553         * config/arm/arm-mve-builtins-shapes.cc (binary_widen_opt_n): New.
36554         * config/arm/arm-mve-builtins-shapes.h (binary_widen_opt_n): New.
36556 2023-05-12  Kito Cheng  <kito.cheng@sifive.com>
36558         * common/config/riscv/riscv-common.cc (riscv_select_multilib_by_abi):
36559         Drop unused parameter.
36560         (riscv_select_multilib): Ditto.
36561         (riscv_compute_multilib): Update call site of
36562         riscv_select_multilib_by_abi and riscv_select_multilib_by_abi.
36564 2023-05-12  Juzhe Zhong  <juzhe.zhong@rivai.ai>
36566         * config/riscv/autovec.md (vec_init<mode><vel>): New pattern.
36567         * config/riscv/riscv-protos.h (expand_vec_init): New function.
36568         * config/riscv/riscv-v.cc (class rvv_builder): New class.
36569         (rvv_builder::can_duplicate_repeating_sequence_p): New function.
36570         (rvv_builder::get_merged_repeating_sequence): Ditto.
36571         (expand_vector_init_insert_elems): Ditto.
36572         (expand_vec_init): Ditto.
36573         * config/riscv/vector-iterators.md: New attribute.
36575 2023-05-12  Haochen Gui  <guihaoc@gcc.gnu.org>
36577         * config/rs6000/rs6000-builtins.def
36578         (__builtin_vsx_scalar_insert_exp): Replace bif-pattern from xsiexpdp
36579         to xsiexpdp_di.
36580         (__builtin_vsx_scalar_insert_exp_dp): Replace bif-pattern from
36581         xsiexpdpf to xsiexpdpf_di.
36582         * config/rs6000/vsx.md (xsiexpdp): Rename to...
36583         (xsiexpdp_<mode>): ..., set the mode of second operand to GPR and
36584         replace TARGET_64BIT with TARGET_POWERPC64.
36585         (xsiexpdpf): Rename to...
36586         (xsiexpdpf_<mode>): ..., set the mode of second operand to GPR and
36587         replace TARGET_64BIT with TARGET_POWERPC64.
36589 2023-05-12  Haochen Gui  <guihaoc@gcc.gnu.org>
36591         * config/rs6000/rs6000-builtins.def
36592         (__builtin_vsx_scalar_extract_sig): Set return type to const signed
36593         long long.
36594         * config/rs6000/vsx.md (xsxsigdp): Replace TARGET_64BIT with
36595         TARGET_POWERPC64.
36597 2023-05-12  Haochen Gui  <guihaoc@gcc.gnu.org>
36599         * config/rs6000/rs6000-builtins.def
36600         (__builtin_vsx_scalar_extract_exp): Set return type to const signed
36601         int and set its bif-pattern to xsxexpdp_si, move it from power9-64
36602         to power9 catalog.
36603         * config/rs6000/vsx.md (xsxexpdp): Rename to ...
36604         (xsxexpdp_<mode>): ..., set mode of operand 0 to GPR and remove
36605         TARGET_64BIT check.
36606         * doc/extend.texi (scalar_extract_exp): Remove 64-bit environment
36607         requirement when it has a 64-bit argument.
36609 2023-05-12  Pan Li  <pan2.li@intel.com>
36610             Richard Sandiford  <richard.sandiford@arm.com>
36611             Richard Biener  <rguenther@suse.de>
36612             Jakub Jelinek  <jakub@redhat.com>
36614         * mux-utils.h: Add overload operator == and != for pointer_mux.
36615         * var-tracking.cc: Included mux-utils.h for pointer_tmux.
36616         (decl_or_value): Changed from void * to pointer_mux<tree_node, rtx_def>.
36617         (dv_is_decl_p): Reconciled to the new type, aka pointer_mux.
36618         (dv_as_decl): Ditto.
36619         (dv_as_opaque): Removed due to unnecessary.
36620         (struct variable_hasher): Take decl_or_value as compare_type.
36621         (variable_hasher::equal): Diito.
36622         (dv_from_decl): Reconciled to the new type, aka pointer_mux.
36623         (dv_from_value): Ditto.
36624         (attrs_list_member):  Ditto.
36625         (vars_copy): Ditto.
36626         (var_reg_decl_set): Ditto.
36627         (var_reg_delete_and_set): Ditto.
36628         (find_loc_in_1pdv): Ditto.
36629         (canonicalize_values_star): Ditto.
36630         (variable_post_merge_new_vals): Ditto.
36631         (dump_onepart_variable_differences): Ditto.
36632         (variable_different_p): Ditto.
36633         (set_slot_part): Ditto.
36634         (clobber_slot_part): Ditto.
36635         (clobber_variable_part): Ditto.
36637 2023-05-11  mtsamis  <manolis.tsamis@vrull.eu>
36639         * match.pd: simplify vector shift + bit_and + multiply.
36641 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
36643         * config/arm/arm-mve-builtins-base.cc (vmlaq, vmlasq, vqdmlahq)
36644         (vqdmlashq, vqrdmlahq, vqrdmlashq): New.
36645         * config/arm/arm-mve-builtins-base.def (vmlaq, vmlasq, vqdmlahq)
36646         (vqdmlashq, vqrdmlahq, vqrdmlashq): New.
36647         * config/arm/arm-mve-builtins-base.h (vmlaq, vmlasq, vqdmlahq)
36648         (vqdmlashq, vqrdmlahq, vqrdmlashq): New.
36649         * config/arm/arm-mve-builtins.cc
36650         (function_instance::has_inactive_argument): Handle vmlaq, vmlasq,
36651         vqdmlahq, vqdmlashq, vqrdmlahq, vqrdmlashq.
36652         * config/arm/arm_mve.h (vqrdmlashq): Remove.
36653         (vqrdmlahq): Remove.
36654         (vqdmlashq): Remove.
36655         (vqdmlahq): Remove.
36656         (vmlasq): Remove.
36657         (vmlaq): Remove.
36658         (vmlaq_m): Remove.
36659         (vmlasq_m): Remove.
36660         (vqdmlashq_m): Remove.
36661         (vqdmlahq_m): Remove.
36662         (vqrdmlahq_m): Remove.
36663         (vqrdmlashq_m): Remove.
36664         (vmlasq_n_u8): Remove.
36665         (vmlaq_n_u8): Remove.
36666         (vqrdmlashq_n_s8): Remove.
36667         (vqrdmlahq_n_s8): Remove.
36668         (vqdmlahq_n_s8): Remove.
36669         (vqdmlashq_n_s8): Remove.
36670         (vmlasq_n_s8): Remove.
36671         (vmlaq_n_s8): Remove.
36672         (vmlasq_n_u16): Remove.
36673         (vmlaq_n_u16): Remove.
36674         (vqrdmlashq_n_s16): Remove.
36675         (vqrdmlahq_n_s16): Remove.
36676         (vqdmlashq_n_s16): Remove.
36677         (vqdmlahq_n_s16): Remove.
36678         (vmlasq_n_s16): Remove.
36679         (vmlaq_n_s16): Remove.
36680         (vmlasq_n_u32): Remove.
36681         (vmlaq_n_u32): Remove.
36682         (vqrdmlashq_n_s32): Remove.
36683         (vqrdmlahq_n_s32): Remove.
36684         (vqdmlashq_n_s32): Remove.
36685         (vqdmlahq_n_s32): Remove.
36686         (vmlasq_n_s32): Remove.
36687         (vmlaq_n_s32): Remove.
36688         (vmlaq_m_n_s8): Remove.
36689         (vmlaq_m_n_s32): Remove.
36690         (vmlaq_m_n_s16): Remove.
36691         (vmlaq_m_n_u8): Remove.
36692         (vmlaq_m_n_u32): Remove.
36693         (vmlaq_m_n_u16): Remove.
36694         (vmlasq_m_n_s8): Remove.
36695         (vmlasq_m_n_s32): Remove.
36696         (vmlasq_m_n_s16): Remove.
36697         (vmlasq_m_n_u8): Remove.
36698         (vmlasq_m_n_u32): Remove.
36699         (vmlasq_m_n_u16): Remove.
36700         (vqdmlashq_m_n_s8): Remove.
36701         (vqdmlashq_m_n_s32): Remove.
36702         (vqdmlashq_m_n_s16): Remove.
36703         (vqdmlahq_m_n_s8): Remove.
36704         (vqdmlahq_m_n_s32): Remove.
36705         (vqdmlahq_m_n_s16): Remove.
36706         (vqrdmlahq_m_n_s8): Remove.
36707         (vqrdmlahq_m_n_s32): Remove.
36708         (vqrdmlahq_m_n_s16): Remove.
36709         (vqrdmlashq_m_n_s8): Remove.
36710         (vqrdmlashq_m_n_s32): Remove.
36711         (vqrdmlashq_m_n_s16): Remove.
36712         (__arm_vmlasq_n_u8): Remove.
36713         (__arm_vmlaq_n_u8): Remove.
36714         (__arm_vqrdmlashq_n_s8): Remove.
36715         (__arm_vqdmlashq_n_s8): Remove.
36716         (__arm_vqrdmlahq_n_s8): Remove.
36717         (__arm_vqdmlahq_n_s8): Remove.
36718         (__arm_vmlasq_n_s8): Remove.
36719         (__arm_vmlaq_n_s8): Remove.
36720         (__arm_vmlasq_n_u16): Remove.
36721         (__arm_vmlaq_n_u16): Remove.
36722         (__arm_vqrdmlashq_n_s16): Remove.
36723         (__arm_vqdmlashq_n_s16): Remove.
36724         (__arm_vqrdmlahq_n_s16): Remove.
36725         (__arm_vqdmlahq_n_s16): Remove.
36726         (__arm_vmlasq_n_s16): Remove.
36727         (__arm_vmlaq_n_s16): Remove.
36728         (__arm_vmlasq_n_u32): Remove.
36729         (__arm_vmlaq_n_u32): Remove.
36730         (__arm_vqrdmlashq_n_s32): Remove.
36731         (__arm_vqdmlashq_n_s32): Remove.
36732         (__arm_vqrdmlahq_n_s32): Remove.
36733         (__arm_vqdmlahq_n_s32): Remove.
36734         (__arm_vmlasq_n_s32): Remove.
36735         (__arm_vmlaq_n_s32): Remove.
36736         (__arm_vmlaq_m_n_s8): Remove.
36737         (__arm_vmlaq_m_n_s32): Remove.
36738         (__arm_vmlaq_m_n_s16): Remove.
36739         (__arm_vmlaq_m_n_u8): Remove.
36740         (__arm_vmlaq_m_n_u32): Remove.
36741         (__arm_vmlaq_m_n_u16): Remove.
36742         (__arm_vmlasq_m_n_s8): Remove.
36743         (__arm_vmlasq_m_n_s32): Remove.
36744         (__arm_vmlasq_m_n_s16): Remove.
36745         (__arm_vmlasq_m_n_u8): Remove.
36746         (__arm_vmlasq_m_n_u32): Remove.
36747         (__arm_vmlasq_m_n_u16): Remove.
36748         (__arm_vqdmlahq_m_n_s8): Remove.
36749         (__arm_vqdmlahq_m_n_s32): Remove.
36750         (__arm_vqdmlahq_m_n_s16): Remove.
36751         (__arm_vqrdmlahq_m_n_s8): Remove.
36752         (__arm_vqrdmlahq_m_n_s32): Remove.
36753         (__arm_vqrdmlahq_m_n_s16): Remove.
36754         (__arm_vqrdmlashq_m_n_s8): Remove.
36755         (__arm_vqrdmlashq_m_n_s32): Remove.
36756         (__arm_vqrdmlashq_m_n_s16): Remove.
36757         (__arm_vqdmlashq_m_n_s8): Remove.
36758         (__arm_vqdmlashq_m_n_s16): Remove.
36759         (__arm_vqdmlashq_m_n_s32): Remove.
36760         (__arm_vmlasq): Remove.
36761         (__arm_vmlaq): Remove.
36762         (__arm_vqrdmlashq): Remove.
36763         (__arm_vqdmlashq): Remove.
36764         (__arm_vqrdmlahq): Remove.
36765         (__arm_vqdmlahq): Remove.
36766         (__arm_vmlaq_m): Remove.
36767         (__arm_vmlasq_m): Remove.
36768         (__arm_vqdmlahq_m): Remove.
36769         (__arm_vqrdmlahq_m): Remove.
36770         (__arm_vqrdmlashq_m): Remove.
36771         (__arm_vqdmlashq_m): Remove.
36773 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
36775         * config/arm/iterators.md (MVE_VMLxQ_N): New.
36776         (mve_insn): Add vmla, vmlas, vqdmlah, vqdmlash, vqrdmlah,
36777         vqrdmlash.
36778         (supf): Add VQDMLAHQ_N_S, VQDMLASHQ_N_S, VQRDMLAHQ_N_S,
36779         VQRDMLASHQ_N_S.
36780         * config/arm/mve.md (mve_vmlaq_n_<supf><mode>)
36781         (mve_vmlasq_n_<supf><mode>, mve_vqdmlahq_n_<supf><mode>)
36782         (mve_vqdmlashq_n_<supf><mode>, mve_vqrdmlahq_n_<supf><mode>)
36783         (mve_vqrdmlashq_n_<supf><mode>): Merge into ...
36784         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
36786 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
36788         * config/arm/arm-mve-builtins-shapes.cc (ternary_n): New.
36789         * config/arm/arm-mve-builtins-shapes.h (ternary_n): New.
36791 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
36793         * config/arm/arm-mve-builtins-base.cc (vqdmladhq, vqdmladhxq)
36794         (vqdmlsdhq, vqdmlsdhxq, vqrdmladhq, vqrdmladhxq, vqrdmlsdhq)
36795         (vqrdmlsdhxq): New.
36796         * config/arm/arm-mve-builtins-base.def (vqdmladhq, vqdmladhxq)
36797         (vqdmlsdhq, vqdmlsdhxq, vqrdmladhq, vqrdmladhxq, vqrdmlsdhq)
36798         (vqrdmlsdhxq): New.
36799         * config/arm/arm-mve-builtins-base.h (vqdmladhq, vqdmladhxq)
36800         (vqdmlsdhq, vqdmlsdhxq, vqrdmladhq, vqrdmladhxq, vqrdmlsdhq)
36801         (vqrdmlsdhxq): New.
36802         * config/arm/arm-mve-builtins.cc
36803         (function_instance::has_inactive_argument): Handle vqrdmladhq,
36804         vqrdmladhxq, vqrdmlsdhq, vqrdmlsdhxq vqdmladhq, vqdmladhxq,
36805         vqdmlsdhq, vqdmlsdhxq.
36806         * config/arm/arm_mve.h (vqrdmlsdhxq): Remove.
36807         (vqrdmlsdhq): Remove.
36808         (vqrdmladhxq): Remove.
36809         (vqrdmladhq): Remove.
36810         (vqdmlsdhxq): Remove.
36811         (vqdmlsdhq): Remove.
36812         (vqdmladhxq): Remove.
36813         (vqdmladhq): Remove.
36814         (vqdmladhq_m): Remove.
36815         (vqdmladhxq_m): Remove.
36816         (vqdmlsdhq_m): Remove.
36817         (vqdmlsdhxq_m): Remove.
36818         (vqrdmladhq_m): Remove.
36819         (vqrdmladhxq_m): Remove.
36820         (vqrdmlsdhq_m): Remove.
36821         (vqrdmlsdhxq_m): Remove.
36822         (vqrdmlsdhxq_s8): Remove.
36823         (vqrdmlsdhq_s8): Remove.
36824         (vqrdmladhxq_s8): Remove.
36825         (vqrdmladhq_s8): Remove.
36826         (vqdmlsdhxq_s8): Remove.
36827         (vqdmlsdhq_s8): Remove.
36828         (vqdmladhxq_s8): Remove.
36829         (vqdmladhq_s8): Remove.
36830         (vqrdmlsdhxq_s16): Remove.
36831         (vqrdmlsdhq_s16): Remove.
36832         (vqrdmladhxq_s16): Remove.
36833         (vqrdmladhq_s16): Remove.
36834         (vqdmlsdhxq_s16): Remove.
36835         (vqdmlsdhq_s16): Remove.
36836         (vqdmladhxq_s16): Remove.
36837         (vqdmladhq_s16): Remove.
36838         (vqrdmlsdhxq_s32): Remove.
36839         (vqrdmlsdhq_s32): Remove.
36840         (vqrdmladhxq_s32): Remove.
36841         (vqrdmladhq_s32): Remove.
36842         (vqdmlsdhxq_s32): Remove.
36843         (vqdmlsdhq_s32): Remove.
36844         (vqdmladhxq_s32): Remove.
36845         (vqdmladhq_s32): Remove.
36846         (vqdmladhq_m_s8): Remove.
36847         (vqdmladhq_m_s32): Remove.
36848         (vqdmladhq_m_s16): Remove.
36849         (vqdmladhxq_m_s8): Remove.
36850         (vqdmladhxq_m_s32): Remove.
36851         (vqdmladhxq_m_s16): Remove.
36852         (vqdmlsdhq_m_s8): Remove.
36853         (vqdmlsdhq_m_s32): Remove.
36854         (vqdmlsdhq_m_s16): Remove.
36855         (vqdmlsdhxq_m_s8): Remove.
36856         (vqdmlsdhxq_m_s32): Remove.
36857         (vqdmlsdhxq_m_s16): Remove.
36858         (vqrdmladhq_m_s8): Remove.
36859         (vqrdmladhq_m_s32): Remove.
36860         (vqrdmladhq_m_s16): Remove.
36861         (vqrdmladhxq_m_s8): Remove.
36862         (vqrdmladhxq_m_s32): Remove.
36863         (vqrdmladhxq_m_s16): Remove.
36864         (vqrdmlsdhq_m_s8): Remove.
36865         (vqrdmlsdhq_m_s32): Remove.
36866         (vqrdmlsdhq_m_s16): Remove.
36867         (vqrdmlsdhxq_m_s8): Remove.
36868         (vqrdmlsdhxq_m_s32): Remove.
36869         (vqrdmlsdhxq_m_s16): Remove.
36870         (__arm_vqrdmlsdhxq_s8): Remove.
36871         (__arm_vqrdmlsdhq_s8): Remove.
36872         (__arm_vqrdmladhxq_s8): Remove.
36873         (__arm_vqrdmladhq_s8): Remove.
36874         (__arm_vqdmlsdhxq_s8): Remove.
36875         (__arm_vqdmlsdhq_s8): Remove.
36876         (__arm_vqdmladhxq_s8): Remove.
36877         (__arm_vqdmladhq_s8): Remove.
36878         (__arm_vqrdmlsdhxq_s16): Remove.
36879         (__arm_vqrdmlsdhq_s16): Remove.
36880         (__arm_vqrdmladhxq_s16): Remove.
36881         (__arm_vqrdmladhq_s16): Remove.
36882         (__arm_vqdmlsdhxq_s16): Remove.
36883         (__arm_vqdmlsdhq_s16): Remove.
36884         (__arm_vqdmladhxq_s16): Remove.
36885         (__arm_vqdmladhq_s16): Remove.
36886         (__arm_vqrdmlsdhxq_s32): Remove.
36887         (__arm_vqrdmlsdhq_s32): Remove.
36888         (__arm_vqrdmladhxq_s32): Remove.
36889         (__arm_vqrdmladhq_s32): Remove.
36890         (__arm_vqdmlsdhxq_s32): Remove.
36891         (__arm_vqdmlsdhq_s32): Remove.
36892         (__arm_vqdmladhxq_s32): Remove.
36893         (__arm_vqdmladhq_s32): Remove.
36894         (__arm_vqdmladhq_m_s8): Remove.
36895         (__arm_vqdmladhq_m_s32): Remove.
36896         (__arm_vqdmladhq_m_s16): Remove.
36897         (__arm_vqdmladhxq_m_s8): Remove.
36898         (__arm_vqdmladhxq_m_s32): Remove.
36899         (__arm_vqdmladhxq_m_s16): Remove.
36900         (__arm_vqdmlsdhq_m_s8): Remove.
36901         (__arm_vqdmlsdhq_m_s32): Remove.
36902         (__arm_vqdmlsdhq_m_s16): Remove.
36903         (__arm_vqdmlsdhxq_m_s8): Remove.
36904         (__arm_vqdmlsdhxq_m_s32): Remove.
36905         (__arm_vqdmlsdhxq_m_s16): Remove.
36906         (__arm_vqrdmladhq_m_s8): Remove.
36907         (__arm_vqrdmladhq_m_s32): Remove.
36908         (__arm_vqrdmladhq_m_s16): Remove.
36909         (__arm_vqrdmladhxq_m_s8): Remove.
36910         (__arm_vqrdmladhxq_m_s32): Remove.
36911         (__arm_vqrdmladhxq_m_s16): Remove.
36912         (__arm_vqrdmlsdhq_m_s8): Remove.
36913         (__arm_vqrdmlsdhq_m_s32): Remove.
36914         (__arm_vqrdmlsdhq_m_s16): Remove.
36915         (__arm_vqrdmlsdhxq_m_s8): Remove.
36916         (__arm_vqrdmlsdhxq_m_s32): Remove.
36917         (__arm_vqrdmlsdhxq_m_s16): Remove.
36918         (__arm_vqrdmlsdhxq): Remove.
36919         (__arm_vqrdmlsdhq): Remove.
36920         (__arm_vqrdmladhxq): Remove.
36921         (__arm_vqrdmladhq): Remove.
36922         (__arm_vqdmlsdhxq): Remove.
36923         (__arm_vqdmlsdhq): Remove.
36924         (__arm_vqdmladhxq): Remove.
36925         (__arm_vqdmladhq): Remove.
36926         (__arm_vqdmladhq_m): Remove.
36927         (__arm_vqdmladhxq_m): Remove.
36928         (__arm_vqdmlsdhq_m): Remove.
36929         (__arm_vqdmlsdhxq_m): Remove.
36930         (__arm_vqrdmladhq_m): Remove.
36931         (__arm_vqrdmladhxq_m): Remove.
36932         (__arm_vqrdmlsdhq_m): Remove.
36933         (__arm_vqrdmlsdhxq_m): Remove.
36935 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
36937         * config/arm/iterators.md (MVE_VQxDMLxDHxQ_S): New.
36938         (mve_insn): Add vqdmladh, vqdmladhx, vqdmlsdh, vqdmlsdhx,
36939         vqrdmladh, vqrdmladhx, vqrdmlsdh, vqrdmlsdhx.
36940         (supf): Add VQDMLADHQ_S, VQDMLADHXQ_S, VQDMLSDHQ_S, VQDMLSDHXQ_S,
36941         VQRDMLADHQ_S,VQRDMLADHXQ_S, VQRDMLSDHQ_S, VQRDMLSDHXQ_S.
36942         * config/arm/mve.md (mve_vqrdmladhq_s<mode>)
36943         (mve_vqrdmladhxq_s<mode>, mve_vqrdmlsdhq_s<mode>)
36944         (mve_vqrdmlsdhxq_s<mode>, mve_vqdmlsdhxq_s<mode>)
36945         (mve_vqdmlsdhq_s<mode>, mve_vqdmladhxq_s<mode>)
36946         (mve_vqdmladhq_s<mode>): Merge into ...
36947         (@mve_<mve_insn>q_<supf><mode>): ... this.
36949 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
36951         * config/arm/arm-mve-builtins-shapes.cc (ternary): New.
36952         * config/arm/arm-mve-builtins-shapes.h (ternary): New.
36954 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
36956         * config/arm/arm-mve-builtins-base.cc (vmlaldavaq, vmlaldavaxq)
36957         (vmlsldavaq, vmlsldavaxq): New.
36958         * config/arm/arm-mve-builtins-base.def (vmlaldavaq, vmlaldavaxq)
36959         (vmlsldavaq, vmlsldavaxq): New.
36960         * config/arm/arm-mve-builtins-base.h (vmlaldavaq, vmlaldavaxq)
36961         (vmlsldavaq, vmlsldavaxq): New.
36962         * config/arm/arm_mve.h (vmlaldavaq): Remove.
36963         (vmlaldavaxq): Remove.
36964         (vmlsldavaq): Remove.
36965         (vmlsldavaxq): Remove.
36966         (vmlaldavaq_p): Remove.
36967         (vmlaldavaxq_p): Remove.
36968         (vmlsldavaq_p): Remove.
36969         (vmlsldavaxq_p): Remove.
36970         (vmlaldavaq_s16): Remove.
36971         (vmlaldavaxq_s16): Remove.
36972         (vmlsldavaq_s16): Remove.
36973         (vmlsldavaxq_s16): Remove.
36974         (vmlaldavaq_u16): Remove.
36975         (vmlaldavaq_s32): Remove.
36976         (vmlaldavaxq_s32): Remove.
36977         (vmlsldavaq_s32): Remove.
36978         (vmlsldavaxq_s32): Remove.
36979         (vmlaldavaq_u32): Remove.
36980         (vmlaldavaq_p_s32): Remove.
36981         (vmlaldavaq_p_s16): Remove.
36982         (vmlaldavaq_p_u32): Remove.
36983         (vmlaldavaq_p_u16): Remove.
36984         (vmlaldavaxq_p_s32): Remove.
36985         (vmlaldavaxq_p_s16): Remove.
36986         (vmlsldavaq_p_s32): Remove.
36987         (vmlsldavaq_p_s16): Remove.
36988         (vmlsldavaxq_p_s32): Remove.
36989         (vmlsldavaxq_p_s16): Remove.
36990         (__arm_vmlaldavaq_s16): Remove.
36991         (__arm_vmlaldavaxq_s16): Remove.
36992         (__arm_vmlsldavaq_s16): Remove.
36993         (__arm_vmlsldavaxq_s16): Remove.
36994         (__arm_vmlaldavaq_u16): Remove.
36995         (__arm_vmlaldavaq_s32): Remove.
36996         (__arm_vmlaldavaxq_s32): Remove.
36997         (__arm_vmlsldavaq_s32): Remove.
36998         (__arm_vmlsldavaxq_s32): Remove.
36999         (__arm_vmlaldavaq_u32): Remove.
37000         (__arm_vmlaldavaq_p_s32): Remove.
37001         (__arm_vmlaldavaq_p_s16): Remove.
37002         (__arm_vmlaldavaq_p_u32): Remove.
37003         (__arm_vmlaldavaq_p_u16): Remove.
37004         (__arm_vmlaldavaxq_p_s32): Remove.
37005         (__arm_vmlaldavaxq_p_s16): Remove.
37006         (__arm_vmlsldavaq_p_s32): Remove.
37007         (__arm_vmlsldavaq_p_s16): Remove.
37008         (__arm_vmlsldavaxq_p_s32): Remove.
37009         (__arm_vmlsldavaxq_p_s16): Remove.
37010         (__arm_vmlaldavaq): Remove.
37011         (__arm_vmlaldavaxq): Remove.
37012         (__arm_vmlsldavaq): Remove.
37013         (__arm_vmlsldavaxq): Remove.
37014         (__arm_vmlaldavaq_p): Remove.
37015         (__arm_vmlaldavaxq_p): Remove.
37016         (__arm_vmlsldavaq_p): Remove.
37017         (__arm_vmlsldavaxq_p): Remove.
37019 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37021         * config/arm/iterators.md (MVE_VMLxLDAVAxQ, MVE_VMLxLDAVAxQ_P):
37022         New.
37023         (mve_insn): Add vmlaldava, vmlaldavax, vmlsldava, vmlsldavax.
37024         (supf): Add VMLALDAVAXQ_P_S, VMLALDAVAXQ_S, VMLSLDAVAQ_P_S,
37025         VMLSLDAVAQ_S, VMLSLDAVAXQ_P_S, VMLSLDAVAXQ_S.
37026         * config/arm/mve.md (mve_vmlaldavaq_<supf><mode>)
37027         (mve_vmlsldavaq_s<mode>, mve_vmlsldavaxq_s<mode>)
37028         (mve_vmlaldavaxq_s<mode>): Merge into ...
37029         (@mve_<mve_insn>q_<supf><mode>): ... this.
37030         (mve_vmlaldavaq_p_<supf><mode>, mve_vmlaldavaxq_p_<supf><mode>)
37031         (mve_vmlsldavaq_p_s<mode>, mve_vmlsldavaxq_p_s<mode>): Merge into
37032         ...
37033         (@mve_<mve_insn>q_p_<supf><mode>): ... this.
37035 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37037         * config/arm/arm-mve-builtins-shapes.cc (binary_acca_int64): New.
37038         * config/arm/arm-mve-builtins-shapes.h (binary_acca_int64): New.
37040 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37042         * config/arm/arm-mve-builtins-base.cc (vrmlaldavhq, vrmlaldavhxq)
37043         (vrmlsldavhq, vrmlsldavhxq): New.
37044         * config/arm/arm-mve-builtins-base.def (vrmlaldavhq, vrmlaldavhxq)
37045         (vrmlsldavhq, vrmlsldavhxq): New.
37046         * config/arm/arm-mve-builtins-base.h (vrmlaldavhq, vrmlaldavhxq)
37047         (vrmlsldavhq, vrmlsldavhxq): New.
37048         * config/arm/arm-mve-builtins-functions.h
37049         (unspec_mve_function_exact_insn_pred_p): Handle vrmlaldavhq,
37050         vrmlaldavhxq, vrmlsldavhq, vrmlsldavhxq.
37051         * config/arm/arm_mve.h (vrmlaldavhq): Remove.
37052         (vrmlsldavhxq): Remove.
37053         (vrmlsldavhq): Remove.
37054         (vrmlaldavhxq): Remove.
37055         (vrmlaldavhq_p): Remove.
37056         (vrmlaldavhxq_p): Remove.
37057         (vrmlsldavhq_p): Remove.
37058         (vrmlsldavhxq_p): Remove.
37059         (vrmlaldavhq_u32): Remove.
37060         (vrmlsldavhxq_s32): Remove.
37061         (vrmlsldavhq_s32): Remove.
37062         (vrmlaldavhxq_s32): Remove.
37063         (vrmlaldavhq_s32): Remove.
37064         (vrmlaldavhq_p_s32): Remove.
37065         (vrmlaldavhxq_p_s32): Remove.
37066         (vrmlsldavhq_p_s32): Remove.
37067         (vrmlsldavhxq_p_s32): Remove.
37068         (vrmlaldavhq_p_u32): Remove.
37069         (__arm_vrmlaldavhq_u32): Remove.
37070         (__arm_vrmlsldavhxq_s32): Remove.
37071         (__arm_vrmlsldavhq_s32): Remove.
37072         (__arm_vrmlaldavhxq_s32): Remove.
37073         (__arm_vrmlaldavhq_s32): Remove.
37074         (__arm_vrmlaldavhq_p_s32): Remove.
37075         (__arm_vrmlaldavhxq_p_s32): Remove.
37076         (__arm_vrmlsldavhq_p_s32): Remove.
37077         (__arm_vrmlsldavhxq_p_s32): Remove.
37078         (__arm_vrmlaldavhq_p_u32): Remove.
37079         (__arm_vrmlaldavhq): Remove.
37080         (__arm_vrmlsldavhxq): Remove.
37081         (__arm_vrmlsldavhq): Remove.
37082         (__arm_vrmlaldavhxq): Remove.
37083         (__arm_vrmlaldavhq_p): Remove.
37084         (__arm_vrmlaldavhxq_p): Remove.
37085         (__arm_vrmlsldavhq_p): Remove.
37086         (__arm_vrmlsldavhxq_p): Remove.
37088 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37090         * config/arm/iterators.md (MVE_VRMLxLDAVxQ, MVE_VRMLxLDAVHxQ_P):
37091         New.
37092         (mve_insn): Add vrmlaldavh, vrmlaldavhx, vrmlsldavh, vrmlsldavhx.
37093         (supf): Add VRMLALDAVHXQ_P_S, VRMLALDAVHXQ_S, VRMLSLDAVHQ_P_S,
37094         VRMLSLDAVHQ_S, VRMLSLDAVHXQ_P_S, VRMLSLDAVHXQ_S.
37095         * config/arm/mve.md (mve_vrmlaldavhxq_sv4si)
37096         (mve_vrmlsldavhq_sv4si, mve_vrmlsldavhxq_sv4si)
37097         (mve_vrmlaldavhq_<supf>v4si): Merge into ...
37098         (@mve_<mve_insn>q_<supf>v4si): ... this.
37099         (mve_vrmlaldavhxq_p_sv4si, mve_vrmlsldavhq_p_sv4si)
37100         (mve_vrmlsldavhxq_p_sv4si, mve_vrmlaldavhq_p_<supf>v4si): Merge
37101         into ...
37102         (@mve_<mve_insn>q_p_<supf>v4si): ... this.
37104 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37106         * config/arm/arm-mve-builtins-base.cc (vmlaldavq, vmlaldavxq)
37107         (vmlsldavq, vmlsldavxq): New.
37108         * config/arm/arm-mve-builtins-base.def (vmlaldavq, vmlaldavxq)
37109         (vmlsldavq, vmlsldavxq): New.
37110         * config/arm/arm-mve-builtins-base.h (vmlaldavq, vmlaldavxq)
37111         (vmlsldavq, vmlsldavxq): New.
37112         * config/arm/arm_mve.h (vmlaldavq): Remove.
37113         (vmlsldavxq): Remove.
37114         (vmlsldavq): Remove.
37115         (vmlaldavxq): Remove.
37116         (vmlaldavq_p): Remove.
37117         (vmlaldavxq_p): Remove.
37118         (vmlsldavq_p): Remove.
37119         (vmlsldavxq_p): Remove.
37120         (vmlaldavq_u16): Remove.
37121         (vmlsldavxq_s16): Remove.
37122         (vmlsldavq_s16): Remove.
37123         (vmlaldavxq_s16): Remove.
37124         (vmlaldavq_s16): Remove.
37125         (vmlaldavq_u32): Remove.
37126         (vmlsldavxq_s32): Remove.
37127         (vmlsldavq_s32): Remove.
37128         (vmlaldavxq_s32): Remove.
37129         (vmlaldavq_s32): Remove.
37130         (vmlaldavq_p_s16): Remove.
37131         (vmlaldavxq_p_s16): Remove.
37132         (vmlsldavq_p_s16): Remove.
37133         (vmlsldavxq_p_s16): Remove.
37134         (vmlaldavq_p_u16): Remove.
37135         (vmlaldavq_p_s32): Remove.
37136         (vmlaldavxq_p_s32): Remove.
37137         (vmlsldavq_p_s32): Remove.
37138         (vmlsldavxq_p_s32): Remove.
37139         (vmlaldavq_p_u32): Remove.
37140         (__arm_vmlaldavq_u16): Remove.
37141         (__arm_vmlsldavxq_s16): Remove.
37142         (__arm_vmlsldavq_s16): Remove.
37143         (__arm_vmlaldavxq_s16): Remove.
37144         (__arm_vmlaldavq_s16): Remove.
37145         (__arm_vmlaldavq_u32): Remove.
37146         (__arm_vmlsldavxq_s32): Remove.
37147         (__arm_vmlsldavq_s32): Remove.
37148         (__arm_vmlaldavxq_s32): Remove.
37149         (__arm_vmlaldavq_s32): Remove.
37150         (__arm_vmlaldavq_p_s16): Remove.
37151         (__arm_vmlaldavxq_p_s16): Remove.
37152         (__arm_vmlsldavq_p_s16): Remove.
37153         (__arm_vmlsldavxq_p_s16): Remove.
37154         (__arm_vmlaldavq_p_u16): Remove.
37155         (__arm_vmlaldavq_p_s32): Remove.
37156         (__arm_vmlaldavxq_p_s32): Remove.
37157         (__arm_vmlsldavq_p_s32): Remove.
37158         (__arm_vmlsldavxq_p_s32): Remove.
37159         (__arm_vmlaldavq_p_u32): Remove.
37160         (__arm_vmlaldavq): Remove.
37161         (__arm_vmlsldavxq): Remove.
37162         (__arm_vmlsldavq): Remove.
37163         (__arm_vmlaldavxq): Remove.
37164         (__arm_vmlaldavq_p): Remove.
37165         (__arm_vmlaldavxq_p): Remove.
37166         (__arm_vmlsldavq_p): Remove.
37167         (__arm_vmlsldavxq_p): Remove.
37169 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37171         * config/arm/iterators.md (MVE_VMLxLDAVxQ, MVE_VMLxLDAVxQ_P): New.
37172         (mve_insn): Add vmlaldav, vmlaldavx, vmlsldav, vmlsldavx.
37173         (supf): Add VMLALDAVXQ_S, VMLSLDAVQ_S, VMLSLDAVXQ_S,
37174         VMLALDAVXQ_P_S, VMLSLDAVQ_P_S, VMLSLDAVXQ_P_S.
37175         * config/arm/mve.md (mve_vmlaldavq_<supf><mode>)
37176         (mve_vmlaldavxq_s<mode>, mve_vmlsldavq_s<mode>)
37177         (mve_vmlsldavxq_s<mode>): Merge into ...
37178         (@mve_<mve_insn>q_<supf><mode>): ... this.
37179         (mve_vmlaldavq_p_<supf><mode>, mve_vmlaldavxq_p_s<mode>)
37180         (mve_vmlsldavq_p_s<mode>, mve_vmlsldavxq_p_s<mode>): Merge into
37181         ...
37182         (@mve_<mve_insn>q_p_<supf><mode>): ... this.
37184 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37186         * config/arm/arm-mve-builtins-shapes.cc (binary_acc_int64): New.
37187         * config/arm/arm-mve-builtins-shapes.h (binary_acc_int64): New.
37189 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37191         * config/arm/arm-mve-builtins-base.cc (vabavq): New.
37192         * config/arm/arm-mve-builtins-base.def (vabavq): New.
37193         * config/arm/arm-mve-builtins-base.h (vabavq): New.
37194         * config/arm/arm_mve.h (vabavq): Remove.
37195         (vabavq_p): Remove.
37196         (vabavq_s8): Remove.
37197         (vabavq_s16): Remove.
37198         (vabavq_s32): Remove.
37199         (vabavq_u8): Remove.
37200         (vabavq_u16): Remove.
37201         (vabavq_u32): Remove.
37202         (vabavq_p_s8): Remove.
37203         (vabavq_p_u8): Remove.
37204         (vabavq_p_s16): Remove.
37205         (vabavq_p_u16): Remove.
37206         (vabavq_p_s32): Remove.
37207         (vabavq_p_u32): Remove.
37208         (__arm_vabavq_s8): Remove.
37209         (__arm_vabavq_s16): Remove.
37210         (__arm_vabavq_s32): Remove.
37211         (__arm_vabavq_u8): Remove.
37212         (__arm_vabavq_u16): Remove.
37213         (__arm_vabavq_u32): Remove.
37214         (__arm_vabavq_p_s8): Remove.
37215         (__arm_vabavq_p_u8): Remove.
37216         (__arm_vabavq_p_s16): Remove.
37217         (__arm_vabavq_p_u16): Remove.
37218         (__arm_vabavq_p_s32): Remove.
37219         (__arm_vabavq_p_u32): Remove.
37220         (__arm_vabavq): Remove.
37221         (__arm_vabavq_p): Remove.
37223 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37225         * config/arm/iterators.md (mve_insn): Add vabav.
37226         * config/arm/mve.md (mve_vabavq_<supf><mode>): Rename into ...
37227         (@mve_<mve_insn>q_<supf><mode>): ... this,.
37228         (mve_vabavq_p_<supf><mode>): Rename into ...
37229         (@mve_<mve_insn>q_p_<supf><mode>): ... this,.
37231 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37233         * config/arm/arm-mve-builtins-base.cc (vmladavaxq, vmladavaq)
37234         (vmlsdavaq, vmlsdavaxq): New.
37235         * config/arm/arm-mve-builtins-base.def (vmladavaxq, vmladavaq)
37236         (vmlsdavaq, vmlsdavaxq): New.
37237         * config/arm/arm-mve-builtins-base.h (vmladavaxq, vmladavaq)
37238         (vmlsdavaq, vmlsdavaxq): New.
37239         * config/arm/arm_mve.h (vmladavaq): Remove.
37240         (vmlsdavaxq): Remove.
37241         (vmlsdavaq): Remove.
37242         (vmladavaxq): Remove.
37243         (vmladavaq_p): Remove.
37244         (vmladavaxq_p): Remove.
37245         (vmlsdavaq_p): Remove.
37246         (vmlsdavaxq_p): Remove.
37247         (vmladavaq_u8): Remove.
37248         (vmlsdavaxq_s8): Remove.
37249         (vmlsdavaq_s8): Remove.
37250         (vmladavaxq_s8): Remove.
37251         (vmladavaq_s8): Remove.
37252         (vmladavaq_u16): Remove.
37253         (vmlsdavaxq_s16): Remove.
37254         (vmlsdavaq_s16): Remove.
37255         (vmladavaxq_s16): Remove.
37256         (vmladavaq_s16): Remove.
37257         (vmladavaq_u32): Remove.
37258         (vmlsdavaxq_s32): Remove.
37259         (vmlsdavaq_s32): Remove.
37260         (vmladavaxq_s32): Remove.
37261         (vmladavaq_s32): Remove.
37262         (vmladavaq_p_s8): Remove.
37263         (vmladavaq_p_s32): Remove.
37264         (vmladavaq_p_s16): Remove.
37265         (vmladavaq_p_u8): Remove.
37266         (vmladavaq_p_u32): Remove.
37267         (vmladavaq_p_u16): Remove.
37268         (vmladavaxq_p_s8): Remove.
37269         (vmladavaxq_p_s32): Remove.
37270         (vmladavaxq_p_s16): Remove.
37271         (vmlsdavaq_p_s8): Remove.
37272         (vmlsdavaq_p_s32): Remove.
37273         (vmlsdavaq_p_s16): Remove.
37274         (vmlsdavaxq_p_s8): Remove.
37275         (vmlsdavaxq_p_s32): Remove.
37276         (vmlsdavaxq_p_s16): Remove.
37277         (__arm_vmladavaq_u8): Remove.
37278         (__arm_vmlsdavaxq_s8): Remove.
37279         (__arm_vmlsdavaq_s8): Remove.
37280         (__arm_vmladavaxq_s8): Remove.
37281         (__arm_vmladavaq_s8): Remove.
37282         (__arm_vmladavaq_u16): Remove.
37283         (__arm_vmlsdavaxq_s16): Remove.
37284         (__arm_vmlsdavaq_s16): Remove.
37285         (__arm_vmladavaxq_s16): Remove.
37286         (__arm_vmladavaq_s16): Remove.
37287         (__arm_vmladavaq_u32): Remove.
37288         (__arm_vmlsdavaxq_s32): Remove.
37289         (__arm_vmlsdavaq_s32): Remove.
37290         (__arm_vmladavaxq_s32): Remove.
37291         (__arm_vmladavaq_s32): Remove.
37292         (__arm_vmladavaq_p_s8): Remove.
37293         (__arm_vmladavaq_p_s32): Remove.
37294         (__arm_vmladavaq_p_s16): Remove.
37295         (__arm_vmladavaq_p_u8): Remove.
37296         (__arm_vmladavaq_p_u32): Remove.
37297         (__arm_vmladavaq_p_u16): Remove.
37298         (__arm_vmladavaxq_p_s8): Remove.
37299         (__arm_vmladavaxq_p_s32): Remove.
37300         (__arm_vmladavaxq_p_s16): Remove.
37301         (__arm_vmlsdavaq_p_s8): Remove.
37302         (__arm_vmlsdavaq_p_s32): Remove.
37303         (__arm_vmlsdavaq_p_s16): Remove.
37304         (__arm_vmlsdavaxq_p_s8): Remove.
37305         (__arm_vmlsdavaxq_p_s32): Remove.
37306         (__arm_vmlsdavaxq_p_s16): Remove.
37307         (__arm_vmladavaq): Remove.
37308         (__arm_vmlsdavaxq): Remove.
37309         (__arm_vmlsdavaq): Remove.
37310         (__arm_vmladavaxq): Remove.
37311         (__arm_vmladavaq_p): Remove.
37312         (__arm_vmladavaxq_p): Remove.
37313         (__arm_vmlsdavaq_p): Remove.
37314         (__arm_vmlsdavaxq_p): Remove.
37316 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37318         * config/arm/arm-mve-builtins-shapes.cc (binary_acca_int32): New.
37319         * config/arm/arm-mve-builtins-shapes.h  (binary_acca_int32): New.
37321 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37323         * config/arm/arm-mve-builtins-base.cc (vmladavq, vmladavxq)
37324         (vmlsdavq, vmlsdavxq): New.
37325         * config/arm/arm-mve-builtins-base.def (vmladavq, vmladavxq)
37326         (vmlsdavq, vmlsdavxq): New.
37327         * config/arm/arm-mve-builtins-base.h (vmladavq, vmladavxq)
37328         (vmlsdavq, vmlsdavxq): New.
37329         * config/arm/arm_mve.h (vmladavq): Remove.
37330         (vmlsdavxq): Remove.
37331         (vmlsdavq): Remove.
37332         (vmladavxq): Remove.
37333         (vmladavq_p): Remove.
37334         (vmlsdavxq_p): Remove.
37335         (vmlsdavq_p): Remove.
37336         (vmladavxq_p): Remove.
37337         (vmladavq_u8): Remove.
37338         (vmlsdavxq_s8): Remove.
37339         (vmlsdavq_s8): Remove.
37340         (vmladavxq_s8): Remove.
37341         (vmladavq_s8): Remove.
37342         (vmladavq_u16): Remove.
37343         (vmlsdavxq_s16): Remove.
37344         (vmlsdavq_s16): Remove.
37345         (vmladavxq_s16): Remove.
37346         (vmladavq_s16): Remove.
37347         (vmladavq_u32): Remove.
37348         (vmlsdavxq_s32): Remove.
37349         (vmlsdavq_s32): Remove.
37350         (vmladavxq_s32): Remove.
37351         (vmladavq_s32): Remove.
37352         (vmladavq_p_u8): Remove.
37353         (vmlsdavxq_p_s8): Remove.
37354         (vmlsdavq_p_s8): Remove.
37355         (vmladavxq_p_s8): Remove.
37356         (vmladavq_p_s8): Remove.
37357         (vmladavq_p_u16): Remove.
37358         (vmlsdavxq_p_s16): Remove.
37359         (vmlsdavq_p_s16): Remove.
37360         (vmladavxq_p_s16): Remove.
37361         (vmladavq_p_s16): Remove.
37362         (vmladavq_p_u32): Remove.
37363         (vmlsdavxq_p_s32): Remove.
37364         (vmlsdavq_p_s32): Remove.
37365         (vmladavxq_p_s32): Remove.
37366         (vmladavq_p_s32): Remove.
37367         (__arm_vmladavq_u8): Remove.
37368         (__arm_vmlsdavxq_s8): Remove.
37369         (__arm_vmlsdavq_s8): Remove.
37370         (__arm_vmladavxq_s8): Remove.
37371         (__arm_vmladavq_s8): Remove.
37372         (__arm_vmladavq_u16): Remove.
37373         (__arm_vmlsdavxq_s16): Remove.
37374         (__arm_vmlsdavq_s16): Remove.
37375         (__arm_vmladavxq_s16): Remove.
37376         (__arm_vmladavq_s16): Remove.
37377         (__arm_vmladavq_u32): Remove.
37378         (__arm_vmlsdavxq_s32): Remove.
37379         (__arm_vmlsdavq_s32): Remove.
37380         (__arm_vmladavxq_s32): Remove.
37381         (__arm_vmladavq_s32): Remove.
37382         (__arm_vmladavq_p_u8): Remove.
37383         (__arm_vmlsdavxq_p_s8): Remove.
37384         (__arm_vmlsdavq_p_s8): Remove.
37385         (__arm_vmladavxq_p_s8): Remove.
37386         (__arm_vmladavq_p_s8): Remove.
37387         (__arm_vmladavq_p_u16): Remove.
37388         (__arm_vmlsdavxq_p_s16): Remove.
37389         (__arm_vmlsdavq_p_s16): Remove.
37390         (__arm_vmladavxq_p_s16): Remove.
37391         (__arm_vmladavq_p_s16): Remove.
37392         (__arm_vmladavq_p_u32): Remove.
37393         (__arm_vmlsdavxq_p_s32): Remove.
37394         (__arm_vmlsdavq_p_s32): Remove.
37395         (__arm_vmladavxq_p_s32): Remove.
37396         (__arm_vmladavq_p_s32): Remove.
37397         (__arm_vmladavq): Remove.
37398         (__arm_vmlsdavxq): Remove.
37399         (__arm_vmlsdavq): Remove.
37400         (__arm_vmladavxq): Remove.
37401         (__arm_vmladavq_p): Remove.
37402         (__arm_vmlsdavxq_p): Remove.
37403         (__arm_vmlsdavq_p): Remove.
37404         (__arm_vmladavxq_p): Remove.
37406 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37408         * config/arm/iterators.md (MVE_VMLxDAVQ, MVE_VMLxDAVQ_P)
37409         (MVE_VMLxDAVAQ, MVE_VMLxDAVAQ_P): New.
37410         (mve_insn): Add vmladava, vmladavax, vmladav, vmladavx, vmlsdava,
37411         vmlsdavax, vmlsdav, vmlsdavx.
37412         (supf): Add VMLADAVAXQ_P_S, VMLADAVAXQ_S, VMLADAVXQ_P_S,
37413         VMLADAVXQ_S, VMLSDAVAQ_P_S, VMLSDAVAQ_S, VMLSDAVAXQ_P_S,
37414         VMLSDAVAXQ_S, VMLSDAVQ_P_S, VMLSDAVQ_S, VMLSDAVXQ_P_S,
37415         VMLSDAVXQ_S.
37416         * config/arm/mve.md (mve_vmladavq_<supf><mode>)
37417         (mve_vmladavxq_s<mode>, mve_vmlsdavq_s<mode>)
37418         (mve_vmlsdavxq_s<mode>): Merge into ...
37419         (@mve_<mve_insn>q_<supf><mode>): ... this.
37420         (mve_vmlsdavaq_s<mode>, mve_vmladavaxq_s<mode>)
37421         (mve_vmlsdavaxq_s<mode>, mve_vmladavaq_<supf><mode>): Merge into
37422         ...
37423         (@mve_<mve_insn>q_<supf><mode>): ... this.
37424         (mve_vmladavq_p_<supf><mode>, mve_vmladavxq_p_s<mode>)
37425         (mve_vmlsdavq_p_s<mode>, mve_vmlsdavxq_p_s<mode>): Merge into ...
37426         (@mve_<mve_insn>q_p_<supf><mode>): ... this.
37427         (mve_vmladavaq_p_<supf><mode>, mve_vmladavaxq_p_s<mode>)
37428         (mve_vmlsdavaq_p_s<mode>, mve_vmlsdavaxq_p_s<mode>): Merge into
37429         ...
37430         (@mve_<mve_insn>q_p_<supf><mode>): ... this.
37432 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37434         * config/arm/arm-mve-builtins-shapes.cc (binary_acc_int32): New.
37435         * config/arm/arm-mve-builtins-shapes.h (binary_acc_int32): New.
37437 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37439         * config/arm/arm-mve-builtins-base.cc (vaddlvaq): New.
37440         * config/arm/arm-mve-builtins-base.def (vaddlvaq): New.
37441         * config/arm/arm-mve-builtins-base.h (vaddlvaq): New.
37442         * config/arm/arm_mve.h (vaddlvaq): Remove.
37443         (vaddlvaq_p): Remove.
37444         (vaddlvaq_u32): Remove.
37445         (vaddlvaq_s32): Remove.
37446         (vaddlvaq_p_s32): Remove.
37447         (vaddlvaq_p_u32): Remove.
37448         (__arm_vaddlvaq_u32): Remove.
37449         (__arm_vaddlvaq_s32): Remove.
37450         (__arm_vaddlvaq_p_s32): Remove.
37451         (__arm_vaddlvaq_p_u32): Remove.
37452         (__arm_vaddlvaq): Remove.
37453         (__arm_vaddlvaq_p): Remove.
37455 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37457         * config/arm/arm-mve-builtins-shapes.cc (unary_widen_acc): New.
37458         * config/arm/arm-mve-builtins-shapes.h (unary_widen_acc): New.
37460 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37462         * config/arm/iterators.md (mve_insn): Add vaddlva.
37463         * config/arm/mve.md (mve_vaddlvaq_<supf>v4si): Rename into ...
37464         (@mve_<mve_insn>q_<supf>v4si): ... this.
37465         (mve_vaddlvaq_p_<supf>v4si): Rename into ...
37466         (@mve_<mve_insn>q_p_<supf>v4si): ... this.
37468 2023-05-11  Uros Bizjak  <ubizjak@gmail.com>
37470         PR target/109807
37471         * config/i386/i386.cc (ix86_widen_mult_cost):
37472         Handle V4HImode and V2SImode.
37474 2023-05-11  Andrew Pinski  <apinski@marvell.com>
37476         * tree-ssa-dce.cc (simple_dce_from_worklist): For ssa names
37477         defined by a phi node with more than one uses, allow for the
37478         only uses are in that same defining statement.
37480 2023-05-11  Robin Dapp  <rdapp@ventanamicro.com>
37482         * config/riscv/riscv.cc (riscv_const_insns): Add permissible
37483         vector constants.
37485 2023-05-11  Pan Li  <pan2.li@intel.com>
37487         * config/riscv/vector.md: Add comments for simplifying to vmset.
37489 2023-05-11  Robin Dapp  <rdapp@ventanamicro.com>
37491         * config/riscv/autovec.md (<optab><mode>3): Add scalar shift
37492         pattern.
37493         (v<optab><mode>3): Add vector shift pattern.
37494         * config/riscv/vector-iterators.md: New iterator.
37496 2023-05-11  Robin Dapp  <rdapp@ventanamicro.com>
37498         * config/riscv/autovec.md: Use renamed functions.
37499         * config/riscv/riscv-protos.h (emit_vlmax_op): Rename.
37500         (emit_vlmax_reg_op): To this.
37501         (emit_nonvlmax_op): Rename.
37502         (emit_len_op): To this.
37503         (emit_nonvlmax_binop): Rename.
37504         (emit_len_binop): To this.
37505         * config/riscv/riscv-v.cc (emit_pred_op): Add default parameter.
37506         (emit_pred_binop): Remove vlmax_p.
37507         (emit_vlmax_op): Rename.
37508         (emit_vlmax_reg_op): To this.
37509         (emit_nonvlmax_op): Rename.
37510         (emit_len_op): To this.
37511         (emit_nonvlmax_binop): Rename.
37512         (emit_len_binop): To this.
37513         (sew64_scalar_helper): Use renamed functions.
37514         (expand_tuple_move): Use renamed functions.
37515         * config/riscv/riscv.cc (vector_zero_call_used_regs): Use
37516         renamed functions.
37517         * config/riscv/vector.md: Use renamed functions.
37519 2023-05-11  Robin Dapp  <rdapp@ventanamicro.com>
37520             Michael Collison  <collison@rivosinc.com>
37522         * config/riscv/autovec.md (<optab><mode>3): Add integer binops.
37523         * config/riscv/riscv-protos.h (emit_nonvlmax_binop): Declare.
37524         * config/riscv/riscv-v.cc (emit_pred_op): New function.
37525         (set_expander_dest_and_mask): New function.
37526         (emit_pred_binop): New function.
37527         (emit_nonvlmax_binop): New function.
37529 2023-05-11  Pan Li  <pan2.li@intel.com>
37531         * cfgloopmanip.cc (create_empty_loop_on_edge): Add PLUS_EXPR.
37532         * gimple-loop-interchange.cc
37533         (tree_loop_interchange::map_inductions_to_loop): Ditto.
37534         * tree-ssa-loop-ivcanon.cc (create_canonical_iv): Ditto.
37535         * tree-ssa-loop-ivopts.cc (create_new_iv): Ditto.
37536         * tree-ssa-loop-manip.cc (create_iv): Ditto.
37537         (tree_transform_and_unroll_loop): Ditto.
37538         (canonicalize_loop_ivs): Ditto.
37539         * tree-ssa-loop-manip.h (create_iv): Ditto.
37540         * tree-vect-data-refs.cc (vect_create_data_ref_ptr): Ditto.
37541         * tree-vect-loop-manip.cc (vect_set_loop_controls_directly):
37542         Ditto.
37543         (vect_set_loop_condition_normal): Ditto.
37544         * tree-vect-loop.cc (vect_create_epilog_for_reduction): Ditto.
37545         * tree-vect-stmts.cc (vectorizable_store): Ditto.
37546         (vectorizable_load): Ditto.
37548 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37550         * config/arm/arm-mve-builtins-base.cc (vmovlbq, vmovltq): New.
37551         * config/arm/arm-mve-builtins-base.def (vmovlbq, vmovltq): New.
37552         * config/arm/arm-mve-builtins-base.h (vmovlbq, vmovltq): New.
37553         * config/arm/arm_mve.h (vmovlbq): Remove.
37554         (vmovltq): Remove.
37555         (vmovlbq_m): Remove.
37556         (vmovltq_m): Remove.
37557         (vmovlbq_x): Remove.
37558         (vmovltq_x): Remove.
37559         (vmovlbq_s8): Remove.
37560         (vmovlbq_s16): Remove.
37561         (vmovltq_s8): Remove.
37562         (vmovltq_s16): Remove.
37563         (vmovltq_u8): Remove.
37564         (vmovltq_u16): Remove.
37565         (vmovlbq_u8): Remove.
37566         (vmovlbq_u16): Remove.
37567         (vmovlbq_m_s8): Remove.
37568         (vmovltq_m_s8): Remove.
37569         (vmovlbq_m_u8): Remove.
37570         (vmovltq_m_u8): Remove.
37571         (vmovlbq_m_s16): Remove.
37572         (vmovltq_m_s16): Remove.
37573         (vmovlbq_m_u16): Remove.
37574         (vmovltq_m_u16): Remove.
37575         (vmovlbq_x_s8): Remove.
37576         (vmovlbq_x_s16): Remove.
37577         (vmovlbq_x_u8): Remove.
37578         (vmovlbq_x_u16): Remove.
37579         (vmovltq_x_s8): Remove.
37580         (vmovltq_x_s16): Remove.
37581         (vmovltq_x_u8): Remove.
37582         (vmovltq_x_u16): Remove.
37583         (__arm_vmovlbq_s8): Remove.
37584         (__arm_vmovlbq_s16): Remove.
37585         (__arm_vmovltq_s8): Remove.
37586         (__arm_vmovltq_s16): Remove.
37587         (__arm_vmovltq_u8): Remove.
37588         (__arm_vmovltq_u16): Remove.
37589         (__arm_vmovlbq_u8): Remove.
37590         (__arm_vmovlbq_u16): Remove.
37591         (__arm_vmovlbq_m_s8): Remove.
37592         (__arm_vmovltq_m_s8): Remove.
37593         (__arm_vmovlbq_m_u8): Remove.
37594         (__arm_vmovltq_m_u8): Remove.
37595         (__arm_vmovlbq_m_s16): Remove.
37596         (__arm_vmovltq_m_s16): Remove.
37597         (__arm_vmovlbq_m_u16): Remove.
37598         (__arm_vmovltq_m_u16): Remove.
37599         (__arm_vmovlbq_x_s8): Remove.
37600         (__arm_vmovlbq_x_s16): Remove.
37601         (__arm_vmovlbq_x_u8): Remove.
37602         (__arm_vmovlbq_x_u16): Remove.
37603         (__arm_vmovltq_x_s8): Remove.
37604         (__arm_vmovltq_x_s16): Remove.
37605         (__arm_vmovltq_x_u8): Remove.
37606         (__arm_vmovltq_x_u16): Remove.
37607         (__arm_vmovlbq): Remove.
37608         (__arm_vmovltq): Remove.
37609         (__arm_vmovlbq_m): Remove.
37610         (__arm_vmovltq_m): Remove.
37611         (__arm_vmovlbq_x): Remove.
37612         (__arm_vmovltq_x): Remove.
37614 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37616         * config/arm/arm-mve-builtins-shapes.cc (unary_widen): New.
37617         * config/arm/arm-mve-builtins-shapes.h (unary_widen): New.
37619 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37621         * config/arm/iterators.md (mve_insn): Add vmovlb, vmovlt.
37622         (VMOVLBQ, VMOVLTQ): Merge into ...
37623         (VMOVLxQ): ... this.
37624         (VMOVLTQ_M, VMOVLBQ_M): Merge into ...
37625         (VMOVLxQ_M): ... this.
37626         * config/arm/mve.md (mve_vmovltq_<supf><mode>)
37627         (mve_vmovlbq_<supf><mode>): Merge into ...
37628         (@mve_<mve_insn>q_<supf><mode>): ... this.
37629         (mve_vmovlbq_m_<supf><mode>, mve_vmovltq_m_<supf><mode>): Merge
37630         into ...
37631         (@mve_<mve_insn>q_m_<supf><mode>): ... this.
37633 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37635         * config/arm/arm-mve-builtins-base.cc (vaddlvq): New.
37636         * config/arm/arm-mve-builtins-base.def (vaddlvq): New.
37637         * config/arm/arm-mve-builtins-base.h (vaddlvq): New.
37638         * config/arm/arm-mve-builtins-functions.h
37639         (unspec_mve_function_exact_insn_pred_p): Handle vaddlvq.
37640         * config/arm/arm_mve.h (vaddlvq): Remove.
37641         (vaddlvq_p): Remove.
37642         (vaddlvq_s32): Remove.
37643         (vaddlvq_u32): Remove.
37644         (vaddlvq_p_s32): Remove.
37645         (vaddlvq_p_u32): Remove.
37646         (__arm_vaddlvq_s32): Remove.
37647         (__arm_vaddlvq_u32): Remove.
37648         (__arm_vaddlvq_p_s32): Remove.
37649         (__arm_vaddlvq_p_u32): Remove.
37650         (__arm_vaddlvq): Remove.
37651         (__arm_vaddlvq_p): Remove.
37653 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37655         * config/arm/iterators.md (mve_insn): Add vaddlv.
37656         * config/arm/mve.md (mve_vaddlvq_<supf>v4si): Rename into ...
37657         (@mve_<mve_insn>q_<supf>v4si): ... this.
37658         (mve_vaddlvq_p_<supf>v4si): Rename into ...
37659         (@mve_<mve_insn>q_p_<supf>v4si): ... this.
37661 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37663         * config/arm/arm-mve-builtins-shapes.cc (unary_acc): New.
37664         * config/arm/arm-mve-builtins-shapes.h (unary_acc): New.
37666 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37668         * config/arm/arm-mve-builtins-base.cc (vaddvaq): New.
37669         * config/arm/arm-mve-builtins-base.def (vaddvaq): New.
37670         * config/arm/arm-mve-builtins-base.h (vaddvaq): New.
37671         * config/arm/arm_mve.h (vaddvaq): Remove.
37672         (vaddvaq_p): Remove.
37673         (vaddvaq_u8): Remove.
37674         (vaddvaq_s8): Remove.
37675         (vaddvaq_u16): Remove.
37676         (vaddvaq_s16): Remove.
37677         (vaddvaq_u32): Remove.
37678         (vaddvaq_s32): Remove.
37679         (vaddvaq_p_u8): Remove.
37680         (vaddvaq_p_s8): Remove.
37681         (vaddvaq_p_u16): Remove.
37682         (vaddvaq_p_s16): Remove.
37683         (vaddvaq_p_u32): Remove.
37684         (vaddvaq_p_s32): Remove.
37685         (__arm_vaddvaq_u8): Remove.
37686         (__arm_vaddvaq_s8): Remove.
37687         (__arm_vaddvaq_u16): Remove.
37688         (__arm_vaddvaq_s16): Remove.
37689         (__arm_vaddvaq_u32): Remove.
37690         (__arm_vaddvaq_s32): Remove.
37691         (__arm_vaddvaq_p_u8): Remove.
37692         (__arm_vaddvaq_p_s8): Remove.
37693         (__arm_vaddvaq_p_u16): Remove.
37694         (__arm_vaddvaq_p_s16): Remove.
37695         (__arm_vaddvaq_p_u32): Remove.
37696         (__arm_vaddvaq_p_s32): Remove.
37697         (__arm_vaddvaq): Remove.
37698         (__arm_vaddvaq_p): Remove.
37700 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37702         * config/arm/arm-mve-builtins-shapes.cc (unary_int32_acc): New.
37703         * config/arm/arm-mve-builtins-shapes.h (unary_int32_acc): New.
37705 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37707         * config/arm/iterators.md (mve_insn): Add vaddva.
37708         * config/arm/mve.md (mve_vaddvaq_<supf><mode>): Rename into ...
37709         (@mve_<mve_insn>q_<supf><mode>): ... this.
37710         (mve_vaddvaq_p_<supf><mode>): Rename into ...
37711         (@mve_<mve_insn>q_p_<supf><mode>): ... this.
37713 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37715         * config/arm/arm-mve-builtins-base.cc (vaddvq): New.
37716         * config/arm/arm-mve-builtins-base.def (vaddvq): New.
37717         * config/arm/arm-mve-builtins-base.h (vaddvq): New.
37718         * config/arm/arm_mve.h (vaddvq): Remove.
37719         (vaddvq_p): Remove.
37720         (vaddvq_s8): Remove.
37721         (vaddvq_s16): Remove.
37722         (vaddvq_s32): Remove.
37723         (vaddvq_u8): Remove.
37724         (vaddvq_u16): Remove.
37725         (vaddvq_u32): Remove.
37726         (vaddvq_p_u8): Remove.
37727         (vaddvq_p_s8): Remove.
37728         (vaddvq_p_u16): Remove.
37729         (vaddvq_p_s16): Remove.
37730         (vaddvq_p_u32): Remove.
37731         (vaddvq_p_s32): Remove.
37732         (__arm_vaddvq_s8): Remove.
37733         (__arm_vaddvq_s16): Remove.
37734         (__arm_vaddvq_s32): Remove.
37735         (__arm_vaddvq_u8): Remove.
37736         (__arm_vaddvq_u16): Remove.
37737         (__arm_vaddvq_u32): Remove.
37738         (__arm_vaddvq_p_u8): Remove.
37739         (__arm_vaddvq_p_s8): Remove.
37740         (__arm_vaddvq_p_u16): Remove.
37741         (__arm_vaddvq_p_s16): Remove.
37742         (__arm_vaddvq_p_u32): Remove.
37743         (__arm_vaddvq_p_s32): Remove.
37744         (__arm_vaddvq): Remove.
37745         (__arm_vaddvq_p): Remove.
37747 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37749         * config/arm/arm-mve-builtins-shapes.cc (unary_int32): New.
37750         * config/arm/arm-mve-builtins-shapes.h (unary_int32): New.
37752 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37754         * config/arm/iterators.md (mve_insn): Add vaddv.
37755         * config/arm/mve.md (@mve_vaddvq_<supf><mode>): Rename into ...
37756         (@mve_<mve_insn>q_<supf><mode>): ... this.
37757         (mve_vaddvq_p_<supf><mode>): Rename into ...
37758         (@mve_<mve_insn>q_p_<supf><mode>): ... this.
37759         * config/arm/vec-common.md: Use gen_mve_q instead of
37760         gen_mve_vaddvq.
37762 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37764         * config/arm/arm-mve-builtins-base.cc (FUNCTION_ONLY_N): New.
37765         (vdupq): New.
37766         * config/arm/arm-mve-builtins-base.def (vdupq): New.
37767         * config/arm/arm-mve-builtins-base.h: (vdupq): New.
37768         * config/arm/arm_mve.h (vdupq_n): Remove.
37769         (vdupq_m): Remove.
37770         (vdupq_n_f16): Remove.
37771         (vdupq_n_f32): Remove.
37772         (vdupq_n_s8): Remove.
37773         (vdupq_n_s16): Remove.
37774         (vdupq_n_s32): Remove.
37775         (vdupq_n_u8): Remove.
37776         (vdupq_n_u16): Remove.
37777         (vdupq_n_u32): Remove.
37778         (vdupq_m_n_u8): Remove.
37779         (vdupq_m_n_s8): Remove.
37780         (vdupq_m_n_u16): Remove.
37781         (vdupq_m_n_s16): Remove.
37782         (vdupq_m_n_u32): Remove.
37783         (vdupq_m_n_s32): Remove.
37784         (vdupq_m_n_f16): Remove.
37785         (vdupq_m_n_f32): Remove.
37786         (vdupq_x_n_s8): Remove.
37787         (vdupq_x_n_s16): Remove.
37788         (vdupq_x_n_s32): Remove.
37789         (vdupq_x_n_u8): Remove.
37790         (vdupq_x_n_u16): Remove.
37791         (vdupq_x_n_u32): Remove.
37792         (vdupq_x_n_f16): Remove.
37793         (vdupq_x_n_f32): Remove.
37794         (__arm_vdupq_n_s8): Remove.
37795         (__arm_vdupq_n_s16): Remove.
37796         (__arm_vdupq_n_s32): Remove.
37797         (__arm_vdupq_n_u8): Remove.
37798         (__arm_vdupq_n_u16): Remove.
37799         (__arm_vdupq_n_u32): Remove.
37800         (__arm_vdupq_m_n_u8): Remove.
37801         (__arm_vdupq_m_n_s8): Remove.
37802         (__arm_vdupq_m_n_u16): Remove.
37803         (__arm_vdupq_m_n_s16): Remove.
37804         (__arm_vdupq_m_n_u32): Remove.
37805         (__arm_vdupq_m_n_s32): Remove.
37806         (__arm_vdupq_x_n_s8): Remove.
37807         (__arm_vdupq_x_n_s16): Remove.
37808         (__arm_vdupq_x_n_s32): Remove.
37809         (__arm_vdupq_x_n_u8): Remove.
37810         (__arm_vdupq_x_n_u16): Remove.
37811         (__arm_vdupq_x_n_u32): Remove.
37812         (__arm_vdupq_n_f16): Remove.
37813         (__arm_vdupq_n_f32): Remove.
37814         (__arm_vdupq_m_n_f16): Remove.
37815         (__arm_vdupq_m_n_f32): Remove.
37816         (__arm_vdupq_x_n_f16): Remove.
37817         (__arm_vdupq_x_n_f32): Remove.
37818         (__arm_vdupq_n): Remove.
37819         (__arm_vdupq_m): Remove.
37821 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37823         * config/arm/arm-mve-builtins-shapes.cc (unary_n): New.
37824         * config/arm/arm-mve-builtins-shapes.h (unary_n): New.
37826 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37828         * config/arm/iterators.md (MVE_FP_M_N_VDUPQ_ONLY)
37829         (MVE_FP_N_VDUPQ_ONLY): New.
37830         (mve_insn): Add vdupq.
37831         * config/arm/mve.md (mve_vdupq_n_f<mode>): Rename into ...
37832         (@mve_<mve_insn>q_n_f<mode>): ... this.
37833         (mve_vdupq_n_<supf><mode>): Rename into ...
37834         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
37835         (mve_vdupq_m_n_<supf><mode>): Rename into ...
37836         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
37837         (mve_vdupq_m_n_f<mode>): Rename into ...
37838         (@mve_<mve_insn>q_m_n_f<mode>): ... this.
37840 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37842         * config/arm/arm-mve-builtins-base.cc (vrev16q, vrev32q, vrev64q):
37843         New.
37844         * config/arm/arm-mve-builtins-base.def (vrev16q, vrev32q)
37845         (vrev64q): New.
37846         * config/arm/arm-mve-builtins-base.h (vrev16q, vrev32q)
37847         (vrev64q): New.
37848         * config/arm/arm_mve.h (vrev16q): Remove.
37849         (vrev32q): Remove.
37850         (vrev64q): Remove.
37851         (vrev64q_m): Remove.
37852         (vrev16q_m): Remove.
37853         (vrev32q_m): Remove.
37854         (vrev16q_x): Remove.
37855         (vrev32q_x): Remove.
37856         (vrev64q_x): Remove.
37857         (vrev64q_f16): Remove.
37858         (vrev64q_f32): Remove.
37859         (vrev32q_f16): Remove.
37860         (vrev16q_s8): Remove.
37861         (vrev32q_s8): Remove.
37862         (vrev32q_s16): Remove.
37863         (vrev64q_s8): Remove.
37864         (vrev64q_s16): Remove.
37865         (vrev64q_s32): Remove.
37866         (vrev64q_u8): Remove.
37867         (vrev64q_u16): Remove.
37868         (vrev64q_u32): Remove.
37869         (vrev32q_u8): Remove.
37870         (vrev32q_u16): Remove.
37871         (vrev16q_u8): Remove.
37872         (vrev64q_m_u8): Remove.
37873         (vrev64q_m_s8): Remove.
37874         (vrev64q_m_u16): Remove.
37875         (vrev64q_m_s16): Remove.
37876         (vrev64q_m_u32): Remove.
37877         (vrev64q_m_s32): Remove.
37878         (vrev16q_m_s8): Remove.
37879         (vrev32q_m_f16): Remove.
37880         (vrev16q_m_u8): Remove.
37881         (vrev32q_m_s8): Remove.
37882         (vrev64q_m_f16): Remove.
37883         (vrev32q_m_u8): Remove.
37884         (vrev32q_m_s16): Remove.
37885         (vrev64q_m_f32): Remove.
37886         (vrev32q_m_u16): Remove.
37887         (vrev16q_x_s8): Remove.
37888         (vrev16q_x_u8): Remove.
37889         (vrev32q_x_s8): Remove.
37890         (vrev32q_x_s16): Remove.
37891         (vrev32q_x_u8): Remove.
37892         (vrev32q_x_u16): Remove.
37893         (vrev64q_x_s8): Remove.
37894         (vrev64q_x_s16): Remove.
37895         (vrev64q_x_s32): Remove.
37896         (vrev64q_x_u8): Remove.
37897         (vrev64q_x_u16): Remove.
37898         (vrev64q_x_u32): Remove.
37899         (vrev32q_x_f16): Remove.
37900         (vrev64q_x_f16): Remove.
37901         (vrev64q_x_f32): Remove.
37902         (__arm_vrev16q_s8): Remove.
37903         (__arm_vrev32q_s8): Remove.
37904         (__arm_vrev32q_s16): Remove.
37905         (__arm_vrev64q_s8): Remove.
37906         (__arm_vrev64q_s16): Remove.
37907         (__arm_vrev64q_s32): Remove.
37908         (__arm_vrev64q_u8): Remove.
37909         (__arm_vrev64q_u16): Remove.
37910         (__arm_vrev64q_u32): Remove.
37911         (__arm_vrev32q_u8): Remove.
37912         (__arm_vrev32q_u16): Remove.
37913         (__arm_vrev16q_u8): Remove.
37914         (__arm_vrev64q_m_u8): Remove.
37915         (__arm_vrev64q_m_s8): Remove.
37916         (__arm_vrev64q_m_u16): Remove.
37917         (__arm_vrev64q_m_s16): Remove.
37918         (__arm_vrev64q_m_u32): Remove.
37919         (__arm_vrev64q_m_s32): Remove.
37920         (__arm_vrev16q_m_s8): Remove.
37921         (__arm_vrev16q_m_u8): Remove.
37922         (__arm_vrev32q_m_s8): Remove.
37923         (__arm_vrev32q_m_u8): Remove.
37924         (__arm_vrev32q_m_s16): Remove.
37925         (__arm_vrev32q_m_u16): Remove.
37926         (__arm_vrev16q_x_s8): Remove.
37927         (__arm_vrev16q_x_u8): Remove.
37928         (__arm_vrev32q_x_s8): Remove.
37929         (__arm_vrev32q_x_s16): Remove.
37930         (__arm_vrev32q_x_u8): Remove.
37931         (__arm_vrev32q_x_u16): Remove.
37932         (__arm_vrev64q_x_s8): Remove.
37933         (__arm_vrev64q_x_s16): Remove.
37934         (__arm_vrev64q_x_s32): Remove.
37935         (__arm_vrev64q_x_u8): Remove.
37936         (__arm_vrev64q_x_u16): Remove.
37937         (__arm_vrev64q_x_u32): Remove.
37938         (__arm_vrev64q_f16): Remove.
37939         (__arm_vrev64q_f32): Remove.
37940         (__arm_vrev32q_f16): Remove.
37941         (__arm_vrev32q_m_f16): Remove.
37942         (__arm_vrev64q_m_f16): Remove.
37943         (__arm_vrev64q_m_f32): Remove.
37944         (__arm_vrev32q_x_f16): Remove.
37945         (__arm_vrev64q_x_f16): Remove.
37946         (__arm_vrev64q_x_f32): Remove.
37947         (__arm_vrev16q): Remove.
37948         (__arm_vrev32q): Remove.
37949         (__arm_vrev64q): Remove.
37950         (__arm_vrev64q_m): Remove.
37951         (__arm_vrev16q_m): Remove.
37952         (__arm_vrev32q_m): Remove.
37953         (__arm_vrev16q_x): Remove.
37954         (__arm_vrev32q_x): Remove.
37955         (__arm_vrev64q_x): Remove.
37957 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37959         * config/arm/iterators.md (MVE_V8HF, MVE_V16QI)
37960         (MVE_FP_VREV64Q_ONLY, MVE_FP_M_VREV64Q_ONLY, MVE_FP_VREV32Q_ONLY)
37961         (MVE_FP_M_VREV32Q_ONLY): New iterators.
37962         (mve_insn): Add vrev16q, vrev32q, vrev64q.
37963         * config/arm/mve.md (mve_vrev64q_f<mode>): Rename into ...
37964         (@mve_<mve_insn>q_f<mode>): ... this
37965         (mve_vrev32q_fv8hf): Rename into @mve_<mve_insn>q_f<mode>.
37966         (mve_vrev64q_<supf><mode>): Rename into ...
37967         (@mve_<mve_insn>q_<supf><mode>): ... this.
37968         (mve_vrev32q_<supf><mode>): Rename into
37969         @mve_<mve_insn>q_<supf><mode>.
37970         (mve_vrev16q_<supf>v16qi): Rename into
37971         @mve_<mve_insn>q_<supf><mode>.
37972         (mve_vrev64q_m_<supf><mode>): Rename into
37973         @mve_<mve_insn>q_m_<supf><mode>.
37974         (mve_vrev32q_m_fv8hf): Rename into @mve_<mve_insn>q_m_f<mode>.
37975         (mve_vrev32q_m_<supf><mode>): Rename into
37976         @mve_<mve_insn>q_m_<supf><mode>.
37977         (mve_vrev64q_m_f<mode>): Rename into @mve_<mve_insn>q_m_f<mode>.
37978         (mve_vrev16q_m_<supf>v16qi): Rename into
37979         @mve_<mve_insn>q_m_<supf><mode>.
37981 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
37983         * config/arm/arm-mve-builtins-base.cc (vcmpeqq, vcmpneq, vcmpgeq)
37984         (vcmpgtq, vcmpleq, vcmpltq, vcmpcsq, vcmphiq): New.
37985         * config/arm/arm-mve-builtins-base.def (vcmpeqq, vcmpneq, vcmpgeq)
37986         (vcmpgtq, vcmpleq, vcmpltq, vcmpcsq, vcmphiq): New.
37987         * config/arm/arm-mve-builtins-base.h (vcmpeqq, vcmpneq, vcmpgeq)
37988         (vcmpgtq, vcmpleq, vcmpltq, vcmpcsq, vcmphiq): New.
37989         * config/arm/arm-mve-builtins-functions.h (class
37990         unspec_based_mve_function_exact_insn_vcmp): New.
37991         * config/arm/arm-mve-builtins.cc
37992         (function_instance::has_inactive_argument): Handle vcmp.
37993         * config/arm/arm_mve.h (vcmpneq): Remove.
37994         (vcmphiq): Remove.
37995         (vcmpeqq): Remove.
37996         (vcmpcsq): Remove.
37997         (vcmpltq): Remove.
37998         (vcmpleq): Remove.
37999         (vcmpgtq): Remove.
38000         (vcmpgeq): Remove.
38001         (vcmpneq_m): Remove.
38002         (vcmphiq_m): Remove.
38003         (vcmpeqq_m): Remove.
38004         (vcmpcsq_m): Remove.
38005         (vcmpcsq_m_n): Remove.
38006         (vcmpltq_m): Remove.
38007         (vcmpleq_m): Remove.
38008         (vcmpgtq_m): Remove.
38009         (vcmpgeq_m): Remove.
38010         (vcmpneq_s8): Remove.
38011         (vcmpneq_s16): Remove.
38012         (vcmpneq_s32): Remove.
38013         (vcmpneq_u8): Remove.
38014         (vcmpneq_u16): Remove.
38015         (vcmpneq_u32): Remove.
38016         (vcmpneq_n_u8): Remove.
38017         (vcmphiq_u8): Remove.
38018         (vcmphiq_n_u8): Remove.
38019         (vcmpeqq_u8): Remove.
38020         (vcmpeqq_n_u8): Remove.
38021         (vcmpcsq_u8): Remove.
38022         (vcmpcsq_n_u8): Remove.
38023         (vcmpneq_n_s8): Remove.
38024         (vcmpltq_s8): Remove.
38025         (vcmpltq_n_s8): Remove.
38026         (vcmpleq_s8): Remove.
38027         (vcmpleq_n_s8): Remove.
38028         (vcmpgtq_s8): Remove.
38029         (vcmpgtq_n_s8): Remove.
38030         (vcmpgeq_s8): Remove.
38031         (vcmpgeq_n_s8): Remove.
38032         (vcmpeqq_s8): Remove.
38033         (vcmpeqq_n_s8): Remove.
38034         (vcmpneq_n_u16): Remove.
38035         (vcmphiq_u16): Remove.
38036         (vcmphiq_n_u16): Remove.
38037         (vcmpeqq_u16): Remove.
38038         (vcmpeqq_n_u16): Remove.
38039         (vcmpcsq_u16): Remove.
38040         (vcmpcsq_n_u16): Remove.
38041         (vcmpneq_n_s16): Remove.
38042         (vcmpltq_s16): Remove.
38043         (vcmpltq_n_s16): Remove.
38044         (vcmpleq_s16): Remove.
38045         (vcmpleq_n_s16): Remove.
38046         (vcmpgtq_s16): Remove.
38047         (vcmpgtq_n_s16): Remove.
38048         (vcmpgeq_s16): Remove.
38049         (vcmpgeq_n_s16): Remove.
38050         (vcmpeqq_s16): Remove.
38051         (vcmpeqq_n_s16): Remove.
38052         (vcmpneq_n_u32): Remove.
38053         (vcmphiq_u32): Remove.
38054         (vcmphiq_n_u32): Remove.
38055         (vcmpeqq_u32): Remove.
38056         (vcmpeqq_n_u32): Remove.
38057         (vcmpcsq_u32): Remove.
38058         (vcmpcsq_n_u32): Remove.
38059         (vcmpneq_n_s32): Remove.
38060         (vcmpltq_s32): Remove.
38061         (vcmpltq_n_s32): Remove.
38062         (vcmpleq_s32): Remove.
38063         (vcmpleq_n_s32): Remove.
38064         (vcmpgtq_s32): Remove.
38065         (vcmpgtq_n_s32): Remove.
38066         (vcmpgeq_s32): Remove.
38067         (vcmpgeq_n_s32): Remove.
38068         (vcmpeqq_s32): Remove.
38069         (vcmpeqq_n_s32): Remove.
38070         (vcmpneq_n_f16): Remove.
38071         (vcmpneq_f16): Remove.
38072         (vcmpltq_n_f16): Remove.
38073         (vcmpltq_f16): Remove.
38074         (vcmpleq_n_f16): Remove.
38075         (vcmpleq_f16): Remove.
38076         (vcmpgtq_n_f16): Remove.
38077         (vcmpgtq_f16): Remove.
38078         (vcmpgeq_n_f16): Remove.
38079         (vcmpgeq_f16): Remove.
38080         (vcmpeqq_n_f16): Remove.
38081         (vcmpeqq_f16): Remove.
38082         (vcmpneq_n_f32): Remove.
38083         (vcmpneq_f32): Remove.
38084         (vcmpltq_n_f32): Remove.
38085         (vcmpltq_f32): Remove.
38086         (vcmpleq_n_f32): Remove.
38087         (vcmpleq_f32): Remove.
38088         (vcmpgtq_n_f32): Remove.
38089         (vcmpgtq_f32): Remove.
38090         (vcmpgeq_n_f32): Remove.
38091         (vcmpgeq_f32): Remove.
38092         (vcmpeqq_n_f32): Remove.
38093         (vcmpeqq_f32): Remove.
38094         (vcmpeqq_m_f16): Remove.
38095         (vcmpeqq_m_f32): Remove.
38096         (vcmpneq_m_u8): Remove.
38097         (vcmpneq_m_n_u8): Remove.
38098         (vcmphiq_m_u8): Remove.
38099         (vcmphiq_m_n_u8): Remove.
38100         (vcmpeqq_m_u8): Remove.
38101         (vcmpeqq_m_n_u8): Remove.
38102         (vcmpcsq_m_u8): Remove.
38103         (vcmpcsq_m_n_u8): Remove.
38104         (vcmpneq_m_s8): Remove.
38105         (vcmpneq_m_n_s8): Remove.
38106         (vcmpltq_m_s8): Remove.
38107         (vcmpltq_m_n_s8): Remove.
38108         (vcmpleq_m_s8): Remove.
38109         (vcmpleq_m_n_s8): Remove.
38110         (vcmpgtq_m_s8): Remove.
38111         (vcmpgtq_m_n_s8): Remove.
38112         (vcmpgeq_m_s8): Remove.
38113         (vcmpgeq_m_n_s8): Remove.
38114         (vcmpeqq_m_s8): Remove.
38115         (vcmpeqq_m_n_s8): Remove.
38116         (vcmpneq_m_u16): Remove.
38117         (vcmpneq_m_n_u16): Remove.
38118         (vcmphiq_m_u16): Remove.
38119         (vcmphiq_m_n_u16): Remove.
38120         (vcmpeqq_m_u16): Remove.
38121         (vcmpeqq_m_n_u16): Remove.
38122         (vcmpcsq_m_u16): Remove.
38123         (vcmpcsq_m_n_u16): Remove.
38124         (vcmpneq_m_s16): Remove.
38125         (vcmpneq_m_n_s16): Remove.
38126         (vcmpltq_m_s16): Remove.
38127         (vcmpltq_m_n_s16): Remove.
38128         (vcmpleq_m_s16): Remove.
38129         (vcmpleq_m_n_s16): Remove.
38130         (vcmpgtq_m_s16): Remove.
38131         (vcmpgtq_m_n_s16): Remove.
38132         (vcmpgeq_m_s16): Remove.
38133         (vcmpgeq_m_n_s16): Remove.
38134         (vcmpeqq_m_s16): Remove.
38135         (vcmpeqq_m_n_s16): Remove.
38136         (vcmpneq_m_u32): Remove.
38137         (vcmpneq_m_n_u32): Remove.
38138         (vcmphiq_m_u32): Remove.
38139         (vcmphiq_m_n_u32): Remove.
38140         (vcmpeqq_m_u32): Remove.
38141         (vcmpeqq_m_n_u32): Remove.
38142         (vcmpcsq_m_u32): Remove.
38143         (vcmpcsq_m_n_u32): Remove.
38144         (vcmpneq_m_s32): Remove.
38145         (vcmpneq_m_n_s32): Remove.
38146         (vcmpltq_m_s32): Remove.
38147         (vcmpltq_m_n_s32): Remove.
38148         (vcmpleq_m_s32): Remove.
38149         (vcmpleq_m_n_s32): Remove.
38150         (vcmpgtq_m_s32): Remove.
38151         (vcmpgtq_m_n_s32): Remove.
38152         (vcmpgeq_m_s32): Remove.
38153         (vcmpgeq_m_n_s32): Remove.
38154         (vcmpeqq_m_s32): Remove.
38155         (vcmpeqq_m_n_s32): Remove.
38156         (vcmpeqq_m_n_f16): Remove.
38157         (vcmpgeq_m_f16): Remove.
38158         (vcmpgeq_m_n_f16): Remove.
38159         (vcmpgtq_m_f16): Remove.
38160         (vcmpgtq_m_n_f16): Remove.
38161         (vcmpleq_m_f16): Remove.
38162         (vcmpleq_m_n_f16): Remove.
38163         (vcmpltq_m_f16): Remove.
38164         (vcmpltq_m_n_f16): Remove.
38165         (vcmpneq_m_f16): Remove.
38166         (vcmpneq_m_n_f16): Remove.
38167         (vcmpeqq_m_n_f32): Remove.
38168         (vcmpgeq_m_f32): Remove.
38169         (vcmpgeq_m_n_f32): Remove.
38170         (vcmpgtq_m_f32): Remove.
38171         (vcmpgtq_m_n_f32): Remove.
38172         (vcmpleq_m_f32): Remove.
38173         (vcmpleq_m_n_f32): Remove.
38174         (vcmpltq_m_f32): Remove.
38175         (vcmpltq_m_n_f32): Remove.
38176         (vcmpneq_m_f32): Remove.
38177         (vcmpneq_m_n_f32): Remove.
38178         (__arm_vcmpneq_s8): Remove.
38179         (__arm_vcmpneq_s16): Remove.
38180         (__arm_vcmpneq_s32): Remove.
38181         (__arm_vcmpneq_u8): Remove.
38182         (__arm_vcmpneq_u16): Remove.
38183         (__arm_vcmpneq_u32): Remove.
38184         (__arm_vcmpneq_n_u8): Remove.
38185         (__arm_vcmphiq_u8): Remove.
38186         (__arm_vcmphiq_n_u8): Remove.
38187         (__arm_vcmpeqq_u8): Remove.
38188         (__arm_vcmpeqq_n_u8): Remove.
38189         (__arm_vcmpcsq_u8): Remove.
38190         (__arm_vcmpcsq_n_u8): Remove.
38191         (__arm_vcmpneq_n_s8): Remove.
38192         (__arm_vcmpltq_s8): Remove.
38193         (__arm_vcmpltq_n_s8): Remove.
38194         (__arm_vcmpleq_s8): Remove.
38195         (__arm_vcmpleq_n_s8): Remove.
38196         (__arm_vcmpgtq_s8): Remove.
38197         (__arm_vcmpgtq_n_s8): Remove.
38198         (__arm_vcmpgeq_s8): Remove.
38199         (__arm_vcmpgeq_n_s8): Remove.
38200         (__arm_vcmpeqq_s8): Remove.
38201         (__arm_vcmpeqq_n_s8): Remove.
38202         (__arm_vcmpneq_n_u16): Remove.
38203         (__arm_vcmphiq_u16): Remove.
38204         (__arm_vcmphiq_n_u16): Remove.
38205         (__arm_vcmpeqq_u16): Remove.
38206         (__arm_vcmpeqq_n_u16): Remove.
38207         (__arm_vcmpcsq_u16): Remove.
38208         (__arm_vcmpcsq_n_u16): Remove.
38209         (__arm_vcmpneq_n_s16): Remove.
38210         (__arm_vcmpltq_s16): Remove.
38211         (__arm_vcmpltq_n_s16): Remove.
38212         (__arm_vcmpleq_s16): Remove.
38213         (__arm_vcmpleq_n_s16): Remove.
38214         (__arm_vcmpgtq_s16): Remove.
38215         (__arm_vcmpgtq_n_s16): Remove.
38216         (__arm_vcmpgeq_s16): Remove.
38217         (__arm_vcmpgeq_n_s16): Remove.
38218         (__arm_vcmpeqq_s16): Remove.
38219         (__arm_vcmpeqq_n_s16): Remove.
38220         (__arm_vcmpneq_n_u32): Remove.
38221         (__arm_vcmphiq_u32): Remove.
38222         (__arm_vcmphiq_n_u32): Remove.
38223         (__arm_vcmpeqq_u32): Remove.
38224         (__arm_vcmpeqq_n_u32): Remove.
38225         (__arm_vcmpcsq_u32): Remove.
38226         (__arm_vcmpcsq_n_u32): Remove.
38227         (__arm_vcmpneq_n_s32): Remove.
38228         (__arm_vcmpltq_s32): Remove.
38229         (__arm_vcmpltq_n_s32): Remove.
38230         (__arm_vcmpleq_s32): Remove.
38231         (__arm_vcmpleq_n_s32): Remove.
38232         (__arm_vcmpgtq_s32): Remove.
38233         (__arm_vcmpgtq_n_s32): Remove.
38234         (__arm_vcmpgeq_s32): Remove.
38235         (__arm_vcmpgeq_n_s32): Remove.
38236         (__arm_vcmpeqq_s32): Remove.
38237         (__arm_vcmpeqq_n_s32): Remove.
38238         (__arm_vcmpneq_m_u8): Remove.
38239         (__arm_vcmpneq_m_n_u8): Remove.
38240         (__arm_vcmphiq_m_u8): Remove.
38241         (__arm_vcmphiq_m_n_u8): Remove.
38242         (__arm_vcmpeqq_m_u8): Remove.
38243         (__arm_vcmpeqq_m_n_u8): Remove.
38244         (__arm_vcmpcsq_m_u8): Remove.
38245         (__arm_vcmpcsq_m_n_u8): Remove.
38246         (__arm_vcmpneq_m_s8): Remove.
38247         (__arm_vcmpneq_m_n_s8): Remove.
38248         (__arm_vcmpltq_m_s8): Remove.
38249         (__arm_vcmpltq_m_n_s8): Remove.
38250         (__arm_vcmpleq_m_s8): Remove.
38251         (__arm_vcmpleq_m_n_s8): Remove.
38252         (__arm_vcmpgtq_m_s8): Remove.
38253         (__arm_vcmpgtq_m_n_s8): Remove.
38254         (__arm_vcmpgeq_m_s8): Remove.
38255         (__arm_vcmpgeq_m_n_s8): Remove.
38256         (__arm_vcmpeqq_m_s8): Remove.
38257         (__arm_vcmpeqq_m_n_s8): Remove.
38258         (__arm_vcmpneq_m_u16): Remove.
38259         (__arm_vcmpneq_m_n_u16): Remove.
38260         (__arm_vcmphiq_m_u16): Remove.
38261         (__arm_vcmphiq_m_n_u16): Remove.
38262         (__arm_vcmpeqq_m_u16): Remove.
38263         (__arm_vcmpeqq_m_n_u16): Remove.
38264         (__arm_vcmpcsq_m_u16): Remove.
38265         (__arm_vcmpcsq_m_n_u16): Remove.
38266         (__arm_vcmpneq_m_s16): Remove.
38267         (__arm_vcmpneq_m_n_s16): Remove.
38268         (__arm_vcmpltq_m_s16): Remove.
38269         (__arm_vcmpltq_m_n_s16): Remove.
38270         (__arm_vcmpleq_m_s16): Remove.
38271         (__arm_vcmpleq_m_n_s16): Remove.
38272         (__arm_vcmpgtq_m_s16): Remove.
38273         (__arm_vcmpgtq_m_n_s16): Remove.
38274         (__arm_vcmpgeq_m_s16): Remove.
38275         (__arm_vcmpgeq_m_n_s16): Remove.
38276         (__arm_vcmpeqq_m_s16): Remove.
38277         (__arm_vcmpeqq_m_n_s16): Remove.
38278         (__arm_vcmpneq_m_u32): Remove.
38279         (__arm_vcmpneq_m_n_u32): Remove.
38280         (__arm_vcmphiq_m_u32): Remove.
38281         (__arm_vcmphiq_m_n_u32): Remove.
38282         (__arm_vcmpeqq_m_u32): Remove.
38283         (__arm_vcmpeqq_m_n_u32): Remove.
38284         (__arm_vcmpcsq_m_u32): Remove.
38285         (__arm_vcmpcsq_m_n_u32): Remove.
38286         (__arm_vcmpneq_m_s32): Remove.
38287         (__arm_vcmpneq_m_n_s32): Remove.
38288         (__arm_vcmpltq_m_s32): Remove.
38289         (__arm_vcmpltq_m_n_s32): Remove.
38290         (__arm_vcmpleq_m_s32): Remove.
38291         (__arm_vcmpleq_m_n_s32): Remove.
38292         (__arm_vcmpgtq_m_s32): Remove.
38293         (__arm_vcmpgtq_m_n_s32): Remove.
38294         (__arm_vcmpgeq_m_s32): Remove.
38295         (__arm_vcmpgeq_m_n_s32): Remove.
38296         (__arm_vcmpeqq_m_s32): Remove.
38297         (__arm_vcmpeqq_m_n_s32): Remove.
38298         (__arm_vcmpneq_n_f16): Remove.
38299         (__arm_vcmpneq_f16): Remove.
38300         (__arm_vcmpltq_n_f16): Remove.
38301         (__arm_vcmpltq_f16): Remove.
38302         (__arm_vcmpleq_n_f16): Remove.
38303         (__arm_vcmpleq_f16): Remove.
38304         (__arm_vcmpgtq_n_f16): Remove.
38305         (__arm_vcmpgtq_f16): Remove.
38306         (__arm_vcmpgeq_n_f16): Remove.
38307         (__arm_vcmpgeq_f16): Remove.
38308         (__arm_vcmpeqq_n_f16): Remove.
38309         (__arm_vcmpeqq_f16): Remove.
38310         (__arm_vcmpneq_n_f32): Remove.
38311         (__arm_vcmpneq_f32): Remove.
38312         (__arm_vcmpltq_n_f32): Remove.
38313         (__arm_vcmpltq_f32): Remove.
38314         (__arm_vcmpleq_n_f32): Remove.
38315         (__arm_vcmpleq_f32): Remove.
38316         (__arm_vcmpgtq_n_f32): Remove.
38317         (__arm_vcmpgtq_f32): Remove.
38318         (__arm_vcmpgeq_n_f32): Remove.
38319         (__arm_vcmpgeq_f32): Remove.
38320         (__arm_vcmpeqq_n_f32): Remove.
38321         (__arm_vcmpeqq_f32): Remove.
38322         (__arm_vcmpeqq_m_f16): Remove.
38323         (__arm_vcmpeqq_m_f32): Remove.
38324         (__arm_vcmpeqq_m_n_f16): Remove.
38325         (__arm_vcmpgeq_m_f16): Remove.
38326         (__arm_vcmpgeq_m_n_f16): Remove.
38327         (__arm_vcmpgtq_m_f16): Remove.
38328         (__arm_vcmpgtq_m_n_f16): Remove.
38329         (__arm_vcmpleq_m_f16): Remove.
38330         (__arm_vcmpleq_m_n_f16): Remove.
38331         (__arm_vcmpltq_m_f16): Remove.
38332         (__arm_vcmpltq_m_n_f16): Remove.
38333         (__arm_vcmpneq_m_f16): Remove.
38334         (__arm_vcmpneq_m_n_f16): Remove.
38335         (__arm_vcmpeqq_m_n_f32): Remove.
38336         (__arm_vcmpgeq_m_f32): Remove.
38337         (__arm_vcmpgeq_m_n_f32): Remove.
38338         (__arm_vcmpgtq_m_f32): Remove.
38339         (__arm_vcmpgtq_m_n_f32): Remove.
38340         (__arm_vcmpleq_m_f32): Remove.
38341         (__arm_vcmpleq_m_n_f32): Remove.
38342         (__arm_vcmpltq_m_f32): Remove.
38343         (__arm_vcmpltq_m_n_f32): Remove.
38344         (__arm_vcmpneq_m_f32): Remove.
38345         (__arm_vcmpneq_m_n_f32): Remove.
38346         (__arm_vcmpneq): Remove.
38347         (__arm_vcmphiq): Remove.
38348         (__arm_vcmpeqq): Remove.
38349         (__arm_vcmpcsq): Remove.
38350         (__arm_vcmpltq): Remove.
38351         (__arm_vcmpleq): Remove.
38352         (__arm_vcmpgtq): Remove.
38353         (__arm_vcmpgeq): Remove.
38354         (__arm_vcmpneq_m): Remove.
38355         (__arm_vcmphiq_m): Remove.
38356         (__arm_vcmpeqq_m): Remove.
38357         (__arm_vcmpcsq_m): Remove.
38358         (__arm_vcmpltq_m): Remove.
38359         (__arm_vcmpleq_m): Remove.
38360         (__arm_vcmpgtq_m): Remove.
38361         (__arm_vcmpgeq_m): Remove.
38363 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
38365         * config/arm/arm-mve-builtins-shapes.cc (cmp): New.
38366         * config/arm/arm-mve-builtins-shapes.h (cmp): New.
38368 2023-05-11  Christophe Lyon  <christophe.lyon@arm.com>
38370         * config/arm/iterators.md (MVE_CMP_M, MVE_CMP_M_F, MVE_CMP_M_N)
38371         (MVE_CMP_M_N_F, mve_cmp_op1): New.
38372         (isu): Add VCMP*
38373         (supf): Likewise.
38374         * config/arm/mve.md (mve_vcmp<mve_cmp_op>q_n_<mode>): Rename into ...
38375         (@mve_vcmp<mve_cmp_op>q_n_<mode>): ... this.
38376         (mve_vcmpeqq_m_f<mode>, mve_vcmpgeq_m_f<mode>)
38377         (mve_vcmpgtq_m_f<mode>, mve_vcmpleq_m_f<mode>)
38378         (mve_vcmpltq_m_f<mode>, mve_vcmpneq_m_f<mode>): Merge into ...
38379         (@mve_vcmp<mve_cmp_op1>q_m_f<mode>): ... this.
38380         (mve_vcmpcsq_m_u<mode>, mve_vcmpeqq_m_<supf><mode>)
38381         (mve_vcmpgeq_m_s<mode>, mve_vcmpgtq_m_s<mode>)
38382         (mve_vcmphiq_m_u<mode>, mve_vcmpleq_m_s<mode>)
38383         (mve_vcmpltq_m_s<mode>, mve_vcmpneq_m_<supf><mode>): Merge into
38384         ...
38385         (@mve_vcmp<mve_cmp_op1>q_m_<supf><mode>): ... this.
38386         (mve_vcmpcsq_m_n_u<mode>, mve_vcmpeqq_m_n_<supf><mode>)
38387         (mve_vcmpgeq_m_n_s<mode>, mve_vcmpgtq_m_n_s<mode>)
38388         (mve_vcmphiq_m_n_u<mode>, mve_vcmpleq_m_n_s<mode>)
38389         (mve_vcmpltq_m_n_s<mode>, mve_vcmpneq_m_n_<supf><mode>): Merge
38390         into ...
38391         (@mve_vcmp<mve_cmp_op1>q_m_n_<supf><mode>): ... this.
38392         (mve_vcmpeqq_m_n_f<mode>, mve_vcmpgeq_m_n_f<mode>)
38393         (mve_vcmpgtq_m_n_f<mode>, mve_vcmpleq_m_n_f<mode>)
38394         (mve_vcmpltq_m_n_f<mode>, mve_vcmpneq_m_n_f<mode>): Merge into ...
38395         (@mve_vcmp<mve_cmp_op1>q_m_n_f<mode>): ... this.
38397 2023-05-11  Roger Sayle  <roger@nextmovesoftware.com>
38399         * match.pd <popcount optimizations>: Simplify popcount(X|Y) +
38400         popcount(X&Y) as popcount(X)+popcount(Y).  Likewise, simplify
38401         popcount(X)+popcount(Y)-popcount(X&Y) as popcount(X|Y), and
38402         vice versa.
38404 2023-05-11  Roger Sayle  <roger@nextmovesoftware.com>
38406         * match.pd <popcount optimizations>: Simplify popcount(bswap(x))
38407         as popcount(x).  Simplify popcount(rotate(x,y)) as popcount(x).
38408         <parity optimizations>:  Simplify parity(bswap(x)) as parity(x).
38409         Simplify parity(rotate(x,y)) as parity(x).
38411 2023-05-11  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
38413         * config/riscv/autovec.md (@vec_series<mode>): New pattern
38414         * config/riscv/riscv-protos.h (expand_vec_series): New function.
38415         * config/riscv/riscv-v.cc (emit_binop): Ditto.
38416         (emit_index_op): Ditto.
38417         (expand_vec_series): Ditto.
38418         (expand_const_vector): Add series vector handling.
38419         * config/riscv/riscv.cc (riscv_const_insns): Enable series vector for testing.
38421 2023-05-10  Roger Sayle  <roger@nextmovesoftware.com>
38423         * config/i386/i386.md (*concat<mode><dwi>3_1): Use preferred
38424         [(const_int 0)] idiom, instead of [(clobber (const_int 0))].
38425         (*concat<mode><dwi>3_2): Likewise.
38426         (*concat<mode><dwi>3_3): Likewise.
38427         (*concat<mode><dwi>3_4): Likewise.
38428         (*concat<mode><dwi>3_5): Likewise.
38429         (*concat<mode><dwi>3_6): Likewise.
38430         (*concat<mode><dwi>3_7): Likewise.
38432 2023-05-10  Uros Bizjak  <ubizjak@gmail.com>
38434         PR target/92658
38435         * config/i386/mmx.md (sse4_1_<code>v2qiv2si2): New insn pattern.
38436         (<insn>v4qiv4hi2): New expander.
38437         (<insn>v2hiv2si2): Ditto.
38438         (<insn>v2qiv2si2): Ditto.
38439         (<insn>v2qiv2hi2): Ditto.
38441 2023-05-10  Jeff Law  <jlaw@ventanamicro>
38443         * config/h8300/constraints.md (Q): Make this a special memory
38444         constraint.
38445         (Zz): Similarly.
38447 2023-05-10  Jakub Jelinek  <jakub@redhat.com>
38449         PR fortran/109788
38450         * ipa-prop.cc (ipa_get_callee_param_type): Don't return TREE_VALUE (t)
38451         if t is void_list_node.
38453 2023-05-10  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
38455         * config/aarch64/aarch64-simd.md (aarch64_sqmovun<mode>_insn_le): Delete.
38456         (aarch64_sqmovun<mode>_insn_be): Delete.
38457         (aarch64_sqmovun<mode><vczle><vczbe>): New define_insn.
38458         (aarch64_sqmovun<mode>): Delete expander.
38460 2023-05-10  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
38462         PR target/99195
38463         * config/aarch64/aarch64-simd.md (aarch64_<PERMUTE:perm_insn><mode>):
38464         Rename to...
38465         (aarch64_<PERMUTE:perm_insn><mode><vczle><vczbe>): ... This.
38466         (aarch64_rev<REVERSE:rev_op><mode>): Rename to...
38467         (aarch64_rev<REVERSE:rev_op><mode><vczle><vczbe>): ... This.
38469 2023-05-10  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
38471         PR target/99195
38472         * config/aarch64/aarch64-simd.md (aarch64_<su_optab>q<addsub><mode>):
38473         Rename to...
38474         (aarch64_<su_optab>q<addsub><mode><vczle><vczbe>): ... This.
38475         (aarch64_<sur>qadd<mode>): Rename to...
38476         (aarch64_<sur>qadd<mode><vczle><vczbe>): ... This.
38478 2023-05-10  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
38480         * config/aarch64/aarch64-simd.md
38481         (aarch64_<sur>q<r>shr<u>n_n<mode>_insn_le): Delete.
38482         (aarch64_<sur>q<r>shr<u>n_n<mode>_insn_be): Delete.
38483         (aarch64_<sur>q<r>shr<u>n_n<mode>_insn<vczle><vczbe>): New define_insn.
38484         (aarch64_<sur>q<r>shr<u>n_n<mode>): Simplify expander.
38486 2023-05-10  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
38488         PR target/99195
38489         * config/aarch64/aarch64-simd.md (aarch64_xtn<mode>_insn_le): Delete.
38490         (aarch64_xtn<mode>_insn_be): Likewise.
38491         (trunc<mode><Vnarrowq>2): Rename to...
38492         (trunc<mode><Vnarrowq>2<vczle><vczbe>): ... This.
38493         (aarch64_xtn<mode>): Move under the above.  Just emit the truncate RTL.
38494         (aarch64_<su>qmovn<mode>): Likewise.
38495         (aarch64_<su>qmovn<mode><vczle><vczbe>): New define_insn.
38496         (aarch64_<su>qmovn<mode>_insn_le): Delete.
38497         (aarch64_<su>qmovn<mode>_insn_be): Likewise.
38499 2023-05-10  Li Xu  <xuli1@eswincomputing.com>
38501         * config/riscv/riscv-vsetvl.cc (gen_vsetvl_pat): For vfmv.f.s/vmv.x.s
38502         intruction replace null avl with (const_int 0).
38504 2023-05-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
38506         * config/riscv/riscv.cc (riscv_support_vector_misalignment): Fix
38507         incorrect codes.
38509 2023-05-10  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
38511         PR target/109773
38512         * config/riscv/riscv-vsetvl.cc (avl_source_has_vsetvl_p): New function.
38513         (source_equal_p): Fix dead loop in vsetvl avl checking.
38515 2023-05-10  Hans-Peter Nilsson  <hp@axis.com>
38517         * config/cris/cris.cc (cris_postdbr_cmpelim): Correct mode
38518         of modeadjusted_dccr.
38520 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38522         * config/arm/arm-mve-builtins-base.cc (vmaxaq, vminaq): New.
38523         * config/arm/arm-mve-builtins-base.def (vmaxaq, vminaq): New.
38524         * config/arm/arm-mve-builtins-base.h (vmaxaq, vminaq): New.
38525         * config/arm/arm-mve-builtins.cc
38526         (function_instance::has_inactive_argument): Handle vmaxaq and
38527         vminaq.
38528         * config/arm/arm_mve.h (vminaq): Remove.
38529         (vmaxaq): Remove.
38530         (vminaq_m): Remove.
38531         (vmaxaq_m): Remove.
38532         (vminaq_s8): Remove.
38533         (vmaxaq_s8): Remove.
38534         (vminaq_s16): Remove.
38535         (vmaxaq_s16): Remove.
38536         (vminaq_s32): Remove.
38537         (vmaxaq_s32): Remove.
38538         (vminaq_m_s8): Remove.
38539         (vmaxaq_m_s8): Remove.
38540         (vminaq_m_s16): Remove.
38541         (vmaxaq_m_s16): Remove.
38542         (vminaq_m_s32): Remove.
38543         (vmaxaq_m_s32): Remove.
38544         (__arm_vminaq_s8): Remove.
38545         (__arm_vmaxaq_s8): Remove.
38546         (__arm_vminaq_s16): Remove.
38547         (__arm_vmaxaq_s16): Remove.
38548         (__arm_vminaq_s32): Remove.
38549         (__arm_vmaxaq_s32): Remove.
38550         (__arm_vminaq_m_s8): Remove.
38551         (__arm_vmaxaq_m_s8): Remove.
38552         (__arm_vminaq_m_s16): Remove.
38553         (__arm_vmaxaq_m_s16): Remove.
38554         (__arm_vminaq_m_s32): Remove.
38555         (__arm_vmaxaq_m_s32): Remove.
38556         (__arm_vminaq): Remove.
38557         (__arm_vmaxaq): Remove.
38558         (__arm_vminaq_m): Remove.
38559         (__arm_vmaxaq_m): Remove.
38561 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38563         * config/arm/iterators.md (MVE_VMAXAVMINAQ, MVE_VMAXAVMINAQ_M):
38564         New.
38565         (mve_insn): Add vmaxa, vmina.
38566         (supf): Add VMAXAQ_S, VMAXAQ_M_S, VMINAQ_S, VMINAQ_M_S.
38567         * config/arm/mve.md (mve_vmaxaq_s<mode>, mve_vminaq_s<mode>):
38568         Merge into ...
38569         (@mve_<mve_insn>q_<supf><mode>): ... this.
38570         (mve_vmaxaq_m_s<mode>, mve_vminaq_m_s<mode>): Merge into ...
38571         (@mve_<mve_insn>q_m_<supf><mode>): ... this.
38573 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38575         * config/arm/arm-mve-builtins-shapes.cc (binary_maxamina): New.
38576         * config/arm/arm-mve-builtins-shapes.h (binary_maxamina): New.
38578 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38580         * config/arm/arm-mve-builtins-base.cc (vmaxnmaq, vminnmaq): New.
38581         * config/arm/arm-mve-builtins-base.def (vmaxnmaq, vminnmaq): New.
38582         * config/arm/arm-mve-builtins-base.h (vmaxnmaq, vminnmaq): New.
38583         * config/arm/arm-mve-builtins.cc
38584         (function_instance::has_inactive_argument): Handle vmaxnmaq and
38585         vminnmaq.
38586         * config/arm/arm_mve.h (vminnmaq): Remove.
38587         (vmaxnmaq): Remove.
38588         (vmaxnmaq_m): Remove.
38589         (vminnmaq_m): Remove.
38590         (vminnmaq_f16): Remove.
38591         (vmaxnmaq_f16): Remove.
38592         (vminnmaq_f32): Remove.
38593         (vmaxnmaq_f32): Remove.
38594         (vmaxnmaq_m_f16): Remove.
38595         (vminnmaq_m_f16): Remove.
38596         (vmaxnmaq_m_f32): Remove.
38597         (vminnmaq_m_f32): Remove.
38598         (__arm_vminnmaq_f16): Remove.
38599         (__arm_vmaxnmaq_f16): Remove.
38600         (__arm_vminnmaq_f32): Remove.
38601         (__arm_vmaxnmaq_f32): Remove.
38602         (__arm_vmaxnmaq_m_f16): Remove.
38603         (__arm_vminnmaq_m_f16): Remove.
38604         (__arm_vmaxnmaq_m_f32): Remove.
38605         (__arm_vminnmaq_m_f32): Remove.
38606         (__arm_vminnmaq): Remove.
38607         (__arm_vmaxnmaq): Remove.
38608         (__arm_vmaxnmaq_m): Remove.
38609         (__arm_vminnmaq_m): Remove.
38611 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38613         * config/arm/iterators.md (MVE_VMAXNMA_VMINNMAQ)
38614         (MVE_VMAXNMA_VMINNMAQ_M): New.
38615         (mve_insn): Add vmaxnma, vminnma.
38616         * config/arm/mve.md (mve_vmaxnmaq_f<mode>, mve_vminnmaq_f<mode>):
38617         Merge into ...
38618         (@mve_<mve_insn>q_f<mode>): ... this.
38619         (mve_vmaxnmaq_m_f<mode>, mve_vminnmaq_m_f<mode>): Merge into ...
38620         (@mve_<mve_insn>q_m_f<mode>): ... this.
38622 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38624         * config/arm/arm-mve-builtins-base.cc (FUNCTION_PRED_P_F): New.
38625         (vmaxnmavq, vmaxnmvq, vminnmavq, vminnmvq): New.
38626         * config/arm/arm-mve-builtins-base.def (vmaxnmavq, vmaxnmvq)
38627         (vminnmavq, vminnmvq): New.
38628         * config/arm/arm-mve-builtins-base.h (vmaxnmavq, vmaxnmvq)
38629         (vminnmavq, vminnmvq): New.
38630         * config/arm/arm_mve.h (vminnmvq): Remove.
38631         (vminnmavq): Remove.
38632         (vmaxnmvq): Remove.
38633         (vmaxnmavq): Remove.
38634         (vmaxnmavq_p): Remove.
38635         (vmaxnmvq_p): Remove.
38636         (vminnmavq_p): Remove.
38637         (vminnmvq_p): Remove.
38638         (vminnmvq_f16): Remove.
38639         (vminnmavq_f16): Remove.
38640         (vmaxnmvq_f16): Remove.
38641         (vmaxnmavq_f16): Remove.
38642         (vminnmvq_f32): Remove.
38643         (vminnmavq_f32): Remove.
38644         (vmaxnmvq_f32): Remove.
38645         (vmaxnmavq_f32): Remove.
38646         (vmaxnmavq_p_f16): Remove.
38647         (vmaxnmvq_p_f16): Remove.
38648         (vminnmavq_p_f16): Remove.
38649         (vminnmvq_p_f16): Remove.
38650         (vmaxnmavq_p_f32): Remove.
38651         (vmaxnmvq_p_f32): Remove.
38652         (vminnmavq_p_f32): Remove.
38653         (vminnmvq_p_f32): Remove.
38654         (__arm_vminnmvq_f16): Remove.
38655         (__arm_vminnmavq_f16): Remove.
38656         (__arm_vmaxnmvq_f16): Remove.
38657         (__arm_vmaxnmavq_f16): Remove.
38658         (__arm_vminnmvq_f32): Remove.
38659         (__arm_vminnmavq_f32): Remove.
38660         (__arm_vmaxnmvq_f32): Remove.
38661         (__arm_vmaxnmavq_f32): Remove.
38662         (__arm_vmaxnmavq_p_f16): Remove.
38663         (__arm_vmaxnmvq_p_f16): Remove.
38664         (__arm_vminnmavq_p_f16): Remove.
38665         (__arm_vminnmvq_p_f16): Remove.
38666         (__arm_vmaxnmavq_p_f32): Remove.
38667         (__arm_vmaxnmvq_p_f32): Remove.
38668         (__arm_vminnmavq_p_f32): Remove.
38669         (__arm_vminnmvq_p_f32): Remove.
38670         (__arm_vminnmvq): Remove.
38671         (__arm_vminnmavq): Remove.
38672         (__arm_vmaxnmvq): Remove.
38673         (__arm_vmaxnmavq): Remove.
38674         (__arm_vmaxnmavq_p): Remove.
38675         (__arm_vmaxnmvq_p): Remove.
38676         (__arm_vminnmavq_p): Remove.
38677         (__arm_vminnmvq_p): Remove.
38678         (__arm_vmaxnmavq_m): Remove.
38679         (__arm_vmaxnmvq_m): Remove.
38681 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38683         * config/arm/arm-mve-builtins-functions.h
38684         (unspec_mve_function_exact_insn_pred_p): Use code_for_mve_q_p_f.
38686 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38688         * config/arm/iterators.md (MVE_VMAXNMxV_MINNMxVQ)
38689         (MVE_VMAXNMxV_MINNMxVQ_P): New.
38690         (mve_insn): Add vmaxnmav, vmaxnmv, vminnmav, vminnmv.
38691         * config/arm/mve.md (mve_vmaxnmavq_f<mode>, mve_vmaxnmvq_f<mode>)
38692         (mve_vminnmavq_f<mode>, mve_vminnmvq_f<mode>): Merge into ...
38693         (@mve_<mve_insn>q_f<mode>): ... this.
38694         (mve_vmaxnmavq_p_f<mode>, mve_vmaxnmvq_p_f<mode>)
38695         (mve_vminnmavq_p_f<mode>, mve_vminnmvq_p_f<mode>): Merge into ...
38696         (@mve_<mve_insn>q_p_f<mode>): ... this.
38698 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38700         * config/arm/arm-mve-builtins-base.cc (vmaxnmq, vminnmq): New.
38701         * config/arm/arm-mve-builtins-base.def (vmaxnmq, vminnmq): New.
38702         * config/arm/arm-mve-builtins-base.h (vmaxnmq, vminnmq): New.
38703         * config/arm/arm_mve.h (vminnmq): Remove.
38704         (vmaxnmq): Remove.
38705         (vmaxnmq_m): Remove.
38706         (vminnmq_m): Remove.
38707         (vminnmq_x): Remove.
38708         (vmaxnmq_x): Remove.
38709         (vminnmq_f16): Remove.
38710         (vmaxnmq_f16): Remove.
38711         (vminnmq_f32): Remove.
38712         (vmaxnmq_f32): Remove.
38713         (vmaxnmq_m_f32): Remove.
38714         (vmaxnmq_m_f16): Remove.
38715         (vminnmq_m_f32): Remove.
38716         (vminnmq_m_f16): Remove.
38717         (vminnmq_x_f16): Remove.
38718         (vminnmq_x_f32): Remove.
38719         (vmaxnmq_x_f16): Remove.
38720         (vmaxnmq_x_f32): Remove.
38721         (__arm_vminnmq_f16): Remove.
38722         (__arm_vmaxnmq_f16): Remove.
38723         (__arm_vminnmq_f32): Remove.
38724         (__arm_vmaxnmq_f32): Remove.
38725         (__arm_vmaxnmq_m_f32): Remove.
38726         (__arm_vmaxnmq_m_f16): Remove.
38727         (__arm_vminnmq_m_f32): Remove.
38728         (__arm_vminnmq_m_f16): Remove.
38729         (__arm_vminnmq_x_f16): Remove.
38730         (__arm_vminnmq_x_f32): Remove.
38731         (__arm_vmaxnmq_x_f16): Remove.
38732         (__arm_vmaxnmq_x_f32): Remove.
38733         (__arm_vminnmq): Remove.
38734         (__arm_vmaxnmq): Remove.
38735         (__arm_vmaxnmq_m): Remove.
38736         (__arm_vminnmq_m): Remove.
38737         (__arm_vminnmq_x): Remove.
38738         (__arm_vmaxnmq_x): Remove.
38740 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38742         * config/arm/iterators.md (MAX_MIN_F): New.
38743         (MVE_FP_M_BINARY): Add VMAXNMQ_M_F, VMINNMQ_M_F.
38744         (mve_insn): Add vmaxnm, vminnm.
38745         (max_min_f_str): New.
38746         * config/arm/mve.md (mve_vmaxnmq_f<mode>, mve_vminnmq_f<mode>):
38747         Merge into ...
38748         (@mve_<max_min_f_str>q_f<mode>): ... this.
38749         (mve_vmaxnmq_m_f<mode>, mve_vminnmq_m_f<mode>): Merge into ...
38750         (@mve_<mve_insn>q_m_f<mode>): ... this.
38752 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38754         * config/arm/vec-common.md (smin<mode>3): Use VDQWH iterator.
38755         (smax<mode>3): Likewise.
38757 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38759         * config/arm/arm-mve-builtins-base.cc (FUNCTION_PRED_P_S_U)
38760         (FUNCTION_PRED_P_S): New.
38761         (vmaxavq, vminavq, vmaxvq, vminvq): New.
38762         * config/arm/arm-mve-builtins-base.def (vmaxavq, vminavq, vmaxvq)
38763         (vminvq): New.
38764         * config/arm/arm-mve-builtins-base.h (vmaxavq, vminavq, vmaxvq)
38765         (vminvq): New.
38766         * config/arm/arm_mve.h (vminvq): Remove.
38767         (vmaxvq): Remove.
38768         (vminvq_p): Remove.
38769         (vmaxvq_p): Remove.
38770         (vminvq_u8): Remove.
38771         (vmaxvq_u8): Remove.
38772         (vminvq_s8): Remove.
38773         (vmaxvq_s8): Remove.
38774         (vminvq_u16): Remove.
38775         (vmaxvq_u16): Remove.
38776         (vminvq_s16): Remove.
38777         (vmaxvq_s16): Remove.
38778         (vminvq_u32): Remove.
38779         (vmaxvq_u32): Remove.
38780         (vminvq_s32): Remove.
38781         (vmaxvq_s32): Remove.
38782         (vminvq_p_u8): Remove.
38783         (vmaxvq_p_u8): Remove.
38784         (vminvq_p_s8): Remove.
38785         (vmaxvq_p_s8): Remove.
38786         (vminvq_p_u16): Remove.
38787         (vmaxvq_p_u16): Remove.
38788         (vminvq_p_s16): Remove.
38789         (vmaxvq_p_s16): Remove.
38790         (vminvq_p_u32): Remove.
38791         (vmaxvq_p_u32): Remove.
38792         (vminvq_p_s32): Remove.
38793         (vmaxvq_p_s32): Remove.
38794         (__arm_vminvq_u8): Remove.
38795         (__arm_vmaxvq_u8): Remove.
38796         (__arm_vminvq_s8): Remove.
38797         (__arm_vmaxvq_s8): Remove.
38798         (__arm_vminvq_u16): Remove.
38799         (__arm_vmaxvq_u16): Remove.
38800         (__arm_vminvq_s16): Remove.
38801         (__arm_vmaxvq_s16): Remove.
38802         (__arm_vminvq_u32): Remove.
38803         (__arm_vmaxvq_u32): Remove.
38804         (__arm_vminvq_s32): Remove.
38805         (__arm_vmaxvq_s32): Remove.
38806         (__arm_vminvq_p_u8): Remove.
38807         (__arm_vmaxvq_p_u8): Remove.
38808         (__arm_vminvq_p_s8): Remove.
38809         (__arm_vmaxvq_p_s8): Remove.
38810         (__arm_vminvq_p_u16): Remove.
38811         (__arm_vmaxvq_p_u16): Remove.
38812         (__arm_vminvq_p_s16): Remove.
38813         (__arm_vmaxvq_p_s16): Remove.
38814         (__arm_vminvq_p_u32): Remove.
38815         (__arm_vmaxvq_p_u32): Remove.
38816         (__arm_vminvq_p_s32): Remove.
38817         (__arm_vmaxvq_p_s32): Remove.
38818         (__arm_vminvq): Remove.
38819         (__arm_vmaxvq): Remove.
38820         (__arm_vminvq_p): Remove.
38821         (__arm_vmaxvq_p): Remove.
38822         (vminavq): Remove.
38823         (vmaxavq): Remove.
38824         (vminavq_p): Remove.
38825         (vmaxavq_p): Remove.
38826         (vminavq_s8): Remove.
38827         (vmaxavq_s8): Remove.
38828         (vminavq_s16): Remove.
38829         (vmaxavq_s16): Remove.
38830         (vminavq_s32): Remove.
38831         (vmaxavq_s32): Remove.
38832         (vminavq_p_s8): Remove.
38833         (vmaxavq_p_s8): Remove.
38834         (vminavq_p_s16): Remove.
38835         (vmaxavq_p_s16): Remove.
38836         (vminavq_p_s32): Remove.
38837         (vmaxavq_p_s32): Remove.
38838         (__arm_vminavq_s8): Remove.
38839         (__arm_vmaxavq_s8): Remove.
38840         (__arm_vminavq_s16): Remove.
38841         (__arm_vmaxavq_s16): Remove.
38842         (__arm_vminavq_s32): Remove.
38843         (__arm_vmaxavq_s32): Remove.
38844         (__arm_vminavq_p_s8): Remove.
38845         (__arm_vmaxavq_p_s8): Remove.
38846         (__arm_vminavq_p_s16): Remove.
38847         (__arm_vmaxavq_p_s16): Remove.
38848         (__arm_vminavq_p_s32): Remove.
38849         (__arm_vmaxavq_p_s32): Remove.
38850         (__arm_vminavq): Remove.
38851         (__arm_vmaxavq): Remove.
38852         (__arm_vminavq_p): Remove.
38853         (__arm_vmaxavq_p): Remove.
38855 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38857         * config/arm/iterators.md (MVE_VMAXVQ_VMINVQ, MVE_VMAXVQ_VMINVQ_P): New.
38858         (mve_insn): Add vmaxav, vmaxv, vminav, vminv.
38859         (supf): Add VMAXAVQ_S, VMAXAVQ_P_S, VMINAVQ_S, VMINAVQ_P_S.
38860         * config/arm/mve.md (mve_vmaxavq_s<mode>, mve_vmaxvq_<supf><mode>)
38861         (mve_vminavq_s<mode>, mve_vminvq_<supf><mode>): Merge into ...
38862         (@mve_<mve_insn>q_<supf><mode>): ... this.
38863         (mve_vmaxavq_p_s<mode>, mve_vmaxvq_p_<supf><mode>)
38864         (mve_vminavq_p_s<mode>, mve_vminvq_p_<supf><mode>): Merge into ...
38865         (@mve_<mve_insn>q_p_<supf><mode>): ... this.
38867 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38869         * config/arm/arm-mve-builtins-functions.h (class
38870         unspec_mve_function_exact_insn_pred_p): New.
38872 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38874         * config/arm/arm-mve-builtins-shapes.cc (binary_maxavminav): New.
38875         * config/arm/arm-mve-builtins-shapes.h (binary_maxavminav): New.
38877 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38879         * config/arm/arm-mve-builtins-shapes.cc (binary_maxvminv): New.
38880         * config/arm/arm-mve-builtins-shapes.h (binary_maxvminv): New.
38882 2023-05-09  Richard Sandiford  <richard.sandiford@arm.com>
38884         * config/aarch64/aarch64-protos.h (aarch64_adjust_reg_alloc_order):
38885         Declare.
38886         * config/aarch64/aarch64.h (REG_ALLOC_ORDER): Define.
38887         (ADJUST_REG_ALLOC_ORDER): Likewise.
38888         * config/aarch64/aarch64.cc (aarch64_adjust_reg_alloc_order): New
38889         function.
38890         * config/aarch64/aarch64-sve.md (*vcond_mask_<mode><vpred>): Use
38891         Upa rather than Upl for unpredicated movprfx alternatives.
38893 2023-05-09  Jeff Law  <jlaw@ventanamicro>
38895         * config/h8300/testcompare.md: Add peephole2 which uses a memory
38896         load to set flags, thus eliminating a compare against zero.
38898 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38900         * config/arm/arm-mve-builtins-base.cc (vshllbq, vshlltq): New.
38901         * config/arm/arm-mve-builtins-base.def (vshllbq, vshlltq): New.
38902         * config/arm/arm-mve-builtins-base.h (vshllbq, vshlltq): New.
38903         * config/arm/arm_mve.h (vshlltq): Remove.
38904         (vshllbq): Remove.
38905         (vshllbq_m): Remove.
38906         (vshlltq_m): Remove.
38907         (vshllbq_x): Remove.
38908         (vshlltq_x): Remove.
38909         (vshlltq_n_u8): Remove.
38910         (vshllbq_n_u8): Remove.
38911         (vshlltq_n_s8): Remove.
38912         (vshllbq_n_s8): Remove.
38913         (vshlltq_n_u16): Remove.
38914         (vshllbq_n_u16): Remove.
38915         (vshlltq_n_s16): Remove.
38916         (vshllbq_n_s16): Remove.
38917         (vshllbq_m_n_s8): Remove.
38918         (vshllbq_m_n_s16): Remove.
38919         (vshllbq_m_n_u8): Remove.
38920         (vshllbq_m_n_u16): Remove.
38921         (vshlltq_m_n_s8): Remove.
38922         (vshlltq_m_n_s16): Remove.
38923         (vshlltq_m_n_u8): Remove.
38924         (vshlltq_m_n_u16): Remove.
38925         (vshllbq_x_n_s8): Remove.
38926         (vshllbq_x_n_s16): Remove.
38927         (vshllbq_x_n_u8): Remove.
38928         (vshllbq_x_n_u16): Remove.
38929         (vshlltq_x_n_s8): Remove.
38930         (vshlltq_x_n_s16): Remove.
38931         (vshlltq_x_n_u8): Remove.
38932         (vshlltq_x_n_u16): Remove.
38933         (__arm_vshlltq_n_u8): Remove.
38934         (__arm_vshllbq_n_u8): Remove.
38935         (__arm_vshlltq_n_s8): Remove.
38936         (__arm_vshllbq_n_s8): Remove.
38937         (__arm_vshlltq_n_u16): Remove.
38938         (__arm_vshllbq_n_u16): Remove.
38939         (__arm_vshlltq_n_s16): Remove.
38940         (__arm_vshllbq_n_s16): Remove.
38941         (__arm_vshllbq_m_n_s8): Remove.
38942         (__arm_vshllbq_m_n_s16): Remove.
38943         (__arm_vshllbq_m_n_u8): Remove.
38944         (__arm_vshllbq_m_n_u16): Remove.
38945         (__arm_vshlltq_m_n_s8): Remove.
38946         (__arm_vshlltq_m_n_s16): Remove.
38947         (__arm_vshlltq_m_n_u8): Remove.
38948         (__arm_vshlltq_m_n_u16): Remove.
38949         (__arm_vshllbq_x_n_s8): Remove.
38950         (__arm_vshllbq_x_n_s16): Remove.
38951         (__arm_vshllbq_x_n_u8): Remove.
38952         (__arm_vshllbq_x_n_u16): Remove.
38953         (__arm_vshlltq_x_n_s8): Remove.
38954         (__arm_vshlltq_x_n_s16): Remove.
38955         (__arm_vshlltq_x_n_u8): Remove.
38956         (__arm_vshlltq_x_n_u16): Remove.
38957         (__arm_vshlltq): Remove.
38958         (__arm_vshllbq): Remove.
38959         (__arm_vshllbq_m): Remove.
38960         (__arm_vshlltq_m): Remove.
38961         (__arm_vshllbq_x): Remove.
38962         (__arm_vshlltq_x): Remove.
38964 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38966         * config/arm/iterators.md (mve_insn): Add vshllb, vshllt.
38967         (VSHLLBQ_N, VSHLLTQ_N): Remove.
38968         (VSHLLxQ_N): New.
38969         (VSHLLBQ_M_N, VSHLLTQ_M_N): Remove.
38970         (VSHLLxQ_M_N): New.
38971         * config/arm/mve.md (mve_vshllbq_n_<supf><mode>)
38972         (mve_vshlltq_n_<supf><mode>): Merge into ...
38973         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
38974         (mve_vshllbq_m_n_<supf><mode>, mve_vshlltq_m_n_<supf><mode>):
38975         Merge into ...
38976         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
38978 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38980         * config/arm/arm-mve-builtins-shapes.cc (binary_widen_n): New.
38981         * config/arm/arm-mve-builtins-shapes.h (binary_widen_n): New.
38983 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
38985         * config/arm/arm-mve-builtins-base.cc (vmovnbq, vmovntq, vqmovnbq)
38986         (vqmovntq, vqmovunbq, vqmovuntq): New.
38987         * config/arm/arm-mve-builtins-base.def (vmovnbq, vmovntq)
38988         (vqmovnbq, vqmovntq, vqmovunbq, vqmovuntq): New.
38989         * config/arm/arm-mve-builtins-base.h (vmovnbq, vmovntq, vqmovnbq)
38990         (vqmovntq, vqmovunbq, vqmovuntq): New.
38991         * config/arm/arm-mve-builtins.cc
38992         (function_instance::has_inactive_argument): Handle vmovnbq,
38993         vmovntq, vqmovnbq, vqmovntq, vqmovunbq, vqmovuntq.
38994         * config/arm/arm_mve.h (vqmovntq): Remove.
38995         (vqmovnbq): Remove.
38996         (vqmovnbq_m): Remove.
38997         (vqmovntq_m): Remove.
38998         (vqmovntq_u16): Remove.
38999         (vqmovnbq_u16): Remove.
39000         (vqmovntq_s16): Remove.
39001         (vqmovnbq_s16): Remove.
39002         (vqmovntq_u32): Remove.
39003         (vqmovnbq_u32): Remove.
39004         (vqmovntq_s32): Remove.
39005         (vqmovnbq_s32): Remove.
39006         (vqmovnbq_m_s16): Remove.
39007         (vqmovntq_m_s16): Remove.
39008         (vqmovnbq_m_u16): Remove.
39009         (vqmovntq_m_u16): Remove.
39010         (vqmovnbq_m_s32): Remove.
39011         (vqmovntq_m_s32): Remove.
39012         (vqmovnbq_m_u32): Remove.
39013         (vqmovntq_m_u32): Remove.
39014         (__arm_vqmovntq_u16): Remove.
39015         (__arm_vqmovnbq_u16): Remove.
39016         (__arm_vqmovntq_s16): Remove.
39017         (__arm_vqmovnbq_s16): Remove.
39018         (__arm_vqmovntq_u32): Remove.
39019         (__arm_vqmovnbq_u32): Remove.
39020         (__arm_vqmovntq_s32): Remove.
39021         (__arm_vqmovnbq_s32): Remove.
39022         (__arm_vqmovnbq_m_s16): Remove.
39023         (__arm_vqmovntq_m_s16): Remove.
39024         (__arm_vqmovnbq_m_u16): Remove.
39025         (__arm_vqmovntq_m_u16): Remove.
39026         (__arm_vqmovnbq_m_s32): Remove.
39027         (__arm_vqmovntq_m_s32): Remove.
39028         (__arm_vqmovnbq_m_u32): Remove.
39029         (__arm_vqmovntq_m_u32): Remove.
39030         (__arm_vqmovntq): Remove.
39031         (__arm_vqmovnbq): Remove.
39032         (__arm_vqmovnbq_m): Remove.
39033         (__arm_vqmovntq_m): Remove.
39034         (vmovntq): Remove.
39035         (vmovnbq): Remove.
39036         (vmovnbq_m): Remove.
39037         (vmovntq_m): Remove.
39038         (vmovntq_u16): Remove.
39039         (vmovnbq_u16): Remove.
39040         (vmovntq_s16): Remove.
39041         (vmovnbq_s16): Remove.
39042         (vmovntq_u32): Remove.
39043         (vmovnbq_u32): Remove.
39044         (vmovntq_s32): Remove.
39045         (vmovnbq_s32): Remove.
39046         (vmovnbq_m_s16): Remove.
39047         (vmovntq_m_s16): Remove.
39048         (vmovnbq_m_u16): Remove.
39049         (vmovntq_m_u16): Remove.
39050         (vmovnbq_m_s32): Remove.
39051         (vmovntq_m_s32): Remove.
39052         (vmovnbq_m_u32): Remove.
39053         (vmovntq_m_u32): Remove.
39054         (__arm_vmovntq_u16): Remove.
39055         (__arm_vmovnbq_u16): Remove.
39056         (__arm_vmovntq_s16): Remove.
39057         (__arm_vmovnbq_s16): Remove.
39058         (__arm_vmovntq_u32): Remove.
39059         (__arm_vmovnbq_u32): Remove.
39060         (__arm_vmovntq_s32): Remove.
39061         (__arm_vmovnbq_s32): Remove.
39062         (__arm_vmovnbq_m_s16): Remove.
39063         (__arm_vmovntq_m_s16): Remove.
39064         (__arm_vmovnbq_m_u16): Remove.
39065         (__arm_vmovntq_m_u16): Remove.
39066         (__arm_vmovnbq_m_s32): Remove.
39067         (__arm_vmovntq_m_s32): Remove.
39068         (__arm_vmovnbq_m_u32): Remove.
39069         (__arm_vmovntq_m_u32): Remove.
39070         (__arm_vmovntq): Remove.
39071         (__arm_vmovnbq): Remove.
39072         (__arm_vmovnbq_m): Remove.
39073         (__arm_vmovntq_m): Remove.
39074         (vqmovuntq): Remove.
39075         (vqmovunbq): Remove.
39076         (vqmovunbq_m): Remove.
39077         (vqmovuntq_m): Remove.
39078         (vqmovuntq_s16): Remove.
39079         (vqmovunbq_s16): Remove.
39080         (vqmovuntq_s32): Remove.
39081         (vqmovunbq_s32): Remove.
39082         (vqmovunbq_m_s16): Remove.
39083         (vqmovuntq_m_s16): Remove.
39084         (vqmovunbq_m_s32): Remove.
39085         (vqmovuntq_m_s32): Remove.
39086         (__arm_vqmovuntq_s16): Remove.
39087         (__arm_vqmovunbq_s16): Remove.
39088         (__arm_vqmovuntq_s32): Remove.
39089         (__arm_vqmovunbq_s32): Remove.
39090         (__arm_vqmovunbq_m_s16): Remove.
39091         (__arm_vqmovuntq_m_s16): Remove.
39092         (__arm_vqmovunbq_m_s32): Remove.
39093         (__arm_vqmovuntq_m_s32): Remove.
39094         (__arm_vqmovuntq): Remove.
39095         (__arm_vqmovunbq): Remove.
39096         (__arm_vqmovunbq_m): Remove.
39097         (__arm_vqmovuntq_m): Remove.
39099 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
39101         * config/arm/iterators.md (MVE_MOVN, MVE_MOVN_M): New.
39102         (mve_insn): Add vmovnb, vmovnt, vqmovnb, vqmovnt, vqmovunb,
39103         vqmovunt.
39104         (isu): Likewise.
39105         (supf): Add VQMOVUNBQ_M_S, VQMOVUNBQ_S, VQMOVUNTQ_M_S,
39106         VQMOVUNTQ_S.
39107         * config/arm/mve.md (mve_vmovnbq_<supf><mode>)
39108         (mve_vmovntq_<supf><mode>, mve_vqmovnbq_<supf><mode>)
39109         (mve_vqmovntq_<supf><mode>, mve_vqmovunbq_s<mode>)
39110         (mve_vqmovuntq_s<mode>): Merge into ...
39111         (@mve_<mve_insn>q_<supf><mode>): ... this.
39112         (mve_vmovnbq_m_<supf><mode>, mve_vmovntq_m_<supf><mode>)
39113         (mve_vqmovnbq_m_<supf><mode>, mve_vqmovntq_m_<supf><mode>)
39114         (mve_vqmovunbq_m_s<mode>, mve_vqmovuntq_m_s<mode>): Merge into ...
39115         (@mve_<mve_insn>q_m_<supf><mode>): ... this.
39117 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
39119         * config/arm/arm-mve-builtins-shapes.cc (binary_move_narrow): New.
39120         (binary_move_narrow_unsigned): New.
39121         * config/arm/arm-mve-builtins-shapes.h (binary_move_narrow): New.
39122         (binary_move_narrow_unsigned): New.
39124 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
39126         * config/arm/arm-mve-builtins-base.cc (FUNCTION_ONLY_F): New.
39127         (vrndaq, vrndmq, vrndnq, vrndpq, vrndq, vrndxq): New.
39128         * config/arm/arm-mve-builtins-base.def (vrndaq, vrndmq, vrndnq)
39129         (vrndpq, vrndq, vrndxq): New.
39130         * config/arm/arm-mve-builtins-base.h (vrndaq, vrndmq, vrndnq)
39131         (vrndpq, vrndq, vrndxq): New.
39132         * config/arm/arm_mve.h (vrndxq): Remove.
39133         (vrndq): Remove.
39134         (vrndpq): Remove.
39135         (vrndnq): Remove.
39136         (vrndmq): Remove.
39137         (vrndaq): Remove.
39138         (vrndaq_m): Remove.
39139         (vrndmq_m): Remove.
39140         (vrndnq_m): Remove.
39141         (vrndpq_m): Remove.
39142         (vrndq_m): Remove.
39143         (vrndxq_m): Remove.
39144         (vrndq_x): Remove.
39145         (vrndnq_x): Remove.
39146         (vrndmq_x): Remove.
39147         (vrndpq_x): Remove.
39148         (vrndaq_x): Remove.
39149         (vrndxq_x): Remove.
39150         (vrndxq_f16): Remove.
39151         (vrndxq_f32): Remove.
39152         (vrndq_f16): Remove.
39153         (vrndq_f32): Remove.
39154         (vrndpq_f16): Remove.
39155         (vrndpq_f32): Remove.
39156         (vrndnq_f16): Remove.
39157         (vrndnq_f32): Remove.
39158         (vrndmq_f16): Remove.
39159         (vrndmq_f32): Remove.
39160         (vrndaq_f16): Remove.
39161         (vrndaq_f32): Remove.
39162         (vrndaq_m_f16): Remove.
39163         (vrndmq_m_f16): Remove.
39164         (vrndnq_m_f16): Remove.
39165         (vrndpq_m_f16): Remove.
39166         (vrndq_m_f16): Remove.
39167         (vrndxq_m_f16): Remove.
39168         (vrndaq_m_f32): Remove.
39169         (vrndmq_m_f32): Remove.
39170         (vrndnq_m_f32): Remove.
39171         (vrndpq_m_f32): Remove.
39172         (vrndq_m_f32): Remove.
39173         (vrndxq_m_f32): Remove.
39174         (vrndq_x_f16): Remove.
39175         (vrndq_x_f32): Remove.
39176         (vrndnq_x_f16): Remove.
39177         (vrndnq_x_f32): Remove.
39178         (vrndmq_x_f16): Remove.
39179         (vrndmq_x_f32): Remove.
39180         (vrndpq_x_f16): Remove.
39181         (vrndpq_x_f32): Remove.
39182         (vrndaq_x_f16): Remove.
39183         (vrndaq_x_f32): Remove.
39184         (vrndxq_x_f16): Remove.
39185         (vrndxq_x_f32): Remove.
39186         (__arm_vrndxq_f16): Remove.
39187         (__arm_vrndxq_f32): Remove.
39188         (__arm_vrndq_f16): Remove.
39189         (__arm_vrndq_f32): Remove.
39190         (__arm_vrndpq_f16): Remove.
39191         (__arm_vrndpq_f32): Remove.
39192         (__arm_vrndnq_f16): Remove.
39193         (__arm_vrndnq_f32): Remove.
39194         (__arm_vrndmq_f16): Remove.
39195         (__arm_vrndmq_f32): Remove.
39196         (__arm_vrndaq_f16): Remove.
39197         (__arm_vrndaq_f32): Remove.
39198         (__arm_vrndaq_m_f16): Remove.
39199         (__arm_vrndmq_m_f16): Remove.
39200         (__arm_vrndnq_m_f16): Remove.
39201         (__arm_vrndpq_m_f16): Remove.
39202         (__arm_vrndq_m_f16): Remove.
39203         (__arm_vrndxq_m_f16): Remove.
39204         (__arm_vrndaq_m_f32): Remove.
39205         (__arm_vrndmq_m_f32): Remove.
39206         (__arm_vrndnq_m_f32): Remove.
39207         (__arm_vrndpq_m_f32): Remove.
39208         (__arm_vrndq_m_f32): Remove.
39209         (__arm_vrndxq_m_f32): Remove.
39210         (__arm_vrndq_x_f16): Remove.
39211         (__arm_vrndq_x_f32): Remove.
39212         (__arm_vrndnq_x_f16): Remove.
39213         (__arm_vrndnq_x_f32): Remove.
39214         (__arm_vrndmq_x_f16): Remove.
39215         (__arm_vrndmq_x_f32): Remove.
39216         (__arm_vrndpq_x_f16): Remove.
39217         (__arm_vrndpq_x_f32): Remove.
39218         (__arm_vrndaq_x_f16): Remove.
39219         (__arm_vrndaq_x_f32): Remove.
39220         (__arm_vrndxq_x_f16): Remove.
39221         (__arm_vrndxq_x_f32): Remove.
39222         (__arm_vrndxq): Remove.
39223         (__arm_vrndq): Remove.
39224         (__arm_vrndpq): Remove.
39225         (__arm_vrndnq): Remove.
39226         (__arm_vrndmq): Remove.
39227         (__arm_vrndaq): Remove.
39228         (__arm_vrndaq_m): Remove.
39229         (__arm_vrndmq_m): Remove.
39230         (__arm_vrndnq_m): Remove.
39231         (__arm_vrndpq_m): Remove.
39232         (__arm_vrndq_m): Remove.
39233         (__arm_vrndxq_m): Remove.
39234         (__arm_vrndq_x): Remove.
39235         (__arm_vrndnq_x): Remove.
39236         (__arm_vrndmq_x): Remove.
39237         (__arm_vrndpq_x): Remove.
39238         (__arm_vrndaq_x): Remove.
39239         (__arm_vrndxq_x): Remove.
39241 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
39243         * config/arm/arm-mve-builtins-base.cc (FUNCTION_WITHOUT_N_NO_U_F): New.
39244         (vabsq, vnegq, vclsq, vclzq, vqabsq, vqnegq): New.
39245         * config/arm/arm-mve-builtins-base.def (vabsq, vnegq, vclsq)
39246         (vclzq, vqabsq, vqnegq): New.
39247         * config/arm/arm-mve-builtins-base.h (vabsq, vnegq, vclsq, vclzq)
39248         (vqabsq, vqnegq): New.
39249         * config/arm/arm_mve.h (vabsq): Remove.
39250         (vabsq_m): Remove.
39251         (vabsq_x): Remove.
39252         (vabsq_f16): Remove.
39253         (vabsq_f32): Remove.
39254         (vabsq_s8): Remove.
39255         (vabsq_s16): Remove.
39256         (vabsq_s32): Remove.
39257         (vabsq_m_s8): Remove.
39258         (vabsq_m_s16): Remove.
39259         (vabsq_m_s32): Remove.
39260         (vabsq_m_f16): Remove.
39261         (vabsq_m_f32): Remove.
39262         (vabsq_x_s8): Remove.
39263         (vabsq_x_s16): Remove.
39264         (vabsq_x_s32): Remove.
39265         (vabsq_x_f16): Remove.
39266         (vabsq_x_f32): Remove.
39267         (__arm_vabsq_s8): Remove.
39268         (__arm_vabsq_s16): Remove.
39269         (__arm_vabsq_s32): Remove.
39270         (__arm_vabsq_m_s8): Remove.
39271         (__arm_vabsq_m_s16): Remove.
39272         (__arm_vabsq_m_s32): Remove.
39273         (__arm_vabsq_x_s8): Remove.
39274         (__arm_vabsq_x_s16): Remove.
39275         (__arm_vabsq_x_s32): Remove.
39276         (__arm_vabsq_f16): Remove.
39277         (__arm_vabsq_f32): Remove.
39278         (__arm_vabsq_m_f16): Remove.
39279         (__arm_vabsq_m_f32): Remove.
39280         (__arm_vabsq_x_f16): Remove.
39281         (__arm_vabsq_x_f32): Remove.
39282         (__arm_vabsq): Remove.
39283         (__arm_vabsq_m): Remove.
39284         (__arm_vabsq_x): Remove.
39285         (vnegq): Remove.
39286         (vnegq_m): Remove.
39287         (vnegq_x): Remove.
39288         (vnegq_f16): Remove.
39289         (vnegq_f32): Remove.
39290         (vnegq_s8): Remove.
39291         (vnegq_s16): Remove.
39292         (vnegq_s32): Remove.
39293         (vnegq_m_s8): Remove.
39294         (vnegq_m_s16): Remove.
39295         (vnegq_m_s32): Remove.
39296         (vnegq_m_f16): Remove.
39297         (vnegq_m_f32): Remove.
39298         (vnegq_x_s8): Remove.
39299         (vnegq_x_s16): Remove.
39300         (vnegq_x_s32): Remove.
39301         (vnegq_x_f16): Remove.
39302         (vnegq_x_f32): Remove.
39303         (__arm_vnegq_s8): Remove.
39304         (__arm_vnegq_s16): Remove.
39305         (__arm_vnegq_s32): Remove.
39306         (__arm_vnegq_m_s8): Remove.
39307         (__arm_vnegq_m_s16): Remove.
39308         (__arm_vnegq_m_s32): Remove.
39309         (__arm_vnegq_x_s8): Remove.
39310         (__arm_vnegq_x_s16): Remove.
39311         (__arm_vnegq_x_s32): Remove.
39312         (__arm_vnegq_f16): Remove.
39313         (__arm_vnegq_f32): Remove.
39314         (__arm_vnegq_m_f16): Remove.
39315         (__arm_vnegq_m_f32): Remove.
39316         (__arm_vnegq_x_f16): Remove.
39317         (__arm_vnegq_x_f32): Remove.
39318         (__arm_vnegq): Remove.
39319         (__arm_vnegq_m): Remove.
39320         (__arm_vnegq_x): Remove.
39321         (vclsq): Remove.
39322         (vclsq_m): Remove.
39323         (vclsq_x): Remove.
39324         (vclsq_s8): Remove.
39325         (vclsq_s16): Remove.
39326         (vclsq_s32): Remove.
39327         (vclsq_m_s8): Remove.
39328         (vclsq_m_s16): Remove.
39329         (vclsq_m_s32): Remove.
39330         (vclsq_x_s8): Remove.
39331         (vclsq_x_s16): Remove.
39332         (vclsq_x_s32): Remove.
39333         (__arm_vclsq_s8): Remove.
39334         (__arm_vclsq_s16): Remove.
39335         (__arm_vclsq_s32): Remove.
39336         (__arm_vclsq_m_s8): Remove.
39337         (__arm_vclsq_m_s16): Remove.
39338         (__arm_vclsq_m_s32): Remove.
39339         (__arm_vclsq_x_s8): Remove.
39340         (__arm_vclsq_x_s16): Remove.
39341         (__arm_vclsq_x_s32): Remove.
39342         (__arm_vclsq): Remove.
39343         (__arm_vclsq_m): Remove.
39344         (__arm_vclsq_x): Remove.
39345         (vclzq): Remove.
39346         (vclzq_m): Remove.
39347         (vclzq_x): Remove.
39348         (vclzq_s8): Remove.
39349         (vclzq_s16): Remove.
39350         (vclzq_s32): Remove.
39351         (vclzq_u8): Remove.
39352         (vclzq_u16): Remove.
39353         (vclzq_u32): Remove.
39354         (vclzq_m_u8): Remove.
39355         (vclzq_m_s8): Remove.
39356         (vclzq_m_u16): Remove.
39357         (vclzq_m_s16): Remove.
39358         (vclzq_m_u32): Remove.
39359         (vclzq_m_s32): Remove.
39360         (vclzq_x_s8): Remove.
39361         (vclzq_x_s16): Remove.
39362         (vclzq_x_s32): Remove.
39363         (vclzq_x_u8): Remove.
39364         (vclzq_x_u16): Remove.
39365         (vclzq_x_u32): Remove.
39366         (__arm_vclzq_s8): Remove.
39367         (__arm_vclzq_s16): Remove.
39368         (__arm_vclzq_s32): Remove.
39369         (__arm_vclzq_u8): Remove.
39370         (__arm_vclzq_u16): Remove.
39371         (__arm_vclzq_u32): Remove.
39372         (__arm_vclzq_m_u8): Remove.
39373         (__arm_vclzq_m_s8): Remove.
39374         (__arm_vclzq_m_u16): Remove.
39375         (__arm_vclzq_m_s16): Remove.
39376         (__arm_vclzq_m_u32): Remove.
39377         (__arm_vclzq_m_s32): Remove.
39378         (__arm_vclzq_x_s8): Remove.
39379         (__arm_vclzq_x_s16): Remove.
39380         (__arm_vclzq_x_s32): Remove.
39381         (__arm_vclzq_x_u8): Remove.
39382         (__arm_vclzq_x_u16): Remove.
39383         (__arm_vclzq_x_u32): Remove.
39384         (__arm_vclzq): Remove.
39385         (__arm_vclzq_m): Remove.
39386         (__arm_vclzq_x): Remove.
39387         (vqabsq): Remove.
39388         (vqnegq): Remove.
39389         (vqnegq_m): Remove.
39390         (vqabsq_m): Remove.
39391         (vqabsq_s8): Remove.
39392         (vqabsq_s16): Remove.
39393         (vqabsq_s32): Remove.
39394         (vqnegq_s8): Remove.
39395         (vqnegq_s16): Remove.
39396         (vqnegq_s32): Remove.
39397         (vqnegq_m_s8): Remove.
39398         (vqabsq_m_s8): Remove.
39399         (vqnegq_m_s16): Remove.
39400         (vqabsq_m_s16): Remove.
39401         (vqnegq_m_s32): Remove.
39402         (vqabsq_m_s32): Remove.
39403         (__arm_vqabsq_s8): Remove.
39404         (__arm_vqabsq_s16): Remove.
39405         (__arm_vqabsq_s32): Remove.
39406         (__arm_vqnegq_s8): Remove.
39407         (__arm_vqnegq_s16): Remove.
39408         (__arm_vqnegq_s32): Remove.
39409         (__arm_vqnegq_m_s8): Remove.
39410         (__arm_vqabsq_m_s8): Remove.
39411         (__arm_vqnegq_m_s16): Remove.
39412         (__arm_vqabsq_m_s16): Remove.
39413         (__arm_vqnegq_m_s32): Remove.
39414         (__arm_vqabsq_m_s32): Remove.
39415         (__arm_vqabsq): Remove.
39416         (__arm_vqnegq): Remove.
39417         (__arm_vqnegq_m): Remove.
39418         (__arm_vqabsq_m): Remove.
39420 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
39422         * config/arm/iterators.md (MVE_INT_M_UNARY, MVE_INT_UNARY)
39423         (MVE_FP_UNARY, MVE_FP_M_UNARY): New.
39424         (mve_insn): Add vabs, vcls, vclz, vneg, vqabs, vqneg, vrnda,
39425         vrndm, vrndn, vrndp, vrnd, vrndx.
39426         (isu): Add VABSQ_M_S, VCLSQ_M_S, VCLZQ_M_S, VCLZQ_M_U, VNEGQ_M_S,
39427         VQABSQ_M_S, VQNEGQ_M_S.
39428         (mve_mnemo): New.
39429         * config/arm/mve.md (mve_vrndq_m_f<mode>, mve_vrndxq_f<mode>)
39430         (mve_vrndq_f<mode>, mve_vrndpq_f<mode>, mve_vrndnq_f<mode>)
39431         (mve_vrndmq_f<mode>, mve_vrndaq_f<mode>): Merge into ...
39432         (@mve_<mve_insn>q_f<mode>): ... this.
39433         (mve_vnegq_f<mode>, mve_vabsq_f<mode>): Merge into ...
39434         (mve_v<absneg_str>q_f<mode>): ... this.
39435         (mve_vnegq_s<mode>, mve_vabsq_s<mode>): Merge into ...
39436         (mve_v<absneg_str>q_s<mode>): ... this.
39437         (mve_vclsq_s<mode>, mve_vqnegq_s<mode>, mve_vqabsq_s<mode>): Merge into ...
39438         (@mve_<mve_insn>q_<supf><mode>): ... this.
39439         (mve_vabsq_m_s<mode>, mve_vclsq_m_s<mode>)
39440         (mve_vclzq_m_<supf><mode>, mve_vnegq_m_s<mode>)
39441         (mve_vqabsq_m_s<mode>, mve_vqnegq_m_s<mode>): Merge into ...
39442         (@mve_<mve_insn>q_m_<supf><mode>): ... this.
39443         (mve_vabsq_m_f<mode>, mve_vnegq_m_f<mode>, mve_vrndaq_m_f<mode>)
39444         (mve_vrndmq_m_f<mode>, mve_vrndnq_m_f<mode>, mve_vrndpq_m_f<mode>)
39445         (mve_vrndxq_m_f<mode>): Merge into ...
39446         (@mve_<mve_insn>q_m_f<mode>): ... this.
39448 2023-05-09  Christophe Lyon  <christophe.lyon@arm.com>
39450         * config/arm/arm-mve-builtins-shapes.cc (unary): New.
39451         * config/arm/arm-mve-builtins-shapes.h (unary): New.
39453 2023-05-09  Jakub Jelinek  <jakub@redhat.com>
39455         * mux-utils.h: Fix comment typo, avoides -> avoids.
39457 2023-05-09  Jakub Jelinek  <jakub@redhat.com>
39459         PR tree-optimization/109778
39460         * wide-int.h (wi::lrotate, wi::rrotate): Call wi::lrshift on
39461         wi::zext (x, width) rather than x if width != precision, rather
39462         than using wi::zext (right, width) after the shift.
39463         * tree-ssa-ccp.cc (bit_value_binop): Call wi::ext on the results
39464         of wi::lrotate or wi::rrotate.
39466 2023-05-09  Alexander Monakov  <amonakov@ispras.ru>
39468         * genmatch.cc (get_out_file): Make static and rename to ...
39469         (choose_output): ... this. Reimplement. Update all uses ...
39470         (decision_tree::gen): ... here and ...
39471         (main): ... here.
39473 2023-05-09  Alexander Monakov  <amonakov@ispras.ru>
39475         * genmatch.cc (showUsage): Reimplement as ...
39476         (usage): ...this.  Adjust all uses.
39477         (main): Print usage when no arguments.  Add missing 'return 1'.
39479 2023-05-09  Alexander Monakov  <amonakov@ispras.ru>
39481         * genmatch.cc (header_file): Make static.
39482         (emit_func): Rename to...
39483         (fp_decl): ... this.  Adjust all uses.
39484         (fp_decl_done): New function.  Use it...
39485         (decision_tree::gen): ... here and...
39486         (write_predicate): ... here.
39487         (main): Adjust.
39489 2023-05-09  Richard Sandiford  <richard.sandiford@arm.com>
39491         * ira-conflicts.cc (can_use_same_reg_p): Skip over non-matching
39492         earlyclobbers.
39494 2023-05-08  Roger Sayle  <roger@nextmovesoftware.com>
39495             Uros Bizjak  <ubizjak@gmail.com>
39497         * config/i386/i386.md (any_or_plus): Move definition earlier.
39498         (*insvti_highpart_1): New define_insn_and_split to overwrite
39499         (insv) the highpart of a TImode register/memory.
39501 2023-05-08  Eugene Rozenfeld  <erozen@microsoft.com>
39503         * auto-profile.cc (auto_profile): Check todo from early_inline
39504         to see if cleanup_tree_vfg needs to be called.
39505         (early_inline): Return todo from early_inliner.
39507 2023-05-08  Kito Cheng  <kito.cheng@sifive.com>
39509         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::get_vector_info):
39510         New.
39511         (pass_vsetvl::get_block_info): New.
39512         (pass_vsetvl::update_vector_info): New.
39513         (pass_vsetvl::simple_vsetvl): Use get_vector_info.
39514         (pass_vsetvl::compute_local_backward_infos): Ditto.
39515         (pass_vsetvl::transfer_before): Ditto.
39516         (pass_vsetvl::transfer_after): Ditto.
39517         (pass_vsetvl::emit_local_forward_vsetvls): Ditto.
39518         (pass_vsetvl::local_eliminate_vsetvl_insn): Ditto.
39519         (pass_vsetvl::cleanup_insns): Ditto.
39520         (pass_vsetvl::compute_local_backward_infos): Use
39521         update_vector_info.
39523 2023-05-08  Jeff Law  <jlaw@ventanamicro>
39525         * config/stormy16/stormy16.md (zero_extendhisi2): Fix length.
39527 2023-05-08  Richard Biener  <rguenther@suse.de>
39528             Michael Meissner  <meissner@linux.ibm.com>
39530         PR middle-end/108623
39531         * tree-core.h (tree_type_common): Bump up precision field to 16 bits.
39532         Align bit fields > 1 bit to at least an 8-bit boundary.
39534 2023-05-08  Andrew Pinski  <apinski@marvell.com>
39536         PR tree-optimization/109424
39537         PR tree-optimization/59424
39538         * tree-ssa-phiopt.cc (factor_out_conditional_conversion): Rename to ...
39539         (factor_out_conditional_operation): This and add support for all unary
39540         operations.
39541         (pass_phiopt::execute): Update call to factor_out_conditional_conversion
39542         to call factor_out_conditional_operation instead.
39544 2023-05-08  Andrew Pinski  <apinski@marvell.com>
39546         * tree-ssa-phiopt.cc (pass_phiopt::execute): Loop
39547         over factor_out_conditional_conversion.
39549 2023-05-08  Andrew Pinski  <apinski@marvell.com>
39551         PR tree-optimization/49959
39552         PR tree-optimization/103771
39553         * tree-ssa-phiopt.cc (pass_phiopt::execute): Support
39554         Diamond shapped bb form for factor_out_conditional_conversion.
39556 2023-05-08  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
39558         * config/riscv/autovec.md (movmisalign<mode>): New pattern.
39559         * config/riscv/riscv-protos.h (riscv_vector_mask_mode_p): Delete.
39560         (riscv_vector_get_mask_mode): Ditto.
39561         (get_mask_policy_no_pred): Ditto.
39562         (get_tail_policy_no_pred): Ditto.
39563         (get_mask_mode): New function.
39564         * config/riscv/riscv-v.cc (get_mask_policy_no_pred): Delete.
39565         (get_tail_policy_no_pred): Ditto.
39566         (riscv_vector_mask_mode_p): Ditto.
39567         (riscv_vector_get_mask_mode): Ditto.
39568         (get_mask_mode): New function.
39569         * config/riscv/riscv-vector-builtins.cc (use_real_merge_p): Remove
39570         global extern.
39571         (get_tail_policy_for_pred): Ditto.
39572         * config/riscv/riscv-vector-builtins.h (get_tail_policy_for_pred): Ditto.
39573         (get_mask_policy_for_pred): Ditto
39574         * config/riscv/riscv.cc (riscv_get_mask_mode): Refine codes.
39576 2023-05-08  Kito Cheng  <kito.cheng@sifive.com>
39578         * common/config/riscv/riscv-common.cc (riscv_select_multilib_by_abi): New.
39579         (riscv_select_multilib): New.
39580         (riscv_compute_multilib): Extract logic to riscv_select_multilib and
39581         also handle select_by_abi.
39582         * config/riscv/elf.h (RISCV_USE_CUSTOMISED_MULTI_LIB): Change it
39583         to select_by_abi_arch_cmodel from 1.
39584         * config/riscv/linux.h (RISCV_USE_CUSTOMISED_MULTI_LIB): Define.
39585         * config/riscv/riscv-opts.h (enum riscv_multilib_select_kind): New.
39587 2023-05-08  Alexander Monakov  <amonakov@ispras.ru>
39589         * Makefile.in: (gimple-match-head.o-warn): Remove.
39590         (GIMPLE_MATCH_PD_SEQ_SRC): Do not depend on
39591         gimple-match-exports.cc.
39592         (gimple-match-auto.h): Only depend on s-gimple-match.
39593         (generic-match-auto.h): Likewise.
39595 2023-05-08  Andrew Pinski  <apinski@marvell.com>
39597         PR tree-optimization/109691
39598         * tree-ssa-dce.cc (simple_dce_from_worklist): Add need_eh_cleanup
39599         argument.
39600         If the removed statement can throw, have need_eh_cleanup
39601         include the bb of that statement.
39602         * tree-ssa-dce.h (simple_dce_from_worklist): Update declaration.
39603         * tree-ssa-propagate.cc (struct prop_stats_d): Remove
39604         num_dce.
39605         (substitute_and_fold_dom_walker::substitute_and_fold_dom_walker):
39606         Initialize dceworklist instead of stmts_to_remove.
39607         (substitute_and_fold_dom_walker::~substitute_and_fold_dom_walker):
39608         Destore dceworklist instead of stmts_to_remove.
39609         (substitute_and_fold_dom_walker::before_dom_children):
39610         Set dceworklist instead of adding to stmts_to_remove.
39611         (substitute_and_fold_engine::substitute_and_fold):
39612         Call simple_dce_from_worklist instead of poping
39613         from the list.
39614         Don't update the stat on removal statements.
39616 2023-05-07  Andrew Pinski  <apinski@marvell.com>
39618         PR target/109762
39619         * config/aarch64/aarch64-builtins.cc (aarch64_simd_switcher::aarch64_simd_switcher):
39620         Change argument type to aarch64_feature_flags.
39621         * config/aarch64/aarch64-protos.h (aarch64_simd_switcher): Change
39622         constructor argument type to aarch64_feature_flags.
39623         Change m_old_asm_isa_flags to be aarch64_feature_flags.
39625 2023-05-07  Jiufu Guo  <guojiufu@linux.ibm.com>
39627         * config/rs6000/rs6000.cc (rs6000_emit_set_long_const): Generate
39628         more parallel code if can_create_pseudo_p.
39630 2023-05-07  Roger Sayle  <roger@nextmovesoftware.com>
39632         PR target/43644
39633         * lower-subreg.cc (resolve_simple_move): Don't emit a clobber
39634         immediately before moving a multi-word register by parts.
39636 2023-05-06  Jeff Law  <jlaw@ventanamicro>
39638         * config/riscv/riscv-v.cc (riscv_vector_preferred_simd_mode): Delete.
39640 2023-05-06  Michael Collison  <collison@rivosinc.com>
39642         * tree-vect-slp.cc (can_duplicate_and_interleave_p):
39643         Check that GET_MODE_NUNITS is a multiple of 2.
39645 2023-05-06  Michael Collison  <collison@rivosinc.com>
39647         * config/riscv/riscv.cc
39648         (riscv_estimated_poly_value): Implement
39649         TARGET_ESTIMATED_POLY_VALUE.
39650         (riscv_preferred_simd_mode): Implement
39651         TARGET_VECTORIZE_PREFERRED_SIMD_MODE.
39652         (riscv_get_mask_mode): Implement TARGET_VECTORIZE_GET_MASK_MODE.
39653         (riscv_empty_mask_is_expensive): Implement
39654         TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE.
39655         (riscv_vectorize_create_costs): Implement
39656         TARGET_VECTORIZE_CREATE_COSTS.
39657         (riscv_support_vector_misalignment): Implement
39658         TARGET_VECTORIZE_SUPPORT_VECTOR_MISALIGNMENT.
39659         (TARGET_ESTIMATED_POLY_VALUE): Register target macro.
39660         (TARGET_VECTORIZE_GET_MASK_MODE): Ditto.
39661         (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Ditto.
39662         (TARGET_VECTORIZE_SUPPORT_VECTOR_MISALIGNMENT): Ditto.
39664 2023-05-06  Jeff Law  <jlaw@ventanamicro>
39666         * config/riscv/riscv-v.cc (autovec_use_vlmax_p): Remove
39667         duplicate definition.
39669 2023-05-06  Michael Collison  <collison@rivosinc.com>
39671         * config/riscv/riscv-v.cc (autovec_use_vlmax_p): New function.
39672         (riscv_vector_preferred_simd_mode): Ditto.
39673         (get_mask_policy_no_pred): Ditto.
39674         (get_tail_policy_no_pred): Ditto.
39675         (riscv_vector_mask_mode_p): Ditto.
39676         (riscv_vector_get_mask_mode): Ditto.
39678 2023-05-06  Michael Collison  <collison@rivosinc.com>
39680         * config/riscv/riscv-vector-builtins.cc (get_tail_policy_for_pred):
39681         Remove static declaration to to make externally visible.
39682         (get_mask_policy_for_pred): Ditto.
39683         * config/riscv/riscv-vector-builtins.h (get_tail_policy_for_pred):
39684         New external declaration.
39685         (get_mask_policy_for_pred): Ditto.
39687 2023-05-06  Michael Collison  <collison@rivosinc.com>
39689         * config/riscv/riscv-protos.h (riscv_vector_mask_mode_p): New.
39690         (riscv_vector_get_mask_mode): Ditto.
39691         (get_mask_policy_no_pred): Ditto.
39692         (get_tail_policy_no_pred): Ditto.
39694 2023-05-06  Xi Ruoyao  <xry111@xry111.site>
39696         * config/loongarch/loongarch.h (struct machine_function): Add
39697         reg_is_wrapped_separately array for register wrapping
39698         information.
39699         * config/loongarch/loongarch.cc
39700         (loongarch_get_separate_components): New function.
39701         (loongarch_components_for_bb): Likewise.
39702         (loongarch_disqualify_components): Likewise.
39703         (loongarch_process_components): Likewise.
39704         (loongarch_emit_prologue_components): Likewise.
39705         (loongarch_emit_epilogue_components): Likewise.
39706         (loongarch_set_handled_components): Likewise.
39707         (TARGET_SHRINK_WRAP_GET_SEPARATE_COMPONENTS): Define.
39708         (TARGET_SHRINK_WRAP_COMPONENTS_FOR_BB): Likewise.
39709         (TARGET_SHRINK_WRAP_DISQUALIFY_COMPONENTS): Likewise.
39710         (TARGET_SHRINK_WRAP_EMIT_PROLOGUE_COMPONENTS): Likewise.
39711         (TARGET_SHRINK_WRAP_EMIT_EPILOGUE_COMPONENTS): Likewise.
39712         (TARGET_SHRINK_WRAP_SET_HANDLED_COMPONENTS): Likewise.
39713         (loongarch_for_each_saved_reg): Skip registers that are wrapped
39714         separately.
39716 2023-05-06  Xi Ruoyao  <xry111@xry111.site>
39718         PR other/109522
39719         * Makefile.in (s-macro_list): Pass -nostdinc to
39720         $(GCC_FOR_TARGET).
39722 2023-05-06  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
39724         * config/riscv/riscv-protos.h (preferred_simd_mode): New function.
39725         * config/riscv/riscv-v.cc (autovec_use_vlmax_p): Ditto.
39726         (preferred_simd_mode): Ditto.
39727         * config/riscv/riscv.cc (riscv_get_arg_info): Handle RVV type in function arg.
39728         (riscv_convert_vector_bits): Adjust for RVV auto-vectorization.
39729         (riscv_preferred_simd_mode): New function.
39730         (TARGET_VECTORIZE_PREFERRED_SIMD_MODE): New target hook support.
39731         * config/riscv/vector.md: Add autovec.md.
39732         * config/riscv/autovec.md: New file.
39734 2023-05-06  Jakub Jelinek  <jakub@redhat.com>
39736         * real.h (dconst_pi): Define.
39737         (dconst_e_ptr): Formatting fix.
39738         (dconst_pi_ptr): Declare.
39739         * real.cc (dconst_pi_ptr): New function.
39740         * gimple-range-op.cc (cfn_sincos::fold_range): Intersect the generic
39741         boundaries range with range computed from sin/cos of the particular
39742         bounds if the argument range is shorter than 2*pi.
39743         (cfn_sincos::op1_range): Take bulps into account when determining
39744         which result ranges are always invalid or behave like known NAN.
39746 2023-05-06  Aldy Hernandez  <aldyh@redhat.com>
39748         * gimple-range-cache.cc (sbr_sparse_bitmap::set_bb_range): Do not
39749         pass type to vrange_storage::equal_p.
39750         * value-range-storage.cc (vrange_storage::equal_p): Remove type.
39751         (irange_storage::equal_p): Same.
39752         (frange_storage::equal_p): Same.
39753         * value-range-storage.h (class frange_storage): Same.
39755 2023-05-06  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
39757         PR target/109748
39758         * config/riscv/riscv-vsetvl.cc (local_eliminate_vsetvl_insn): Remove it.
39759         (pass_vsetvl::local_eliminate_vsetvl_insn): New function.
39761 2023-05-06  liuhongt  <hongtao.liu@intel.com>
39763         * combine.cc (maybe_swap_commutative_operands): Canonicalize
39764         vec_merge when mask is constant.
39765         * doc/md.texi: Document vec_merge canonicalization.
39767 2023-05-06  Jakub Jelinek  <jakub@redhat.com>
39769         * value-range.h (frange_arithmetic): Declare.
39770         * range-op-float.cc (frange_arithmetic): No longer static.
39771         * gimple-range-op.cc (frange_mpfr_arg1): New function.
39772         (cfn_sqrt::fold_range): Intersect the generic boundaries range
39773         with range computed from sqrt of the particular bounds.
39774         (cfn_sqrt::op1_range): Intersect the generic boundaries range
39775         with range computed from squared particular bounds.
39777 2023-05-06  Jakub Jelinek  <jakub@redhat.com>
39779         * Makefile.in (check_p_numbers): Rename to one_to_9999, move
39780         earlier with helper variables also renamed.
39781         (MATCH_SPLUT_SEQ): Use $(wordlist 1,$(NUM_MATCH_SPLITS),$(one_to_9999))
39782         instead of $(shell seq 1 $(NUM_MATCH_SPLITS)).
39783         (check_p_subdirs): Use $(one_to_9999) instead of $(check_p_numbers).
39785 2023-05-06  Hans-Peter Nilsson  <hp@axis.com>
39787         * config/cris/cris.md (splitop): Add PLUS.
39788         * config/cris/cris.cc (cris_split_constant): Also handle
39789         PLUS when a split into two insns may be useful.
39791 2023-05-05  Hans-Peter Nilsson  <hp@axis.com>
39793         * config/cris/cris.md (movandsplit1): New define_peephole2.
39795 2023-05-05  Hans-Peter Nilsson  <hp@axis.com>
39797         * config/cris/cris.md (lsrandsplit1): New define_peephole2.
39799 2023-05-05  Hans-Peter Nilsson  <hp@axis.com>
39801         * doc/md.texi (define_peephole2): Document order of scanning.
39803 2023-05-05  Pan Li  <pan2.li@intel.com>
39804             Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
39806         * config/riscv/vector.md: Allow const as the operand of RVV
39807         indexed load/store.
39809 2023-05-05  Pan Li  <pan2.li@intel.com>
39811         * config/riscv/riscv.h (VECTOR_STORE_FLAG_VALUE): Add new macro
39812         consumed by simplify_rtx.
39814 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
39816         * config/arm/arm-mve-builtins-base.cc (vrshrq, vshrq): New.
39817         * config/arm/arm-mve-builtins-base.def (vrshrq, vshrq): New.
39818         * config/arm/arm-mve-builtins-base.h (vrshrq, vshrq): New.
39819         * config/arm/arm_mve.h (vshrq): Remove.
39820         (vrshrq): Remove.
39821         (vrshrq_m): Remove.
39822         (vshrq_m): Remove.
39823         (vrshrq_x): Remove.
39824         (vshrq_x): Remove.
39825         (vshrq_n_s8): Remove.
39826         (vshrq_n_s16): Remove.
39827         (vshrq_n_s32): Remove.
39828         (vshrq_n_u8): Remove.
39829         (vshrq_n_u16): Remove.
39830         (vshrq_n_u32): Remove.
39831         (vrshrq_n_u8): Remove.
39832         (vrshrq_n_s8): Remove.
39833         (vrshrq_n_u16): Remove.
39834         (vrshrq_n_s16): Remove.
39835         (vrshrq_n_u32): Remove.
39836         (vrshrq_n_s32): Remove.
39837         (vrshrq_m_n_s8): Remove.
39838         (vrshrq_m_n_s32): Remove.
39839         (vrshrq_m_n_s16): Remove.
39840         (vrshrq_m_n_u8): Remove.
39841         (vrshrq_m_n_u32): Remove.
39842         (vrshrq_m_n_u16): Remove.
39843         (vshrq_m_n_s8): Remove.
39844         (vshrq_m_n_s32): Remove.
39845         (vshrq_m_n_s16): Remove.
39846         (vshrq_m_n_u8): Remove.
39847         (vshrq_m_n_u32): Remove.
39848         (vshrq_m_n_u16): Remove.
39849         (vrshrq_x_n_s8): Remove.
39850         (vrshrq_x_n_s16): Remove.
39851         (vrshrq_x_n_s32): Remove.
39852         (vrshrq_x_n_u8): Remove.
39853         (vrshrq_x_n_u16): Remove.
39854         (vrshrq_x_n_u32): Remove.
39855         (vshrq_x_n_s8): Remove.
39856         (vshrq_x_n_s16): Remove.
39857         (vshrq_x_n_s32): Remove.
39858         (vshrq_x_n_u8): Remove.
39859         (vshrq_x_n_u16): Remove.
39860         (vshrq_x_n_u32): Remove.
39861         (__arm_vshrq_n_s8): Remove.
39862         (__arm_vshrq_n_s16): Remove.
39863         (__arm_vshrq_n_s32): Remove.
39864         (__arm_vshrq_n_u8): Remove.
39865         (__arm_vshrq_n_u16): Remove.
39866         (__arm_vshrq_n_u32): Remove.
39867         (__arm_vrshrq_n_u8): Remove.
39868         (__arm_vrshrq_n_s8): Remove.
39869         (__arm_vrshrq_n_u16): Remove.
39870         (__arm_vrshrq_n_s16): Remove.
39871         (__arm_vrshrq_n_u32): Remove.
39872         (__arm_vrshrq_n_s32): Remove.
39873         (__arm_vrshrq_m_n_s8): Remove.
39874         (__arm_vrshrq_m_n_s32): Remove.
39875         (__arm_vrshrq_m_n_s16): Remove.
39876         (__arm_vrshrq_m_n_u8): Remove.
39877         (__arm_vrshrq_m_n_u32): Remove.
39878         (__arm_vrshrq_m_n_u16): Remove.
39879         (__arm_vshrq_m_n_s8): Remove.
39880         (__arm_vshrq_m_n_s32): Remove.
39881         (__arm_vshrq_m_n_s16): Remove.
39882         (__arm_vshrq_m_n_u8): Remove.
39883         (__arm_vshrq_m_n_u32): Remove.
39884         (__arm_vshrq_m_n_u16): Remove.
39885         (__arm_vrshrq_x_n_s8): Remove.
39886         (__arm_vrshrq_x_n_s16): Remove.
39887         (__arm_vrshrq_x_n_s32): Remove.
39888         (__arm_vrshrq_x_n_u8): Remove.
39889         (__arm_vrshrq_x_n_u16): Remove.
39890         (__arm_vrshrq_x_n_u32): Remove.
39891         (__arm_vshrq_x_n_s8): Remove.
39892         (__arm_vshrq_x_n_s16): Remove.
39893         (__arm_vshrq_x_n_s32): Remove.
39894         (__arm_vshrq_x_n_u8): Remove.
39895         (__arm_vshrq_x_n_u16): Remove.
39896         (__arm_vshrq_x_n_u32): Remove.
39897         (__arm_vshrq): Remove.
39898         (__arm_vrshrq): Remove.
39899         (__arm_vrshrq_m): Remove.
39900         (__arm_vshrq_m): Remove.
39901         (__arm_vrshrq_x): Remove.
39902         (__arm_vshrq_x): Remove.
39904 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
39906         * config/arm/iterators.md (MVE_VSHRQ_M_N, MVE_VSHRQ_N): New.
39907         (mve_insn): Add vrshr, vshr.
39908         * config/arm/mve.md (mve_vshrq_n_<supf><mode>)
39909         (mve_vrshrq_n_<supf><mode>): Merge into ...
39910         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
39911         (mve_vrshrq_m_n_<supf><mode>, mve_vshrq_m_n_<supf><mode>): Merge
39912         into ...
39913         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
39915 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
39917         * config/arm/arm-mve-builtins-shapes.cc (binary_rshift): New.
39918         * config/arm/arm-mve-builtins-shapes.h (binary_rshift): New.
39920 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
39922         * config/arm/arm-mve-builtins-base.cc (FUNCTION_ONLY_N_NO_U_F): New.
39923         (vqshrunbq, vqshruntq, vqrshrunbq, vqrshruntq): New.
39924         * config/arm/arm-mve-builtins-base.def (vqshrunbq, vqshruntq)
39925         (vqrshrunbq, vqrshruntq): New.
39926         * config/arm/arm-mve-builtins-base.h (vqshrunbq, vqshruntq)
39927         (vqrshrunbq, vqrshruntq): New.
39928         * config/arm/arm-mve-builtins.cc
39929         (function_instance::has_inactive_argument): Handle vqshrunbq,
39930         vqshruntq, vqrshrunbq, vqrshruntq.
39931         * config/arm/arm_mve.h (vqrshrunbq): Remove.
39932         (vqrshruntq): Remove.
39933         (vqrshrunbq_m): Remove.
39934         (vqrshruntq_m): Remove.
39935         (vqrshrunbq_n_s16): Remove.
39936         (vqrshrunbq_n_s32): Remove.
39937         (vqrshruntq_n_s16): Remove.
39938         (vqrshruntq_n_s32): Remove.
39939         (vqrshrunbq_m_n_s32): Remove.
39940         (vqrshrunbq_m_n_s16): Remove.
39941         (vqrshruntq_m_n_s32): Remove.
39942         (vqrshruntq_m_n_s16): Remove.
39943         (__arm_vqrshrunbq_n_s16): Remove.
39944         (__arm_vqrshrunbq_n_s32): Remove.
39945         (__arm_vqrshruntq_n_s16): Remove.
39946         (__arm_vqrshruntq_n_s32): Remove.
39947         (__arm_vqrshrunbq_m_n_s32): Remove.
39948         (__arm_vqrshrunbq_m_n_s16): Remove.
39949         (__arm_vqrshruntq_m_n_s32): Remove.
39950         (__arm_vqrshruntq_m_n_s16): Remove.
39951         (__arm_vqrshrunbq): Remove.
39952         (__arm_vqrshruntq): Remove.
39953         (__arm_vqrshrunbq_m): Remove.
39954         (__arm_vqrshruntq_m): Remove.
39955         (vqshrunbq): Remove.
39956         (vqshruntq): Remove.
39957         (vqshrunbq_m): Remove.
39958         (vqshruntq_m): Remove.
39959         (vqshrunbq_n_s16): Remove.
39960         (vqshruntq_n_s16): Remove.
39961         (vqshrunbq_n_s32): Remove.
39962         (vqshruntq_n_s32): Remove.
39963         (vqshrunbq_m_n_s32): Remove.
39964         (vqshrunbq_m_n_s16): Remove.
39965         (vqshruntq_m_n_s32): Remove.
39966         (vqshruntq_m_n_s16): Remove.
39967         (__arm_vqshrunbq_n_s16): Remove.
39968         (__arm_vqshruntq_n_s16): Remove.
39969         (__arm_vqshrunbq_n_s32): Remove.
39970         (__arm_vqshruntq_n_s32): Remove.
39971         (__arm_vqshrunbq_m_n_s32): Remove.
39972         (__arm_vqshrunbq_m_n_s16): Remove.
39973         (__arm_vqshruntq_m_n_s32): Remove.
39974         (__arm_vqshruntq_m_n_s16): Remove.
39975         (__arm_vqshrunbq): Remove.
39976         (__arm_vqshruntq): Remove.
39977         (__arm_vqshrunbq_m): Remove.
39978         (__arm_vqshruntq_m): Remove.
39980 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
39982         * config/arm/iterators.md (MVE_SHRN_N): Add VQRSHRUNBQ,
39983         VQRSHRUNTQ, VQSHRUNBQ, VQSHRUNTQ.
39984         (MVE_SHRN_M_N): Likewise.
39985         (mve_insn): Add vqrshrunb, vqrshrunt, vqshrunb, vqshrunt.
39986         (isu): Add VQRSHRUNBQ, VQRSHRUNTQ, VQSHRUNBQ, VQSHRUNTQ.
39987         (supf): Likewise.
39988         * config/arm/mve.md (mve_vqrshrunbq_n_s<mode>): Remove.
39989         (mve_vqrshruntq_n_s<mode>): Remove.
39990         (mve_vqshrunbq_n_s<mode>): Remove.
39991         (mve_vqshruntq_n_s<mode>): Remove.
39992         (mve_vqrshrunbq_m_n_s<mode>): Remove.
39993         (mve_vqrshruntq_m_n_s<mode>): Remove.
39994         (mve_vqshrunbq_m_n_s<mode>): Remove.
39995         (mve_vqshruntq_m_n_s<mode>): Remove.
39997 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
39999         * config/arm/arm-mve-builtins-shapes.cc
40000         (binary_rshift_narrow_unsigned): New.
40001         * config/arm/arm-mve-builtins-shapes.h
40002         (binary_rshift_narrow_unsigned): New.
40004 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40006         * config/arm/arm-mve-builtins-base.cc (FUNCTION_ONLY_N_NO_F): New.
40007         (vshrnbq, vshrntq, vrshrnbq, vrshrntq, vqshrnbq, vqshrntq)
40008         (vqrshrnbq, vqrshrntq): New.
40009         * config/arm/arm-mve-builtins-base.def (vshrnbq, vshrntq)
40010         (vrshrnbq, vrshrntq, vqshrnbq, vqshrntq, vqrshrnbq, vqrshrntq):
40011         New.
40012         * config/arm/arm-mve-builtins-base.h (vshrnbq, vshrntq, vrshrnbq)
40013         (vrshrntq, vqshrnbq, vqshrntq, vqrshrnbq, vqrshrntq): New.
40014         * config/arm/arm-mve-builtins.cc
40015         (function_instance::has_inactive_argument): Handle vshrnbq,
40016         vshrntq, vrshrnbq, vrshrntq, vqshrnbq, vqshrntq, vqrshrnbq,
40017         vqrshrntq.
40018         * config/arm/arm_mve.h (vshrnbq): Remove.
40019         (vshrntq): Remove.
40020         (vshrnbq_m): Remove.
40021         (vshrntq_m): Remove.
40022         (vshrnbq_n_s16): Remove.
40023         (vshrntq_n_s16): Remove.
40024         (vshrnbq_n_u16): Remove.
40025         (vshrntq_n_u16): Remove.
40026         (vshrnbq_n_s32): Remove.
40027         (vshrntq_n_s32): Remove.
40028         (vshrnbq_n_u32): Remove.
40029         (vshrntq_n_u32): Remove.
40030         (vshrnbq_m_n_s32): Remove.
40031         (vshrnbq_m_n_s16): Remove.
40032         (vshrnbq_m_n_u32): Remove.
40033         (vshrnbq_m_n_u16): Remove.
40034         (vshrntq_m_n_s32): Remove.
40035         (vshrntq_m_n_s16): Remove.
40036         (vshrntq_m_n_u32): Remove.
40037         (vshrntq_m_n_u16): Remove.
40038         (__arm_vshrnbq_n_s16): Remove.
40039         (__arm_vshrntq_n_s16): Remove.
40040         (__arm_vshrnbq_n_u16): Remove.
40041         (__arm_vshrntq_n_u16): Remove.
40042         (__arm_vshrnbq_n_s32): Remove.
40043         (__arm_vshrntq_n_s32): Remove.
40044         (__arm_vshrnbq_n_u32): Remove.
40045         (__arm_vshrntq_n_u32): Remove.
40046         (__arm_vshrnbq_m_n_s32): Remove.
40047         (__arm_vshrnbq_m_n_s16): Remove.
40048         (__arm_vshrnbq_m_n_u32): Remove.
40049         (__arm_vshrnbq_m_n_u16): Remove.
40050         (__arm_vshrntq_m_n_s32): Remove.
40051         (__arm_vshrntq_m_n_s16): Remove.
40052         (__arm_vshrntq_m_n_u32): Remove.
40053         (__arm_vshrntq_m_n_u16): Remove.
40054         (__arm_vshrnbq): Remove.
40055         (__arm_vshrntq): Remove.
40056         (__arm_vshrnbq_m): Remove.
40057         (__arm_vshrntq_m): Remove.
40058         (vrshrnbq): Remove.
40059         (vrshrntq): Remove.
40060         (vrshrnbq_m): Remove.
40061         (vrshrntq_m): Remove.
40062         (vrshrnbq_n_s16): Remove.
40063         (vrshrntq_n_s16): Remove.
40064         (vrshrnbq_n_u16): Remove.
40065         (vrshrntq_n_u16): Remove.
40066         (vrshrnbq_n_s32): Remove.
40067         (vrshrntq_n_s32): Remove.
40068         (vrshrnbq_n_u32): Remove.
40069         (vrshrntq_n_u32): Remove.
40070         (vrshrnbq_m_n_s32): Remove.
40071         (vrshrnbq_m_n_s16): Remove.
40072         (vrshrnbq_m_n_u32): Remove.
40073         (vrshrnbq_m_n_u16): Remove.
40074         (vrshrntq_m_n_s32): Remove.
40075         (vrshrntq_m_n_s16): Remove.
40076         (vrshrntq_m_n_u32): Remove.
40077         (vrshrntq_m_n_u16): Remove.
40078         (__arm_vrshrnbq_n_s16): Remove.
40079         (__arm_vrshrntq_n_s16): Remove.
40080         (__arm_vrshrnbq_n_u16): Remove.
40081         (__arm_vrshrntq_n_u16): Remove.
40082         (__arm_vrshrnbq_n_s32): Remove.
40083         (__arm_vrshrntq_n_s32): Remove.
40084         (__arm_vrshrnbq_n_u32): Remove.
40085         (__arm_vrshrntq_n_u32): Remove.
40086         (__arm_vrshrnbq_m_n_s32): Remove.
40087         (__arm_vrshrnbq_m_n_s16): Remove.
40088         (__arm_vrshrnbq_m_n_u32): Remove.
40089         (__arm_vrshrnbq_m_n_u16): Remove.
40090         (__arm_vrshrntq_m_n_s32): Remove.
40091         (__arm_vrshrntq_m_n_s16): Remove.
40092         (__arm_vrshrntq_m_n_u32): Remove.
40093         (__arm_vrshrntq_m_n_u16): Remove.
40094         (__arm_vrshrnbq): Remove.
40095         (__arm_vrshrntq): Remove.
40096         (__arm_vrshrnbq_m): Remove.
40097         (__arm_vrshrntq_m): Remove.
40098         (vqshrnbq): Remove.
40099         (vqshrntq): Remove.
40100         (vqshrnbq_m): Remove.
40101         (vqshrntq_m): Remove.
40102         (vqshrnbq_n_s16): Remove.
40103         (vqshrntq_n_s16): Remove.
40104         (vqshrnbq_n_u16): Remove.
40105         (vqshrntq_n_u16): Remove.
40106         (vqshrnbq_n_s32): Remove.
40107         (vqshrntq_n_s32): Remove.
40108         (vqshrnbq_n_u32): Remove.
40109         (vqshrntq_n_u32): Remove.
40110         (vqshrnbq_m_n_s32): Remove.
40111         (vqshrnbq_m_n_s16): Remove.
40112         (vqshrnbq_m_n_u32): Remove.
40113         (vqshrnbq_m_n_u16): Remove.
40114         (vqshrntq_m_n_s32): Remove.
40115         (vqshrntq_m_n_s16): Remove.
40116         (vqshrntq_m_n_u32): Remove.
40117         (vqshrntq_m_n_u16): Remove.
40118         (__arm_vqshrnbq_n_s16): Remove.
40119         (__arm_vqshrntq_n_s16): Remove.
40120         (__arm_vqshrnbq_n_u16): Remove.
40121         (__arm_vqshrntq_n_u16): Remove.
40122         (__arm_vqshrnbq_n_s32): Remove.
40123         (__arm_vqshrntq_n_s32): Remove.
40124         (__arm_vqshrnbq_n_u32): Remove.
40125         (__arm_vqshrntq_n_u32): Remove.
40126         (__arm_vqshrnbq_m_n_s32): Remove.
40127         (__arm_vqshrnbq_m_n_s16): Remove.
40128         (__arm_vqshrnbq_m_n_u32): Remove.
40129         (__arm_vqshrnbq_m_n_u16): Remove.
40130         (__arm_vqshrntq_m_n_s32): Remove.
40131         (__arm_vqshrntq_m_n_s16): Remove.
40132         (__arm_vqshrntq_m_n_u32): Remove.
40133         (__arm_vqshrntq_m_n_u16): Remove.
40134         (__arm_vqshrnbq): Remove.
40135         (__arm_vqshrntq): Remove.
40136         (__arm_vqshrnbq_m): Remove.
40137         (__arm_vqshrntq_m): Remove.
40138         (vqrshrnbq): Remove.
40139         (vqrshrntq): Remove.
40140         (vqrshrnbq_m): Remove.
40141         (vqrshrntq_m): Remove.
40142         (vqrshrnbq_n_s16): Remove.
40143         (vqrshrnbq_n_u16): Remove.
40144         (vqrshrnbq_n_s32): Remove.
40145         (vqrshrnbq_n_u32): Remove.
40146         (vqrshrntq_n_s16): Remove.
40147         (vqrshrntq_n_u16): Remove.
40148         (vqrshrntq_n_s32): Remove.
40149         (vqrshrntq_n_u32): Remove.
40150         (vqrshrnbq_m_n_s32): Remove.
40151         (vqrshrnbq_m_n_s16): Remove.
40152         (vqrshrnbq_m_n_u32): Remove.
40153         (vqrshrnbq_m_n_u16): Remove.
40154         (vqrshrntq_m_n_s32): Remove.
40155         (vqrshrntq_m_n_s16): Remove.
40156         (vqrshrntq_m_n_u32): Remove.
40157         (vqrshrntq_m_n_u16): Remove.
40158         (__arm_vqrshrnbq_n_s16): Remove.
40159         (__arm_vqrshrnbq_n_u16): Remove.
40160         (__arm_vqrshrnbq_n_s32): Remove.
40161         (__arm_vqrshrnbq_n_u32): Remove.
40162         (__arm_vqrshrntq_n_s16): Remove.
40163         (__arm_vqrshrntq_n_u16): Remove.
40164         (__arm_vqrshrntq_n_s32): Remove.
40165         (__arm_vqrshrntq_n_u32): Remove.
40166         (__arm_vqrshrnbq_m_n_s32): Remove.
40167         (__arm_vqrshrnbq_m_n_s16): Remove.
40168         (__arm_vqrshrnbq_m_n_u32): Remove.
40169         (__arm_vqrshrnbq_m_n_u16): Remove.
40170         (__arm_vqrshrntq_m_n_s32): Remove.
40171         (__arm_vqrshrntq_m_n_s16): Remove.
40172         (__arm_vqrshrntq_m_n_u32): Remove.
40173         (__arm_vqrshrntq_m_n_u16): Remove.
40174         (__arm_vqrshrnbq): Remove.
40175         (__arm_vqrshrntq): Remove.
40176         (__arm_vqrshrnbq_m): Remove.
40177         (__arm_vqrshrntq_m): Remove.
40179 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40181         * config/arm/iterators.md (MVE_SHRN_N, MVE_SHRN_M_N): New.
40182         (mve_insn): Add vqrshrnb, vqrshrnt, vqshrnb, vqshrnt, vrshrnb,
40183         vrshrnt, vshrnb, vshrnt.
40184         (isu): New.
40185         * config/arm/mve.md (mve_vqrshrnbq_n_<supf><mode>)
40186         (mve_vqrshrntq_n_<supf><mode>, mve_vqshrnbq_n_<supf><mode>)
40187         (mve_vqshrntq_n_<supf><mode>, mve_vrshrnbq_n_<supf><mode>)
40188         (mve_vrshrntq_n_<supf><mode>, mve_vshrnbq_n_<supf><mode>)
40189         (mve_vshrntq_n_<supf><mode>): Merge into ...
40190         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
40191         (mve_vqrshrnbq_m_n_<supf><mode>, mve_vqrshrntq_m_n_<supf><mode>)
40192         (mve_vqshrnbq_m_n_<supf><mode>, mve_vqshrntq_m_n_<supf><mode>)
40193         (mve_vrshrnbq_m_n_<supf><mode>, mve_vrshrntq_m_n_<supf><mode>)
40194         (mve_vshrnbq_m_n_<supf><mode>, mve_vshrntq_m_n_<supf><mode>):
40195         Merge into ...
40196         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
40198 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40200         * config/arm/arm-mve-builtins-shapes.cc (binary_rshift_narrow):
40201         New.
40202         * config/arm/arm-mve-builtins-shapes.h (binary_rshift_narrow): New.
40204 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40206         * config/arm/arm-mve-builtins-base.cc (FUNCTION_WITH_RTX_M_NO_F): New.
40207         (vmaxq, vminq): New.
40208         * config/arm/arm-mve-builtins-base.def (vmaxq, vminq): New.
40209         * config/arm/arm-mve-builtins-base.h (vmaxq, vminq): New.
40210         * config/arm/arm_mve.h (vminq): Remove.
40211         (vmaxq): Remove.
40212         (vmaxq_m): Remove.
40213         (vminq_m): Remove.
40214         (vminq_x): Remove.
40215         (vmaxq_x): Remove.
40216         (vminq_u8): Remove.
40217         (vmaxq_u8): Remove.
40218         (vminq_s8): Remove.
40219         (vmaxq_s8): Remove.
40220         (vminq_u16): Remove.
40221         (vmaxq_u16): Remove.
40222         (vminq_s16): Remove.
40223         (vmaxq_s16): Remove.
40224         (vminq_u32): Remove.
40225         (vmaxq_u32): Remove.
40226         (vminq_s32): Remove.
40227         (vmaxq_s32): Remove.
40228         (vmaxq_m_s8): Remove.
40229         (vmaxq_m_s32): Remove.
40230         (vmaxq_m_s16): Remove.
40231         (vmaxq_m_u8): Remove.
40232         (vmaxq_m_u32): Remove.
40233         (vmaxq_m_u16): Remove.
40234         (vminq_m_s8): Remove.
40235         (vminq_m_s32): Remove.
40236         (vminq_m_s16): Remove.
40237         (vminq_m_u8): Remove.
40238         (vminq_m_u32): Remove.
40239         (vminq_m_u16): Remove.
40240         (vminq_x_s8): Remove.
40241         (vminq_x_s16): Remove.
40242         (vminq_x_s32): Remove.
40243         (vminq_x_u8): Remove.
40244         (vminq_x_u16): Remove.
40245         (vminq_x_u32): Remove.
40246         (vmaxq_x_s8): Remove.
40247         (vmaxq_x_s16): Remove.
40248         (vmaxq_x_s32): Remove.
40249         (vmaxq_x_u8): Remove.
40250         (vmaxq_x_u16): Remove.
40251         (vmaxq_x_u32): Remove.
40252         (__arm_vminq_u8): Remove.
40253         (__arm_vmaxq_u8): Remove.
40254         (__arm_vminq_s8): Remove.
40255         (__arm_vmaxq_s8): Remove.
40256         (__arm_vminq_u16): Remove.
40257         (__arm_vmaxq_u16): Remove.
40258         (__arm_vminq_s16): Remove.
40259         (__arm_vmaxq_s16): Remove.
40260         (__arm_vminq_u32): Remove.
40261         (__arm_vmaxq_u32): Remove.
40262         (__arm_vminq_s32): Remove.
40263         (__arm_vmaxq_s32): Remove.
40264         (__arm_vmaxq_m_s8): Remove.
40265         (__arm_vmaxq_m_s32): Remove.
40266         (__arm_vmaxq_m_s16): Remove.
40267         (__arm_vmaxq_m_u8): Remove.
40268         (__arm_vmaxq_m_u32): Remove.
40269         (__arm_vmaxq_m_u16): Remove.
40270         (__arm_vminq_m_s8): Remove.
40271         (__arm_vminq_m_s32): Remove.
40272         (__arm_vminq_m_s16): Remove.
40273         (__arm_vminq_m_u8): Remove.
40274         (__arm_vminq_m_u32): Remove.
40275         (__arm_vminq_m_u16): Remove.
40276         (__arm_vminq_x_s8): Remove.
40277         (__arm_vminq_x_s16): Remove.
40278         (__arm_vminq_x_s32): Remove.
40279         (__arm_vminq_x_u8): Remove.
40280         (__arm_vminq_x_u16): Remove.
40281         (__arm_vminq_x_u32): Remove.
40282         (__arm_vmaxq_x_s8): Remove.
40283         (__arm_vmaxq_x_s16): Remove.
40284         (__arm_vmaxq_x_s32): Remove.
40285         (__arm_vmaxq_x_u8): Remove.
40286         (__arm_vmaxq_x_u16): Remove.
40287         (__arm_vmaxq_x_u32): Remove.
40288         (__arm_vminq): Remove.
40289         (__arm_vmaxq): Remove.
40290         (__arm_vmaxq_m): Remove.
40291         (__arm_vminq_m): Remove.
40292         (__arm_vminq_x): Remove.
40293         (__arm_vmaxq_x): Remove.
40295 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40297         * config/arm/iterators.md (MAX_MIN_SU): New.
40298         (max_min_su_str): New.
40299         (max_min_supf): New.
40300         * config/arm/mve.md (mve_vmaxq_s<mode>, mve_vmaxq_u<mode>)
40301         (mve_vminq_s<mode>, mve_vminq_u<mode>): Merge into ...
40302         (mve_<max_min_su_str>q_<max_min_supf><mode>): ... this.
40304 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40306         * config/arm/arm-mve-builtins-base.cc (FUNCTION_WITH_M_N_R): New.
40307         (vqshlq, vshlq): New.
40308         * config/arm/arm-mve-builtins-base.def (vqshlq, vshlq): New.
40309         * config/arm/arm-mve-builtins-base.h (vqshlq, vshlq): New.
40310         * config/arm/arm_mve.h (vshlq): Remove.
40311         (vshlq_r): Remove.
40312         (vshlq_n): Remove.
40313         (vshlq_m_r): Remove.
40314         (vshlq_m): Remove.
40315         (vshlq_m_n): Remove.
40316         (vshlq_x): Remove.
40317         (vshlq_x_n): Remove.
40318         (vshlq_s8): Remove.
40319         (vshlq_s16): Remove.
40320         (vshlq_s32): Remove.
40321         (vshlq_u8): Remove.
40322         (vshlq_u16): Remove.
40323         (vshlq_u32): Remove.
40324         (vshlq_r_u8): Remove.
40325         (vshlq_n_u8): Remove.
40326         (vshlq_r_s8): Remove.
40327         (vshlq_n_s8): Remove.
40328         (vshlq_r_u16): Remove.
40329         (vshlq_n_u16): Remove.
40330         (vshlq_r_s16): Remove.
40331         (vshlq_n_s16): Remove.
40332         (vshlq_r_u32): Remove.
40333         (vshlq_n_u32): Remove.
40334         (vshlq_r_s32): Remove.
40335         (vshlq_n_s32): Remove.
40336         (vshlq_m_r_u8): Remove.
40337         (vshlq_m_r_s8): Remove.
40338         (vshlq_m_r_u16): Remove.
40339         (vshlq_m_r_s16): Remove.
40340         (vshlq_m_r_u32): Remove.
40341         (vshlq_m_r_s32): Remove.
40342         (vshlq_m_u8): Remove.
40343         (vshlq_m_s8): Remove.
40344         (vshlq_m_u16): Remove.
40345         (vshlq_m_s16): Remove.
40346         (vshlq_m_u32): Remove.
40347         (vshlq_m_s32): Remove.
40348         (vshlq_m_n_s8): Remove.
40349         (vshlq_m_n_s32): Remove.
40350         (vshlq_m_n_s16): Remove.
40351         (vshlq_m_n_u8): Remove.
40352         (vshlq_m_n_u32): Remove.
40353         (vshlq_m_n_u16): Remove.
40354         (vshlq_x_s8): Remove.
40355         (vshlq_x_s16): Remove.
40356         (vshlq_x_s32): Remove.
40357         (vshlq_x_u8): Remove.
40358         (vshlq_x_u16): Remove.
40359         (vshlq_x_u32): Remove.
40360         (vshlq_x_n_s8): Remove.
40361         (vshlq_x_n_s16): Remove.
40362         (vshlq_x_n_s32): Remove.
40363         (vshlq_x_n_u8): Remove.
40364         (vshlq_x_n_u16): Remove.
40365         (vshlq_x_n_u32): Remove.
40366         (__arm_vshlq_s8): Remove.
40367         (__arm_vshlq_s16): Remove.
40368         (__arm_vshlq_s32): Remove.
40369         (__arm_vshlq_u8): Remove.
40370         (__arm_vshlq_u16): Remove.
40371         (__arm_vshlq_u32): Remove.
40372         (__arm_vshlq_r_u8): Remove.
40373         (__arm_vshlq_n_u8): Remove.
40374         (__arm_vshlq_r_s8): Remove.
40375         (__arm_vshlq_n_s8): Remove.
40376         (__arm_vshlq_r_u16): Remove.
40377         (__arm_vshlq_n_u16): Remove.
40378         (__arm_vshlq_r_s16): Remove.
40379         (__arm_vshlq_n_s16): Remove.
40380         (__arm_vshlq_r_u32): Remove.
40381         (__arm_vshlq_n_u32): Remove.
40382         (__arm_vshlq_r_s32): Remove.
40383         (__arm_vshlq_n_s32): Remove.
40384         (__arm_vshlq_m_r_u8): Remove.
40385         (__arm_vshlq_m_r_s8): Remove.
40386         (__arm_vshlq_m_r_u16): Remove.
40387         (__arm_vshlq_m_r_s16): Remove.
40388         (__arm_vshlq_m_r_u32): Remove.
40389         (__arm_vshlq_m_r_s32): Remove.
40390         (__arm_vshlq_m_u8): Remove.
40391         (__arm_vshlq_m_s8): Remove.
40392         (__arm_vshlq_m_u16): Remove.
40393         (__arm_vshlq_m_s16): Remove.
40394         (__arm_vshlq_m_u32): Remove.
40395         (__arm_vshlq_m_s32): Remove.
40396         (__arm_vshlq_m_n_s8): Remove.
40397         (__arm_vshlq_m_n_s32): Remove.
40398         (__arm_vshlq_m_n_s16): Remove.
40399         (__arm_vshlq_m_n_u8): Remove.
40400         (__arm_vshlq_m_n_u32): Remove.
40401         (__arm_vshlq_m_n_u16): Remove.
40402         (__arm_vshlq_x_s8): Remove.
40403         (__arm_vshlq_x_s16): Remove.
40404         (__arm_vshlq_x_s32): Remove.
40405         (__arm_vshlq_x_u8): Remove.
40406         (__arm_vshlq_x_u16): Remove.
40407         (__arm_vshlq_x_u32): Remove.
40408         (__arm_vshlq_x_n_s8): Remove.
40409         (__arm_vshlq_x_n_s16): Remove.
40410         (__arm_vshlq_x_n_s32): Remove.
40411         (__arm_vshlq_x_n_u8): Remove.
40412         (__arm_vshlq_x_n_u16): Remove.
40413         (__arm_vshlq_x_n_u32): Remove.
40414         (__arm_vshlq): Remove.
40415         (__arm_vshlq_r): Remove.
40416         (__arm_vshlq_n): Remove.
40417         (__arm_vshlq_m_r): Remove.
40418         (__arm_vshlq_m): Remove.
40419         (__arm_vshlq_m_n): Remove.
40420         (__arm_vshlq_x): Remove.
40421         (__arm_vshlq_x_n): Remove.
40422         (vqshlq): Remove.
40423         (vqshlq_r): Remove.
40424         (vqshlq_n): Remove.
40425         (vqshlq_m_r): Remove.
40426         (vqshlq_m_n): Remove.
40427         (vqshlq_m): Remove.
40428         (vqshlq_u8): Remove.
40429         (vqshlq_r_u8): Remove.
40430         (vqshlq_n_u8): Remove.
40431         (vqshlq_s8): Remove.
40432         (vqshlq_r_s8): Remove.
40433         (vqshlq_n_s8): Remove.
40434         (vqshlq_u16): Remove.
40435         (vqshlq_r_u16): Remove.
40436         (vqshlq_n_u16): Remove.
40437         (vqshlq_s16): Remove.
40438         (vqshlq_r_s16): Remove.
40439         (vqshlq_n_s16): Remove.
40440         (vqshlq_u32): Remove.
40441         (vqshlq_r_u32): Remove.
40442         (vqshlq_n_u32): Remove.
40443         (vqshlq_s32): Remove.
40444         (vqshlq_r_s32): Remove.
40445         (vqshlq_n_s32): Remove.
40446         (vqshlq_m_r_u8): Remove.
40447         (vqshlq_m_r_s8): Remove.
40448         (vqshlq_m_r_u16): Remove.
40449         (vqshlq_m_r_s16): Remove.
40450         (vqshlq_m_r_u32): Remove.
40451         (vqshlq_m_r_s32): Remove.
40452         (vqshlq_m_n_s8): Remove.
40453         (vqshlq_m_n_s32): Remove.
40454         (vqshlq_m_n_s16): Remove.
40455         (vqshlq_m_n_u8): Remove.
40456         (vqshlq_m_n_u32): Remove.
40457         (vqshlq_m_n_u16): Remove.
40458         (vqshlq_m_s8): Remove.
40459         (vqshlq_m_s32): Remove.
40460         (vqshlq_m_s16): Remove.
40461         (vqshlq_m_u8): Remove.
40462         (vqshlq_m_u32): Remove.
40463         (vqshlq_m_u16): Remove.
40464         (__arm_vqshlq_u8): Remove.
40465         (__arm_vqshlq_r_u8): Remove.
40466         (__arm_vqshlq_n_u8): Remove.
40467         (__arm_vqshlq_s8): Remove.
40468         (__arm_vqshlq_r_s8): Remove.
40469         (__arm_vqshlq_n_s8): Remove.
40470         (__arm_vqshlq_u16): Remove.
40471         (__arm_vqshlq_r_u16): Remove.
40472         (__arm_vqshlq_n_u16): Remove.
40473         (__arm_vqshlq_s16): Remove.
40474         (__arm_vqshlq_r_s16): Remove.
40475         (__arm_vqshlq_n_s16): Remove.
40476         (__arm_vqshlq_u32): Remove.
40477         (__arm_vqshlq_r_u32): Remove.
40478         (__arm_vqshlq_n_u32): Remove.
40479         (__arm_vqshlq_s32): Remove.
40480         (__arm_vqshlq_r_s32): Remove.
40481         (__arm_vqshlq_n_s32): Remove.
40482         (__arm_vqshlq_m_r_u8): Remove.
40483         (__arm_vqshlq_m_r_s8): Remove.
40484         (__arm_vqshlq_m_r_u16): Remove.
40485         (__arm_vqshlq_m_r_s16): Remove.
40486         (__arm_vqshlq_m_r_u32): Remove.
40487         (__arm_vqshlq_m_r_s32): Remove.
40488         (__arm_vqshlq_m_n_s8): Remove.
40489         (__arm_vqshlq_m_n_s32): Remove.
40490         (__arm_vqshlq_m_n_s16): Remove.
40491         (__arm_vqshlq_m_n_u8): Remove.
40492         (__arm_vqshlq_m_n_u32): Remove.
40493         (__arm_vqshlq_m_n_u16): Remove.
40494         (__arm_vqshlq_m_s8): Remove.
40495         (__arm_vqshlq_m_s32): Remove.
40496         (__arm_vqshlq_m_s16): Remove.
40497         (__arm_vqshlq_m_u8): Remove.
40498         (__arm_vqshlq_m_u32): Remove.
40499         (__arm_vqshlq_m_u16): Remove.
40500         (__arm_vqshlq): Remove.
40501         (__arm_vqshlq_r): Remove.
40502         (__arm_vqshlq_n): Remove.
40503         (__arm_vqshlq_m_r): Remove.
40504         (__arm_vqshlq_m_n): Remove.
40505         (__arm_vqshlq_m): Remove.
40507 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40509         * config/arm/arm-mve-builtins-functions.h (class
40510         unspec_mve_function_exact_insn_vshl): New.
40512 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40514         * config/arm/arm-mve-builtins-shapes.cc (binary_lshift_r): New.
40515         * config/arm/arm-mve-builtins-shapes.h (binary_lshift_r): New.
40517 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40519         * config/arm/arm-mve-builtins.cc (has_inactive_argument)
40520         (finish_opt_n_resolution): Handle MODE_r.
40521         * config/arm/arm-mve-builtins.def (r): New mode.
40523 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40525         * config/arm/arm-mve-builtins-shapes.cc (binary_lshift): New.
40526         * config/arm/arm-mve-builtins-shapes.h (binary_lshift): New.
40528 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40530         * config/arm/arm-mve-builtins-base.cc (FUNCTION_WITHOUT_N): New.
40531         (vabdq): New.
40532         * config/arm/arm-mve-builtins-base.def (vabdq): New.
40533         * config/arm/arm-mve-builtins-base.h (vabdq): New.
40534         * config/arm/arm_mve.h (vabdq): Remove.
40535         (vabdq_m): Remove.
40536         (vabdq_x): Remove.
40537         (vabdq_u8): Remove.
40538         (vabdq_s8): Remove.
40539         (vabdq_u16): Remove.
40540         (vabdq_s16): Remove.
40541         (vabdq_u32): Remove.
40542         (vabdq_s32): Remove.
40543         (vabdq_f16): Remove.
40544         (vabdq_f32): Remove.
40545         (vabdq_m_s8): Remove.
40546         (vabdq_m_s32): Remove.
40547         (vabdq_m_s16): Remove.
40548         (vabdq_m_u8): Remove.
40549         (vabdq_m_u32): Remove.
40550         (vabdq_m_u16): Remove.
40551         (vabdq_m_f32): Remove.
40552         (vabdq_m_f16): Remove.
40553         (vabdq_x_s8): Remove.
40554         (vabdq_x_s16): Remove.
40555         (vabdq_x_s32): Remove.
40556         (vabdq_x_u8): Remove.
40557         (vabdq_x_u16): Remove.
40558         (vabdq_x_u32): Remove.
40559         (vabdq_x_f16): Remove.
40560         (vabdq_x_f32): Remove.
40561         (__arm_vabdq_u8): Remove.
40562         (__arm_vabdq_s8): Remove.
40563         (__arm_vabdq_u16): Remove.
40564         (__arm_vabdq_s16): Remove.
40565         (__arm_vabdq_u32): Remove.
40566         (__arm_vabdq_s32): Remove.
40567         (__arm_vabdq_m_s8): Remove.
40568         (__arm_vabdq_m_s32): Remove.
40569         (__arm_vabdq_m_s16): Remove.
40570         (__arm_vabdq_m_u8): Remove.
40571         (__arm_vabdq_m_u32): Remove.
40572         (__arm_vabdq_m_u16): Remove.
40573         (__arm_vabdq_x_s8): Remove.
40574         (__arm_vabdq_x_s16): Remove.
40575         (__arm_vabdq_x_s32): Remove.
40576         (__arm_vabdq_x_u8): Remove.
40577         (__arm_vabdq_x_u16): Remove.
40578         (__arm_vabdq_x_u32): Remove.
40579         (__arm_vabdq_f16): Remove.
40580         (__arm_vabdq_f32): Remove.
40581         (__arm_vabdq_m_f32): Remove.
40582         (__arm_vabdq_m_f16): Remove.
40583         (__arm_vabdq_x_f16): Remove.
40584         (__arm_vabdq_x_f32): Remove.
40585         (__arm_vabdq): Remove.
40586         (__arm_vabdq_m): Remove.
40587         (__arm_vabdq_x): Remove.
40589 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40591         * config/arm/iterators.md (MVE_FP_M_BINARY): Add vabdq.
40592         (MVE_FP_VABDQ_ONLY): New.
40593         (mve_insn): Add vabd.
40594         * config/arm/mve.md (mve_vabdq_f<mode>): Move into ...
40595         (@mve_<mve_insn>q_f<mode>): ... this.
40596         (mve_vabdq_m_f<mode>): Remove.
40598 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40600         * config/arm/arm-mve-builtins-base.cc (vqrdmulhq): New.
40601         * config/arm/arm-mve-builtins-base.def (vqrdmulhq): New.
40602         * config/arm/arm-mve-builtins-base.h (vqrdmulhq): New.
40603         * config/arm/arm_mve.h (vqrdmulhq): Remove.
40604         (vqrdmulhq_m): Remove.
40605         (vqrdmulhq_s8): Remove.
40606         (vqrdmulhq_n_s8): Remove.
40607         (vqrdmulhq_s16): Remove.
40608         (vqrdmulhq_n_s16): Remove.
40609         (vqrdmulhq_s32): Remove.
40610         (vqrdmulhq_n_s32): Remove.
40611         (vqrdmulhq_m_n_s8): Remove.
40612         (vqrdmulhq_m_n_s32): Remove.
40613         (vqrdmulhq_m_n_s16): Remove.
40614         (vqrdmulhq_m_s8): Remove.
40615         (vqrdmulhq_m_s32): Remove.
40616         (vqrdmulhq_m_s16): Remove.
40617         (__arm_vqrdmulhq_s8): Remove.
40618         (__arm_vqrdmulhq_n_s8): Remove.
40619         (__arm_vqrdmulhq_s16): Remove.
40620         (__arm_vqrdmulhq_n_s16): Remove.
40621         (__arm_vqrdmulhq_s32): Remove.
40622         (__arm_vqrdmulhq_n_s32): Remove.
40623         (__arm_vqrdmulhq_m_n_s8): Remove.
40624         (__arm_vqrdmulhq_m_n_s32): Remove.
40625         (__arm_vqrdmulhq_m_n_s16): Remove.
40626         (__arm_vqrdmulhq_m_s8): Remove.
40627         (__arm_vqrdmulhq_m_s32): Remove.
40628         (__arm_vqrdmulhq_m_s16): Remove.
40629         (__arm_vqrdmulhq): Remove.
40630         (__arm_vqrdmulhq_m): Remove.
40632 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40634         * config/arm/iterators.md (MVE_SHIFT_M_R, MVE_SHIFT_M_N)
40635         (MVE_SHIFT_N, MVE_SHIFT_R): New.
40636         (mve_insn): Add vqshl, vshl.
40637         * config/arm/mve.md (mve_vqshlq_n_<supf><mode>)
40638         (mve_vshlq_n_<supf><mode>): Merge into ...
40639         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
40640         (mve_vqshlq_r_<supf><mode>, mve_vshlq_r_<supf><mode>): Merge into
40641         ...
40642         (@mve_<mve_insn>q_r_<supf><mode>): ... this.
40643         (mve_vqshlq_m_r_<supf><mode>, mve_vshlq_m_r_<supf><mode>): Merge
40644         into ...
40645         (@mve_<mve_insn>q_m_r_<supf><mode>): ... this.
40646         (mve_vqshlq_m_n_<supf><mode>, mve_vshlq_m_n_<supf><mode>): Merge
40647         into ...
40648         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
40649         * config/arm/vec-common.md (mve_vshlq_<supf><mode>): Transform
40650         into ...
40651         (@mve_<mve_insn>q_<supf><mode>): ... this.
40653 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40655         * config/arm/arm-mve-builtins-base.cc (vqrshlq, vrshlq): New.
40656         * config/arm/arm-mve-builtins-base.def (vqrshlq, vrshlq): New.
40657         * config/arm/arm-mve-builtins-base.h (vqrshlq, vrshlq): New.
40658         * config/arm/arm-mve-builtins.cc (has_inactive_argument): Handle
40659         vqrshlq, vrshlq.
40660         * config/arm/arm_mve.h (vrshlq): Remove.
40661         (vrshlq_m_n): Remove.
40662         (vrshlq_m): Remove.
40663         (vrshlq_x): Remove.
40664         (vrshlq_u8): Remove.
40665         (vrshlq_n_u8): Remove.
40666         (vrshlq_s8): Remove.
40667         (vrshlq_n_s8): Remove.
40668         (vrshlq_u16): Remove.
40669         (vrshlq_n_u16): Remove.
40670         (vrshlq_s16): Remove.
40671         (vrshlq_n_s16): Remove.
40672         (vrshlq_u32): Remove.
40673         (vrshlq_n_u32): Remove.
40674         (vrshlq_s32): Remove.
40675         (vrshlq_n_s32): Remove.
40676         (vrshlq_m_n_u8): Remove.
40677         (vrshlq_m_n_s8): Remove.
40678         (vrshlq_m_n_u16): Remove.
40679         (vrshlq_m_n_s16): Remove.
40680         (vrshlq_m_n_u32): Remove.
40681         (vrshlq_m_n_s32): Remove.
40682         (vrshlq_m_s8): Remove.
40683         (vrshlq_m_s32): Remove.
40684         (vrshlq_m_s16): Remove.
40685         (vrshlq_m_u8): Remove.
40686         (vrshlq_m_u32): Remove.
40687         (vrshlq_m_u16): Remove.
40688         (vrshlq_x_s8): Remove.
40689         (vrshlq_x_s16): Remove.
40690         (vrshlq_x_s32): Remove.
40691         (vrshlq_x_u8): Remove.
40692         (vrshlq_x_u16): Remove.
40693         (vrshlq_x_u32): Remove.
40694         (__arm_vrshlq_u8): Remove.
40695         (__arm_vrshlq_n_u8): Remove.
40696         (__arm_vrshlq_s8): Remove.
40697         (__arm_vrshlq_n_s8): Remove.
40698         (__arm_vrshlq_u16): Remove.
40699         (__arm_vrshlq_n_u16): Remove.
40700         (__arm_vrshlq_s16): Remove.
40701         (__arm_vrshlq_n_s16): Remove.
40702         (__arm_vrshlq_u32): Remove.
40703         (__arm_vrshlq_n_u32): Remove.
40704         (__arm_vrshlq_s32): Remove.
40705         (__arm_vrshlq_n_s32): Remove.
40706         (__arm_vrshlq_m_n_u8): Remove.
40707         (__arm_vrshlq_m_n_s8): Remove.
40708         (__arm_vrshlq_m_n_u16): Remove.
40709         (__arm_vrshlq_m_n_s16): Remove.
40710         (__arm_vrshlq_m_n_u32): Remove.
40711         (__arm_vrshlq_m_n_s32): Remove.
40712         (__arm_vrshlq_m_s8): Remove.
40713         (__arm_vrshlq_m_s32): Remove.
40714         (__arm_vrshlq_m_s16): Remove.
40715         (__arm_vrshlq_m_u8): Remove.
40716         (__arm_vrshlq_m_u32): Remove.
40717         (__arm_vrshlq_m_u16): Remove.
40718         (__arm_vrshlq_x_s8): Remove.
40719         (__arm_vrshlq_x_s16): Remove.
40720         (__arm_vrshlq_x_s32): Remove.
40721         (__arm_vrshlq_x_u8): Remove.
40722         (__arm_vrshlq_x_u16): Remove.
40723         (__arm_vrshlq_x_u32): Remove.
40724         (__arm_vrshlq): Remove.
40725         (__arm_vrshlq_m_n): Remove.
40726         (__arm_vrshlq_m): Remove.
40727         (__arm_vrshlq_x): Remove.
40728         (vqrshlq): Remove.
40729         (vqrshlq_m_n): Remove.
40730         (vqrshlq_m): Remove.
40731         (vqrshlq_u8): Remove.
40732         (vqrshlq_n_u8): Remove.
40733         (vqrshlq_s8): Remove.
40734         (vqrshlq_n_s8): Remove.
40735         (vqrshlq_u16): Remove.
40736         (vqrshlq_n_u16): Remove.
40737         (vqrshlq_s16): Remove.
40738         (vqrshlq_n_s16): Remove.
40739         (vqrshlq_u32): Remove.
40740         (vqrshlq_n_u32): Remove.
40741         (vqrshlq_s32): Remove.
40742         (vqrshlq_n_s32): Remove.
40743         (vqrshlq_m_n_u8): Remove.
40744         (vqrshlq_m_n_s8): Remove.
40745         (vqrshlq_m_n_u16): Remove.
40746         (vqrshlq_m_n_s16): Remove.
40747         (vqrshlq_m_n_u32): Remove.
40748         (vqrshlq_m_n_s32): Remove.
40749         (vqrshlq_m_s8): Remove.
40750         (vqrshlq_m_s32): Remove.
40751         (vqrshlq_m_s16): Remove.
40752         (vqrshlq_m_u8): Remove.
40753         (vqrshlq_m_u32): Remove.
40754         (vqrshlq_m_u16): Remove.
40755         (__arm_vqrshlq_u8): Remove.
40756         (__arm_vqrshlq_n_u8): Remove.
40757         (__arm_vqrshlq_s8): Remove.
40758         (__arm_vqrshlq_n_s8): Remove.
40759         (__arm_vqrshlq_u16): Remove.
40760         (__arm_vqrshlq_n_u16): Remove.
40761         (__arm_vqrshlq_s16): Remove.
40762         (__arm_vqrshlq_n_s16): Remove.
40763         (__arm_vqrshlq_u32): Remove.
40764         (__arm_vqrshlq_n_u32): Remove.
40765         (__arm_vqrshlq_s32): Remove.
40766         (__arm_vqrshlq_n_s32): Remove.
40767         (__arm_vqrshlq_m_n_u8): Remove.
40768         (__arm_vqrshlq_m_n_s8): Remove.
40769         (__arm_vqrshlq_m_n_u16): Remove.
40770         (__arm_vqrshlq_m_n_s16): Remove.
40771         (__arm_vqrshlq_m_n_u32): Remove.
40772         (__arm_vqrshlq_m_n_s32): Remove.
40773         (__arm_vqrshlq_m_s8): Remove.
40774         (__arm_vqrshlq_m_s32): Remove.
40775         (__arm_vqrshlq_m_s16): Remove.
40776         (__arm_vqrshlq_m_u8): Remove.
40777         (__arm_vqrshlq_m_u32): Remove.
40778         (__arm_vqrshlq_m_u16): Remove.
40779         (__arm_vqrshlq): Remove.
40780         (__arm_vqrshlq_m_n): Remove.
40781         (__arm_vqrshlq_m): Remove.
40783 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40785         * config/arm/iterators.md (MVE_RSHIFT_M_N, MVE_RSHIFT_N): New.
40786         (mve_insn): Add vqrshl, vrshl.
40787         * config/arm/mve.md (mve_vqrshlq_n_<supf><mode>)
40788         (mve_vrshlq_n_<supf><mode>): Merge into ...
40789         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
40790         (mve_vqrshlq_m_n_<supf><mode>, mve_vrshlq_m_n_<supf><mode>): Merge
40791         into ...
40792         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
40794 2023-05-05  Christophe Lyon  <christophe.lyon@arm.com>
40796         * config/arm/arm-mve-builtins-shapes.cc (binary_round_lshift): New.
40797         * config/arm/arm-mve-builtins-shapes.h (binary_round_lshift): New.
40799 2023-05-05  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
40801         PR target/109615
40802         * config/riscv/riscv-vsetvl.cc (avl_info::multiple_source_equal_p): Add
40803         denegrate PHI optmization.
40805 2023-05-05  Uros Bizjak  <ubizjak@gmail.com>
40807         * config/i386/predicates.md (register_no_SP_operand):
40808         Rename from index_register_operand.
40809         (call_register_operand): Update for rename.
40810         * config/i386/i386.md (*lea<mode>_general_[1234]): Update for rename.
40812 2023-05-05  Tamar Christina  <tamar.christina@arm.com>
40814         PR bootstrap/84402
40815         * Makefile.in (NUM_MATCH_SPLITS, MATCH_SPLITS_SEQ,
40816         GIMPLE_MATCH_PD_SEQ_SRC, GIMPLE_MATCH_PD_SEQ_O,
40817         GENERIC_MATCH_PD_SEQ_SRC, GENERIC_MATCH_PD_SEQ_O): New.
40818         (OBJS, MOSTLYCLEANFILES, .PRECIOUS): Use them.
40819         (s-match): Split into s-generic-match and s-gimple-match.
40820         * configure.ac (with-matchpd-partitions,
40821         DEFAULT_MATCHPD_PARTITIONS): New.
40822         * configure: Regenerate.
40824 2023-05-05  Tamar Christina  <tamar.christina@arm.com>
40826         PR bootstrap/84402
40827         * genmatch.cc (emit_func, SIZED_BASED_CHUNKS, get_out_file): New.
40828         (decision_tree::gen): Accept list of files instead of single and update
40829         to write function definition to header and main file.
40830         (write_predicate): Likewise.
40831         (write_header): Emit pragmas and new includes.
40832         (main): Create file buffers and cleanup.
40833         (showUsage, write_header_includes): New.
40835 2023-05-05  Tamar Christina  <tamar.christina@arm.com>
40837         PR bootstrap/84402
40838         * Makefile.in (OBJS): Add gimple-match-exports.o.
40839         * genmatch.cc (decision_tree::gen): Export gimple_gimplify helpers.
40840         * gimple-match-head.cc (gimple_simplify, gimple_resimplify1,
40841         gimple_resimplify2, gimple_resimplify3, gimple_resimplify4,
40842         gimple_resimplify5, constant_for_folding, convert_conditional_op,
40843         maybe_resimplify_conditional_op, gimple_match_op::resimplify,
40844         maybe_build_generic_op, build_call_internal, maybe_push_res_to_seq,
40845         do_valueize, try_conditional_simplification, gimple_extract,
40846         gimple_extract_op, canonicalize_code, commutative_binary_op_p,
40847         commutative_ternary_op_p, first_commutative_argument,
40848         associative_binary_op_p, directly_supported_p,
40849         get_conditional_internal_fn): Moved to gimple-match-exports.cc
40850         * gimple-match-exports.cc: New file.
40852 2023-05-05  Tamar Christina  <tamar.christina@arm.com>
40854         PR bootstrap/84402
40855         * genmatch.cc (decision_tree::gen, write_predicate): Generate new
40856         debug_dump var.
40857         (dt_simplify::gen_1): Use it.
40859 2023-05-05  Tamar Christina  <tamar.christina@arm.com>
40861         PR bootstrap/84402
40862         * genmatch.cc (output_line_directive): Only emit commented directive
40863         when -vv.
40865 2023-05-05  Tamar Christina  <tamar.christina@arm.com>
40867         PR bootstrap/84402
40868         * genmatch.cc (dt_simplify::gen_1): Only emit labels if used.
40870 2023-05-05  Tobias Burnus  <tobias@codesourcery.com>
40872         * config/gcn/gcn.cc (gcn_vectorize_builtin_vectorized_function): Remove
40873         unused in_mode/in_n variables.
40875 2023-05-05  Richard Biener  <rguenther@suse.de>
40877         PR tree-optimization/109735
40878         * tree-vect-stmts.cc (vectorizable_operation): Perform
40879         conversion for POINTER_DIFF_EXPR unconditionally.
40881 2023-05-05  Uros Bizjak  <ubizjak@gmail.com>
40883         * config/i386/mmx.md (mulv2si3): New expander.
40884         (*mulv2si3): New insn pattern.
40886 2023-05-05  Tobias Burnus  <tobias@codesourcery.com>
40887             Thomas Schwinge  <thomas@codesourcery.com>
40889         PR libgomp/108098
40890         * config/nvptx/mkoffload.cc (process): Emit dummy procedure
40891         alongside reverse-offload function table to prevent NULL values
40892         of the function addresses.
40894 2023-05-05  Jakub Jelinek  <jakub@redhat.com>
40896         * builtins.cc (do_mpfr_ckconv, do_mpc_ckconv): Fix comment typo,
40897         mpft_t -> mpfr_t.
40898         * fold-const-call.cc (do_mpfr_ckconv, do_mpc_ckconv): Likewise.
40900 2023-05-05  Andrew Pinski  <apinski@marvell.com>
40902         PR tree-optimization/109732
40903         * tree-ssa-phiopt.cc (match_simplify_replacement): Fix the selection
40904         of the argtrue/argfalse.
40906 2023-05-05  Andrew Pinski  <apinski@marvell.com>
40908         PR tree-optimization/109722
40909         * match.pd: Extend the `ABS<a> == 0` pattern
40910         to cover `ABSU<a> == 0` too.
40912 2023-05-04  Uros Bizjak  <ubizjak@gmail.com>
40914         PR target/109733
40915         * config/i386/predicates.md (index_reg_operand): New predicate.
40916         * config/i386/i386.md (ashift to lea spliter): Use
40917         general_reg_operand and index_reg_operand predicates.
40919 2023-05-04  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
40921         * config/aarch64/aarch64-simd.md (aarch64_<sur><addsub>hn2<mode>_insn_le):
40922         Rename and reimplement with RTL codes to...
40923         (aarch64_<optab>hn2<mode>_insn_le): .. This.
40924         (aarch64_r<optab>hn2<mode>_insn_le): New pattern.
40925         (aarch64_<sur><addsub>hn2<mode>_insn_be): Rename and reimplement with RTL
40926         codes to...
40927         (aarch64_<optab>hn2<mode>_insn_be): ... This.
40928         (aarch64_r<optab>hn2<mode>_insn_be): New pattern.
40929         (aarch64_<sur><addsub>hn2<mode>): Rename and adjust expander to...
40930         (aarch64_<optab>hn2<mode>): ... This.
40931         (aarch64_r<optab>hn2<mode>): New expander.
40932         * config/aarch64/iterators.md (UNSPEC_ADDHN, UNSPEC_RADDHN,
40933         UNSPEC_SUBHN, UNSPEC_RSUBHN): Delete unspecs.
40934         (ADDSUBHN): Delete.
40935         (sur): Remove handling of the above.
40936         (addsub): Likewise.
40938 2023-05-04  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
40940         * config/aarch64/aarch64-simd.md (aarch64_<sur><addsub>hn<mode>_insn_le):
40941         Delete.
40942         (aarch64_<optab>hn<mode>_insn<vczle><vczbe>): New define_insn.
40943         (aarch64_<sur><addsub>hn<mode>_insn_be): Delete.
40944         (aarch64_r<optab>hn<mode>_insn<vczle><vczbe>): New define_insn.
40945         (aarch64_<sur><addsub>hn<mode>): Delete.
40946         (aarch64_<optab>hn<mode>): New define_expand.
40947         (aarch64_r<optab>hn<mode>): Likewise.
40948         * config/aarch64/predicates.md (aarch64_simd_raddsubhn_imm_vec):
40949         New predicate.
40951 2023-05-04  Andrew Pinski  <apinski@marvell.com>
40953         * tree-ssa-phiopt.cc (replace_phi_edge_with_variable): Handle
40954         diamond form bb with forwarder only empty blocks better.
40956 2023-05-04  Andrew Pinski  <apinski@marvell.com>
40958         * tree-ssa-threadupdate.cc (copy_phi_arg_into_existing_phi): Move to ...
40959         * tree-cfg.cc (copy_phi_arg_into_existing_phi): Here and remove static.
40960         (gimple_duplicate_sese_tail): Use copy_phi_arg_into_existing_phi instead
40961         of an inline version of it.
40962         * tree-cfgcleanup.cc (remove_forwarder_block): Likewise.
40963         * tree-cfg.h (copy_phi_arg_into_existing_phi): New declaration.
40965 2023-05-04  Andrew Pinski  <apinski@marvell.com>
40967         * tree-ssa-phiopt.cc (replace_phi_edge_with_variable): Change
40968         the default argument value for dce_ssa_names to nullptr.
40969         Check to make sure dce_ssa_names is a non-nullptr before
40970         calling simple_dce_from_worklist.
40972 2023-05-04  Uros Bizjak  <ubizjak@gmail.com>
40974         * config/i386/predicates.md (index_register_operand): Reject
40975         arg_pointer_rtx, frame_pointer_rtx, stack_pointer_rtx and
40976         VIRTUAL_REGISTER_P operands.  Allow subregs of memory before reload.
40977         (call_register_no_elim_operand): Rewrite as ...
40978         (call_register_operand): ... this.
40979         (call_insn_operand): Use call_register_operand predicate.
40981 2023-05-04  Richard Biener  <rguenther@suse.de>
40983         PR tree-optimization/109721
40984         * tree-vect-stmts.cc (vectorizable_operation): Make sure
40985         to test word_mode for all !target_support_p operations.
40987 2023-05-04  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
40989         PR target/99195
40990         * config/aarch64/aarch64-simd.md (aarch64_<su>aba<mode>): Rename to...
40991         (aarch64_<su>aba<mode><vczle><vczbe>): ... This.
40992         (aarch64_mla<mode>): Rename to...
40993         (aarch64_mla<mode><vczle><vczbe>): ... This.
40994         (*aarch64_mla_elt<mode>): Rename to...
40995         (*aarch64_mla_elt<mode><vczle><vczbe>): ... This.
40996         (*aarch64_mla_elt_<vswap_width_name><mode>): Rename to...
40997         (*aarch64_mla_elt_<vswap_width_name><mode><vczle><vczbe>): ... This.
40998         (aarch64_mla_n<mode>): Rename to...
40999         (aarch64_mla_n<mode><vczle><vczbe>): ... This.
41000         (aarch64_mls<mode>): Rename to...
41001         (aarch64_mls<mode><vczle><vczbe>): ... This.
41002         (*aarch64_mls_elt<mode>): Rename to...
41003         (*aarch64_mls_elt<mode><vczle><vczbe>): ... This.
41004         (*aarch64_mls_elt_<vswap_width_name><mode>): Rename to...
41005         (*aarch64_mls_elt_<vswap_width_name><mode><vczle><vczbe>): ... This.
41006         (aarch64_mls_n<mode>): Rename to...
41007         (aarch64_mls_n<mode><vczle><vczbe>): ... This.
41008         (fma<mode>4): Rename to...
41009         (fma<mode>4<vczle><vczbe>): ... This.
41010         (*aarch64_fma4_elt<mode>): Rename to...
41011         (*aarch64_fma4_elt<mode><vczle><vczbe>): ... This.
41012         (*aarch64_fma4_elt_<vswap_width_name><mode>): Rename to...
41013         (*aarch64_fma4_elt_<vswap_width_name><mode><vczle><vczbe>): ... This.
41014         (*aarch64_fma4_elt_from_dup<mode>): Rename to...
41015         (*aarch64_fma4_elt_from_dup<mode><vczle><vczbe>): ... This.
41016         (fnma<mode>4): Rename to...
41017         (fnma<mode>4<vczle><vczbe>): ... This.
41018         (*aarch64_fnma4_elt<mode>): Rename to...
41019         (*aarch64_fnma4_elt<mode><vczle><vczbe>): ... This.
41020         (*aarch64_fnma4_elt_<vswap_width_name><mode>): Rename to...
41021         (*aarch64_fnma4_elt_<vswap_width_name><mode><vczle><vczbe>): ... This.
41022         (*aarch64_fnma4_elt_from_dup<mode>): Rename to...
41023         (*aarch64_fnma4_elt_from_dup<mode><vczle><vczbe>): ... This.
41024         (aarch64_simd_bsl<mode>_internal): Rename to...
41025         (aarch64_simd_bsl<mode>_internal<vczle><vczbe>): ... This.
41026         (*aarch64_simd_bsl<mode>_alt): Rename to...
41027         (*aarch64_simd_bsl<mode>_alt<vczle><vczbe>): ... This.
41029 2023-05-04  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
41031         PR target/99195
41032         * config/aarch64/aarch64-simd.md (aarch64_<su>abd<mode>): Rename to...
41033         (aarch64_<su>abd<mode><vczle><vczbe>): ... This.
41034         (fabd<mode>3): Rename to...
41035         (fabd<mode>3<vczle><vczbe>): ... This.
41036         (aarch64_<optab>p<mode>): Rename to...
41037         (aarch64_<optab>p<mode><vczle><vczbe>): ... This.
41038         (aarch64_faddp<mode>): Rename to...
41039         (aarch64_faddp<mode><vczle><vczbe>): ... This.
41041 2023-05-04  Martin Liska  <mliska@suse.cz>
41043         * gcov.cc (GCOV_JSON_FORMAT_VERSION): New definition.
41044         (print_version): Use it.
41045         (generate_results): Likewise.
41047 2023-05-04  Richard Biener  <rguenther@suse.de>
41049         * tree-cfg.h (last_stmt): Rename to ...
41050         (last_nondebug_stmt): ... this.
41051         * tree-cfg.cc (last_stmt): Rename to ...
41052         (last_nondebug_stmt): ... this.
41053         (assign_discriminators): Adjust.
41054         (group_case_labels_stmt): Likewise.
41055         (gimple_can_duplicate_bb_p): Likewise.
41056         (execute_fixup_cfg): Likewise.
41057         * auto-profile.cc (afdo_propagate_circuit): Likewise.
41058         * gimple-range.cc (gimple_ranger::range_on_exit): Likewise.
41059         * omp-expand.cc (workshare_safe_to_combine_p): Likewise.
41060         (determine_parallel_type): Likewise.
41061         (adjust_context_and_scope): Likewise.
41062         (expand_task_call): Likewise.
41063         (remove_exit_barrier): Likewise.
41064         (expand_omp_taskreg): Likewise.
41065         (expand_omp_for_init_counts): Likewise.
41066         (expand_omp_for_init_vars): Likewise.
41067         (expand_omp_for_static_chunk): Likewise.
41068         (expand_omp_simd): Likewise.
41069         (expand_oacc_for): Likewise.
41070         (expand_omp_for): Likewise.
41071         (expand_omp_sections): Likewise.
41072         (expand_omp_atomic_fetch_op): Likewise.
41073         (expand_omp_atomic_cas): Likewise.
41074         (expand_omp_atomic): Likewise.
41075         (expand_omp_target): Likewise.
41076         (expand_omp): Likewise.
41077         (omp_make_gimple_edges): Likewise.
41078         * trans-mem.cc (tm_region_init): Likewise.
41079         * tree-inline.cc (redirect_all_calls): Likewise.
41080         * tree-parloops.cc (gen_parallel_loop): Likewise.
41081         * tree-ssa-loop-ch.cc (do_while_loop_p): Likewise.
41082         * tree-ssa-loop-ivcanon.cc (canonicalize_loop_induction_variables):
41083         Likewise.
41084         * tree-ssa-loop-ivopts.cc (stmt_after_ip_normal_pos): Likewise.
41085         (may_eliminate_iv): Likewise.
41086         * tree-ssa-loop-manip.cc (standard_iv_increment_position): Likewise.
41087         * tree-ssa-loop-niter.cc (do_warn_aggressive_loop_optimizations):
41088         Likewise.
41089         (estimate_numbers_of_iterations): Likewise.
41090         * tree-ssa-loop-split.cc (compute_added_num_insns): Likewise.
41091         * tree-ssa-loop-unswitch.cc (get_predicates_for_bb): Likewise.
41092         (set_predicates_for_bb): Likewise.
41093         (init_loop_unswitch_info): Likewise.
41094         (hoist_guard): Likewise.
41095         * tree-ssa-phiopt.cc (match_simplify_replacement): Likewise.
41096         (minmax_replacement): Likewise.
41097         * tree-ssa-reassoc.cc (update_range_test): Likewise.
41098         (optimize_range_tests_to_bit_test): Likewise.
41099         (optimize_range_tests_var_bound): Likewise.
41100         (optimize_range_tests): Likewise.
41101         (no_side_effect_bb): Likewise.
41102         (suitable_cond_bb): Likewise.
41103         (maybe_optimize_range_tests): Likewise.
41104         (reassociate_bb): Likewise.
41105         * tree-vrp.cc (rvrp_folder::pre_fold_bb): Likewise.
41107 2023-05-04  Jakub Jelinek  <jakub@redhat.com>
41109         PR debug/109676
41110         * config/i386/i386-features.cc (timode_scalar_chain::convert_insn):
41111         If src is REG, change its mode to V1TImode and call fix_debug_reg_uses
41112         for it only if it still has TImode.  Don't decide whether to call
41113         fix_debug_reg_uses based on whether SRC is ever set or not.
41115 2023-05-04  Hans-Peter Nilsson  <hp@axis.com>
41117         * config/cris/cris.cc (cris_split_constant): New function.
41118         * config/cris/cris.md (splitop): New iterator.
41119         (opsplit1): New define_peephole2.
41120         * config/cris/cris-protos.h (cris_split_constant): Declare.
41121         (cris_splittable_constant_p): New macro.
41123 2023-05-04  Hans-Peter Nilsson  <hp@axis.com>
41125         * config/cris/cris.cc (TARGET_SPILL_CLASS): Define
41126         to ALL_REGS.
41128 2023-05-04  Hans-Peter Nilsson  <hp@axis.com>
41130         * config/cris/cris.cc (cris_side_effect_mode_ok): Use
41131         lra_in_progress, not reload_in_progress.
41132         * config/cris/cris.md ("movdi", "*addi_reload"): Ditto.
41133         * config/cris/constraints.md ("Q"): Ditto.
41135 2023-05-03  Andrew Pinski  <apinski@marvell.com>
41137         * tree-ssa-dce.cc (simple_dce_from_worklist): Record
41138         stats on removed number of statements and phis.
41140 2023-05-03  Aldy Hernandez  <aldyh@redhat.com>
41142         PR tree-optimization/109711
41143         * value-range.cc (irange::verify_range): Allow types of
41144         error_mark_node.
41146 2023-05-03  Alexander Monakov  <amonakov@ispras.ru>
41148         PR sanitizer/90746
41149         * calls.cc (can_implement_as_sibling_call_p): Reject calls
41150         to __sanitizer_cov_trace_pc.
41152 2023-05-03  Richard Sandiford  <richard.sandiford@arm.com>
41154         PR target/109661
41155         * config/aarch64/aarch64.cc (aarch64_function_arg_alignment): Add
41156         a new ABI break parameter for GCC 14.  Set it to the alignment
41157         of enums that have an underlying type.  Take the true alignment
41158         of such enums from the TYPE_ALIGN of the underlying type's
41159         TYPE_MAIN_VARIANT.
41160         (aarch64_function_arg_boundary): Update accordingly.
41161         (aarch64_layout_arg, aarch64_gimplify_va_arg_expr): Likewise.
41162         Warn about ABI differences.
41164 2023-05-03  Richard Sandiford  <richard.sandiford@arm.com>
41166         PR target/109661
41167         * config/aarch64/aarch64.cc (aarch64_function_arg_alignment): Rename
41168         ABI break variables to abi_break_gcc_9 and abi_break_gcc_13.
41169         (aarch64_layout_arg, aarch64_function_arg_boundary): Likewise.
41170         (aarch64_gimplify_va_arg_expr): Likewise.
41172 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41174         * config/arm/arm-mve-builtins-base.cc (FUNCTION_WITH_M_N_NO_F)
41175         (FUNCTION_WITHOUT_N_NO_F, FUNCTION_WITH_M_N_NO_U_F): New.
41176         (vhaddq, vhsubq, vmulhq, vqaddq, vqsubq, vqdmulhq, vrhaddq)
41177         (vrmulhq): New.
41178         * config/arm/arm-mve-builtins-base.def (vhaddq, vhsubq, vmulhq)
41179         (vqaddq, vqsubq, vqdmulhq, vrhaddq, vrmulhq): New.
41180         * config/arm/arm-mve-builtins-base.h (vhaddq, vhsubq, vmulhq)
41181         (vqaddq, vqsubq, vqdmulhq, vrhaddq, vrmulhq): New.
41182         * config/arm/arm_mve.h (vhsubq): Remove.
41183         (vhaddq): Remove.
41184         (vhaddq_m): Remove.
41185         (vhsubq_m): Remove.
41186         (vhaddq_x): Remove.
41187         (vhsubq_x): Remove.
41188         (vhsubq_u8): Remove.
41189         (vhsubq_n_u8): Remove.
41190         (vhaddq_u8): Remove.
41191         (vhaddq_n_u8): Remove.
41192         (vhsubq_s8): Remove.
41193         (vhsubq_n_s8): Remove.
41194         (vhaddq_s8): Remove.
41195         (vhaddq_n_s8): Remove.
41196         (vhsubq_u16): Remove.
41197         (vhsubq_n_u16): Remove.
41198         (vhaddq_u16): Remove.
41199         (vhaddq_n_u16): Remove.
41200         (vhsubq_s16): Remove.
41201         (vhsubq_n_s16): Remove.
41202         (vhaddq_s16): Remove.
41203         (vhaddq_n_s16): Remove.
41204         (vhsubq_u32): Remove.
41205         (vhsubq_n_u32): Remove.
41206         (vhaddq_u32): Remove.
41207         (vhaddq_n_u32): Remove.
41208         (vhsubq_s32): Remove.
41209         (vhsubq_n_s32): Remove.
41210         (vhaddq_s32): Remove.
41211         (vhaddq_n_s32): Remove.
41212         (vhaddq_m_n_s8): Remove.
41213         (vhaddq_m_n_s32): Remove.
41214         (vhaddq_m_n_s16): Remove.
41215         (vhaddq_m_n_u8): Remove.
41216         (vhaddq_m_n_u32): Remove.
41217         (vhaddq_m_n_u16): Remove.
41218         (vhaddq_m_s8): Remove.
41219         (vhaddq_m_s32): Remove.
41220         (vhaddq_m_s16): Remove.
41221         (vhaddq_m_u8): Remove.
41222         (vhaddq_m_u32): Remove.
41223         (vhaddq_m_u16): Remove.
41224         (vhsubq_m_n_s8): Remove.
41225         (vhsubq_m_n_s32): Remove.
41226         (vhsubq_m_n_s16): Remove.
41227         (vhsubq_m_n_u8): Remove.
41228         (vhsubq_m_n_u32): Remove.
41229         (vhsubq_m_n_u16): Remove.
41230         (vhsubq_m_s8): Remove.
41231         (vhsubq_m_s32): Remove.
41232         (vhsubq_m_s16): Remove.
41233         (vhsubq_m_u8): Remove.
41234         (vhsubq_m_u32): Remove.
41235         (vhsubq_m_u16): Remove.
41236         (vhaddq_x_n_s8): Remove.
41237         (vhaddq_x_n_s16): Remove.
41238         (vhaddq_x_n_s32): Remove.
41239         (vhaddq_x_n_u8): Remove.
41240         (vhaddq_x_n_u16): Remove.
41241         (vhaddq_x_n_u32): Remove.
41242         (vhaddq_x_s8): Remove.
41243         (vhaddq_x_s16): Remove.
41244         (vhaddq_x_s32): Remove.
41245         (vhaddq_x_u8): Remove.
41246         (vhaddq_x_u16): Remove.
41247         (vhaddq_x_u32): Remove.
41248         (vhsubq_x_n_s8): Remove.
41249         (vhsubq_x_n_s16): Remove.
41250         (vhsubq_x_n_s32): Remove.
41251         (vhsubq_x_n_u8): Remove.
41252         (vhsubq_x_n_u16): Remove.
41253         (vhsubq_x_n_u32): Remove.
41254         (vhsubq_x_s8): Remove.
41255         (vhsubq_x_s16): Remove.
41256         (vhsubq_x_s32): Remove.
41257         (vhsubq_x_u8): Remove.
41258         (vhsubq_x_u16): Remove.
41259         (vhsubq_x_u32): Remove.
41260         (__arm_vhsubq_u8): Remove.
41261         (__arm_vhsubq_n_u8): Remove.
41262         (__arm_vhaddq_u8): Remove.
41263         (__arm_vhaddq_n_u8): Remove.
41264         (__arm_vhsubq_s8): Remove.
41265         (__arm_vhsubq_n_s8): Remove.
41266         (__arm_vhaddq_s8): Remove.
41267         (__arm_vhaddq_n_s8): Remove.
41268         (__arm_vhsubq_u16): Remove.
41269         (__arm_vhsubq_n_u16): Remove.
41270         (__arm_vhaddq_u16): Remove.
41271         (__arm_vhaddq_n_u16): Remove.
41272         (__arm_vhsubq_s16): Remove.
41273         (__arm_vhsubq_n_s16): Remove.
41274         (__arm_vhaddq_s16): Remove.
41275         (__arm_vhaddq_n_s16): Remove.
41276         (__arm_vhsubq_u32): Remove.
41277         (__arm_vhsubq_n_u32): Remove.
41278         (__arm_vhaddq_u32): Remove.
41279         (__arm_vhaddq_n_u32): Remove.
41280         (__arm_vhsubq_s32): Remove.
41281         (__arm_vhsubq_n_s32): Remove.
41282         (__arm_vhaddq_s32): Remove.
41283         (__arm_vhaddq_n_s32): Remove.
41284         (__arm_vhaddq_m_n_s8): Remove.
41285         (__arm_vhaddq_m_n_s32): Remove.
41286         (__arm_vhaddq_m_n_s16): Remove.
41287         (__arm_vhaddq_m_n_u8): Remove.
41288         (__arm_vhaddq_m_n_u32): Remove.
41289         (__arm_vhaddq_m_n_u16): Remove.
41290         (__arm_vhaddq_m_s8): Remove.
41291         (__arm_vhaddq_m_s32): Remove.
41292         (__arm_vhaddq_m_s16): Remove.
41293         (__arm_vhaddq_m_u8): Remove.
41294         (__arm_vhaddq_m_u32): Remove.
41295         (__arm_vhaddq_m_u16): Remove.
41296         (__arm_vhsubq_m_n_s8): Remove.
41297         (__arm_vhsubq_m_n_s32): Remove.
41298         (__arm_vhsubq_m_n_s16): Remove.
41299         (__arm_vhsubq_m_n_u8): Remove.
41300         (__arm_vhsubq_m_n_u32): Remove.
41301         (__arm_vhsubq_m_n_u16): Remove.
41302         (__arm_vhsubq_m_s8): Remove.
41303         (__arm_vhsubq_m_s32): Remove.
41304         (__arm_vhsubq_m_s16): Remove.
41305         (__arm_vhsubq_m_u8): Remove.
41306         (__arm_vhsubq_m_u32): Remove.
41307         (__arm_vhsubq_m_u16): Remove.
41308         (__arm_vhaddq_x_n_s8): Remove.
41309         (__arm_vhaddq_x_n_s16): Remove.
41310         (__arm_vhaddq_x_n_s32): Remove.
41311         (__arm_vhaddq_x_n_u8): Remove.
41312         (__arm_vhaddq_x_n_u16): Remove.
41313         (__arm_vhaddq_x_n_u32): Remove.
41314         (__arm_vhaddq_x_s8): Remove.
41315         (__arm_vhaddq_x_s16): Remove.
41316         (__arm_vhaddq_x_s32): Remove.
41317         (__arm_vhaddq_x_u8): Remove.
41318         (__arm_vhaddq_x_u16): Remove.
41319         (__arm_vhaddq_x_u32): Remove.
41320         (__arm_vhsubq_x_n_s8): Remove.
41321         (__arm_vhsubq_x_n_s16): Remove.
41322         (__arm_vhsubq_x_n_s32): Remove.
41323         (__arm_vhsubq_x_n_u8): Remove.
41324         (__arm_vhsubq_x_n_u16): Remove.
41325         (__arm_vhsubq_x_n_u32): Remove.
41326         (__arm_vhsubq_x_s8): Remove.
41327         (__arm_vhsubq_x_s16): Remove.
41328         (__arm_vhsubq_x_s32): Remove.
41329         (__arm_vhsubq_x_u8): Remove.
41330         (__arm_vhsubq_x_u16): Remove.
41331         (__arm_vhsubq_x_u32): Remove.
41332         (__arm_vhsubq): Remove.
41333         (__arm_vhaddq): Remove.
41334         (__arm_vhaddq_m): Remove.
41335         (__arm_vhsubq_m): Remove.
41336         (__arm_vhaddq_x): Remove.
41337         (__arm_vhsubq_x): Remove.
41338         (vmulhq): Remove.
41339         (vmulhq_m): Remove.
41340         (vmulhq_x): Remove.
41341         (vmulhq_u8): Remove.
41342         (vmulhq_s8): Remove.
41343         (vmulhq_u16): Remove.
41344         (vmulhq_s16): Remove.
41345         (vmulhq_u32): Remove.
41346         (vmulhq_s32): Remove.
41347         (vmulhq_m_s8): Remove.
41348         (vmulhq_m_s32): Remove.
41349         (vmulhq_m_s16): Remove.
41350         (vmulhq_m_u8): Remove.
41351         (vmulhq_m_u32): Remove.
41352         (vmulhq_m_u16): Remove.
41353         (vmulhq_x_s8): Remove.
41354         (vmulhq_x_s16): Remove.
41355         (vmulhq_x_s32): Remove.
41356         (vmulhq_x_u8): Remove.
41357         (vmulhq_x_u16): Remove.
41358         (vmulhq_x_u32): Remove.
41359         (__arm_vmulhq_u8): Remove.
41360         (__arm_vmulhq_s8): Remove.
41361         (__arm_vmulhq_u16): Remove.
41362         (__arm_vmulhq_s16): Remove.
41363         (__arm_vmulhq_u32): Remove.
41364         (__arm_vmulhq_s32): Remove.
41365         (__arm_vmulhq_m_s8): Remove.
41366         (__arm_vmulhq_m_s32): Remove.
41367         (__arm_vmulhq_m_s16): Remove.
41368         (__arm_vmulhq_m_u8): Remove.
41369         (__arm_vmulhq_m_u32): Remove.
41370         (__arm_vmulhq_m_u16): Remove.
41371         (__arm_vmulhq_x_s8): Remove.
41372         (__arm_vmulhq_x_s16): Remove.
41373         (__arm_vmulhq_x_s32): Remove.
41374         (__arm_vmulhq_x_u8): Remove.
41375         (__arm_vmulhq_x_u16): Remove.
41376         (__arm_vmulhq_x_u32): Remove.
41377         (__arm_vmulhq): Remove.
41378         (__arm_vmulhq_m): Remove.
41379         (__arm_vmulhq_x): Remove.
41380         (vqsubq): Remove.
41381         (vqaddq): Remove.
41382         (vqaddq_m): Remove.
41383         (vqsubq_m): Remove.
41384         (vqsubq_u8): Remove.
41385         (vqsubq_n_u8): Remove.
41386         (vqaddq_u8): Remove.
41387         (vqaddq_n_u8): Remove.
41388         (vqsubq_s8): Remove.
41389         (vqsubq_n_s8): Remove.
41390         (vqaddq_s8): Remove.
41391         (vqaddq_n_s8): Remove.
41392         (vqsubq_u16): Remove.
41393         (vqsubq_n_u16): Remove.
41394         (vqaddq_u16): Remove.
41395         (vqaddq_n_u16): Remove.
41396         (vqsubq_s16): Remove.
41397         (vqsubq_n_s16): Remove.
41398         (vqaddq_s16): Remove.
41399         (vqaddq_n_s16): Remove.
41400         (vqsubq_u32): Remove.
41401         (vqsubq_n_u32): Remove.
41402         (vqaddq_u32): Remove.
41403         (vqaddq_n_u32): Remove.
41404         (vqsubq_s32): Remove.
41405         (vqsubq_n_s32): Remove.
41406         (vqaddq_s32): Remove.
41407         (vqaddq_n_s32): Remove.
41408         (vqaddq_m_n_s8): Remove.
41409         (vqaddq_m_n_s32): Remove.
41410         (vqaddq_m_n_s16): Remove.
41411         (vqaddq_m_n_u8): Remove.
41412         (vqaddq_m_n_u32): Remove.
41413         (vqaddq_m_n_u16): Remove.
41414         (vqaddq_m_s8): Remove.
41415         (vqaddq_m_s32): Remove.
41416         (vqaddq_m_s16): Remove.
41417         (vqaddq_m_u8): Remove.
41418         (vqaddq_m_u32): Remove.
41419         (vqaddq_m_u16): Remove.
41420         (vqsubq_m_n_s8): Remove.
41421         (vqsubq_m_n_s32): Remove.
41422         (vqsubq_m_n_s16): Remove.
41423         (vqsubq_m_n_u8): Remove.
41424         (vqsubq_m_n_u32): Remove.
41425         (vqsubq_m_n_u16): Remove.
41426         (vqsubq_m_s8): Remove.
41427         (vqsubq_m_s32): Remove.
41428         (vqsubq_m_s16): Remove.
41429         (vqsubq_m_u8): Remove.
41430         (vqsubq_m_u32): Remove.
41431         (vqsubq_m_u16): Remove.
41432         (__arm_vqsubq_u8): Remove.
41433         (__arm_vqsubq_n_u8): Remove.
41434         (__arm_vqaddq_u8): Remove.
41435         (__arm_vqaddq_n_u8): Remove.
41436         (__arm_vqsubq_s8): Remove.
41437         (__arm_vqsubq_n_s8): Remove.
41438         (__arm_vqaddq_s8): Remove.
41439         (__arm_vqaddq_n_s8): Remove.
41440         (__arm_vqsubq_u16): Remove.
41441         (__arm_vqsubq_n_u16): Remove.
41442         (__arm_vqaddq_u16): Remove.
41443         (__arm_vqaddq_n_u16): Remove.
41444         (__arm_vqsubq_s16): Remove.
41445         (__arm_vqsubq_n_s16): Remove.
41446         (__arm_vqaddq_s16): Remove.
41447         (__arm_vqaddq_n_s16): Remove.
41448         (__arm_vqsubq_u32): Remove.
41449         (__arm_vqsubq_n_u32): Remove.
41450         (__arm_vqaddq_u32): Remove.
41451         (__arm_vqaddq_n_u32): Remove.
41452         (__arm_vqsubq_s32): Remove.
41453         (__arm_vqsubq_n_s32): Remove.
41454         (__arm_vqaddq_s32): Remove.
41455         (__arm_vqaddq_n_s32): Remove.
41456         (__arm_vqaddq_m_n_s8): Remove.
41457         (__arm_vqaddq_m_n_s32): Remove.
41458         (__arm_vqaddq_m_n_s16): Remove.
41459         (__arm_vqaddq_m_n_u8): Remove.
41460         (__arm_vqaddq_m_n_u32): Remove.
41461         (__arm_vqaddq_m_n_u16): Remove.
41462         (__arm_vqaddq_m_s8): Remove.
41463         (__arm_vqaddq_m_s32): Remove.
41464         (__arm_vqaddq_m_s16): Remove.
41465         (__arm_vqaddq_m_u8): Remove.
41466         (__arm_vqaddq_m_u32): Remove.
41467         (__arm_vqaddq_m_u16): Remove.
41468         (__arm_vqsubq_m_n_s8): Remove.
41469         (__arm_vqsubq_m_n_s32): Remove.
41470         (__arm_vqsubq_m_n_s16): Remove.
41471         (__arm_vqsubq_m_n_u8): Remove.
41472         (__arm_vqsubq_m_n_u32): Remove.
41473         (__arm_vqsubq_m_n_u16): Remove.
41474         (__arm_vqsubq_m_s8): Remove.
41475         (__arm_vqsubq_m_s32): Remove.
41476         (__arm_vqsubq_m_s16): Remove.
41477         (__arm_vqsubq_m_u8): Remove.
41478         (__arm_vqsubq_m_u32): Remove.
41479         (__arm_vqsubq_m_u16): Remove.
41480         (__arm_vqsubq): Remove.
41481         (__arm_vqaddq): Remove.
41482         (__arm_vqaddq_m): Remove.
41483         (__arm_vqsubq_m): Remove.
41484         (vqdmulhq): Remove.
41485         (vqdmulhq_m): Remove.
41486         (vqdmulhq_s8): Remove.
41487         (vqdmulhq_n_s8): Remove.
41488         (vqdmulhq_s16): Remove.
41489         (vqdmulhq_n_s16): Remove.
41490         (vqdmulhq_s32): Remove.
41491         (vqdmulhq_n_s32): Remove.
41492         (vqdmulhq_m_n_s8): Remove.
41493         (vqdmulhq_m_n_s32): Remove.
41494         (vqdmulhq_m_n_s16): Remove.
41495         (vqdmulhq_m_s8): Remove.
41496         (vqdmulhq_m_s32): Remove.
41497         (vqdmulhq_m_s16): Remove.
41498         (__arm_vqdmulhq_s8): Remove.
41499         (__arm_vqdmulhq_n_s8): Remove.
41500         (__arm_vqdmulhq_s16): Remove.
41501         (__arm_vqdmulhq_n_s16): Remove.
41502         (__arm_vqdmulhq_s32): Remove.
41503         (__arm_vqdmulhq_n_s32): Remove.
41504         (__arm_vqdmulhq_m_n_s8): Remove.
41505         (__arm_vqdmulhq_m_n_s32): Remove.
41506         (__arm_vqdmulhq_m_n_s16): Remove.
41507         (__arm_vqdmulhq_m_s8): Remove.
41508         (__arm_vqdmulhq_m_s32): Remove.
41509         (__arm_vqdmulhq_m_s16): Remove.
41510         (__arm_vqdmulhq): Remove.
41511         (__arm_vqdmulhq_m): Remove.
41512         (vrhaddq): Remove.
41513         (vrhaddq_m): Remove.
41514         (vrhaddq_x): Remove.
41515         (vrhaddq_u8): Remove.
41516         (vrhaddq_s8): Remove.
41517         (vrhaddq_u16): Remove.
41518         (vrhaddq_s16): Remove.
41519         (vrhaddq_u32): Remove.
41520         (vrhaddq_s32): Remove.
41521         (vrhaddq_m_s8): Remove.
41522         (vrhaddq_m_s32): Remove.
41523         (vrhaddq_m_s16): Remove.
41524         (vrhaddq_m_u8): Remove.
41525         (vrhaddq_m_u32): Remove.
41526         (vrhaddq_m_u16): Remove.
41527         (vrhaddq_x_s8): Remove.
41528         (vrhaddq_x_s16): Remove.
41529         (vrhaddq_x_s32): Remove.
41530         (vrhaddq_x_u8): Remove.
41531         (vrhaddq_x_u16): Remove.
41532         (vrhaddq_x_u32): Remove.
41533         (__arm_vrhaddq_u8): Remove.
41534         (__arm_vrhaddq_s8): Remove.
41535         (__arm_vrhaddq_u16): Remove.
41536         (__arm_vrhaddq_s16): Remove.
41537         (__arm_vrhaddq_u32): Remove.
41538         (__arm_vrhaddq_s32): Remove.
41539         (__arm_vrhaddq_m_s8): Remove.
41540         (__arm_vrhaddq_m_s32): Remove.
41541         (__arm_vrhaddq_m_s16): Remove.
41542         (__arm_vrhaddq_m_u8): Remove.
41543         (__arm_vrhaddq_m_u32): Remove.
41544         (__arm_vrhaddq_m_u16): Remove.
41545         (__arm_vrhaddq_x_s8): Remove.
41546         (__arm_vrhaddq_x_s16): Remove.
41547         (__arm_vrhaddq_x_s32): Remove.
41548         (__arm_vrhaddq_x_u8): Remove.
41549         (__arm_vrhaddq_x_u16): Remove.
41550         (__arm_vrhaddq_x_u32): Remove.
41551         (__arm_vrhaddq): Remove.
41552         (__arm_vrhaddq_m): Remove.
41553         (__arm_vrhaddq_x): Remove.
41554         (vrmulhq): Remove.
41555         (vrmulhq_m): Remove.
41556         (vrmulhq_x): Remove.
41557         (vrmulhq_u8): Remove.
41558         (vrmulhq_s8): Remove.
41559         (vrmulhq_u16): Remove.
41560         (vrmulhq_s16): Remove.
41561         (vrmulhq_u32): Remove.
41562         (vrmulhq_s32): Remove.
41563         (vrmulhq_m_s8): Remove.
41564         (vrmulhq_m_s32): Remove.
41565         (vrmulhq_m_s16): Remove.
41566         (vrmulhq_m_u8): Remove.
41567         (vrmulhq_m_u32): Remove.
41568         (vrmulhq_m_u16): Remove.
41569         (vrmulhq_x_s8): Remove.
41570         (vrmulhq_x_s16): Remove.
41571         (vrmulhq_x_s32): Remove.
41572         (vrmulhq_x_u8): Remove.
41573         (vrmulhq_x_u16): Remove.
41574         (vrmulhq_x_u32): Remove.
41575         (__arm_vrmulhq_u8): Remove.
41576         (__arm_vrmulhq_s8): Remove.
41577         (__arm_vrmulhq_u16): Remove.
41578         (__arm_vrmulhq_s16): Remove.
41579         (__arm_vrmulhq_u32): Remove.
41580         (__arm_vrmulhq_s32): Remove.
41581         (__arm_vrmulhq_m_s8): Remove.
41582         (__arm_vrmulhq_m_s32): Remove.
41583         (__arm_vrmulhq_m_s16): Remove.
41584         (__arm_vrmulhq_m_u8): Remove.
41585         (__arm_vrmulhq_m_u32): Remove.
41586         (__arm_vrmulhq_m_u16): Remove.
41587         (__arm_vrmulhq_x_s8): Remove.
41588         (__arm_vrmulhq_x_s16): Remove.
41589         (__arm_vrmulhq_x_s32): Remove.
41590         (__arm_vrmulhq_x_u8): Remove.
41591         (__arm_vrmulhq_x_u16): Remove.
41592         (__arm_vrmulhq_x_u32): Remove.
41593         (__arm_vrmulhq): Remove.
41594         (__arm_vrmulhq_m): Remove.
41595         (__arm_vrmulhq_x): Remove.
41597 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41599         * config/arm/iterators.md (MVE_INT_SU_BINARY): New.
41600         (mve_insn): Add vabdq, vhaddq, vhsubq, vmulhq, vqaddq, vqdmulhq,
41601         vqrdmulhq, vqrshlq, vqshlq, vqsubq, vrhaddq, vrmulhq, vrshlq.
41602         (supf): Add VQDMULHQ_S, VQRDMULHQ_S.
41603         * config/arm/mve.md (mve_vabdq_<supf><mode>)
41604         (@mve_vhaddq_<supf><mode>, mve_vhsubq_<supf><mode>)
41605         (mve_vmulhq_<supf><mode>, mve_vqaddq_<supf><mode>)
41606         (mve_vqdmulhq_s<mode>, mve_vqrdmulhq_s<mode>)
41607         (mve_vqrshlq_<supf><mode>, mve_vqshlq_<supf><mode>)
41608         (mve_vqsubq_<supf><mode>, @mve_vrhaddq_<supf><mode>)
41609         (mve_vrmulhq_<supf><mode>, mve_vrshlq_<supf><mode>): Merge into
41610         ...
41611         (@mve_<mve_insn>q_<supf><mode>): ... this.
41612         * config/arm/vec-common.md (avg<mode>3_floor, uavg<mode>3_floor)
41613         (avg<mode>3_ceil, uavg<mode>3_ceil): Use gen_mve_q instead of
41614         gen_mve_vhaddq / gen_mve_vrhaddq.
41616 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41618         * config/arm/iterators.md (MVE_INT_SU_M_N_BINARY): New.
41619         (mve_insn): Add vhaddq, vhsubq, vmlaq, vmlasq, vqaddq, vqdmlahq,
41620         vqdmlashq, vqdmulhq, vqrdmlahq, vqrdmlashq, vqrdmulhq, vqsubq.
41621         (supf): Add VQDMLAHQ_M_N_S, VQDMLASHQ_M_N_S, VQRDMLAHQ_M_N_S,
41622         VQRDMLASHQ_M_N_S, VQDMULHQ_M_N_S, VQRDMULHQ_M_N_S.
41623         * config/arm/mve.md (mve_vhaddq_m_n_<supf><mode>)
41624         (mve_vhsubq_m_n_<supf><mode>, mve_vmlaq_m_n_<supf><mode>)
41625         (mve_vmlasq_m_n_<supf><mode>, mve_vqaddq_m_n_<supf><mode>)
41626         (mve_vqdmlahq_m_n_s<mode>, mve_vqdmlashq_m_n_s<mode>)
41627         (mve_vqrdmlahq_m_n_s<mode>, mve_vqrdmlashq_m_n_s<mode>)
41628         (mve_vqsubq_m_n_<supf><mode>, mve_vqdmulhq_m_n_s<mode>)
41629         (mve_vqrdmulhq_m_n_s<mode>): Merge into ...
41630         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
41632 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41634         * config/arm/iterators.md (MVE_INT_SU_N_BINARY): New.
41635         (mve_insn): Add vhaddq, vhsubq, vqaddq, vqdmulhq, vqrdmulhq,
41636         vqsubq.
41637         (supf): Add VQDMULHQ_N_S, VQRDMULHQ_N_S.
41638         * config/arm/mve.md (mve_vhaddq_n_<supf><mode>)
41639         (mve_vhsubq_n_<supf><mode>, mve_vqaddq_n_<supf><mode>)
41640         (mve_vqdmulhq_n_s<mode>, mve_vqrdmulhq_n_s<mode>)
41641         (mve_vqsubq_n_<supf><mode>): Merge into ...
41642         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
41644 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41646         * config/arm/iterators.md (MVE_INT_SU_M_BINARY): New.
41647         (mve_insn): Add vabdq, vhaddq, vhsubq, vmaxq, vminq, vmulhq,
41648         vqaddq, vqdmladhq, vqdmladhxq, vqdmlsdhq, vqdmlsdhxq, vqdmulhq,
41649         vqrdmladhq, vqrdmladhxq, vqrdmlsdhq, vqrdmlsdhxq, vqrdmulhq,
41650         vqrshlq, vqshlq, vqsubq, vrhaddq, vrmulhq, vrshlq, vshlq.
41651         (supf): Add VQDMLADHQ_M_S, VQDMLADHXQ_M_S, VQDMLSDHQ_M_S,
41652         VQDMLSDHXQ_M_S, VQDMULHQ_M_S, VQRDMLADHQ_M_S, VQRDMLADHXQ_M_S,
41653         VQRDMLSDHQ_M_S, VQRDMLSDHXQ_M_S, VQRDMULHQ_M_S.
41654         * config/arm/mve.md (@mve_<mve_insn>q_m_<supf><mode>): New.
41655         (mve_vshlq_m_<supf><mode>): Merged into
41656         @mve_<mve_insn>q_m_<supf><mode>.
41657         (mve_vabdq_m_<supf><mode>): Likewise.
41658         (mve_vhaddq_m_<supf><mode>): Likewise.
41659         (mve_vhsubq_m_<supf><mode>): Likewise.
41660         (mve_vmaxq_m_<supf><mode>): Likewise.
41661         (mve_vminq_m_<supf><mode>): Likewise.
41662         (mve_vmulhq_m_<supf><mode>): Likewise.
41663         (mve_vqaddq_m_<supf><mode>): Likewise.
41664         (mve_vqrshlq_m_<supf><mode>): Likewise.
41665         (mve_vqshlq_m_<supf><mode>): Likewise.
41666         (mve_vqsubq_m_<supf><mode>): Likewise.
41667         (mve_vrhaddq_m_<supf><mode>): Likewise.
41668         (mve_vrmulhq_m_<supf><mode>): Likewise.
41669         (mve_vrshlq_m_<supf><mode>): Likewise.
41670         (mve_vqdmladhq_m_s<mode>): Likewise.
41671         (mve_vqdmladhxq_m_s<mode>): Likewise.
41672         (mve_vqdmlsdhq_m_s<mode>): Likewise.
41673         (mve_vqdmlsdhxq_m_s<mode>): Likewise.
41674         (mve_vqdmulhq_m_s<mode>): Likewise.
41675         (mve_vqrdmladhq_m_s<mode>): Likewise.
41676         (mve_vqrdmladhxq_m_s<mode>): Likewise.
41677         (mve_vqrdmlsdhq_m_s<mode>): Likewise.
41678         (mve_vqrdmlsdhxq_m_s<mode>): Likewise.
41679         (mve_vqrdmulhq_m_s<mode>): Likewise.
41681 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41683         * config/arm/arm-mve-builtins-base.cc (FUNCTION_WITHOUT_M_N): New. (vcreateq): New.
41684         * config/arm/arm-mve-builtins-base.def (vcreateq): New.
41685         * config/arm/arm-mve-builtins-base.h (vcreateq): New.
41686         * config/arm/arm_mve.h (vcreateq_f16): Remove.
41687         (vcreateq_f32): Remove.
41688         (vcreateq_u8): Remove.
41689         (vcreateq_u16): Remove.
41690         (vcreateq_u32): Remove.
41691         (vcreateq_u64): Remove.
41692         (vcreateq_s8): Remove.
41693         (vcreateq_s16): Remove.
41694         (vcreateq_s32): Remove.
41695         (vcreateq_s64): Remove.
41696         (__arm_vcreateq_u8): Remove.
41697         (__arm_vcreateq_u16): Remove.
41698         (__arm_vcreateq_u32): Remove.
41699         (__arm_vcreateq_u64): Remove.
41700         (__arm_vcreateq_s8): Remove.
41701         (__arm_vcreateq_s16): Remove.
41702         (__arm_vcreateq_s32): Remove.
41703         (__arm_vcreateq_s64): Remove.
41704         (__arm_vcreateq_f16): Remove.
41705         (__arm_vcreateq_f32): Remove.
41707 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41709         * config/arm/iterators.md (MVE_FP_CREATE_ONLY): New.
41710         (mve_insn): Add VCREATEQ_S, VCREATEQ_U, VCREATEQ_F.
41711         * config/arm/mve.md (mve_vcreateq_f<mode>): Rename into ...
41712         (@mve_<mve_insn>q_f<mode>): ... this.
41713         (mve_vcreateq_<supf><mode>): Rename into ...
41714         (@mve_<mve_insn>q_<supf><mode>): ... this.
41716 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41718         * config/arm/arm-mve-builtins-shapes.cc (create): New.
41719         * config/arm/arm-mve-builtins-shapes.h: (create): New.
41721 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41723         * config/arm/arm-mve-builtins-functions.h (class
41724         unspec_mve_function_exact_insn): New.
41726 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41728         * config/arm/arm-mve-builtins-base.cc (FUNCTION_WITH_RTX_M_N_NO_N_F): New.
41729         (vorrq): New.
41730         * config/arm/arm-mve-builtins-base.def (vorrq): New.
41731         * config/arm/arm-mve-builtins-base.h (vorrq): New.
41732         * config/arm/arm-mve-builtins.cc
41733         (function_instance::has_inactive_argument): Handle vorrq.
41734         * config/arm/arm_mve.h (vorrq): Remove.
41735         (vorrq_m_n): Remove.
41736         (vorrq_m): Remove.
41737         (vorrq_x): Remove.
41738         (vorrq_u8): Remove.
41739         (vorrq_s8): Remove.
41740         (vorrq_u16): Remove.
41741         (vorrq_s16): Remove.
41742         (vorrq_u32): Remove.
41743         (vorrq_s32): Remove.
41744         (vorrq_n_u16): Remove.
41745         (vorrq_f16): Remove.
41746         (vorrq_n_s16): Remove.
41747         (vorrq_n_u32): Remove.
41748         (vorrq_f32): Remove.
41749         (vorrq_n_s32): Remove.
41750         (vorrq_m_n_s16): Remove.
41751         (vorrq_m_n_u16): Remove.
41752         (vorrq_m_n_s32): Remove.
41753         (vorrq_m_n_u32): Remove.
41754         (vorrq_m_s8): Remove.
41755         (vorrq_m_s32): Remove.
41756         (vorrq_m_s16): Remove.
41757         (vorrq_m_u8): Remove.
41758         (vorrq_m_u32): Remove.
41759         (vorrq_m_u16): Remove.
41760         (vorrq_m_f32): Remove.
41761         (vorrq_m_f16): Remove.
41762         (vorrq_x_s8): Remove.
41763         (vorrq_x_s16): Remove.
41764         (vorrq_x_s32): Remove.
41765         (vorrq_x_u8): Remove.
41766         (vorrq_x_u16): Remove.
41767         (vorrq_x_u32): Remove.
41768         (vorrq_x_f16): Remove.
41769         (vorrq_x_f32): Remove.
41770         (__arm_vorrq_u8): Remove.
41771         (__arm_vorrq_s8): Remove.
41772         (__arm_vorrq_u16): Remove.
41773         (__arm_vorrq_s16): Remove.
41774         (__arm_vorrq_u32): Remove.
41775         (__arm_vorrq_s32): Remove.
41776         (__arm_vorrq_n_u16): Remove.
41777         (__arm_vorrq_n_s16): Remove.
41778         (__arm_vorrq_n_u32): Remove.
41779         (__arm_vorrq_n_s32): Remove.
41780         (__arm_vorrq_m_n_s16): Remove.
41781         (__arm_vorrq_m_n_u16): Remove.
41782         (__arm_vorrq_m_n_s32): Remove.
41783         (__arm_vorrq_m_n_u32): Remove.
41784         (__arm_vorrq_m_s8): Remove.
41785         (__arm_vorrq_m_s32): Remove.
41786         (__arm_vorrq_m_s16): Remove.
41787         (__arm_vorrq_m_u8): Remove.
41788         (__arm_vorrq_m_u32): Remove.
41789         (__arm_vorrq_m_u16): Remove.
41790         (__arm_vorrq_x_s8): Remove.
41791         (__arm_vorrq_x_s16): Remove.
41792         (__arm_vorrq_x_s32): Remove.
41793         (__arm_vorrq_x_u8): Remove.
41794         (__arm_vorrq_x_u16): Remove.
41795         (__arm_vorrq_x_u32): Remove.
41796         (__arm_vorrq_f16): Remove.
41797         (__arm_vorrq_f32): Remove.
41798         (__arm_vorrq_m_f32): Remove.
41799         (__arm_vorrq_m_f16): Remove.
41800         (__arm_vorrq_x_f16): Remove.
41801         (__arm_vorrq_x_f32): Remove.
41802         (__arm_vorrq): Remove.
41803         (__arm_vorrq_m_n): Remove.
41804         (__arm_vorrq_m): Remove.
41805         (__arm_vorrq_x): Remove.
41807 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41809         * config/arm/arm-mve-builtins-shapes.cc (binary_orrq): New.
41810         * config/arm/arm-mve-builtins-shapes.h (binary_orrq): New.
41811         * config/arm/arm-mve-builtins.cc (preds_m_or_none): Remove static.
41812         * config/arm/arm-mve-builtins.h (preds_m_or_none): Declare.
41814 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41816         * config/arm/arm-mve-builtins-base.cc (FUNCTION_WITH_RTX_M): New.
41817         (vandq,veorq): New.
41818         * config/arm/arm-mve-builtins-base.def (vandq, veorq): New.
41819         * config/arm/arm-mve-builtins-base.h (vandq, veorq): New.
41820         * config/arm/arm_mve.h (vandq): Remove.
41821         (vandq_m): Remove.
41822         (vandq_x): Remove.
41823         (vandq_u8): Remove.
41824         (vandq_s8): Remove.
41825         (vandq_u16): Remove.
41826         (vandq_s16): Remove.
41827         (vandq_u32): Remove.
41828         (vandq_s32): Remove.
41829         (vandq_f16): Remove.
41830         (vandq_f32): Remove.
41831         (vandq_m_s8): Remove.
41832         (vandq_m_s32): Remove.
41833         (vandq_m_s16): Remove.
41834         (vandq_m_u8): Remove.
41835         (vandq_m_u32): Remove.
41836         (vandq_m_u16): Remove.
41837         (vandq_m_f32): Remove.
41838         (vandq_m_f16): Remove.
41839         (vandq_x_s8): Remove.
41840         (vandq_x_s16): Remove.
41841         (vandq_x_s32): Remove.
41842         (vandq_x_u8): Remove.
41843         (vandq_x_u16): Remove.
41844         (vandq_x_u32): Remove.
41845         (vandq_x_f16): Remove.
41846         (vandq_x_f32): Remove.
41847         (__arm_vandq_u8): Remove.
41848         (__arm_vandq_s8): Remove.
41849         (__arm_vandq_u16): Remove.
41850         (__arm_vandq_s16): Remove.
41851         (__arm_vandq_u32): Remove.
41852         (__arm_vandq_s32): Remove.
41853         (__arm_vandq_m_s8): Remove.
41854         (__arm_vandq_m_s32): Remove.
41855         (__arm_vandq_m_s16): Remove.
41856         (__arm_vandq_m_u8): Remove.
41857         (__arm_vandq_m_u32): Remove.
41858         (__arm_vandq_m_u16): Remove.
41859         (__arm_vandq_x_s8): Remove.
41860         (__arm_vandq_x_s16): Remove.
41861         (__arm_vandq_x_s32): Remove.
41862         (__arm_vandq_x_u8): Remove.
41863         (__arm_vandq_x_u16): Remove.
41864         (__arm_vandq_x_u32): Remove.
41865         (__arm_vandq_f16): Remove.
41866         (__arm_vandq_f32): Remove.
41867         (__arm_vandq_m_f32): Remove.
41868         (__arm_vandq_m_f16): Remove.
41869         (__arm_vandq_x_f16): Remove.
41870         (__arm_vandq_x_f32): Remove.
41871         (__arm_vandq): Remove.
41872         (__arm_vandq_m): Remove.
41873         (__arm_vandq_x): Remove.
41874         (veorq_m): Remove.
41875         (veorq_x): Remove.
41876         (veorq_u8): Remove.
41877         (veorq_s8): Remove.
41878         (veorq_u16): Remove.
41879         (veorq_s16): Remove.
41880         (veorq_u32): Remove.
41881         (veorq_s32): Remove.
41882         (veorq_f16): Remove.
41883         (veorq_f32): Remove.
41884         (veorq_m_s8): Remove.
41885         (veorq_m_s32): Remove.
41886         (veorq_m_s16): Remove.
41887         (veorq_m_u8): Remove.
41888         (veorq_m_u32): Remove.
41889         (veorq_m_u16): Remove.
41890         (veorq_m_f32): Remove.
41891         (veorq_m_f16): Remove.
41892         (veorq_x_s8): Remove.
41893         (veorq_x_s16): Remove.
41894         (veorq_x_s32): Remove.
41895         (veorq_x_u8): Remove.
41896         (veorq_x_u16): Remove.
41897         (veorq_x_u32): Remove.
41898         (veorq_x_f16): Remove.
41899         (veorq_x_f32): Remove.
41900         (__arm_veorq_u8): Remove.
41901         (__arm_veorq_s8): Remove.
41902         (__arm_veorq_u16): Remove.
41903         (__arm_veorq_s16): Remove.
41904         (__arm_veorq_u32): Remove.
41905         (__arm_veorq_s32): Remove.
41906         (__arm_veorq_m_s8): Remove.
41907         (__arm_veorq_m_s32): Remove.
41908         (__arm_veorq_m_s16): Remove.
41909         (__arm_veorq_m_u8): Remove.
41910         (__arm_veorq_m_u32): Remove.
41911         (__arm_veorq_m_u16): Remove.
41912         (__arm_veorq_x_s8): Remove.
41913         (__arm_veorq_x_s16): Remove.
41914         (__arm_veorq_x_s32): Remove.
41915         (__arm_veorq_x_u8): Remove.
41916         (__arm_veorq_x_u16): Remove.
41917         (__arm_veorq_x_u32): Remove.
41918         (__arm_veorq_f16): Remove.
41919         (__arm_veorq_f32): Remove.
41920         (__arm_veorq_m_f32): Remove.
41921         (__arm_veorq_m_f16): Remove.
41922         (__arm_veorq_x_f16): Remove.
41923         (__arm_veorq_x_f32): Remove.
41924         (__arm_veorq): Remove.
41925         (__arm_veorq_m): Remove.
41926         (__arm_veorq_x): Remove.
41928 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41930         * config/arm/iterators.md (MVE_INT_M_BINARY_LOGIC)
41931         (MVE_FP_M_BINARY_LOGIC): New.
41932         (MVE_INT_M_N_BINARY_LOGIC): New.
41933         (MVE_INT_N_BINARY_LOGIC): New.
41934         (mve_insn): Add vand, veor, vorr, vbic.
41935         * config/arm/mve.md (mve_vandq_m_<supf><mode>)
41936         (mve_veorq_m_<supf><mode>, mve_vorrq_m_<supf><mode>)
41937         (mve_vbicq_m_<supf><mode>): Merge into ...
41938         (@mve_<mve_insn>q_m_<supf><mode>): ... this.
41939         (mve_vandq_m_f<mode>, mve_veorq_m_f<mode>, mve_vorrq_m_f<mode>)
41940         (mve_vbicq_m_f<mode>): Merge into ...
41941         (@mve_<mve_insn>q_m_f<mode>): ... this.
41942         (mve_vorrq_n_<supf><mode>)
41943         (mve_vbicq_n_<supf><mode>): Merge into ...
41944         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
41945         (mve_vorrq_m_n_<supf><mode>, mve_vbicq_m_n_<supf><mode>): Merge
41946         into ...
41947         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
41949 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41951         * config/arm/arm-mve-builtins-shapes.cc (binary): New.
41952         * config/arm/arm-mve-builtins-shapes.h (binary): New.
41954 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
41956         * config/arm/arm-mve-builtins-base.cc (FUNCTION_WITH_RTX_M_N):
41957         New.
41958         (vaddq, vmulq, vsubq): New.
41959         * config/arm/arm-mve-builtins-base.def (vaddq, vmulq, vsubq): New.
41960         * config/arm/arm-mve-builtins-base.h (vaddq, vmulq, vsubq): New.
41961         * config/arm/arm_mve.h (vaddq): Remove.
41962         (vaddq_m): Remove.
41963         (vaddq_x): Remove.
41964         (vaddq_n_u8): Remove.
41965         (vaddq_n_s8): Remove.
41966         (vaddq_n_u16): Remove.
41967         (vaddq_n_s16): Remove.
41968         (vaddq_n_u32): Remove.
41969         (vaddq_n_s32): Remove.
41970         (vaddq_n_f16): Remove.
41971         (vaddq_n_f32): Remove.
41972         (vaddq_m_n_s8): Remove.
41973         (vaddq_m_n_s32): Remove.
41974         (vaddq_m_n_s16): Remove.
41975         (vaddq_m_n_u8): Remove.
41976         (vaddq_m_n_u32): Remove.
41977         (vaddq_m_n_u16): Remove.
41978         (vaddq_m_s8): Remove.
41979         (vaddq_m_s32): Remove.
41980         (vaddq_m_s16): Remove.
41981         (vaddq_m_u8): Remove.
41982         (vaddq_m_u32): Remove.
41983         (vaddq_m_u16): Remove.
41984         (vaddq_m_f32): Remove.
41985         (vaddq_m_f16): Remove.
41986         (vaddq_m_n_f32): Remove.
41987         (vaddq_m_n_f16): Remove.
41988         (vaddq_s8): Remove.
41989         (vaddq_s16): Remove.
41990         (vaddq_s32): Remove.
41991         (vaddq_u8): Remove.
41992         (vaddq_u16): Remove.
41993         (vaddq_u32): Remove.
41994         (vaddq_f16): Remove.
41995         (vaddq_f32): Remove.
41996         (vaddq_x_s8): Remove.
41997         (vaddq_x_s16): Remove.
41998         (vaddq_x_s32): Remove.
41999         (vaddq_x_n_s8): Remove.
42000         (vaddq_x_n_s16): Remove.
42001         (vaddq_x_n_s32): Remove.
42002         (vaddq_x_u8): Remove.
42003         (vaddq_x_u16): Remove.
42004         (vaddq_x_u32): Remove.
42005         (vaddq_x_n_u8): Remove.
42006         (vaddq_x_n_u16): Remove.
42007         (vaddq_x_n_u32): Remove.
42008         (vaddq_x_f16): Remove.
42009         (vaddq_x_f32): Remove.
42010         (vaddq_x_n_f16): Remove.
42011         (vaddq_x_n_f32): Remove.
42012         (__arm_vaddq_n_u8): Remove.
42013         (__arm_vaddq_n_s8): Remove.
42014         (__arm_vaddq_n_u16): Remove.
42015         (__arm_vaddq_n_s16): Remove.
42016         (__arm_vaddq_n_u32): Remove.
42017         (__arm_vaddq_n_s32): Remove.
42018         (__arm_vaddq_m_n_s8): Remove.
42019         (__arm_vaddq_m_n_s32): Remove.
42020         (__arm_vaddq_m_n_s16): Remove.
42021         (__arm_vaddq_m_n_u8): Remove.
42022         (__arm_vaddq_m_n_u32): Remove.
42023         (__arm_vaddq_m_n_u16): Remove.
42024         (__arm_vaddq_m_s8): Remove.
42025         (__arm_vaddq_m_s32): Remove.
42026         (__arm_vaddq_m_s16): Remove.
42027         (__arm_vaddq_m_u8): Remove.
42028         (__arm_vaddq_m_u32): Remove.
42029         (__arm_vaddq_m_u16): Remove.
42030         (__arm_vaddq_s8): Remove.
42031         (__arm_vaddq_s16): Remove.
42032         (__arm_vaddq_s32): Remove.
42033         (__arm_vaddq_u8): Remove.
42034         (__arm_vaddq_u16): Remove.
42035         (__arm_vaddq_u32): Remove.
42036         (__arm_vaddq_x_s8): Remove.
42037         (__arm_vaddq_x_s16): Remove.
42038         (__arm_vaddq_x_s32): Remove.
42039         (__arm_vaddq_x_n_s8): Remove.
42040         (__arm_vaddq_x_n_s16): Remove.
42041         (__arm_vaddq_x_n_s32): Remove.
42042         (__arm_vaddq_x_u8): Remove.
42043         (__arm_vaddq_x_u16): Remove.
42044         (__arm_vaddq_x_u32): Remove.
42045         (__arm_vaddq_x_n_u8): Remove.
42046         (__arm_vaddq_x_n_u16): Remove.
42047         (__arm_vaddq_x_n_u32): Remove.
42048         (__arm_vaddq_n_f16): Remove.
42049         (__arm_vaddq_n_f32): Remove.
42050         (__arm_vaddq_m_f32): Remove.
42051         (__arm_vaddq_m_f16): Remove.
42052         (__arm_vaddq_m_n_f32): Remove.
42053         (__arm_vaddq_m_n_f16): Remove.
42054         (__arm_vaddq_f16): Remove.
42055         (__arm_vaddq_f32): Remove.
42056         (__arm_vaddq_x_f16): Remove.
42057         (__arm_vaddq_x_f32): Remove.
42058         (__arm_vaddq_x_n_f16): Remove.
42059         (__arm_vaddq_x_n_f32): Remove.
42060         (__arm_vaddq): Remove.
42061         (__arm_vaddq_m): Remove.
42062         (__arm_vaddq_x): Remove.
42063         (vmulq): Remove.
42064         (vmulq_m): Remove.
42065         (vmulq_x): Remove.
42066         (vmulq_u8): Remove.
42067         (vmulq_n_u8): Remove.
42068         (vmulq_s8): Remove.
42069         (vmulq_n_s8): Remove.
42070         (vmulq_u16): Remove.
42071         (vmulq_n_u16): Remove.
42072         (vmulq_s16): Remove.
42073         (vmulq_n_s16): Remove.
42074         (vmulq_u32): Remove.
42075         (vmulq_n_u32): Remove.
42076         (vmulq_s32): Remove.
42077         (vmulq_n_s32): Remove.
42078         (vmulq_n_f16): Remove.
42079         (vmulq_f16): Remove.
42080         (vmulq_n_f32): Remove.
42081         (vmulq_f32): Remove.
42082         (vmulq_m_n_s8): Remove.
42083         (vmulq_m_n_s32): Remove.
42084         (vmulq_m_n_s16): Remove.
42085         (vmulq_m_n_u8): Remove.
42086         (vmulq_m_n_u32): Remove.
42087         (vmulq_m_n_u16): Remove.
42088         (vmulq_m_s8): Remove.
42089         (vmulq_m_s32): Remove.
42090         (vmulq_m_s16): Remove.
42091         (vmulq_m_u8): Remove.
42092         (vmulq_m_u32): Remove.
42093         (vmulq_m_u16): Remove.
42094         (vmulq_m_f32): Remove.
42095         (vmulq_m_f16): Remove.
42096         (vmulq_m_n_f32): Remove.
42097         (vmulq_m_n_f16): Remove.
42098         (vmulq_x_s8): Remove.
42099         (vmulq_x_s16): Remove.
42100         (vmulq_x_s32): Remove.
42101         (vmulq_x_n_s8): Remove.
42102         (vmulq_x_n_s16): Remove.
42103         (vmulq_x_n_s32): Remove.
42104         (vmulq_x_u8): Remove.
42105         (vmulq_x_u16): Remove.
42106         (vmulq_x_u32): Remove.
42107         (vmulq_x_n_u8): Remove.
42108         (vmulq_x_n_u16): Remove.
42109         (vmulq_x_n_u32): Remove.
42110         (vmulq_x_f16): Remove.
42111         (vmulq_x_f32): Remove.
42112         (vmulq_x_n_f16): Remove.
42113         (vmulq_x_n_f32): Remove.
42114         (__arm_vmulq_u8): Remove.
42115         (__arm_vmulq_n_u8): Remove.
42116         (__arm_vmulq_s8): Remove.
42117         (__arm_vmulq_n_s8): Remove.
42118         (__arm_vmulq_u16): Remove.
42119         (__arm_vmulq_n_u16): Remove.
42120         (__arm_vmulq_s16): Remove.
42121         (__arm_vmulq_n_s16): Remove.
42122         (__arm_vmulq_u32): Remove.
42123         (__arm_vmulq_n_u32): Remove.
42124         (__arm_vmulq_s32): Remove.
42125         (__arm_vmulq_n_s32): Remove.
42126         (__arm_vmulq_m_n_s8): Remove.
42127         (__arm_vmulq_m_n_s32): Remove.
42128         (__arm_vmulq_m_n_s16): Remove.
42129         (__arm_vmulq_m_n_u8): Remove.
42130         (__arm_vmulq_m_n_u32): Remove.
42131         (__arm_vmulq_m_n_u16): Remove.
42132         (__arm_vmulq_m_s8): Remove.
42133         (__arm_vmulq_m_s32): Remove.
42134         (__arm_vmulq_m_s16): Remove.
42135         (__arm_vmulq_m_u8): Remove.
42136         (__arm_vmulq_m_u32): Remove.
42137         (__arm_vmulq_m_u16): Remove.
42138         (__arm_vmulq_x_s8): Remove.
42139         (__arm_vmulq_x_s16): Remove.
42140         (__arm_vmulq_x_s32): Remove.
42141         (__arm_vmulq_x_n_s8): Remove.
42142         (__arm_vmulq_x_n_s16): Remove.
42143         (__arm_vmulq_x_n_s32): Remove.
42144         (__arm_vmulq_x_u8): Remove.
42145         (__arm_vmulq_x_u16): Remove.
42146         (__arm_vmulq_x_u32): Remove.
42147         (__arm_vmulq_x_n_u8): Remove.
42148         (__arm_vmulq_x_n_u16): Remove.
42149         (__arm_vmulq_x_n_u32): Remove.
42150         (__arm_vmulq_n_f16): Remove.
42151         (__arm_vmulq_f16): Remove.
42152         (__arm_vmulq_n_f32): Remove.
42153         (__arm_vmulq_f32): Remove.
42154         (__arm_vmulq_m_f32): Remove.
42155         (__arm_vmulq_m_f16): Remove.
42156         (__arm_vmulq_m_n_f32): Remove.
42157         (__arm_vmulq_m_n_f16): Remove.
42158         (__arm_vmulq_x_f16): Remove.
42159         (__arm_vmulq_x_f32): Remove.
42160         (__arm_vmulq_x_n_f16): Remove.
42161         (__arm_vmulq_x_n_f32): Remove.
42162         (__arm_vmulq): Remove.
42163         (__arm_vmulq_m): Remove.
42164         (__arm_vmulq_x): Remove.
42165         (vsubq): Remove.
42166         (vsubq_m): Remove.
42167         (vsubq_x): Remove.
42168         (vsubq_n_f16): Remove.
42169         (vsubq_n_f32): Remove.
42170         (vsubq_u8): Remove.
42171         (vsubq_n_u8): Remove.
42172         (vsubq_s8): Remove.
42173         (vsubq_n_s8): Remove.
42174         (vsubq_u16): Remove.
42175         (vsubq_n_u16): Remove.
42176         (vsubq_s16): Remove.
42177         (vsubq_n_s16): Remove.
42178         (vsubq_u32): Remove.
42179         (vsubq_n_u32): Remove.
42180         (vsubq_s32): Remove.
42181         (vsubq_n_s32): Remove.
42182         (vsubq_f16): Remove.
42183         (vsubq_f32): Remove.
42184         (vsubq_m_s8): Remove.
42185         (vsubq_m_u8): Remove.
42186         (vsubq_m_s16): Remove.
42187         (vsubq_m_u16): Remove.
42188         (vsubq_m_s32): Remove.
42189         (vsubq_m_u32): Remove.
42190         (vsubq_m_n_s8): Remove.
42191         (vsubq_m_n_s32): Remove.
42192         (vsubq_m_n_s16): Remove.
42193         (vsubq_m_n_u8): Remove.
42194         (vsubq_m_n_u32): Remove.
42195         (vsubq_m_n_u16): Remove.
42196         (vsubq_m_f32): Remove.
42197         (vsubq_m_f16): Remove.
42198         (vsubq_m_n_f32): Remove.
42199         (vsubq_m_n_f16): Remove.
42200         (vsubq_x_s8): Remove.
42201         (vsubq_x_s16): Remove.
42202         (vsubq_x_s32): Remove.
42203         (vsubq_x_n_s8): Remove.
42204         (vsubq_x_n_s16): Remove.
42205         (vsubq_x_n_s32): Remove.
42206         (vsubq_x_u8): Remove.
42207         (vsubq_x_u16): Remove.
42208         (vsubq_x_u32): Remove.
42209         (vsubq_x_n_u8): Remove.
42210         (vsubq_x_n_u16): Remove.
42211         (vsubq_x_n_u32): Remove.
42212         (vsubq_x_f16): Remove.
42213         (vsubq_x_f32): Remove.
42214         (vsubq_x_n_f16): Remove.
42215         (vsubq_x_n_f32): Remove.
42216         (__arm_vsubq_u8): Remove.
42217         (__arm_vsubq_n_u8): Remove.
42218         (__arm_vsubq_s8): Remove.
42219         (__arm_vsubq_n_s8): Remove.
42220         (__arm_vsubq_u16): Remove.
42221         (__arm_vsubq_n_u16): Remove.
42222         (__arm_vsubq_s16): Remove.
42223         (__arm_vsubq_n_s16): Remove.
42224         (__arm_vsubq_u32): Remove.
42225         (__arm_vsubq_n_u32): Remove.
42226         (__arm_vsubq_s32): Remove.
42227         (__arm_vsubq_n_s32): Remove.
42228         (__arm_vsubq_m_s8): Remove.
42229         (__arm_vsubq_m_u8): Remove.
42230         (__arm_vsubq_m_s16): Remove.
42231         (__arm_vsubq_m_u16): Remove.
42232         (__arm_vsubq_m_s32): Remove.
42233         (__arm_vsubq_m_u32): Remove.
42234         (__arm_vsubq_m_n_s8): Remove.
42235         (__arm_vsubq_m_n_s32): Remove.
42236         (__arm_vsubq_m_n_s16): Remove.
42237         (__arm_vsubq_m_n_u8): Remove.
42238         (__arm_vsubq_m_n_u32): Remove.
42239         (__arm_vsubq_m_n_u16): Remove.
42240         (__arm_vsubq_x_s8): Remove.
42241         (__arm_vsubq_x_s16): Remove.
42242         (__arm_vsubq_x_s32): Remove.
42243         (__arm_vsubq_x_n_s8): Remove.
42244         (__arm_vsubq_x_n_s16): Remove.
42245         (__arm_vsubq_x_n_s32): Remove.
42246         (__arm_vsubq_x_u8): Remove.
42247         (__arm_vsubq_x_u16): Remove.
42248         (__arm_vsubq_x_u32): Remove.
42249         (__arm_vsubq_x_n_u8): Remove.
42250         (__arm_vsubq_x_n_u16): Remove.
42251         (__arm_vsubq_x_n_u32): Remove.
42252         (__arm_vsubq_n_f16): Remove.
42253         (__arm_vsubq_n_f32): Remove.
42254         (__arm_vsubq_f16): Remove.
42255         (__arm_vsubq_f32): Remove.
42256         (__arm_vsubq_m_f32): Remove.
42257         (__arm_vsubq_m_f16): Remove.
42258         (__arm_vsubq_m_n_f32): Remove.
42259         (__arm_vsubq_m_n_f16): Remove.
42260         (__arm_vsubq_x_f16): Remove.
42261         (__arm_vsubq_x_f32): Remove.
42262         (__arm_vsubq_x_n_f16): Remove.
42263         (__arm_vsubq_x_n_f32): Remove.
42264         (__arm_vsubq): Remove.
42265         (__arm_vsubq_m): Remove.
42266         (__arm_vsubq_x): Remove.
42267         * config/arm/arm_mve_builtins.def (vsubq_u, vsubq_s, vsubq_f):
42268         Remove.
42269         (vmulq_u, vmulq_s, vmulq_f): Remove.
42270         * config/arm/mve.md (mve_vsubq_<supf><mode>): Remove.
42271         (mve_vmulq_<supf><mode>): Remove.
42273 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
42275         * config/arm/iterators.md (MVE_INT_BINARY_RTX, MVE_INT_M_BINARY)
42276         (MVE_INT_M_N_BINARY, MVE_INT_N_BINARY, MVE_FP_M_BINARY)
42277         (MVE_FP_M_N_BINARY, MVE_FP_N_BINARY, mve_addsubmul, mve_insn): New
42278         iterators.
42279         * config/arm/mve.md
42280         (mve_vsubq_n_f<mode>, mve_vaddq_n_f<mode>, mve_vmulq_n_f<mode>):
42281         Factorize into ...
42282         (@mve_<mve_insn>q_n_f<mode>): ... this.
42283         (mve_vaddq_n_<supf><mode>, mve_vmulq_n_<supf><mode>)
42284         (mve_vsubq_n_<supf><mode>): Factorize into ...
42285         (@mve_<mve_insn>q_n_<supf><mode>): ... this.
42286         (mve_vaddq<mode>, mve_vmulq<mode>, mve_vsubq<mode>): Factorize
42287         into ...
42288         (mve_<mve_addsubmul>q<mode>): ... this.
42289         (mve_vaddq_f<mode>, mve_vmulq_f<mode>, mve_vsubq_f<mode>):
42290         Factorize into ...
42291         (mve_<mve_addsubmul>q_f<mode>): ... this.
42292         (mve_vaddq_m_<supf><mode>, mve_vmulq_m_<supf><mode>)
42293         (mve_vsubq_m_<supf><mode>): Factorize into ...
42294         (@mve_<mve_insn>q_m_<supf><mode>): ... this,
42295         (mve_vaddq_m_n_<supf><mode>, mve_vmulq_m_n_<supf><mode>)
42296         (mve_vsubq_m_n_<supf><mode>): Factorize into ...
42297         (@mve_<mve_insn>q_m_n_<supf><mode>): ... this.
42298         (mve_vaddq_m_f<mode>, mve_vmulq_m_f<mode>, mve_vsubq_m_f<mode>):
42299         Factorize into ...
42300         (@mve_<mve_insn>q_m_f<mode>): ... this.
42301         (mve_vaddq_m_n_f<mode>, mve_vmulq_m_n_f<mode>)
42302         (mve_vsubq_m_n_f<mode>): Factorize into ...
42303         (@mve_<mve_insn>q_m_n_f<mode>): ... this.
42305 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
42307         * config/arm/arm-mve-builtins-functions.h (class
42308         unspec_based_mve_function_base): New.
42309         (class unspec_based_mve_function_exact_insn): New.
42311 2023-05-03  Christophe Lyon  <christophe.lyon@arm.com>
42313         * config/arm/arm-mve-builtins-shapes.cc (binary_opt_n): New.
42314         * config/arm/arm-mve-builtins-shapes.h (binary_opt_n): New.
42316 2023-05-03  Murray Steele  <murray.steele@arm.com>
42317             Christophe Lyon  <christophe.lyon@arm.com>
42319         * config/arm/arm-mve-builtins-base.cc (class
42320         vuninitializedq_impl): New.
42321         * config/arm/arm-mve-builtins-base.def (vuninitializedq): New.
42322         * config/arm/arm-mve-builtins-base.h (vuninitializedq): New
42323         declaration.
42324         * config/arm/arm-mve-builtins-shapes.cc (inherent): New.
42325         * config/arm/arm-mve-builtins-shapes.h (inherent): New
42326         declaration.
42327         * config/arm/arm_mve_types.h (__arm_vuninitializedq): Move to ...
42328         * config/arm/arm_mve.h (__arm_vuninitializedq): ... here.
42329         (__arm_vuninitializedq_u8): Remove.
42330         (__arm_vuninitializedq_u16): Remove.
42331         (__arm_vuninitializedq_u32): Remove.
42332         (__arm_vuninitializedq_u64): Remove.
42333         (__arm_vuninitializedq_s8): Remove.
42334         (__arm_vuninitializedq_s16): Remove.
42335         (__arm_vuninitializedq_s32): Remove.
42336         (__arm_vuninitializedq_s64): Remove.
42337         (__arm_vuninitializedq_f16): Remove.
42338         (__arm_vuninitializedq_f32): Remove.
42340 2023-05-03  Murray Steele  <murray.steele@arm.com>
42341             Christophe Lyon  <christophe.lyon@arm.com>
42343         * config/arm/arm-mve-builtins-base.cc (vreinterpretq_impl): New class.
42344         * config/arm/arm-mve-builtins-base.def: Define vreinterpretq.
42345         * config/arm/arm-mve-builtins-base.h (vreinterpretq): New declaration.
42346         * config/arm/arm-mve-builtins-shapes.cc (parse_element_type): New function.
42347         (parse_type): Likewise.
42348         (parse_signature): Likewise.
42349         (build_one): Likewise.
42350         (build_all): Likewise.
42351         (overloaded_base): New struct.
42352         (unary_convert_def): Likewise.
42353         * config/arm/arm-mve-builtins-shapes.h (unary_convert): Declare.
42354         * config/arm/arm-mve-builtins.cc (TYPES_reinterpret_signed1): New
42355         macro.
42356         (TYPES_reinterpret_unsigned1): Likewise.
42357         (TYPES_reinterpret_integer): Likewise.
42358         (TYPES_reinterpret_integer1): Likewise.
42359         (TYPES_reinterpret_float1): Likewise.
42360         (TYPES_reinterpret_float): Likewise.
42361         (reinterpret_integer): New.
42362         (reinterpret_float): New.
42363         (handle_arm_mve_h): Register builtins.
42364         * config/arm/arm_mve.h (vreinterpretq_s16): Remove.
42365         (vreinterpretq_s32): Likewise.
42366         (vreinterpretq_s64): Likewise.
42367         (vreinterpretq_s8): Likewise.
42368         (vreinterpretq_u16): Likewise.
42369         (vreinterpretq_u32): Likewise.
42370         (vreinterpretq_u64): Likewise.
42371         (vreinterpretq_u8): Likewise.
42372         (vreinterpretq_f16): Likewise.
42373         (vreinterpretq_f32): Likewise.
42374         (vreinterpretq_s16_s32): Likewise.
42375         (vreinterpretq_s16_s64): Likewise.
42376         (vreinterpretq_s16_s8): Likewise.
42377         (vreinterpretq_s16_u16): Likewise.
42378         (vreinterpretq_s16_u32): Likewise.
42379         (vreinterpretq_s16_u64): Likewise.
42380         (vreinterpretq_s16_u8): Likewise.
42381         (vreinterpretq_s32_s16): Likewise.
42382         (vreinterpretq_s32_s64): Likewise.
42383         (vreinterpretq_s32_s8): Likewise.
42384         (vreinterpretq_s32_u16): Likewise.
42385         (vreinterpretq_s32_u32): Likewise.
42386         (vreinterpretq_s32_u64): Likewise.
42387         (vreinterpretq_s32_u8): Likewise.
42388         (vreinterpretq_s64_s16): Likewise.
42389         (vreinterpretq_s64_s32): Likewise.
42390         (vreinterpretq_s64_s8): Likewise.
42391         (vreinterpretq_s64_u16): Likewise.
42392         (vreinterpretq_s64_u32): Likewise.
42393         (vreinterpretq_s64_u64): Likewise.
42394         (vreinterpretq_s64_u8): Likewise.
42395         (vreinterpretq_s8_s16): Likewise.
42396         (vreinterpretq_s8_s32): Likewise.
42397         (vreinterpretq_s8_s64): Likewise.
42398         (vreinterpretq_s8_u16): Likewise.
42399         (vreinterpretq_s8_u32): Likewise.
42400         (vreinterpretq_s8_u64): Likewise.
42401         (vreinterpretq_s8_u8): Likewise.
42402         (vreinterpretq_u16_s16): Likewise.
42403         (vreinterpretq_u16_s32): Likewise.
42404         (vreinterpretq_u16_s64): Likewise.
42405         (vreinterpretq_u16_s8): Likewise.
42406         (vreinterpretq_u16_u32): Likewise.
42407         (vreinterpretq_u16_u64): Likewise.
42408         (vreinterpretq_u16_u8): Likewise.
42409         (vreinterpretq_u32_s16): Likewise.
42410         (vreinterpretq_u32_s32): Likewise.
42411         (vreinterpretq_u32_s64): Likewise.
42412         (vreinterpretq_u32_s8): Likewise.
42413         (vreinterpretq_u32_u16): Likewise.
42414         (vreinterpretq_u32_u64): Likewise.
42415         (vreinterpretq_u32_u8): Likewise.
42416         (vreinterpretq_u64_s16): Likewise.
42417         (vreinterpretq_u64_s32): Likewise.
42418         (vreinterpretq_u64_s64): Likewise.
42419         (vreinterpretq_u64_s8): Likewise.
42420         (vreinterpretq_u64_u16): Likewise.
42421         (vreinterpretq_u64_u32): Likewise.
42422         (vreinterpretq_u64_u8): Likewise.
42423         (vreinterpretq_u8_s16): Likewise.
42424         (vreinterpretq_u8_s32): Likewise.
42425         (vreinterpretq_u8_s64): Likewise.
42426         (vreinterpretq_u8_s8): Likewise.
42427         (vreinterpretq_u8_u16): Likewise.
42428         (vreinterpretq_u8_u32): Likewise.
42429         (vreinterpretq_u8_u64): Likewise.
42430         (vreinterpretq_s32_f16): Likewise.
42431         (vreinterpretq_s32_f32): Likewise.
42432         (vreinterpretq_u16_f16): Likewise.
42433         (vreinterpretq_u16_f32): Likewise.
42434         (vreinterpretq_u32_f16): Likewise.
42435         (vreinterpretq_u32_f32): Likewise.
42436         (vreinterpretq_u64_f16): Likewise.
42437         (vreinterpretq_u64_f32): Likewise.
42438         (vreinterpretq_u8_f16): Likewise.
42439         (vreinterpretq_u8_f32): Likewise.
42440         (vreinterpretq_f16_f32): Likewise.
42441         (vreinterpretq_f16_s16): Likewise.
42442         (vreinterpretq_f16_s32): Likewise.
42443         (vreinterpretq_f16_s64): Likewise.
42444         (vreinterpretq_f16_s8): Likewise.
42445         (vreinterpretq_f16_u16): Likewise.
42446         (vreinterpretq_f16_u32): Likewise.
42447         (vreinterpretq_f16_u64): Likewise.
42448         (vreinterpretq_f16_u8): Likewise.
42449         (vreinterpretq_f32_f16): Likewise.
42450         (vreinterpretq_f32_s16): Likewise.
42451         (vreinterpretq_f32_s32): Likewise.
42452         (vreinterpretq_f32_s64): Likewise.
42453         (vreinterpretq_f32_s8): Likewise.
42454         (vreinterpretq_f32_u16): Likewise.
42455         (vreinterpretq_f32_u32): Likewise.
42456         (vreinterpretq_f32_u64): Likewise.
42457         (vreinterpretq_f32_u8): Likewise.
42458         (vreinterpretq_s16_f16): Likewise.
42459         (vreinterpretq_s16_f32): Likewise.
42460         (vreinterpretq_s64_f16): Likewise.
42461         (vreinterpretq_s64_f32): Likewise.
42462         (vreinterpretq_s8_f16): Likewise.
42463         (vreinterpretq_s8_f32): Likewise.
42464         (__arm_vreinterpretq_f16): Likewise.
42465         (__arm_vreinterpretq_f32): Likewise.
42466         (__arm_vreinterpretq_s16): Likewise.
42467         (__arm_vreinterpretq_s32): Likewise.
42468         (__arm_vreinterpretq_s64): Likewise.
42469         (__arm_vreinterpretq_s8): Likewise.
42470         (__arm_vreinterpretq_u16): Likewise.
42471         (__arm_vreinterpretq_u32): Likewise.
42472         (__arm_vreinterpretq_u64): Likewise.
42473         (__arm_vreinterpretq_u8): Likewise.
42474         * config/arm/arm_mve_types.h (__arm_vreinterpretq_s16_s32): Remove.
42475         (__arm_vreinterpretq_s16_s64): Likewise.
42476         (__arm_vreinterpretq_s16_s8): Likewise.
42477         (__arm_vreinterpretq_s16_u16): Likewise.
42478         (__arm_vreinterpretq_s16_u32): Likewise.
42479         (__arm_vreinterpretq_s16_u64): Likewise.
42480         (__arm_vreinterpretq_s16_u8): Likewise.
42481         (__arm_vreinterpretq_s32_s16): Likewise.
42482         (__arm_vreinterpretq_s32_s64): Likewise.
42483         (__arm_vreinterpretq_s32_s8): Likewise.
42484         (__arm_vreinterpretq_s32_u16): Likewise.
42485         (__arm_vreinterpretq_s32_u32): Likewise.
42486         (__arm_vreinterpretq_s32_u64): Likewise.
42487         (__arm_vreinterpretq_s32_u8): Likewise.
42488         (__arm_vreinterpretq_s64_s16): Likewise.
42489         (__arm_vreinterpretq_s64_s32): Likewise.
42490         (__arm_vreinterpretq_s64_s8): Likewise.
42491         (__arm_vreinterpretq_s64_u16): Likewise.
42492         (__arm_vreinterpretq_s64_u32): Likewise.
42493         (__arm_vreinterpretq_s64_u64): Likewise.
42494         (__arm_vreinterpretq_s64_u8): Likewise.
42495         (__arm_vreinterpretq_s8_s16): Likewise.
42496         (__arm_vreinterpretq_s8_s32): Likewise.
42497         (__arm_vreinterpretq_s8_s64): Likewise.
42498         (__arm_vreinterpretq_s8_u16): Likewise.
42499         (__arm_vreinterpretq_s8_u32): Likewise.
42500         (__arm_vreinterpretq_s8_u64): Likewise.
42501         (__arm_vreinterpretq_s8_u8): Likewise.
42502         (__arm_vreinterpretq_u16_s16): Likewise.
42503         (__arm_vreinterpretq_u16_s32): Likewise.
42504         (__arm_vreinterpretq_u16_s64): Likewise.
42505         (__arm_vreinterpretq_u16_s8): Likewise.
42506         (__arm_vreinterpretq_u16_u32): Likewise.
42507         (__arm_vreinterpretq_u16_u64): Likewise.
42508         (__arm_vreinterpretq_u16_u8): Likewise.
42509         (__arm_vreinterpretq_u32_s16): Likewise.
42510         (__arm_vreinterpretq_u32_s32): Likewise.
42511         (__arm_vreinterpretq_u32_s64): Likewise.
42512         (__arm_vreinterpretq_u32_s8): Likewise.
42513         (__arm_vreinterpretq_u32_u16): Likewise.
42514         (__arm_vreinterpretq_u32_u64): Likewise.
42515         (__arm_vreinterpretq_u32_u8): Likewise.
42516         (__arm_vreinterpretq_u64_s16): Likewise.
42517         (__arm_vreinterpretq_u64_s32): Likewise.
42518         (__arm_vreinterpretq_u64_s64): Likewise.
42519         (__arm_vreinterpretq_u64_s8): Likewise.
42520         (__arm_vreinterpretq_u64_u16): Likewise.
42521         (__arm_vreinterpretq_u64_u32): Likewise.
42522         (__arm_vreinterpretq_u64_u8): Likewise.
42523         (__arm_vreinterpretq_u8_s16): Likewise.
42524         (__arm_vreinterpretq_u8_s32): Likewise.
42525         (__arm_vreinterpretq_u8_s64): Likewise.
42526         (__arm_vreinterpretq_u8_s8): Likewise.
42527         (__arm_vreinterpretq_u8_u16): Likewise.
42528         (__arm_vreinterpretq_u8_u32): Likewise.
42529         (__arm_vreinterpretq_u8_u64): Likewise.
42530         (__arm_vreinterpretq_s32_f16): Likewise.
42531         (__arm_vreinterpretq_s32_f32): Likewise.
42532         (__arm_vreinterpretq_s16_f16): Likewise.
42533         (__arm_vreinterpretq_s16_f32): Likewise.
42534         (__arm_vreinterpretq_s64_f16): Likewise.
42535         (__arm_vreinterpretq_s64_f32): Likewise.
42536         (__arm_vreinterpretq_s8_f16): Likewise.
42537         (__arm_vreinterpretq_s8_f32): Likewise.
42538         (__arm_vreinterpretq_u16_f16): Likewise.
42539         (__arm_vreinterpretq_u16_f32): Likewise.
42540         (__arm_vreinterpretq_u32_f16): Likewise.
42541         (__arm_vreinterpretq_u32_f32): Likewise.
42542         (__arm_vreinterpretq_u64_f16): Likewise.
42543         (__arm_vreinterpretq_u64_f32): Likewise.
42544         (__arm_vreinterpretq_u8_f16): Likewise.
42545         (__arm_vreinterpretq_u8_f32): Likewise.
42546         (__arm_vreinterpretq_f16_f32): Likewise.
42547         (__arm_vreinterpretq_f16_s16): Likewise.
42548         (__arm_vreinterpretq_f16_s32): Likewise.
42549         (__arm_vreinterpretq_f16_s64): Likewise.
42550         (__arm_vreinterpretq_f16_s8): Likewise.
42551         (__arm_vreinterpretq_f16_u16): Likewise.
42552         (__arm_vreinterpretq_f16_u32): Likewise.
42553         (__arm_vreinterpretq_f16_u64): Likewise.
42554         (__arm_vreinterpretq_f16_u8): Likewise.
42555         (__arm_vreinterpretq_f32_f16): Likewise.
42556         (__arm_vreinterpretq_f32_s16): Likewise.
42557         (__arm_vreinterpretq_f32_s32): Likewise.
42558         (__arm_vreinterpretq_f32_s64): Likewise.
42559         (__arm_vreinterpretq_f32_s8): Likewise.
42560         (__arm_vreinterpretq_f32_u16): Likewise.
42561         (__arm_vreinterpretq_f32_u32): Likewise.
42562         (__arm_vreinterpretq_f32_u64): Likewise.
42563         (__arm_vreinterpretq_f32_u8): Likewise.
42564         (__arm_vreinterpretq_s16): Likewise.
42565         (__arm_vreinterpretq_s32): Likewise.
42566         (__arm_vreinterpretq_s64): Likewise.
42567         (__arm_vreinterpretq_s8): Likewise.
42568         (__arm_vreinterpretq_u16): Likewise.
42569         (__arm_vreinterpretq_u32): Likewise.
42570         (__arm_vreinterpretq_u64): Likewise.
42571         (__arm_vreinterpretq_u8): Likewise.
42572         (__arm_vreinterpretq_f16): Likewise.
42573         (__arm_vreinterpretq_f32): Likewise.
42574         * config/arm/mve.md (@arm_mve_reinterpret<mode>): New pattern.
42575         * config/arm/unspecs.md: (REINTERPRET): New unspec.
42577 2023-05-03  Murray Steele  <murray.steele@arm.com>
42578             Christophe Lyon  <christophe.lyon@arm.com>
42579             Christophe Lyon   <christophe.lyon@arm.com
42581         * config.gcc: Add arm-mve-builtins-base.o and
42582         arm-mve-builtins-shapes.o to extra_objs.
42583         * config/arm/arm-builtins.cc (arm_builtin_decl): Handle MVE builtin
42584         numberspace.
42585         (arm_expand_builtin): Likewise
42586         (arm_check_builtin_call): Likewise
42587         (arm_describe_resolver): Likewise.
42588         * config/arm/arm-builtins.h (enum resolver_ident): Add
42589         arm_mve_resolver.
42590         * config/arm/arm-c.cc (arm_pragma_arm): Handle new pragma.
42591         (arm_resolve_overloaded_builtin): Handle MVE builtins.
42592         (arm_register_target_pragmas): Register arm_check_builtin_call.
42593         * config/arm/arm-mve-builtins.cc (class registered_function): New
42594         class.
42595         (struct registered_function_hasher): New struct.
42596         (pred_suffixes): New table.
42597         (mode_suffixes): New table.
42598         (type_suffix_info): New table.
42599         (TYPES_float16): New.
42600         (TYPES_all_float): New.
42601         (TYPES_integer_8): New.
42602         (TYPES_integer_8_16): New.
42603         (TYPES_integer_16_32): New.
42604         (TYPES_integer_32): New.
42605         (TYPES_signed_16_32): New.
42606         (TYPES_signed_32): New.
42607         (TYPES_all_signed): New.
42608         (TYPES_all_unsigned): New.
42609         (TYPES_all_integer): New.
42610         (TYPES_all_integer_with_64): New.
42611         (DEF_VECTOR_TYPE): New.
42612         (DEF_DOUBLE_TYPE): New.
42613         (DEF_MVE_TYPES_ARRAY): New.
42614         (all_integer): New.
42615         (all_integer_with_64): New.
42616         (float16): New.
42617         (all_float): New.
42618         (all_signed): New.
42619         (all_unsigned): New.
42620         (integer_8): New.
42621         (integer_8_16): New.
42622         (integer_16_32): New.
42623         (integer_32): New.
42624         (signed_16_32): New.
42625         (signed_32): New.
42626         (register_vector_type): Use void_type_node for mve.fp-only types when
42627         mve.fp is not enabled.
42628         (register_builtin_tuple_types): Likewise.
42629         (handle_arm_mve_h): New function..
42630         (matches_type_p): Likewise..
42631         (report_out_of_range): Likewise.
42632         (report_not_enum): Likewise.
42633         (report_missing_float): Likewise.
42634         (report_non_ice): Likewise.
42635         (check_requires_float): Likewise.
42636         (function_instance::hash): Likewise
42637         (function_instance::call_properties): Likewise.
42638         (function_instance::reads_global_state_p): Likewise.
42639         (function_instance::modifies_global_state_p): Likewise.
42640         (function_instance::could_trap_p): Likewise.
42641         (function_instance::has_inactive_argument): Likewise.
42642         (registered_function_hasher::hash): Likewise.
42643         (registered_function_hasher::equal): Likewise.
42644         (function_builder::function_builder): Likewise.
42645         (function_builder::~function_builder): Likewise.
42646         (function_builder::append_name): Likewise.
42647         (function_builder::finish_name): Likewise.
42648         (function_builder::get_name): Likewise.
42649         (add_attribute): Likewise.
42650         (function_builder::get_attributes): Likewise.
42651         (function_builder::add_function): Likewise.
42652         (function_builder::add_unique_function): Likewise.
42653         (function_builder::add_overloaded_function): Likewise.
42654         (function_builder::add_overloaded_functions): Likewise.
42655         (function_builder::register_function_group): Likewise.
42656         (function_call_info::function_call_info): Likewise.
42657         (function_resolver::function_resolver): Likewise.
42658         (function_resolver::get_vector_type): Likewise.
42659         (function_resolver::get_scalar_type_name): Likewise.
42660         (function_resolver::get_argument_type): Likewise.
42661         (function_resolver::scalar_argument_p): Likewise.
42662         (function_resolver::report_no_such_form): Likewise.
42663         (function_resolver::lookup_form): Likewise.
42664         (function_resolver::resolve_to): Likewise.
42665         (function_resolver::infer_vector_or_tuple_type): Likewise.
42666         (function_resolver::infer_vector_type): Likewise.
42667         (function_resolver::require_vector_or_scalar_type): Likewise.
42668         (function_resolver::require_vector_type): Likewise.
42669         (function_resolver::require_matching_vector_type): Likewise.
42670         (function_resolver::require_derived_vector_type): Likewise.
42671         (function_resolver::require_derived_scalar_type): Likewise.
42672         (function_resolver::require_integer_immediate): Likewise.
42673         (function_resolver::require_scalar_type): Likewise.
42674         (function_resolver::check_num_arguments): Likewise.
42675         (function_resolver::check_gp_argument): Likewise.
42676         (function_resolver::finish_opt_n_resolution): Likewise.
42677         (function_resolver::resolve_unary): Likewise.
42678         (function_resolver::resolve_unary_n): Likewise.
42679         (function_resolver::resolve_uniform): Likewise.
42680         (function_resolver::resolve_uniform_opt_n): Likewise.
42681         (function_resolver::resolve): Likewise.
42682         (function_checker::function_checker): Likewise.
42683         (function_checker::argument_exists_p): Likewise.
42684         (function_checker::require_immediate): Likewise.
42685         (function_checker::require_immediate_enum): Likewise.
42686         (function_checker::require_immediate_range): Likewise.
42687         (function_checker::check): Likewise.
42688         (gimple_folder::gimple_folder): Likewise.
42689         (gimple_folder::fold): Likewise.
42690         (function_expander::function_expander): Likewise.
42691         (function_expander::direct_optab_handler): Likewise.
42692         (function_expander::get_fallback_value): Likewise.
42693         (function_expander::get_reg_target): Likewise.
42694         (function_expander::add_output_operand): Likewise.
42695         (function_expander::add_input_operand): Likewise.
42696         (function_expander::add_integer_operand): Likewise.
42697         (function_expander::generate_insn): Likewise.
42698         (function_expander::use_exact_insn): Likewise.
42699         (function_expander::use_unpred_insn): Likewise.
42700         (function_expander::use_pred_x_insn): Likewise.
42701         (function_expander::use_cond_insn): Likewise.
42702         (function_expander::map_to_rtx_codes): Likewise.
42703         (function_expander::expand): Likewise.
42704         (resolve_overloaded_builtin): Likewise.
42705         (check_builtin_call): Likewise.
42706         (gimple_fold_builtin): Likewise.
42707         (expand_builtin): Likewise.
42708         (gt_ggc_mx): Likewise.
42709         (gt_pch_nx): Likewise.
42710         (gt_pch_nx): Likewise.
42711         * config/arm/arm-mve-builtins.def(s8): Define new type suffix.
42712         (s16): Likewise.
42713         (s32): Likewise.
42714         (s64): Likewise.
42715         (u8): Likewise.
42716         (u16): Likewise.
42717         (u32): Likewise.
42718         (u64): Likewise.
42719         (f16): Likewise.
42720         (f32): Likewise.
42721         (n): New mode.
42722         (offset): New mode.
42723         * config/arm/arm-mve-builtins.h (MAX_TUPLE_SIZE): New constant.
42724         (CP_READ_FPCR): Likewise.
42725         (CP_RAISE_FP_EXCEPTIONS): Likewise.
42726         (CP_READ_MEMORY): Likewise.
42727         (CP_WRITE_MEMORY): Likewise.
42728         (enum units_index): New enum.
42729         (enum predication_index): New.
42730         (enum type_class_index): New.
42731         (enum mode_suffix_index): New enum.
42732         (enum type_suffix_index): New.
42733         (struct mode_suffix_info): New struct.
42734         (struct type_suffix_info): New.
42735         (struct function_group_info): Likewise.
42736         (class function_instance): Likewise.
42737         (class registered_function): Likewise.
42738         (class function_builder): Likewise.
42739         (class function_call_info): Likewise.
42740         (class function_resolver): Likewise.
42741         (class function_checker): Likewise.
42742         (class gimple_folder): Likewise.
42743         (class function_expander): Likewise.
42744         (get_mve_pred16_t): Likewise.
42745         (find_mode_suffix): New function.
42746         (class function_base): Likewise.
42747         (class function_shape): Likewise.
42748         (function_instance::operator==): New function.
42749         (function_instance::operator!=): Likewise.
42750         (function_instance::vectors_per_tuple): Likewise.
42751         (function_instance::mode_suffix): Likewise.
42752         (function_instance::type_suffix): Likewise.
42753         (function_instance::scalar_type): Likewise.
42754         (function_instance::vector_type): Likewise.
42755         (function_instance::tuple_type): Likewise.
42756         (function_instance::vector_mode): Likewise.
42757         (function_call_info::function_returns_void_p): Likewise.
42758         (function_base::call_properties): Likewise.
42759         * config/arm/arm-protos.h (enum arm_builtin_class): Add
42760         ARM_BUILTIN_MVE.
42761         (handle_arm_mve_h): New.
42762         (resolve_overloaded_builtin): New.
42763         (check_builtin_call): New.
42764         (gimple_fold_builtin): New.
42765         (expand_builtin): New.
42766         * config/arm/arm.cc (TARGET_GIMPLE_FOLD_BUILTIN): Define as
42767         arm_gimple_fold_builtin.
42768         (arm_gimple_fold_builtin): New function.
42769         * config/arm/arm_mve.h: Use new arm_mve.h pragma.
42770         * config/arm/predicates.md (arm_any_register_operand): New predicate.
42771         * config/arm/t-arm: (arm-mve-builtins.o): Add includes.
42772         (arm-mve-builtins-shapes.o): New target.
42773         (arm-mve-builtins-base.o): New target.
42774         * config/arm/arm-mve-builtins-base.cc: New file.
42775         * config/arm/arm-mve-builtins-base.def: New file.
42776         * config/arm/arm-mve-builtins-base.h: New file.
42777         * config/arm/arm-mve-builtins-functions.h: New file.
42778         * config/arm/arm-mve-builtins-shapes.cc: New file.
42779         * config/arm/arm-mve-builtins-shapes.h: New file.
42781 2023-05-03  Murray Steele  <murray.steele@arm.com>
42782             Christophe Lyon  <christophe.lyon@arm.com>
42783             Christophe Lyon   <christophe.lyon@arm.com>
42785         * config/arm/arm-builtins.cc (arm_general_add_builtin_function):
42786         New function.
42787         (arm_init_builtin): Use arm_general_add_builtin_function instead
42788         of arm_add_builtin_function.
42789         (arm_init_acle_builtins): Likewise.
42790         (arm_init_mve_builtins): Likewise.
42791         (arm_init_crypto_builtins): Likewise.
42792         (arm_init_builtins): Likewise.
42793         (arm_general_builtin_decl): New function.
42794         (arm_builtin_decl): Defer to numberspace-specialized functions.
42795         (arm_expand_builtin_args): Rename into arm_general_expand_builtin_args.
42796         (arm_expand_builtin_1): Rename into arm_general_expand_builtin_1 and ...
42797         (arm_general_expand_builtin_1): ... specialize for general builtins.
42798         (arm_expand_acle_builtin): Use arm_general_expand_builtin
42799         instead of arm_expand_builtin.
42800         (arm_expand_mve_builtin): Likewise.
42801         (arm_expand_neon_builtin): Likewise.
42802         (arm_expand_vfp_builtin): Likewise.
42803         (arm_general_expand_builtin): New function.
42804         (arm_expand_builtin): Specialize for general builtins.
42805         (arm_general_check_builtin_call): New function.
42806         (arm_check_builtin_call): Specialize for general builtins.
42807         (arm_describe_resolver): Validate numberspace.
42808         (arm_cde_end_args): Likewise.
42809         * config/arm/arm-protos.h (enum arm_builtin_class): New enum.
42810         (ARM_BUILTIN_SHIFT, ARM_BUILTIN_CLASS): New constants.
42812 2023-05-03  Martin Liska  <mliska@suse.cz>
42814         PR target/109713
42815         * config/riscv/sync.md: Add gcc_unreachable to a switch.
42817 2023-05-03  Richard Biener  <rguenther@suse.de>
42819         * tree-ssa-loop-split.cc (split_at_bb_p): Avoid last_stmt.
42820         (patch_loop_exit): Likewise.
42821         (connect_loops): Likewise.
42822         (split_loop): Likewise.
42823         (control_dep_semi_invariant_p): Likewise.
42824         (do_split_loop_on_cond): Likewise.
42825         (split_loop_on_cond): Likewise.
42826         * tree-ssa-loop-unswitch.cc (find_unswitching_predicates_for_bb):
42827         Likewise.
42828         (simplify_loop_version): Likewise.
42829         (evaluate_bbs): Likewise.
42830         (find_loop_guard): Likewise.
42831         (clean_up_after_unswitching): Likewise.
42832         * tree-ssa-math-opts.cc (maybe_optimize_guarding_check):
42833         Likewise.
42834         (optimize_spaceship): Take a gcond * argument, avoid
42835         last_stmt.
42836         (math_opts_dom_walker::after_dom_children): Adjust call to
42837         optimize_spaceship.
42838         * tree-vrp.cc (maybe_set_nonzero_bits): Avoid last_stmt.
42839         * value-pointer-equiv.cc (pointer_equiv_analyzer::visit_edge):
42840         Likewise.
42842 2023-05-03  Andreas Schwab  <schwab@suse.de>
42844         * config/riscv/linux.h (LIB_SPEC): Don't redefine.
42846 2023-05-03  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
42848         * config/riscv/riscv-vector-builtins-bases.cc (fold_fault_load):
42849         New function.
42850         (class vlseg): New class.
42851         (class vsseg): Ditto.
42852         (class vlsseg): Ditto.
42853         (class vssseg): Ditto.
42854         (class seg_indexed_load): Ditto.
42855         (class seg_indexed_store): Ditto.
42856         (class vlsegff): Ditto.
42857         (BASE): Ditto.
42858         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
42859         * config/riscv/riscv-vector-builtins-functions.def (vlseg):
42860         Ditto.
42861         (vsseg): Ditto.
42862         (vlsseg): Ditto.
42863         (vssseg): Ditto.
42864         (vluxseg): Ditto.
42865         (vloxseg): Ditto.
42866         (vsuxseg): Ditto.
42867         (vsoxseg): Ditto.
42868         (vlsegff): Ditto.
42869         * config/riscv/riscv-vector-builtins-shapes.cc (struct
42870         seg_loadstore_def): Ditto.
42871         (struct seg_indexed_loadstore_def): Ditto.
42872         (struct seg_fault_load_def): Ditto.
42873         (SHAPE): Ditto.
42874         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
42875         * config/riscv/riscv-vector-builtins.cc
42876         (function_builder::append_nf): New function.
42877         * config/riscv/riscv-vector-builtins.def (vfloat32m1x2_t):
42878         Change ptr from double into float.
42879         (vfloat32m1x3_t): Ditto.
42880         (vfloat32m1x4_t): Ditto.
42881         (vfloat32m1x5_t): Ditto.
42882         (vfloat32m1x6_t): Ditto.
42883         (vfloat32m1x7_t): Ditto.
42884         (vfloat32m1x8_t): Ditto.
42885         (vfloat32m2x2_t): Ditto.
42886         (vfloat32m2x3_t): Ditto.
42887         (vfloat32m2x4_t): Ditto.
42888         (vfloat32m4x2_t): Ditto.
42889         * config/riscv/riscv-vector-builtins.h: Add segment intrinsics.
42890         * config/riscv/riscv-vsetvl.cc (fault_first_load_p): Adapt for
42891         segment ff load.
42892         * config/riscv/riscv.md: Add segment instructions.
42893         * config/riscv/vector-iterators.md: Support segment intrinsics.
42894         * config/riscv/vector.md (@pred_unit_strided_load<mode>): New
42895         pattern.
42896         (@pred_unit_strided_store<mode>): Ditto.
42897         (@pred_strided_load<mode>): Ditto.
42898         (@pred_strided_store<mode>): Ditto.
42899         (@pred_fault_load<mode>): Ditto.
42900         (@pred_indexed_<order>load<V1T:mode><V1I:mode>): Ditto.
42901         (@pred_indexed_<order>load<V2T:mode><V2I:mode>): Ditto.
42902         (@pred_indexed_<order>load<V4T:mode><V4I:mode>): Ditto.
42903         (@pred_indexed_<order>load<V8T:mode><V8I:mode>): Ditto.
42904         (@pred_indexed_<order>load<V16T:mode><V16I:mode>): Ditto.
42905         (@pred_indexed_<order>load<V32T:mode><V32I:mode>): Ditto.
42906         (@pred_indexed_<order>load<V64T:mode><V64I:mode>): Ditto.
42907         (@pred_indexed_<order>store<V1T:mode><V1I:mode>): Ditto.
42908         (@pred_indexed_<order>store<V2T:mode><V2I:mode>): Ditto.
42909         (@pred_indexed_<order>store<V4T:mode><V4I:mode>): Ditto.
42910         (@pred_indexed_<order>store<V8T:mode><V8I:mode>): Ditto.
42911         (@pred_indexed_<order>store<V16T:mode><V16I:mode>): Ditto.
42912         (@pred_indexed_<order>store<V32T:mode><V32I:mode>): Ditto.
42913         (@pred_indexed_<order>store<V64T:mode><V64I:mode>): Ditto.
42915 2023-05-03  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
42917         * config/riscv/genrvv-type-indexer.cc (valid_type): Adapt for
42918         tuple type support.
42919         (inttype): Ditto.
42920         (floattype): Ditto.
42921         (main): Ditto.
42922         * config/riscv/riscv-vector-builtins-bases.cc: Ditto.
42923         * config/riscv/riscv-vector-builtins-functions.def (vset): Add
42924         tuple type vset.
42925         (vget): Add tuple type vget.
42926         * config/riscv/riscv-vector-builtins-types.def
42927         (DEF_RVV_TUPLE_OPS): New macro.
42928         (vint8mf8x2_t): Ditto.
42929         (vuint8mf8x2_t): Ditto.
42930         (vint8mf8x3_t): Ditto.
42931         (vuint8mf8x3_t): Ditto.
42932         (vint8mf8x4_t): Ditto.
42933         (vuint8mf8x4_t): Ditto.
42934         (vint8mf8x5_t): Ditto.
42935         (vuint8mf8x5_t): Ditto.
42936         (vint8mf8x6_t): Ditto.
42937         (vuint8mf8x6_t): Ditto.
42938         (vint8mf8x7_t): Ditto.
42939         (vuint8mf8x7_t): Ditto.
42940         (vint8mf8x8_t): Ditto.
42941         (vuint8mf8x8_t): Ditto.
42942         (vint8mf4x2_t): Ditto.
42943         (vuint8mf4x2_t): Ditto.
42944         (vint8mf4x3_t): Ditto.
42945         (vuint8mf4x3_t): Ditto.
42946         (vint8mf4x4_t): Ditto.
42947         (vuint8mf4x4_t): Ditto.
42948         (vint8mf4x5_t): Ditto.
42949         (vuint8mf4x5_t): Ditto.
42950         (vint8mf4x6_t): Ditto.
42951         (vuint8mf4x6_t): Ditto.
42952         (vint8mf4x7_t): Ditto.
42953         (vuint8mf4x7_t): Ditto.
42954         (vint8mf4x8_t): Ditto.
42955         (vuint8mf4x8_t): Ditto.
42956         (vint8mf2x2_t): Ditto.
42957         (vuint8mf2x2_t): Ditto.
42958         (vint8mf2x3_t): Ditto.
42959         (vuint8mf2x3_t): Ditto.
42960         (vint8mf2x4_t): Ditto.
42961         (vuint8mf2x4_t): Ditto.
42962         (vint8mf2x5_t): Ditto.
42963         (vuint8mf2x5_t): Ditto.
42964         (vint8mf2x6_t): Ditto.
42965         (vuint8mf2x6_t): Ditto.
42966         (vint8mf2x7_t): Ditto.
42967         (vuint8mf2x7_t): Ditto.
42968         (vint8mf2x8_t): Ditto.
42969         (vuint8mf2x8_t): Ditto.
42970         (vint8m1x2_t): Ditto.
42971         (vuint8m1x2_t): Ditto.
42972         (vint8m1x3_t): Ditto.
42973         (vuint8m1x3_t): Ditto.
42974         (vint8m1x4_t): Ditto.
42975         (vuint8m1x4_t): Ditto.
42976         (vint8m1x5_t): Ditto.
42977         (vuint8m1x5_t): Ditto.
42978         (vint8m1x6_t): Ditto.
42979         (vuint8m1x6_t): Ditto.
42980         (vint8m1x7_t): Ditto.
42981         (vuint8m1x7_t): Ditto.
42982         (vint8m1x8_t): Ditto.
42983         (vuint8m1x8_t): Ditto.
42984         (vint8m2x2_t): Ditto.
42985         (vuint8m2x2_t): Ditto.
42986         (vint8m2x3_t): Ditto.
42987         (vuint8m2x3_t): Ditto.
42988         (vint8m2x4_t): Ditto.
42989         (vuint8m2x4_t): Ditto.
42990         (vint8m4x2_t): Ditto.
42991         (vuint8m4x2_t): Ditto.
42992         (vint16mf4x2_t): Ditto.
42993         (vuint16mf4x2_t): Ditto.
42994         (vint16mf4x3_t): Ditto.
42995         (vuint16mf4x3_t): Ditto.
42996         (vint16mf4x4_t): Ditto.
42997         (vuint16mf4x4_t): Ditto.
42998         (vint16mf4x5_t): Ditto.
42999         (vuint16mf4x5_t): Ditto.
43000         (vint16mf4x6_t): Ditto.
43001         (vuint16mf4x6_t): Ditto.
43002         (vint16mf4x7_t): Ditto.
43003         (vuint16mf4x7_t): Ditto.
43004         (vint16mf4x8_t): Ditto.
43005         (vuint16mf4x8_t): Ditto.
43006         (vint16mf2x2_t): Ditto.
43007         (vuint16mf2x2_t): Ditto.
43008         (vint16mf2x3_t): Ditto.
43009         (vuint16mf2x3_t): Ditto.
43010         (vint16mf2x4_t): Ditto.
43011         (vuint16mf2x4_t): Ditto.
43012         (vint16mf2x5_t): Ditto.
43013         (vuint16mf2x5_t): Ditto.
43014         (vint16mf2x6_t): Ditto.
43015         (vuint16mf2x6_t): Ditto.
43016         (vint16mf2x7_t): Ditto.
43017         (vuint16mf2x7_t): Ditto.
43018         (vint16mf2x8_t): Ditto.
43019         (vuint16mf2x8_t): Ditto.
43020         (vint16m1x2_t): Ditto.
43021         (vuint16m1x2_t): Ditto.
43022         (vint16m1x3_t): Ditto.
43023         (vuint16m1x3_t): Ditto.
43024         (vint16m1x4_t): Ditto.
43025         (vuint16m1x4_t): Ditto.
43026         (vint16m1x5_t): Ditto.
43027         (vuint16m1x5_t): Ditto.
43028         (vint16m1x6_t): Ditto.
43029         (vuint16m1x6_t): Ditto.
43030         (vint16m1x7_t): Ditto.
43031         (vuint16m1x7_t): Ditto.
43032         (vint16m1x8_t): Ditto.
43033         (vuint16m1x8_t): Ditto.
43034         (vint16m2x2_t): Ditto.
43035         (vuint16m2x2_t): Ditto.
43036         (vint16m2x3_t): Ditto.
43037         (vuint16m2x3_t): Ditto.
43038         (vint16m2x4_t): Ditto.
43039         (vuint16m2x4_t): Ditto.
43040         (vint16m4x2_t): Ditto.
43041         (vuint16m4x2_t): Ditto.
43042         (vint32mf2x2_t): Ditto.
43043         (vuint32mf2x2_t): Ditto.
43044         (vint32mf2x3_t): Ditto.
43045         (vuint32mf2x3_t): Ditto.
43046         (vint32mf2x4_t): Ditto.
43047         (vuint32mf2x4_t): Ditto.
43048         (vint32mf2x5_t): Ditto.
43049         (vuint32mf2x5_t): Ditto.
43050         (vint32mf2x6_t): Ditto.
43051         (vuint32mf2x6_t): Ditto.
43052         (vint32mf2x7_t): Ditto.
43053         (vuint32mf2x7_t): Ditto.
43054         (vint32mf2x8_t): Ditto.
43055         (vuint32mf2x8_t): Ditto.
43056         (vint32m1x2_t): Ditto.
43057         (vuint32m1x2_t): Ditto.
43058         (vint32m1x3_t): Ditto.
43059         (vuint32m1x3_t): Ditto.
43060         (vint32m1x4_t): Ditto.
43061         (vuint32m1x4_t): Ditto.
43062         (vint32m1x5_t): Ditto.
43063         (vuint32m1x5_t): Ditto.
43064         (vint32m1x6_t): Ditto.
43065         (vuint32m1x6_t): Ditto.
43066         (vint32m1x7_t): Ditto.
43067         (vuint32m1x7_t): Ditto.
43068         (vint32m1x8_t): Ditto.
43069         (vuint32m1x8_t): Ditto.
43070         (vint32m2x2_t): Ditto.
43071         (vuint32m2x2_t): Ditto.
43072         (vint32m2x3_t): Ditto.
43073         (vuint32m2x3_t): Ditto.
43074         (vint32m2x4_t): Ditto.
43075         (vuint32m2x4_t): Ditto.
43076         (vint32m4x2_t): Ditto.
43077         (vuint32m4x2_t): Ditto.
43078         (vint64m1x2_t): Ditto.
43079         (vuint64m1x2_t): Ditto.
43080         (vint64m1x3_t): Ditto.
43081         (vuint64m1x3_t): Ditto.
43082         (vint64m1x4_t): Ditto.
43083         (vuint64m1x4_t): Ditto.
43084         (vint64m1x5_t): Ditto.
43085         (vuint64m1x5_t): Ditto.
43086         (vint64m1x6_t): Ditto.
43087         (vuint64m1x6_t): Ditto.
43088         (vint64m1x7_t): Ditto.
43089         (vuint64m1x7_t): Ditto.
43090         (vint64m1x8_t): Ditto.
43091         (vuint64m1x8_t): Ditto.
43092         (vint64m2x2_t): Ditto.
43093         (vuint64m2x2_t): Ditto.
43094         (vint64m2x3_t): Ditto.
43095         (vuint64m2x3_t): Ditto.
43096         (vint64m2x4_t): Ditto.
43097         (vuint64m2x4_t): Ditto.
43098         (vint64m4x2_t): Ditto.
43099         (vuint64m4x2_t): Ditto.
43100         (vfloat32mf2x2_t): Ditto.
43101         (vfloat32mf2x3_t): Ditto.
43102         (vfloat32mf2x4_t): Ditto.
43103         (vfloat32mf2x5_t): Ditto.
43104         (vfloat32mf2x6_t): Ditto.
43105         (vfloat32mf2x7_t): Ditto.
43106         (vfloat32mf2x8_t): Ditto.
43107         (vfloat32m1x2_t): Ditto.
43108         (vfloat32m1x3_t): Ditto.
43109         (vfloat32m1x4_t): Ditto.
43110         (vfloat32m1x5_t): Ditto.
43111         (vfloat32m1x6_t): Ditto.
43112         (vfloat32m1x7_t): Ditto.
43113         (vfloat32m1x8_t): Ditto.
43114         (vfloat32m2x2_t): Ditto.
43115         (vfloat32m2x3_t): Ditto.
43116         (vfloat32m2x4_t): Ditto.
43117         (vfloat32m4x2_t): Ditto.
43118         (vfloat64m1x2_t): Ditto.
43119         (vfloat64m1x3_t): Ditto.
43120         (vfloat64m1x4_t): Ditto.
43121         (vfloat64m1x5_t): Ditto.
43122         (vfloat64m1x6_t): Ditto.
43123         (vfloat64m1x7_t): Ditto.
43124         (vfloat64m1x8_t): Ditto.
43125         (vfloat64m2x2_t): Ditto.
43126         (vfloat64m2x3_t): Ditto.
43127         (vfloat64m2x4_t): Ditto.
43128         (vfloat64m4x2_t): Ditto.
43129         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_TUPLE_OPS):
43130         Ditto.
43131         (DEF_RVV_TYPE_INDEX): Ditto.
43132         (rvv_arg_type_info::get_tuple_subpart_type): New function.
43133         (DEF_RVV_TUPLE_TYPE): New macro.
43134         * config/riscv/riscv-vector-builtins.def (DEF_RVV_TYPE_INDEX):
43135         Adapt for tuple vget/vset support.
43136         (vint8mf4_t): Ditto.
43137         (vuint8mf4_t): Ditto.
43138         (vint8mf2_t): Ditto.
43139         (vuint8mf2_t): Ditto.
43140         (vint8m1_t): Ditto.
43141         (vuint8m1_t): Ditto.
43142         (vint8m2_t): Ditto.
43143         (vuint8m2_t): Ditto.
43144         (vint8m4_t): Ditto.
43145         (vuint8m4_t): Ditto.
43146         (vint8m8_t): Ditto.
43147         (vuint8m8_t): Ditto.
43148         (vint16mf4_t): Ditto.
43149         (vuint16mf4_t): Ditto.
43150         (vint16mf2_t): Ditto.
43151         (vuint16mf2_t): Ditto.
43152         (vint16m1_t): Ditto.
43153         (vuint16m1_t): Ditto.
43154         (vint16m2_t): Ditto.
43155         (vuint16m2_t): Ditto.
43156         (vint16m4_t): Ditto.
43157         (vuint16m4_t): Ditto.
43158         (vint16m8_t): Ditto.
43159         (vuint16m8_t): Ditto.
43160         (vint32mf2_t): Ditto.
43161         (vuint32mf2_t): Ditto.
43162         (vint32m1_t): Ditto.
43163         (vuint32m1_t): Ditto.
43164         (vint32m2_t): Ditto.
43165         (vuint32m2_t): Ditto.
43166         (vint32m4_t): Ditto.
43167         (vuint32m4_t): Ditto.
43168         (vint32m8_t): Ditto.
43169         (vuint32m8_t): Ditto.
43170         (vint64m1_t): Ditto.
43171         (vuint64m1_t): Ditto.
43172         (vint64m2_t): Ditto.
43173         (vuint64m2_t): Ditto.
43174         (vint64m4_t): Ditto.
43175         (vuint64m4_t): Ditto.
43176         (vint64m8_t): Ditto.
43177         (vuint64m8_t): Ditto.
43178         (vfloat32mf2_t): Ditto.
43179         (vfloat32m1_t): Ditto.
43180         (vfloat32m2_t): Ditto.
43181         (vfloat32m4_t): Ditto.
43182         (vfloat32m8_t): Ditto.
43183         (vfloat64m1_t): Ditto.
43184         (vfloat64m2_t): Ditto.
43185         (vfloat64m4_t): Ditto.
43186         (vfloat64m8_t): Ditto.
43187         (tuple_subpart): Add tuple subpart base type.
43188         * config/riscv/riscv-vector-builtins.h (struct
43189         rvv_arg_type_info): Ditto.
43190         (tuple_type_field): New function.
43192 2023-05-03  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
43194         * config/riscv/riscv-modes.def (RVV_TUPLE_MODES): New macro.
43195         (RVV_TUPLE_PARTIAL_MODES): Ditto.
43196         * config/riscv/riscv-protos.h (riscv_v_ext_tuple_mode_p): New
43197         function.
43198         (get_nf): Ditto.
43199         (get_subpart_mode): Ditto.
43200         (get_tuple_mode): Ditto.
43201         (expand_tuple_move): Ditto.
43202         * config/riscv/riscv-v.cc (ENTRY): New macro.
43203         (TUPLE_ENTRY): Ditto.
43204         (get_nf): New function.
43205         (get_subpart_mode): Ditto.
43206         (get_tuple_mode): Ditto.
43207         (expand_tuple_move): Ditto.
43208         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_TUPLE_TYPE):
43209         New macro.
43210         (register_tuple_type): New function
43211         * config/riscv/riscv-vector-builtins.def (DEF_RVV_TUPLE_TYPE):
43212         New macro.
43213         (vint8mf8x2_t): New macro.
43214         (vuint8mf8x2_t): Ditto.
43215         (vint8mf8x3_t): Ditto.
43216         (vuint8mf8x3_t): Ditto.
43217         (vint8mf8x4_t): Ditto.
43218         (vuint8mf8x4_t): Ditto.
43219         (vint8mf8x5_t): Ditto.
43220         (vuint8mf8x5_t): Ditto.
43221         (vint8mf8x6_t): Ditto.
43222         (vuint8mf8x6_t): Ditto.
43223         (vint8mf8x7_t): Ditto.
43224         (vuint8mf8x7_t): Ditto.
43225         (vint8mf8x8_t): Ditto.
43226         (vuint8mf8x8_t): Ditto.
43227         (vint8mf4x2_t): Ditto.
43228         (vuint8mf4x2_t): Ditto.
43229         (vint8mf4x3_t): Ditto.
43230         (vuint8mf4x3_t): Ditto.
43231         (vint8mf4x4_t): Ditto.
43232         (vuint8mf4x4_t): Ditto.
43233         (vint8mf4x5_t): Ditto.
43234         (vuint8mf4x5_t): Ditto.
43235         (vint8mf4x6_t): Ditto.
43236         (vuint8mf4x6_t): Ditto.
43237         (vint8mf4x7_t): Ditto.
43238         (vuint8mf4x7_t): Ditto.
43239         (vint8mf4x8_t): Ditto.
43240         (vuint8mf4x8_t): Ditto.
43241         (vint8mf2x2_t): Ditto.
43242         (vuint8mf2x2_t): Ditto.
43243         (vint8mf2x3_t): Ditto.
43244         (vuint8mf2x3_t): Ditto.
43245         (vint8mf2x4_t): Ditto.
43246         (vuint8mf2x4_t): Ditto.
43247         (vint8mf2x5_t): Ditto.
43248         (vuint8mf2x5_t): Ditto.
43249         (vint8mf2x6_t): Ditto.
43250         (vuint8mf2x6_t): Ditto.
43251         (vint8mf2x7_t): Ditto.
43252         (vuint8mf2x7_t): Ditto.
43253         (vint8mf2x8_t): Ditto.
43254         (vuint8mf2x8_t): Ditto.
43255         (vint8m1x2_t): Ditto.
43256         (vuint8m1x2_t): Ditto.
43257         (vint8m1x3_t): Ditto.
43258         (vuint8m1x3_t): Ditto.
43259         (vint8m1x4_t): Ditto.
43260         (vuint8m1x4_t): Ditto.
43261         (vint8m1x5_t): Ditto.
43262         (vuint8m1x5_t): Ditto.
43263         (vint8m1x6_t): Ditto.
43264         (vuint8m1x6_t): Ditto.
43265         (vint8m1x7_t): Ditto.
43266         (vuint8m1x7_t): Ditto.
43267         (vint8m1x8_t): Ditto.
43268         (vuint8m1x8_t): Ditto.
43269         (vint8m2x2_t): Ditto.
43270         (vuint8m2x2_t): Ditto.
43271         (vint8m2x3_t): Ditto.
43272         (vuint8m2x3_t): Ditto.
43273         (vint8m2x4_t): Ditto.
43274         (vuint8m2x4_t): Ditto.
43275         (vint8m4x2_t): Ditto.
43276         (vuint8m4x2_t): Ditto.
43277         (vint16mf4x2_t): Ditto.
43278         (vuint16mf4x2_t): Ditto.
43279         (vint16mf4x3_t): Ditto.
43280         (vuint16mf4x3_t): Ditto.
43281         (vint16mf4x4_t): Ditto.
43282         (vuint16mf4x4_t): Ditto.
43283         (vint16mf4x5_t): Ditto.
43284         (vuint16mf4x5_t): Ditto.
43285         (vint16mf4x6_t): Ditto.
43286         (vuint16mf4x6_t): Ditto.
43287         (vint16mf4x7_t): Ditto.
43288         (vuint16mf4x7_t): Ditto.
43289         (vint16mf4x8_t): Ditto.
43290         (vuint16mf4x8_t): Ditto.
43291         (vint16mf2x2_t): Ditto.
43292         (vuint16mf2x2_t): Ditto.
43293         (vint16mf2x3_t): Ditto.
43294         (vuint16mf2x3_t): Ditto.
43295         (vint16mf2x4_t): Ditto.
43296         (vuint16mf2x4_t): Ditto.
43297         (vint16mf2x5_t): Ditto.
43298         (vuint16mf2x5_t): Ditto.
43299         (vint16mf2x6_t): Ditto.
43300         (vuint16mf2x6_t): Ditto.
43301         (vint16mf2x7_t): Ditto.
43302         (vuint16mf2x7_t): Ditto.
43303         (vint16mf2x8_t): Ditto.
43304         (vuint16mf2x8_t): Ditto.
43305         (vint16m1x2_t): Ditto.
43306         (vuint16m1x2_t): Ditto.
43307         (vint16m1x3_t): Ditto.
43308         (vuint16m1x3_t): Ditto.
43309         (vint16m1x4_t): Ditto.
43310         (vuint16m1x4_t): Ditto.
43311         (vint16m1x5_t): Ditto.
43312         (vuint16m1x5_t): Ditto.
43313         (vint16m1x6_t): Ditto.
43314         (vuint16m1x6_t): Ditto.
43315         (vint16m1x7_t): Ditto.
43316         (vuint16m1x7_t): Ditto.
43317         (vint16m1x8_t): Ditto.
43318         (vuint16m1x8_t): Ditto.
43319         (vint16m2x2_t): Ditto.
43320         (vuint16m2x2_t): Ditto.
43321         (vint16m2x3_t): Ditto.
43322         (vuint16m2x3_t): Ditto.
43323         (vint16m2x4_t): Ditto.
43324         (vuint16m2x4_t): Ditto.
43325         (vint16m4x2_t): Ditto.
43326         (vuint16m4x2_t): Ditto.
43327         (vint32mf2x2_t): Ditto.
43328         (vuint32mf2x2_t): Ditto.
43329         (vint32mf2x3_t): Ditto.
43330         (vuint32mf2x3_t): Ditto.
43331         (vint32mf2x4_t): Ditto.
43332         (vuint32mf2x4_t): Ditto.
43333         (vint32mf2x5_t): Ditto.
43334         (vuint32mf2x5_t): Ditto.
43335         (vint32mf2x6_t): Ditto.
43336         (vuint32mf2x6_t): Ditto.
43337         (vint32mf2x7_t): Ditto.
43338         (vuint32mf2x7_t): Ditto.
43339         (vint32mf2x8_t): Ditto.
43340         (vuint32mf2x8_t): Ditto.
43341         (vint32m1x2_t): Ditto.
43342         (vuint32m1x2_t): Ditto.
43343         (vint32m1x3_t): Ditto.
43344         (vuint32m1x3_t): Ditto.
43345         (vint32m1x4_t): Ditto.
43346         (vuint32m1x4_t): Ditto.
43347         (vint32m1x5_t): Ditto.
43348         (vuint32m1x5_t): Ditto.
43349         (vint32m1x6_t): Ditto.
43350         (vuint32m1x6_t): Ditto.
43351         (vint32m1x7_t): Ditto.
43352         (vuint32m1x7_t): Ditto.
43353         (vint32m1x8_t): Ditto.
43354         (vuint32m1x8_t): Ditto.
43355         (vint32m2x2_t): Ditto.
43356         (vuint32m2x2_t): Ditto.
43357         (vint32m2x3_t): Ditto.
43358         (vuint32m2x3_t): Ditto.
43359         (vint32m2x4_t): Ditto.
43360         (vuint32m2x4_t): Ditto.
43361         (vint32m4x2_t): Ditto.
43362         (vuint32m4x2_t): Ditto.
43363         (vint64m1x2_t): Ditto.
43364         (vuint64m1x2_t): Ditto.
43365         (vint64m1x3_t): Ditto.
43366         (vuint64m1x3_t): Ditto.
43367         (vint64m1x4_t): Ditto.
43368         (vuint64m1x4_t): Ditto.
43369         (vint64m1x5_t): Ditto.
43370         (vuint64m1x5_t): Ditto.
43371         (vint64m1x6_t): Ditto.
43372         (vuint64m1x6_t): Ditto.
43373         (vint64m1x7_t): Ditto.
43374         (vuint64m1x7_t): Ditto.
43375         (vint64m1x8_t): Ditto.
43376         (vuint64m1x8_t): Ditto.
43377         (vint64m2x2_t): Ditto.
43378         (vuint64m2x2_t): Ditto.
43379         (vint64m2x3_t): Ditto.
43380         (vuint64m2x3_t): Ditto.
43381         (vint64m2x4_t): Ditto.
43382         (vuint64m2x4_t): Ditto.
43383         (vint64m4x2_t): Ditto.
43384         (vuint64m4x2_t): Ditto.
43385         (vfloat32mf2x2_t): Ditto.
43386         (vfloat32mf2x3_t): Ditto.
43387         (vfloat32mf2x4_t): Ditto.
43388         (vfloat32mf2x5_t): Ditto.
43389         (vfloat32mf2x6_t): Ditto.
43390         (vfloat32mf2x7_t): Ditto.
43391         (vfloat32mf2x8_t): Ditto.
43392         (vfloat32m1x2_t): Ditto.
43393         (vfloat32m1x3_t): Ditto.
43394         (vfloat32m1x4_t): Ditto.
43395         (vfloat32m1x5_t): Ditto.
43396         (vfloat32m1x6_t): Ditto.
43397         (vfloat32m1x7_t): Ditto.
43398         (vfloat32m1x8_t): Ditto.
43399         (vfloat32m2x2_t): Ditto.
43400         (vfloat32m2x3_t): Ditto.
43401         (vfloat32m2x4_t): Ditto.
43402         (vfloat32m4x2_t): Ditto.
43403         (vfloat64m1x2_t): Ditto.
43404         (vfloat64m1x3_t): Ditto.
43405         (vfloat64m1x4_t): Ditto.
43406         (vfloat64m1x5_t): Ditto.
43407         (vfloat64m1x6_t): Ditto.
43408         (vfloat64m1x7_t): Ditto.
43409         (vfloat64m1x8_t): Ditto.
43410         (vfloat64m2x2_t): Ditto.
43411         (vfloat64m2x3_t): Ditto.
43412         (vfloat64m2x4_t): Ditto.
43413         (vfloat64m4x2_t): Ditto.
43414         * config/riscv/riscv-vector-builtins.h (DEF_RVV_TUPLE_TYPE):
43415         Ditto.
43416         * config/riscv/riscv-vector-switch.def (TUPLE_ENTRY): Ditto.
43417         * config/riscv/riscv.cc (riscv_v_ext_tuple_mode_p): New
43418         function.
43419         (TUPLE_ENTRY): Ditto.
43420         (riscv_v_ext_mode_p): New function.
43421         (riscv_v_adjust_nunits): Add tuple mode adjustment.
43422         (riscv_classify_address): Ditto.
43423         (riscv_binary_cost): Ditto.
43424         (riscv_rtx_costs): Ditto.
43425         (riscv_secondary_memory_needed): Ditto.
43426         (riscv_hard_regno_nregs): Ditto.
43427         (riscv_hard_regno_mode_ok): Ditto.
43428         (riscv_vector_mode_supported_p): Ditto.
43429         (riscv_regmode_natural_size): Ditto.
43430         (riscv_array_mode): New function.
43431         (TARGET_ARRAY_MODE): New target hook.
43432         * config/riscv/riscv.md: Add tuple modes.
43433         * config/riscv/vector-iterators.md: Ditto.
43434         * config/riscv/vector.md (mov<mode>): Add tuple modes data
43435         movement.
43436         (*mov<VT:mode>_<P:mode>): Ditto.
43438 2023-05-03  Richard Biener  <rguenther@suse.de>
43440         * cse.cc (cse_insn): Track an equivalence to the destination
43441         separately and delay using src_related for it.
43443 2023-05-03  Richard Biener  <rguenther@suse.de>
43445         * cse.cc (HASH): Turn into inline function and mix
43446         in another HASH_SHIFT bits.
43447         (SAFE_HASH): Likewise.
43449 2023-05-03  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
43451         PR target/99195
43452         * config/aarch64/aarch64-simd.md (aarch64_<sur>h<addsub><mode>): Rename to...
43453         (aarch64_<sur>h<addsub><mode><vczle><vczbe>): ... This.
43455 2023-05-03  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
43457         PR target/99195
43458         * config/aarch64/aarch64-simd.md (add<mode>3): Rename to...
43459         (add<mode>3<vczle><vczbe>): ... This.
43460         (sub<mode>3): Rename to...
43461         (sub<mode>3<vczle><vczbe>): ... This.
43462         (mul<mode>3): Rename to...
43463         (mul<mode>3<vczle><vczbe>): ... This.
43464         (*div<mode>3): Rename to...
43465         (*div<mode>3<vczle><vczbe>): ... This.
43466         (neg<mode>2): Rename to...
43467         (neg<mode>2<vczle><vczbe>): ... This.
43468         (abs<mode>2): Rename to...
43469         (abs<mode>2<vczle><vczbe>): ... This.
43470         (<frint_pattern><mode>2): Rename to...
43471         (<frint_pattern><mode>2<vczle><vczbe>): ... This.
43472         (<fmaxmin><mode>3): Rename to...
43473         (<fmaxmin><mode>3<vczle><vczbe>): ... This.
43474         (*sqrt<mode>2): Rename to...
43475         (*sqrt<mode>2<vczle><vczbe>): ... This.
43477 2023-05-03  Kito Cheng  <kito.cheng@sifive.com>
43479         * doc/md.texi (RISC-V): Add vr, vm, vd constarint.
43481 2023-05-03  Martin Liska  <mliska@suse.cz>
43483         PR tree-optimization/109693
43484         * value-range-storage.cc (vrange_allocator::vrange_allocator):
43485         Remove unused field.
43486         * value-range-storage.h: Likewise.
43488 2023-05-02  Andrew Pinski  <apinski@marvell.com>
43490         * tree-ssa-phiopt.cc (move_stmt): New function.
43491         (match_simplify_replacement): Use move_stmt instead
43492         of the inlined version.
43494 2023-05-02  Andrew Pinski  <apinski@marvell.com>
43496         * match.pd (a != 0 ? CLRSB(a) : CST -> CLRSB(a)): New
43497         pattern.
43499 2023-05-02  Andrew Pinski  <apinski@marvell.com>
43501         PR tree-optimization/109702
43502         * match.pd: Fix "a != 0 ? FUNC(a) : CST" patterns
43503         for FUNC of POPCOUNT BSWAP FFS PARITY CLZ and CTZ.
43505 2023-05-02  Andrew Pinski  <apinski@marvell.com>
43507         PR target/109657
43508         * config/aarch64/aarch64.md (*cmov<mode>_insn_m1): New
43509         insn_and_split pattern.
43511 2023-05-02  Patrick O'Neill  <patrick@rivosinc.com>
43513         * config/riscv/sync.md (atomic_load<mode>): Implement atomic
43514         load mapping.
43516 2023-05-02  Patrick O'Neill  <patrick@rivosinc.com>
43518         * config/riscv/sync.md (mem_thread_fence_1): Change fence
43519         depending on the given memory model.
43521 2023-05-02  Patrick O'Neill  <patrick@rivosinc.com>
43523         * config/riscv/riscv-protos.h (riscv_union_memmodels): Expose
43524         riscv_union_memmodels function to sync.md.
43525         * config/riscv/riscv.cc (riscv_union_memmodels): Add function to
43526         get the union of two memmodels in sync.md.
43527         (riscv_print_operand): Add %I and %J flags that output the
43528         optimal LR/SC flag bits for a given memory model.
43529         * config/riscv/sync.md: Remove static .aqrl bits on LR op/.rl
43530         bits on SC op and replace with optimized %I, %J flags.
43532 2023-05-02  Patrick O'Neill  <patrick@rivosinc.com>
43534         * config/riscv/riscv.cc
43535         (riscv_memmodel_needs_amo_release): Change function name.
43536         (riscv_print_operand): Remove unneeded %F case.
43537         * config/riscv/sync.md: Remove unneeded fences.
43539 2023-05-02  Patrick O'Neill  <patrick@rivosinc.com>
43541         PR target/89835
43542         * config/riscv/sync.md (atomic_store<mode>): Use simple store
43543         instruction in combination with fence(s).
43545 2023-05-02  Patrick O'Neill  <patrick@rivosinc.com>
43547         * config/riscv/riscv.cc (riscv_print_operand): Change behavior
43548         of %A to include release bits.
43550 2023-05-02  Patrick O'Neill  <patrick@rivosinc.com>
43552         * config/riscv/sync.md (atomic_cas_value_strong<mode>): Change
43553         FENCE/LR.aq/SC.aq into sequentially consistent LR.aqrl/SC.rl
43554         pair.
43556 2023-05-02  Patrick O'Neill  <patrick@rivosinc.com>
43558         * config/riscv/sync.md: Change LR.aq/SC.rl pairs into
43559         sequentially consistent LR.aqrl/SC.rl pairs.
43561 2023-05-02  Patrick O'Neill  <patrick@rivosinc.com>
43563         * config/riscv/riscv.cc: Remove MEMMODEL_SYNC_* cases and
43564         sanitize memmodel input with memmodel_base.
43566 2023-05-02  Yanzhang Wang  <yanzhang.wang@intel.com>
43567             Pan Li  <pan2.li@intel.com>
43569         PR target/109617
43570         * config/riscv/vector-iterators.md: Support VNx2HI and VNX4DI when MIN_VLEN >= 128.
43572 2023-05-02  Romain Naour  <romain.naour@gmail.com>
43574         * config/riscv/genrvv-type-indexer.cc: Use log2 from the C header, without
43575         the namespace.
43577 2023-05-02  Martin Liska  <mliska@suse.cz>
43579         * doc/invoke.texi: Update documentation based on param.opt file.
43581 2023-05-02  Richard Biener  <rguenther@suse.de>
43583         PR tree-optimization/109672
43584         * tree-vect-stmts.cc (vectorizable_operation): For plus,
43585         minus and negate always check the vector mode is word mode.
43587 2023-05-01  Andrew Pinski  <apinski@marvell.com>
43589         * tree-ssa-phiopt.cc: Update comment about
43590         how the transformation are implemented.
43592 2023-05-01  Jeff Law  <jlaw@ventanamicro>
43594         * config/stormy16/stormy16.cc (TARGET_LRA_P): Remove defintion.
43596 2023-05-01  Jeff Law  <jlaw@ventanamicro>
43598         * config/cris/cris.cc (TARGET_LRA_P): Remove.
43599         * config/epiphany/epiphany.cc (TARGET_LRA_P): Remove.
43600         * config/iq2000/iq2000.cc (TARGET_LRA_P): Remove.
43601         * config/m32r/m32r.cc (TARGET_LRA_P): Remove.
43602         * config/microblaze/microblaze.cc (TARGET_LRA_P): Remove.
43603         * config/mmix/mmix.cc (TARGET_LRA_P): Remove.
43605 2023-05-01  Rasmus Villemoes  <rasmus.villemoes@prevas.dk>
43607         * print-tree.h (PRINT_DECL_REMAP_DEBUG): New flag.
43608         * print-tree.cc (print_decl_identifier): Implement it.
43609         * toplev.cc (output_stack_usage_1): Use it.
43611 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43613         * value-range.h (class int_range): Remove gt_ggc_mx and gt_pch_nx
43614         friends.
43616 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43618         * value-range.h (irange::set_nonzero): Inline.
43620 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43622         * gimple-range-op.cc (cfn_ffs::fold_range): Use the correct
43623         precision.
43624         * gimple-ssa-warn-alloca.cc (alloca_call_type): Use <2> for
43625         invalid_range, as it is an inverse range.
43626         * tree-vrp.cc (find_case_label_range): Avoid trees.
43627         * value-range.cc (irange::irange_set): Delete.
43628         (irange::irange_set_1bit_anti_range): Delete.
43629         (irange::irange_set_anti_range): Delete.
43630         (irange::set): Cleanup.
43631         * value-range.h (class irange): Remove irange_set,
43632         irange_set_anti_range, irange_set_1bit_anti_range.
43633         (irange::set_undefined): Remove set to m_type.
43635 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43637         * range-op.cc (update_known_bitmask): Adjust for irange containing
43638         wide_ints internally.
43639         * tree-ssanames.cc (set_nonzero_bits): Same.
43640         * tree-ssanames.h (set_nonzero_bits): Same.
43641         * value-range-storage.cc (irange_storage::set_irange): Same.
43642         (irange_storage::get_irange): Same.
43643         * value-range.cc (irange::operator=): Same.
43644         (irange::irange_set): Same.
43645         (irange::irange_set_1bit_anti_range): Same.
43646         (irange::irange_set_anti_range): Same.
43647         (irange::set): Same.
43648         (irange::verify_range): Same.
43649         (irange::contains_p): Same.
43650         (irange::irange_single_pair_union): Same.
43651         (irange::union_): Same.
43652         (irange::irange_contains_p): Same.
43653         (irange::intersect): Same.
43654         (irange::invert): Same.
43655         (irange::set_range_from_nonzero_bits): Same.
43656         (irange::set_nonzero_bits): Same.
43657         (mask_to_wi): Same.
43658         (irange::intersect_nonzero_bits): Same.
43659         (irange::union_nonzero_bits): Same.
43660         (gt_ggc_mx): Same.
43661         (gt_pch_nx): Same.
43662         (tree_range): Same.
43663         (range_tests_strict_enum): Same.
43664         (range_tests_misc): Same.
43665         (range_tests_nonzero_bits): Same.
43666         * value-range.h (irange::type): Same.
43667         (irange::varying_compatible_p): Same.
43668         (irange::irange): Same.
43669         (int_range::int_range): Same.
43670         (irange::set_undefined): Same.
43671         (irange::set_varying): Same.
43672         (irange::lower_bound): Same.
43673         (irange::upper_bound): Same.
43675 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43677         * gimple-range-fold.cc (tree_lower_bound): Delete.
43678         (tree_upper_bound): Delete.
43679         (vrp_val_max): Delete.
43680         (vrp_val_min): Delete.
43681         (fold_using_range::range_of_ssa_name_with_loop_info): Call
43682         range_of_var_in_loop.
43683         * vr-values.cc (valid_value_p): Delete.
43684         (fix_overflow): Delete.
43685         (get_scev_info): New.
43686         (bounds_of_var_in_loop): Refactor into...
43687         (induction_variable_may_overflow_p): ...this,
43688         (range_from_loop_direction): ...and this,
43689         (range_of_var_in_loop): ...and this.
43690         * vr-values.h (bounds_of_var_in_loop): Delete.
43691         (range_of_var_in_loop): New.
43693 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43695         * gimple-range-fold.cc (adjust_pointer_diff_expr): Rewrite with
43696         irange_val*.
43697         (vrp_val_max): New.
43698         (vrp_val_min): New.
43699         * gimple-range-op.cc (cfn_strlen::fold_range): Use irange_val_*.
43700         * range-op.cc (max_limit): Same.
43701         (min_limit): Same.
43702         (plus_minus_ranges): Same.
43703         (operator_rshift::op1_range): Same.
43704         (operator_cast::inside_domain_p): Same.
43705         * value-range.cc (vrp_val_is_max): Delete.
43706         (vrp_val_is_min): Delete.
43707         (range_tests_misc): Use irange_val_*.
43708         * value-range.h (vrp_val_is_min): Delete.
43709         (vrp_val_is_max): Delete.
43710         (vrp_val_max): Delete.
43711         (irange_val_min): New.
43712         (vrp_val_min): Delete.
43713         (irange_val_max): New.
43714         * vr-values.cc (check_for_binary_op_overflow): Use irange_val_*.
43716 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43718         * fold-const.cc (expr_not_equal_to): Convert to irange wide_int API.
43719         * gimple-fold.cc (size_must_be_zero_p): Same.
43720         * gimple-loop-versioning.cc
43721         (loop_versioning::prune_loop_conditions): Same.
43722         * gimple-range-edge.cc (gcond_edge_range): Same.
43723         (gimple_outgoing_range::calc_switch_ranges): Same.
43724         * gimple-range-fold.cc (adjust_imagpart_expr): Same.
43725         (adjust_realpart_expr): Same.
43726         (fold_using_range::range_of_address): Same.
43727         (fold_using_range::relation_fold_and_or): Same.
43728         * gimple-range-gori.cc (gori_compute::gori_compute): Same.
43729         (range_is_either_true_or_false): Same.
43730         * gimple-range-op.cc (cfn_toupper_tolower::get_letter_range): Same.
43731         (cfn_clz::fold_range): Same.
43732         (cfn_ctz::fold_range): Same.
43733         * gimple-range-tests.cc (class test_expr_eval): Same.
43734         * gimple-ssa-warn-alloca.cc (alloca_call_type): Same.
43735         * ipa-cp.cc (ipa_value_range_from_jfunc): Same.
43736         (propagate_vr_across_jump_function): Same.
43737         (decide_whether_version_node): Same.
43738         * ipa-prop.cc (ipa_get_value_range): Same.
43739         * ipa-prop.h (ipa_range_set_and_normalize): Same.
43740         * range-op.cc (get_shift_range): Same.
43741         (value_range_from_overflowed_bounds): Same.
43742         (value_range_with_overflow): Same.
43743         (create_possibly_reversed_range): Same.
43744         (equal_op1_op2_relation): Same.
43745         (not_equal_op1_op2_relation): Same.
43746         (lt_op1_op2_relation): Same.
43747         (le_op1_op2_relation): Same.
43748         (gt_op1_op2_relation): Same.
43749         (ge_op1_op2_relation): Same.
43750         (operator_mult::op1_range): Same.
43751         (operator_exact_divide::op1_range): Same.
43752         (operator_lshift::op1_range): Same.
43753         (operator_rshift::op1_range): Same.
43754         (operator_cast::op1_range): Same.
43755         (operator_logical_and::fold_range): Same.
43756         (set_nonzero_range_from_mask): Same.
43757         (operator_bitwise_or::op1_range): Same.
43758         (operator_bitwise_xor::op1_range): Same.
43759         (operator_addr_expr::fold_range): Same.
43760         (pointer_plus_operator::wi_fold): Same.
43761         (pointer_or_operator::op1_range): Same.
43762         (INT): Same.
43763         (UINT): Same.
43764         (INT16): Same.
43765         (UINT16): Same.
43766         (SCHAR): Same.
43767         (UCHAR): Same.
43768         (range_op_cast_tests): Same.
43769         (range_op_lshift_tests): Same.
43770         (range_op_rshift_tests): Same.
43771         (range_op_bitwise_and_tests): Same.
43772         (range_relational_tests): Same.
43773         * range.cc (range_zero): Same.
43774         (range_nonzero): Same.
43775         * range.h (range_true): Same.
43776         (range_false): Same.
43777         (range_true_and_false): Same.
43778         * tree-data-ref.cc (split_constant_offset_1): Same.
43779         * tree-ssa-loop-ch.cc (entry_loop_condition_is_static): Same.
43780         * tree-ssa-loop-unswitch.cc (struct unswitch_predicate): Same.
43781         (find_unswitching_predicates_for_bb): Same.
43782         * tree-ssa-phiopt.cc (value_replacement): Same.
43783         * tree-ssa-threadbackward.cc
43784         (back_threader::find_taken_edge_cond): Same.
43785         * tree-ssanames.cc (ssa_name_has_boolean_range): Same.
43786         * tree-vrp.cc (find_case_label_range): Same.
43787         * value-query.cc (range_query::get_tree_range): Same.
43788         * value-range.cc (irange::set_nonnegative): Same.
43789         (frange::contains_p): Same.
43790         (frange::singleton_p): Same.
43791         (frange::internal_singleton_p): Same.
43792         (irange::irange_set): Same.
43793         (irange::irange_set_1bit_anti_range): Same.
43794         (irange::irange_set_anti_range): Same.
43795         (irange::set): Same.
43796         (irange::operator==): Same.
43797         (irange::singleton_p): Same.
43798         (irange::contains_p): Same.
43799         (irange::set_range_from_nonzero_bits): Same.
43800         (DEFINE_INT_RANGE_INSTANCE): Same.
43801         (INT): Same.
43802         (UINT): Same.
43803         (SCHAR): Same.
43804         (UINT128): Same.
43805         (UCHAR): Same.
43806         (range): New.
43807         (tree_range): New.
43808         (range_int): New.
43809         (range_uint): New.
43810         (range_uint128): New.
43811         (range_uchar): New.
43812         (range_char): New.
43813         (build_range3): Convert to irange wide_int API.
43814         (range_tests_irange3): Same.
43815         (range_tests_int_range_max): Same.
43816         (range_tests_strict_enum): Same.
43817         (range_tests_misc): Same.
43818         (range_tests_nonzero_bits): Same.
43819         (range_tests_nan): Same.
43820         (range_tests_signed_zeros): Same.
43821         * value-range.h (Value_Range::Value_Range): Same.
43822         (irange::set): Same.
43823         (irange::nonzero_p): Same.
43824         (irange::contains_p): Same.
43825         (range_includes_zero_p): Same.
43826         (irange::set_nonzero): Same.
43827         (irange::set_zero): Same.
43828         (contains_zero_p): Same.
43829         (frange::contains_p): Same.
43830         * vr-values.cc
43831         (simplify_using_ranges::op_with_boolean_value_range_p): Same.
43832         (bounds_of_var_in_loop): Same.
43833         (simplify_using_ranges::legacy_fold_cond_overflow): Same.
43835 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43837         * value-range.cc (irange::irange_union): Rename to...
43838         (irange::union_): ...this.
43839         (irange::irange_intersect): Rename to...
43840         (irange::intersect): ...this.
43841         * value-range.h (irange::union_): Delete.
43842         (irange::intersect): Delete.
43844 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43846         * vr-values.cc (bounds_of_var_in_loop): Convert to irange API.
43848 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43850         * vr-values.cc (check_for_binary_op_overflow): Tidy up by using
43851         ranger API.
43852         (compare_ranges): Delete.
43853         (compare_range_with_value): Delete.
43854         (bounds_of_var_in_loop): Tidy up by using ranger API.
43855         (simplify_using_ranges::fold_cond_with_ops): Cleanup and rename
43856         from vrp_evaluate_conditional_warnv_with_ops_using_ranges.
43857         (simplify_using_ranges::legacy_fold_cond_overflow): Remove
43858         strict_overflow_p and only_ranges.
43859         (simplify_using_ranges::legacy_fold_cond): Adjust call to
43860         legacy_fold_cond_overflow.
43861         (simplify_using_ranges::simplify_abs_using_ranges): Adjust for
43862         rename.
43863         (range_fits_type_p): Rename value_range to irange.
43864         * vr-values.h (range_fits_type_p): Adjust prototype.
43866 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43868         * value-range.cc (irange::irange_set_anti_range): Remove uses of
43869         tree_lower_bound and tree_upper_bound.
43870         (irange::verify_range): Same.
43871         (irange::operator==): Same.
43872         (irange::singleton_p): Same.
43873         * value-range.h (irange::tree_lower_bound): Delete.
43874         (irange::tree_upper_bound): Delete.
43875         (irange::lower_bound): Delete.
43876         (irange::upper_bound): Delete.
43877         (irange::zero_p): Remove uses of tree_lower_bound and
43878         tree_upper_bound.
43880 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43882         * tree-ssa-loop-niter.cc (refine_value_range_using_guard): Remove
43883         kind() call.
43884         (determine_value_range): Same.
43885         (record_nonwrapping_iv): Same.
43886         (infer_loop_bounds_from_signedness): Same.
43887         (scev_var_range_cant_overflow): Same.
43888         * tree-vrp.cc (operand_less_p): Delete.
43889         * tree-vrp.h (operand_less_p): Delete.
43890         * value-range.cc (get_legacy_range): Remove uses of deprecated API.
43891         (irange::value_inside_range): Delete.
43892         * value-range.h (vrange::kind): Delete.
43893         (irange::num_pairs): Remove check of m_kind.
43894         (irange::min): Delete.
43895         (irange::max): Delete.
43897 2023-05-01  Aldy Hernandez  <aldyh@redhat.com>
43899         * gimple-fold.cc (maybe_fold_comparisons_from_match_pd): Adjust
43900         for vrange_storage.
43901         * gimple-range-cache.cc (sbr_vector::sbr_vector): Same.
43902         (sbr_vector::grow): Same.
43903         (sbr_vector::set_bb_range): Same.
43904         (sbr_vector::get_bb_range): Same.
43905         (sbr_sparse_bitmap::sbr_sparse_bitmap): Same.
43906         (sbr_sparse_bitmap::set_bb_range): Same.
43907         (sbr_sparse_bitmap::get_bb_range): Same.
43908         (block_range_cache::block_range_cache): Same.
43909         (ssa_global_cache::ssa_global_cache): Same.
43910         (ssa_global_cache::get_global_range): Same.
43911         (ssa_global_cache::set_global_range): Same.
43912         * gimple-range-cache.h: Same.
43913         * gimple-range-edge.cc
43914         (gimple_outgoing_range::gimple_outgoing_range): Same.
43915         (gimple_outgoing_range::switch_edge_range): Same.
43916         (gimple_outgoing_range::calc_switch_ranges): Same.
43917         * gimple-range-edge.h: Same.
43918         * gimple-range-infer.cc
43919         (infer_range_manager::infer_range_manager): Same.
43920         (infer_range_manager::get_nonzero): Same.
43921         (infer_range_manager::maybe_adjust_range): Same.
43922         (infer_range_manager::add_range): Same.
43923         * gimple-range-infer.h: Rename obstack_vrange_allocator to
43924         vrange_allocator.
43925         * tree-core.h (struct irange_storage_slot): Remove.
43926         (struct tree_ssa_name): Remove irange_info and frange_info.  Make
43927         range_info a pointer to vrange_storage.
43928         * tree-ssanames.cc (range_info_fits_p): Adjust for vrange_storage.
43929         (range_info_alloc): Same.
43930         (range_info_free): Same.
43931         (range_info_get_range): Same.
43932         (range_info_set_range): Same.
43933         (get_nonzero_bits): Same.
43934         * value-query.cc (get_ssa_name_range_info): Same.
43935         * value-range-storage.cc (class vrange_internal_alloc): New.
43936         (class vrange_obstack_alloc): New.
43937         (class vrange_ggc_alloc): New.
43938         (vrange_allocator::vrange_allocator): New.
43939         (vrange_allocator::~vrange_allocator): New.
43940         (vrange_storage::alloc_slot): New.
43941         (vrange_allocator::alloc): New.
43942         (vrange_allocator::free): New.
43943         (vrange_allocator::clone): New.
43944         (vrange_allocator::clone_varying): New.
43945         (vrange_allocator::clone_undefined): New.
43946         (vrange_storage::alloc): New.
43947         (vrange_storage::set_vrange): Remove slot argument.
43948         (vrange_storage::get_vrange): Same.
43949         (vrange_storage::fits_p): Same.
43950         (vrange_storage::equal_p): New.
43951         (irange_storage::write_lengths_address): New.
43952         (irange_storage::lengths_address): New.
43953         (irange_storage_slot::alloc_slot): Remove.
43954         (irange_storage::alloc): New.
43955         (irange_storage_slot::irange_storage_slot): Remove.
43956         (irange_storage::irange_storage): New.
43957         (write_wide_int): New.
43958         (irange_storage_slot::set_irange): Remove.
43959         (irange_storage::set_irange): New.
43960         (read_wide_int): New.
43961         (irange_storage_slot::get_irange): Remove.
43962         (irange_storage::get_irange): New.
43963         (irange_storage_slot::size): Remove.
43964         (irange_storage::equal_p): New.
43965         (irange_storage_slot::num_wide_ints_needed): Remove.
43966         (irange_storage::size): New.
43967         (irange_storage_slot::fits_p): Remove.
43968         (irange_storage::fits_p): New.
43969         (irange_storage_slot::dump): Remove.
43970         (irange_storage::dump): New.
43971         (frange_storage_slot::alloc_slot): Remove.
43972         (frange_storage::alloc): New.
43973         (frange_storage_slot::set_frange): Remove.
43974         (frange_storage::set_frange): New.
43975         (frange_storage_slot::get_frange): Remove.
43976         (frange_storage::get_frange): New.
43977         (frange_storage_slot::fits_p): Remove.
43978         (frange_storage::equal_p): New.
43979         (frange_storage::fits_p): New.
43980         (ggc_vrange_allocator): New.
43981         (ggc_alloc_vrange_storage): New.
43982         * value-range-storage.h (class vrange_storage): Rewrite.
43983         (class irange_storage): Rewrite.
43984         (class frange_storage): Rewrite.
43985         (class obstack_vrange_allocator): Remove.
43986         (class ggc_vrange_allocator): Remove.
43987         (vrange_allocator::alloc_vrange): Remove.
43988         (vrange_allocator::alloc_irange): Remove.
43989         (vrange_allocator::alloc_frange): Remove.
43990         (ggc_alloc_vrange_storage): New.
43991         * value-range.h (class irange): Rename vrange_allocator to
43992         irange_storage.
43993         (class frange): Same.
43995 2023-04-30  Roger Sayle  <roger@nextmovesoftware.com>
43997         * config/stormy16/stormy16.md (neghi2): Rewrite pattern using
43998         inc to avoid clobbering the carry flag.
44000 2023-04-30  Andrew Pinski  <apinski@marvell.com>
44002         * match.pd: Add patterns for "a != 0 ? FUNC(a) : CST"
44003         for FUNC of POPCOUNT BSWAP FFS PARITY CLZ and CTZ.
44005 2023-04-30  Andrew Pinski  <apinski@marvell.com>
44007         * tree-ssa-phiopt.cc (empty_bb_or_one_feeding_into_p):
44008         Allow some builtin/internal function calls which
44009         are known not to trap/throw.
44010         (phiopt_worker::match_simplify_replacement):
44011         Use name instead of getting the lhs again.
44013 2023-04-30  Joakim Nohlgård  <joakim@nohlgard.se>
44015         * configure: Regenerate.
44016         * configure.ac: Use ld -r in the check for HAVE_LD_RO_RW_SECTION_MIXING
44018 2023-04-29  Hans-Peter Nilsson  <hp@axis.com>
44020         * reload1.cc (emit_insn_if_valid_for_reload_1): Rename from
44021         emit_insn_if_valid_for_reload.
44022         (emit_insn_if_valid_for_reload): Call new helper, and if a SET fails
44023         to be recognized, also try emitting a parallel that clobbers
44024         TARGET_FLAGS_REGNUM, as applicable.
44026 2023-04-29  Roger Sayle  <roger@nextmovesoftware.com>
44028         * config/stormy16/stormy16.md (neghi2): Convert from a define_expand
44029         to a define_insn.
44030         (*rotatehi_1): New define_insn for efficient 2 insn sequence.
44031         (*rotatehi_8, *rotaterthi_8): New define_insn to emit a swpb.
44033 2023-04-29  Roger Sayle  <roger@nextmovesoftware.com>
44035         * config/stormy16/stormy16.md (any_lshift): New code iterator.
44036         (any_or_plus): Likewise.
44037         (any_rotate): Likewise.
44038         (*<any_lshift>_and_internal): New define_insn_and_split to
44039         recognize a logical shift followed by an AND, and split it
44040         again after reload.
44041         (*swpn): New define_insn matching xstormy16's swpn.
44042         (*swpn_zext): New define_insn recognizing swpn followed by
44043         zero_extendqihi2, i.e. with the high byte set to zero.
44044         (*swpn_sext): Likewise, for swpn followed by cbw.
44045         (*swpn_sext_2): Likewise, for an alternate RTL form.
44046         (*swpn_zext_ior): A pre-reload splitter so that an swpn+zext+ior
44047         sequence is split in the correct place to recognize the *swpn_zext
44048         followed by any_or_plus (ior, xor or plus) instruction.
44050 2023-04-29  Mikael Pettersson  <mikpelinux@gmail.com>
44052         PR target/105525
44053         * config.gcc (vax-*-linux*): Add glibc-stdint.h.
44054         (lm32-*-uclinux*): Likewise.
44056 2023-04-29  Fei Gao  <gaofei@eswincomputing.com>
44058         * config/riscv/riscv.cc (riscv_avoid_save_libcall): helper function
44059         for riscv_use_save_libcall.
44060         (riscv_use_save_libcall): call riscv_avoid_save_libcall.
44061         (riscv_compute_frame_info): restructure to decouple stack allocation
44062         for rv32e w/o save-restore.
44064 2023-04-28  Eugene Rozenfeld  <erozen@microsoft.com>
44066         * doc/install.texi: Fix documentation typo
44068 2023-04-28  Matevos Mehrabyan  <matevosmehrabyan@gmail.com>
44070         * config/riscv/iterators.md (only_div, paired_mod): New iterators.
44071         (u): Add div/udiv cases.
44072         * config/riscv/riscv-protos.h (riscv_use_divmod_expander): Prototype.
44073         * config/riscv/riscv.cc (struct riscv_tune_param): Add field for
44074         divmod expansion.
44075         (rocket_tune_info, sifive_7_tune_info): Initialize new field.
44076         (thead_c906_tune_info): Likewise.
44077         (optimize_size_tune_info): Likewise.
44078         (riscv_use_divmod_expander): New function.
44079         * config/riscv/riscv.md (<u>divmod<mode>4): New expander.
44081 2023-04-28  Karen Sargsyan  <karen1999411@gmail.com>
44083         * config/riscv/bitmanip.md: Added clmulr instruction.
44084         * config/riscv/riscv-builtins.cc (AVAIL): Add new.
44085         * config/riscv/riscv.md: (UNSPEC_CLMULR): Add new unspec type.
44086         (type): Add clmul
44087         * config/riscv/riscv-cmo.def: Added built-in function for clmulr.
44088         * config/riscv/crypto.md: Move clmul[h] instructions to bitmanip.md.
44089         * config/riscv/riscv-scalar-crypto.def: Move clmul[h] built-in
44090         functions to riscv-cmo.def.
44091         * config/riscv/generic.md: Add clmul to list of instructions
44092         using the generic_imul reservation.
44094 2023-04-28  Jivan Hakobyan  <jivanhakobyan9@gmail.com>
44096         * config/riscv/bitmanip.md: Added expanders for minu/maxu instructions
44098 2023-04-28  Andrew Pinski  <apinski@marvell.com>
44100         PR tree-optimization/100958
44101         * tree-ssa-phiopt.cc (two_value_replacement): Remove.
44102         (pass_phiopt::execute): Don't call two_value_replacement.
44103         * match.pd (a !=/== CST1 ? CST2 : CST3): Add pattern to
44104         handle what two_value_replacement did.
44106 2023-04-28  Andrew Pinski  <apinski@marvell.com>
44108         * match.pd: Add patterns for
44109         "(A CMP B) ? MIN/MAX<A, C> : MIN/MAX <B, C>".
44111 2023-04-28  Andrew Pinski  <apinski@marvell.com>
44113         * match.pd: Factor out the deciding the min/max from
44114         the "(cond (cmp (convert1? x) c1) (convert2? x) c2)"
44115         pattern to ...
44116         * fold-const.cc (minmax_from_comparison): this new function.
44117         * fold-const.h (minmax_from_comparison): New prototype.
44119 2023-04-28  Roger Sayle  <roger@nextmovesoftware.com>
44121         PR rtl-optimization/109476
44122         * lower-subreg.cc: Include explow.h for force_reg.
44123         (find_decomposable_shift_zext): Pass an additional SPEED_P argument.
44124         If decomposing a suitable LSHIFTRT and we're not splitting
44125         ZERO_EXTEND (based on the current SPEED_P), then use a ZERO_EXTEND
44126         instead of setting a high part SUBREG to zero, which helps combine.
44127         (decompose_multiword_subregs): Update call to resolve_shift_zext.
44129 2023-04-28  Richard Biener  <rguenther@suse.de>
44131         * tree-vect-data-refs.cc (vect_analyze_data_refs): Always
44132         consider scatters.
44133         * tree-vect-stmts.cc (vect_model_store_cost): Pass in the
44134         gather-scatter info and cost emulated scatters accordingly.
44135         (get_load_store_type): Support emulated scatters.
44136         (vectorizable_store): Likewise.  Emulate them by extracting
44137         scalar offsets and data, doing scalar stores.
44139 2023-04-28  Richard Biener  <rguenther@suse.de>
44141         * config/i386/i386.cc (ix86_vector_costs::add_stmt_cost):
44142         Tame down element extracts and scalar loads for gather/scatter
44143         similar to elementwise strided accesses.
44145 2023-04-28  Pan Li  <pan2.li@intel.com>
44146             kito-cheng  <kito.cheng@sifive.com>
44148         * config/riscv/vector.md: Add new define split to perform
44149         the simplification.
44151 2023-04-28  Richard Biener  <rguenther@suse.de>
44153         PR ipa/109652
44154         * ipa-param-manipulation.cc
44155         (ipa_param_body_adjustments::modify_expression): Allow
44156         conversion of a register to a non-register type.  Elide
44157         conversions inside BIT_FIELD_REFs.
44159 2023-04-28  Richard Biener  <rguenther@suse.de>
44161         PR tree-optimization/109644
44162         * tree-cfg.cc (verify_types_in_gimple_reference): Check
44163         register constraints on the outermost VIEW_CONVERT_EXPR
44164         only.  Do not allow register or invariant bases on
44165         multi-level or possibly variable index handled components.
44167 2023-04-28  Richard Biener  <rguenther@suse.de>
44169         * gimplify.cc (gimplify_compound_lval): When there's a
44170         non-register type produced by one of the handled component
44171         operations make sure we get a non-register base.
44173 2023-04-28  Richard Biener  <rguenther@suse.de>
44175         PR tree-optimization/108752
44176         * tree-vect-generic.cc (build_replicated_const): Rename
44177         to build_replicated_int_cst and move to tree.{h,cc}.
44178         (do_plus_minus): Adjust.
44179         (do_negate): Likewise.
44180         * tree-vect-stmts.cc (vectorizable_operation): Emit emulated
44181         arithmetic vector operations in lowered form.
44182         * tree.h (build_replicated_int_cst): Declare.
44183         * tree.cc (build_replicated_int_cst): Moved from
44184         tree-vect-generic.cc build_replicated_const.
44186 2023-04-28  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
44188         PR target/99195
44189         * config/aarch64/aarch64-simd.md (aarch64_rbit<mode>): Rename to...
44190         (aarch64_rbit<mode><vczle><vczbe>): ... This.
44191         (neg<mode>2): Rename to...
44192         (neg<mode>2<vczle><vczbe>): ... This.
44193         (abs<mode>2): Rename to...
44194         (abs<mode>2<vczle><vczbe>): ... This.
44195         (aarch64_abs<mode>): Rename to...
44196         (aarch64_abs<mode><vczle><vczbe>): ... This.
44197         (one_cmpl<mode>2): Rename to...
44198         (one_cmpl<mode>2<vczle><vczbe>): ... This.
44199         (clrsb<mode>2): Rename to...
44200         (clrsb<mode>2<vczle><vczbe>): ... This.
44201         (clz<mode>2): Rename to...
44202         (clz<mode>2<vczle><vczbe>): ... This.
44203         (popcount<mode>2): Rename to...
44204         (popcount<mode>2<vczle><vczbe>): ... This.
44206 2023-04-28  Jakub Jelinek  <jakub@redhat.com>
44208         * gimple-range-op.cc (class cfn_sqrt): New type.
44209         (op_cfn_sqrt): New variable.
44210         (gimple_range_op_handler::maybe_builtin_call): Handle
44211         CASE_CFN_SQRT{,_FN}.
44213 2023-04-28  Aldy Hernandez  <aldyh@redhat.com>
44214             Jakub Jelinek  <jakub@redhat.com>
44216         * value-range.h (frange_nextafter): Declare.
44217         * gimple-range-op.cc (class cfn_sincos): New.
44218         (op_cfn_sin, op_cfn_cos): New variables.
44219         (gimple_range_op_handler::maybe_builtin_call): Handle
44220         CASE_CFN_{SIN,COS}{,_FN}.
44222 2023-04-28  Jakub Jelinek  <jakub@redhat.com>
44224         * target.def (libm_function_max_error): New target hook.
44225         * doc/tm.texi.in (TARGET_LIBM_FUNCTION_MAX_ERROR): Add.
44226         * doc/tm.texi: Regenerated.
44227         * targhooks.h (default_libm_function_max_error,
44228         glibc_linux_libm_function_max_error): Declare.
44229         * targhooks.cc: Include case-cfn-macros.h.
44230         (default_libm_function_max_error,
44231         glibc_linux_libm_function_max_error): New functions.
44232         * config/linux.h (TARGET_LIBM_FUNCTION_MAX_ERROR): Redefine.
44233         * config/linux-protos.h (linux_libm_function_max_error): Declare.
44234         * config/linux.cc: Include target.h and targhooks.h.
44235         (linux_libm_function_max_error): New function.
44236         * config/arc/arc.cc: Include targhooks.h and case-cfn-macros.h.
44237         (arc_libm_function_max_error): New function.
44238         (TARGET_LIBM_FUNCTION_MAX_ERROR): Redefine.
44239         * config/i386/i386.cc (ix86_libc_has_fast_function): Formatting fix.
44240         (ix86_libm_function_max_error): New function.
44241         (TARGET_LIBM_FUNCTION_MAX_ERROR): Redefine.
44242         * config/rs6000/rs6000-protos.h
44243         (rs6000_linux_libm_function_max_error): Declare.
44244         * config/rs6000/rs6000-linux.cc: Include target.h, targhooks.h, tree.h
44245         and case-cfn-macros.h.
44246         (rs6000_linux_libm_function_max_error): New function.
44247         * config/rs6000/linux.h (TARGET_LIBM_FUNCTION_MAX_ERROR): Redefine.
44248         * config/rs6000/linux64.h (TARGET_LIBM_FUNCTION_MAX_ERROR): Redefine.
44249         * config/or1k/or1k.cc: Include targhooks.h and case-cfn-macros.h.
44250         (or1k_libm_function_max_error): New function.
44251         (TARGET_LIBM_FUNCTION_MAX_ERROR): Redefine.
44253 2023-04-28  Alexandre Oliva  <oliva@adacore.com>
44255         * gimple-harden-conditionals.cc (insert_edge_check_and_trap):
44256         Move detach value calls...
44257         (pass_harden_conditional_branches::execute): ... here.
44258         (pass_harden_compares::execute): Detach values before
44259         compares.
44261 2023-04-27  Andrew Stubbs  <ams@codesourcery.com>
44263         * config/gcn/gcn-valu.md (cmul<conj_op><mode>3): Use gcn_gen_undef.
44264         (cml<addsub_as><mode>4): Likewise.
44265         (vec_addsub<mode>3): Likewise.
44266         (cadd<rot><mode>3): Likewise.
44267         (vec_fmaddsub<mode>4): Likewise.
44268         (vec_fmsubadd<mode>4): Likewise, and use sub for the odd lanes.
44270 2023-04-27  Andrew Pinski  <apinski@marvell.com>
44272         * tree-ssa-phiopt.cc (phiopt_early_allow): Allow for
44273         up to 2 min/max expressions in the sequence/match code.
44275 2023-04-27  Andrew Pinski  <apinski@marvell.com>
44277         * rtlanal.cc (may_trap_p_1): Treat SMIN/SMAX similar as
44278         COMPARISON.
44279         * tree-eh.cc (operation_could_trap_helper_p): Treate
44280         MIN_EXPR/MAX_EXPR similar as other comparisons.
44282 2023-04-27  Andrew Pinski  <apinski@marvell.com>
44284         * tree-ssa-phiopt.cc (cond_store_replacement): Remove
44285         prototype.
44286         (cond_if_else_store_replacement): Likewise.
44287         (get_non_trapping): Likewise.
44288         (store_elim_worker): Move into ...
44289         (pass_cselim::execute): This.
44291 2023-04-27  Andrew Pinski  <apinski@marvell.com>
44293         * tree-ssa-phiopt.cc (two_value_replacement): Remove
44294         prototype.
44295         (match_simplify_replacement): Likewise.
44296         (factor_out_conditional_conversion): Likewise.
44297         (value_replacement): Likewise.
44298         (minmax_replacement): Likewise.
44299         (spaceship_replacement): Likewise.
44300         (cond_removal_in_builtin_zero_pattern): Likewise.
44301         (hoist_adjacent_loads): Likewise.
44302         (tree_ssa_phiopt_worker): Move into ...
44303         (pass_phiopt::execute): this.
44305 2023-04-27  Andrew Pinski  <apinski@marvell.com>
44307         * tree-ssa-phiopt.cc (tree_ssa_phiopt_worker): Remove
44308         do_store_elim argument and split that part out to ...
44309         (store_elim_worker): This new function.
44310         (pass_cselim::execute): Call store_elim_worker.
44311         (pass_phiopt::execute): Update call to tree_ssa_phiopt_worker.
44313 2023-04-27  Jan Hubicka  <jh@suse.cz>
44315         * cfgloopmanip.h (unloop_loops): Export.
44316         * tree-ssa-loop-ch.cc (ch_base::copy_headers): Unloop loops
44317         that no longer loop.
44318         * tree-ssa-loop-ivcanon.cc (unloop_loops): Export; do not free
44319         vectors of loops to unloop.
44320         (canonicalize_induction_variables): Free vectors here.
44321         (tree_unroll_loops_completely): Free vectors here.
44323 2023-04-27  Richard Biener  <rguenther@suse.de>
44325         PR tree-optimization/109170
44326         * gimple-range-op.cc (gimple_range_op_handler::maybe_builtin_call):
44327         Handle __builtin_expect and similar via cfn_pass_through_arg1
44328         and inspecting the calls fnspec.
44329         * builtins.cc (builtin_fnspec): Handle BUILT_IN_EXPECT
44330         and BUILT_IN_EXPECT_WITH_PROBABILITY.
44332 2023-04-27  Alexandre Oliva  <oliva@adacore.com>
44334         * genmultilib: Use CONFIG_SHELL to run sub-scripts.
44336 2023-04-27  Aldy Hernandez  <aldyh@redhat.com>
44338         PR tree-optimization/109639
44339         * ipa-cp.cc (ipa_value_range_from_jfunc): Normalize range.
44340         (propagate_vr_across_jump_function): Same.
44341         * ipa-fnsummary.cc (evaluate_conditions_for_known_args): Same.
44342         * ipa-prop.h (ipa_range_set_and_normalize): New.
44343         * value-range.cc (irange::set): Assert min and max are INTEGER_CST.
44345 2023-04-27  Richard Biener  <rguenther@suse.de>
44347         * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Do not
44348         create a CTOR operand in the result when simplifying GIMPLE.
44350 2023-04-27  Richard Biener  <rguenther@suse.de>
44352         * gimplify.cc (gimplify_compound_lval): When the base
44353         gimplified to a register make sure to split up chains
44354         of operations.
44356 2023-04-27  Richard Biener  <rguenther@suse.de>
44358         PR ipa/109607
44359         * ipa-param-manipulation.h
44360         (ipa_param_body_adjustments::modify_expression): Add extra_stmts
44361         argument.
44362         * ipa-param-manipulation.cc
44363         (ipa_param_body_adjustments::modify_expression): Likewise.
44364         When we need a conversion and the replacement is a register
44365         split the conversion out.
44366         (ipa_param_body_adjustments::modify_assignment): Pass
44367         extra_stmts to RHS modify_expression.
44369 2023-04-27  Jonathan Wakely  <jwakely@redhat.com>
44371         * doc/extend.texi (Zero Length): Describe example.
44373 2023-04-27  Richard Biener  <rguenther@suse.de>
44375         PR tree-optimization/109594
44376         * tree-ssa.cc (non_rewritable_mem_ref_base): Constrain
44377         what we rewrite to a register based on the above.
44379 2023-04-26  Patrick O'Neill  <patrick@rivosinc.com>
44381         * config/riscv/riscv.cc: Fix whitespace.
44382         * config/riscv/sync.md: Fix whitespace.
44384 2023-04-26  Andrew MacLeod  <amacleod@redhat.com>
44386         PR tree-optimization/108697
44387         * gimple-range-cache.cc (ssa_global_cache::clear_range): Do
44388         not clear the vector on an out of range query.
44389         (ssa_cache::dump): Use dump_range_query instead of get_range.
44390         (ssa_cache::dump_range_query): New.
44391         (ssa_lazy_cache::dump_range_query): New.
44392         (ssa_lazy_cache::set_range): New.
44393         * gimple-range-cache.h (ssa_cache::dump_range_query): New.
44394         (class ssa_lazy_cache): New.
44395         (ssa_lazy_cache::ssa_lazy_cache): New.
44396         (ssa_lazy_cache::~ssa_lazy_cache): New.
44397         (ssa_lazy_cache::get_range): New.
44398         (ssa_lazy_cache::clear_range): New.
44399         (ssa_lazy_cache::clear): New.
44400         (ssa_lazy_cache::dump): New.
44401         * gimple-range-path.cc (path_range_query::path_range_query): Do
44402         not allocate a ssa_cache object nor has_cache bitmap.
44403         (path_range_query::~path_range_query): Do not free objects.
44404         (path_range_query::clear_cache): Remove.
44405         (path_range_query::get_cache): Adjust.
44406         (path_range_query::set_cache): Remove.
44407         (path_range_query::dump): Don't call through a pointer.
44408         (path_range_query::internal_range_of_expr): Set cache directly.
44409         (path_range_query::reset_path): Clear cache directly.
44410         (path_range_query::ssa_range_in_phi): Fold with globals only.
44411         (path_range_query::compute_ranges_in_phis): Simply set range.
44412         (path_range_query::compute_ranges_in_block): Call cache directly.
44413         * gimple-range-path.h (class path_range_query): Replace bitmap
44414         and cache pointer with lazy cache object.
44415         * gimple-range.h (class assume_query): Use ssa_lazy_cache.
44417 2023-04-26  Andrew MacLeod  <amacleod@redhat.com>
44419         * gimple-range-cache.cc (ssa_cache::ssa_cache): Rename.
44420         (ssa_cache::~ssa_cache): Rename.
44421         (ssa_cache::has_range): New.
44422         (ssa_cache::get_range): Rename.
44423         (ssa_cache::set_range): Rename.
44424         (ssa_cache::clear_range): Rename.
44425         (ssa_cache::clear): Rename.
44426         (ssa_cache::dump): Rename and use get_range.
44427         (ranger_cache::get_global_range): Use get_range and set_range.
44428         (ranger_cache::range_of_def): Use get_range.
44429         * gimple-range-cache.h (class ssa_cache): Rename class and methods.
44430         (class ranger_cache): Use ssa_cache.
44431         * gimple-range-path.cc (path_range_query::path_range_query): Use
44432         ssa_cache.
44433         (path_range_query::get_cache): Use get_range.
44434         (path_range_query::set_cache): Use set_range.
44435         * gimple-range-path.h (class path_range_query): Use ssa_cache.
44436         * gimple-range.cc (assume_query::assume_range_p): Use get_range.
44437         (assume_query::range_of_expr): Use get_range.
44438         (assume_query::assume_query): Use set_range.
44439         (assume_query::calculate_op): Use get_range and set_range.
44440         * gimple-range.h (class assume_query): Use ssa_cache.
44442 2023-04-26  Andrew MacLeod  <amacleod@redhat.com>
44444         * gimple-range-cache.cc (sbr_vector::sbr_vector): Add parameter
44445         and local to optionally zero memory.
44446         (br_vector::grow): Only zero memory if flag is set.
44447         (class sbr_lazy_vector): New.
44448         (sbr_lazy_vector::sbr_lazy_vector): New.
44449         (sbr_lazy_vector::set_bb_range): New.
44450         (sbr_lazy_vector::get_bb_range): New.
44451         (sbr_lazy_vector::bb_range_p): New.
44452         (block_range_cache::set_bb_range): Check flags and Use sbr_lazy_vector.
44453         * gimple-range-gori.cc (gori_map::calculate_gori): Use
44454         param_vrp_switch_limit.
44455         (gori_compute::gori_compute): Use param_vrp_switch_limit.
44456         * params.opt (vrp_sparse_threshold): Rename from evrp_sparse_threshold.
44457         (vrp_switch_limit): Rename from evrp_switch_limit.
44458         (vrp_vector_threshold): New.
44460 2023-04-26  Andrew MacLeod  <amacleod@redhat.com>
44462         * value-relation.cc (dom_oracle::query_relation): Check early for lack
44463         of any relation.
44464         * value-relation.h (equiv_oracle::has_equiv_p): New.
44466 2023-04-26  Andrew MacLeod  <amacleod@redhat.com>
44468         PR tree-optimization/109417
44469         * gimple-range-gori.cc (range_def_chain::register_dependency):
44470         Save the ssa version number, not the pointer.
44471         (gori_compute::may_recompute_p): No need to check if a dependency
44472         is in the free list.
44473         * gimple-range-gori.h (class range_def_chain): Change ssa1 and ssa2
44474         fields to be unsigned int instead of trees.
44475         (ange_def_chain::depend1): Adjust.
44476         (ange_def_chain::depend2): Adjust.
44477         * gimple-range.h: Include "ssa.h" to inline ssa_name().
44479 2023-04-26  David Edelsohn  <dje.gcc@gmail.com>
44481         * config/rs6000/aix72.h (TARGET_DEFAULT): Use ISA_2_6_MASKS_SERVER.
44482         * config/rs6000/aix73.h (TARGET_DEFAULT): Use ISA_2_7_MASKS_SERVER.
44483         (PROCESSOR_DEFAULT): Use PROCESSOR_POWER8.
44485 2023-04-26  Patrick O'Neill  <patrick@rivosinc.com>
44487         PR target/104338
44488         * config/riscv/riscv-protos.h: Add helper function stubs.
44489         * config/riscv/riscv.cc: Add helper functions for subword masking.
44490         * config/riscv/riscv.opt: Add command-line flags -minline-atomics and
44491         -mno-inline-atomics.
44492         * config/riscv/sync.md: Add masking logic and inline asm for fetch_and_op,
44493         fetch_and_nand, CAS, and exchange ops.
44494         * doc/invoke.texi: Add blurb regarding new command-line flags
44495         -minline-atomics and -mno-inline-atomics.
44497 2023-04-26  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
44499         * config/aarch64/aarch64-simd.md (aarch64_rshrn2<mode>_insn_le):
44500         Reimplement using standard RTL codes instead of unspec.
44501         (aarch64_rshrn2<mode>_insn_be): Likewise.
44502         (aarch64_rshrn2<mode>): Adjust for the above.
44503         * config/aarch64/aarch64.md (UNSPEC_RSHRN): Delete.
44505 2023-04-26  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
44507         * config/aarch64/aarch64-simd.md (aarch64_rshrn<mode>_insn_le): Reimplement
44508         with standard RTL codes instead of an UNSPEC.
44509         (aarch64_rshrn<mode>_insn_be): Likewise.
44510         (aarch64_rshrn<mode>): Adjust for the above.
44511         * config/aarch64/predicates.md (aarch64_simd_rshrn_imm_vec): Define.
44513 2023-04-26  Pan Li  <pan2.li@intel.com>
44514             Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
44516         * config/riscv/riscv.cc (riscv_classify_address): Allow
44517         const0_rtx for the RVV load/store.
44519 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44521         * range-op.cc (range_op_cast_tests): Remove legacy support.
44522         * value-range-storage.h (vrange_allocator::alloc_irange): Same.
44523         * value-range.cc (irange::operator=): Same.
44524         (get_legacy_range): Same.
44525         (irange::copy_legacy_to_multi_range): Delete.
44526         (irange::copy_to_legacy): Delete.
44527         (irange::irange_set_anti_range): Delete.
44528         (irange::set): Remove legacy support.
44529         (irange::verify_range): Same.
44530         (irange::legacy_lower_bound): Delete.
44531         (irange::legacy_upper_bound): Delete.
44532         (irange::legacy_equal_p): Delete.
44533         (irange::operator==): Remove legacy support.
44534         (irange::singleton_p): Same.
44535         (irange::value_inside_range): Same.
44536         (irange::contains_p): Same.
44537         (intersect_ranges): Delete.
44538         (irange::legacy_intersect): Delete.
44539         (union_ranges): Delete.
44540         (irange::legacy_union): Delete.
44541         (irange::legacy_verbose_union_): Delete.
44542         (irange::legacy_verbose_intersect): Delete.
44543         (irange::irange_union): Remove legacy support.
44544         (irange::irange_intersect): Same.
44545         (irange::intersect): Same.
44546         (irange::invert): Same.
44547         (ranges_from_anti_range): Delete.
44548         (gt_pch_nx): Adjust for legacy removal.
44549         (gt_ggc_mx): Same.
44550         (range_tests_legacy): Delete.
44551         (range_tests_misc): Adjust for legacy removal.
44552         (range_tests): Same.
44553         * value-range.h (class irange): Same.
44554         (irange::legacy_mode_p): Delete.
44555         (ranges_from_anti_range): Delete.
44556         (irange::nonzero_p): Adjust for legacy removal.
44557         (irange::lower_bound): Same.
44558         (irange::upper_bound): Same.
44559         (irange::union_): Same.
44560         (irange::intersect): Same.
44561         (irange::set_nonzero): Same.
44562         (irange::set_zero): Same.
44563         * vr-values.cc (simplify_using_ranges::legacy_fold_cond_overflow): Same.
44565 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44567         * value-range.cc (irange::copy_legacy_to_multi_range): Rewrite use
44568         of range_has_numeric_bounds_p with irange API.
44569         (range_has_numeric_bounds_p): Delete.
44570         * value-range.h (range_has_numeric_bounds_p): Delete.
44572 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44574         * tree-data-ref.cc (compute_distributive_range): Replace uses of
44575         range_int_cst_p with irange API.
44576         * tree-ssa-strlen.cc (get_range_strlen_dynamic): Same.
44577         * tree-vrp.h (range_int_cst_p): Delete.
44578         * vr-values.cc (check_for_binary_op_overflow): Replace usees of
44579         range_int_cst_p with irange API.
44580         (vr_set_zero_nonzero_bits): Same.
44581         (range_fits_type_p): Same.
44582         (simplify_using_ranges::simplify_casted_cond): Same.
44583         * tree-vrp.cc (range_int_cst_p): Remove.
44585 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44587         * tree-ssa-strlen.cc (compare_nonzero_chars): Convert to wide_ints.
44589 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44591         * builtins.cc (expand_builtin_strnlen): Rewrite deprecated irange
44592         API uses to new API.
44593         * gimple-predicate-analysis.cc (find_var_cmp_const): Same.
44594         * internal-fn.cc (get_min_precision): Same.
44595         * match.pd: Same.
44596         * tree-affine.cc (expr_to_aff_combination): Same.
44597         * tree-data-ref.cc (dr_step_indicator): Same.
44598         * tree-dfa.cc (get_ref_base_and_extent): Same.
44599         * tree-scalar-evolution.cc (iv_can_overflow_p): Same.
44600         * tree-ssa-phiopt.cc (two_value_replacement): Same.
44601         * tree-ssa-pre.cc (insert_into_preds_of_block): Same.
44602         * tree-ssa-reassoc.cc (optimize_range_tests_to_bit_test): Same.
44603         * tree-ssa-strlen.cc (compare_nonzero_chars): Same.
44604         * tree-switch-conversion.cc (bit_test_cluster::emit): Same.
44605         * tree-vect-patterns.cc (vect_recog_divmod_pattern): Same.
44606         * tree.cc (get_range_pos_neg): Same.
44608 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44610         * ipa-prop.cc (ipa_print_node_jump_functions_for_edge): Use
44611         vrange::dump instead of ad-hoc dumper.
44612         * tree-ssa-strlen.cc (dump_strlen_info): Same.
44613         * value-range-pretty-print.cc (visit): Pass TDF_NOUID to
44614         dump_generic_node.
44616 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44618         * range-op.cc (operator_cast::op1_range): Use
44619         create_possibly_reversed_range.
44620         (operator_bitwise_and::simple_op1_range_solver): Same.
44621         * value-range.cc (swap_out_of_order_endpoints): Delete.
44622         (irange::set): Remove call to swap_out_of_order_endpoints.
44624 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44626         * builtins.cc (determine_block_size): Convert use of legacy API to
44627         get_legacy_range.
44628         * gimple-array-bounds.cc (check_out_of_bounds_and_warn): Same.
44629         (array_bounds_checker::check_array_ref): Same.
44630         * gimple-ssa-warn-restrict.cc
44631         (builtin_memref::extend_offset_range): Same.
44632         * ipa-cp.cc (ipcp_store_vr_results): Same.
44633         * ipa-fnsummary.cc (set_switch_stmt_execution_predicate): Same.
44634         * ipa-prop.cc (struct ipa_vr_ggc_hash_traits): Same.
44635         (ipa_write_jump_function): Same.
44636         * pointer-query.cc (get_size_range): Same.
44637         * tree-data-ref.cc (split_constant_offset): Same.
44638         * tree-ssa-strlen.cc (get_range): Same.
44639         (maybe_diag_stxncpy_trunc): Same.
44640         (strlen_pass::get_len_or_size): Same.
44641         (strlen_pass::count_nonzero_bytes_addr): Same.
44642         * tree-vect-patterns.cc (vect_get_range_info): Same.
44643         * value-range.cc (irange::maybe_anti_range): Remove.
44644         (get_legacy_range): New.
44645         (irange::copy_to_legacy): Use get_legacy_range.
44646         (ranges_from_anti_range): Same.
44647         * value-range.h (class irange): Remove maybe_anti_range.
44648         (get_legacy_range): New.
44649         * vr-values.cc (check_for_binary_op_overflow): Convert use of
44650         legacy API to get_legacy_range.
44651         (compare_ranges): Same.
44652         (compare_range_with_value): Same.
44653         (bounds_of_var_in_loop): Same.
44654         (find_case_label_ranges): Same.
44655         (simplify_using_ranges::simplify_switch_using_ranges): Same.
44657 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44659         * value-range-pretty-print.cc (vrange_printer::visit): Remove
44660         constant_p use.
44661         * value-range.cc (irange::constant_p): Remove.
44662         (irange::get_nonzero_bits_from_range): Remove constant_p use.
44663         * value-range.h (class irange): Remove constant_p.
44664         (irange::num_pairs): Remove constant_p use.
44666 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44668         * value-range.cc (irange::copy_legacy_to_multi_range): Remove
44669         symbolics support.
44670         (irange::set): Same.
44671         (irange::legacy_lower_bound): Same.
44672         (irange::legacy_upper_bound): Same.
44673         (irange::contains_p): Same.
44674         (range_tests_legacy): Same.
44675         (irange::normalize_addresses): Remove.
44676         (irange::normalize_symbolics): Remove.
44677         (irange::symbolic_p): Remove.
44678         * value-range.h (class irange): Remove symbolic_p,
44679         normalize_symbolics, and normalize_addresses.
44680         * vr-values.cc (simplify_using_ranges::two_valued_val_range_p):
44681         Remove symbolics support.
44683 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44685         * value-range.cc (irange::may_contain_p): Remove.
44686         * value-range.h (range_includes_zero_p):  Rewrite may_contain_p
44687         usage with contains_p.
44688         * vr-values.cc (compare_range_with_value): Same.
44690 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44692         * tree-vrp.cc (supported_types_p): Remove.
44693         (defined_ranges_p): Remove.
44694         (range_fold_binary_expr): Remove.
44695         (range_fold_unary_expr): Remove.
44696         * tree-vrp.h (range_fold_unary_expr): Remove.
44697         (range_fold_binary_expr): Remove.
44699 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44701         * ipa-cp.cc (ipa_vr_operation_and_type_effects): Convert to ranger API.
44702         (ipa_value_range_from_jfunc): Same.
44703         (propagate_vr_across_jump_function): Same.
44704         * ipa-fnsummary.cc (evaluate_conditions_for_known_args): Same.
44705         * ipa-prop.cc (ipa_compute_jump_functions_for_edge): Same.
44706         * vr-values.cc (bounds_of_var_in_loop): Same.
44708 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44710         * gimple-array-bounds.cc (array_bounds_checker::get_value_range):
44711         Add irange argument.
44712         (check_out_of_bounds_and_warn): Remove check for vr.
44713         (array_bounds_checker::check_array_ref): Remove pointer qualifier
44714         for vr and adjust accordingly.
44715         * gimple-array-bounds.h (get_value_range): Add irange argument.
44716         * value-query.cc (class equiv_allocator): Delete.
44717         (range_query::get_value_range): Delete.
44718         (range_query::range_query): Remove allocator access.
44719         (range_query::~range_query): Same.
44720         * value-query.h (get_value_range): Delete.
44721         * vr-values.cc
44722         (simplify_using_ranges::op_with_boolean_value_range_p): Remove
44723         call to get_value_range.
44724         (check_for_binary_op_overflow): Same.
44725         (simplify_using_ranges::legacy_fold_cond_overflow): Same.
44726         (simplify_using_ranges::simplify_abs_using_ranges): Same.
44727         (simplify_using_ranges::simplify_cond_using_ranges_1): Same.
44728         (simplify_using_ranges::simplify_casted_cond): Same.
44729         (simplify_using_ranges::simplify_switch_using_ranges): Same.
44730         (simplify_using_ranges::two_valued_val_range_p): Same.
44732 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44734         * vr-values.cc
44735         (simplify_using_ranges::vrp_evaluate_conditional_warnv_with_ops):
44736         Rename to...
44737         (simplify_using_ranges::legacy_fold_cond_overflow): ...this.
44738         (simplify_using_ranges::vrp_visit_cond_stmt): Rename to...
44739         (simplify_using_ranges::legacy_fold_cond): ...this.
44740         (simplify_using_ranges::fold_cond): Rename
44741         vrp_evaluate_conditional_warnv_with_ops to
44742         legacy_fold_cond_overflow.
44743         * vr-values.h (class vr_values): Replace vrp_visit_cond_stmt and
44744         vrp_evaluate_conditional_warnv_with_ops with legacy_fold_cond and
44745         legacy_fold_cond_overflow respectively.
44747 2023-04-26  Aldy Hernandez  <aldyh@redhat.com>
44749         * vr-values.cc (get_vr_for_comparison): Remove.
44750         (compare_name_with_value): Same.
44751         (vrp_evaluate_conditional_warnv_with_ops): Remove calls to
44752         compare_name_with_value.
44753         * vr-values.h: Remove compare_name_with_value.
44754         Remove get_vr_for_comparison.
44756 2023-04-26  Roger Sayle  <roger@nextmovesoftware.com>
44758         * config/stormy16/stormy16.md (bswaphi2): New define_insn.
44759         (bswapsi2): New define_insn.
44760         (swaphi): New define_insn to exchange two registers (swpw).
44761         (define_peephole2): Recognize exchange of registers as swaphi.
44763 2023-04-26  Richard Biener  <rguenther@suse.de>
44765         * gimple-range-path.cc (path_range_query::compute_outgoing_relations):
44766         Avoid last_stmt.
44767         * ipa-pure-const.cc (pass_nothrow::execute): Likewise.
44768         * predict.cc (apply_return_prediction): Likewise.
44769         * sese.cc (set_ifsese_condition): Likewise.  Simplify.
44770         * tree-cfg.cc (assert_unreachable_fallthru_edge_p): Avoid last_stmt.
44771         (make_edges_bb): Likewise.
44772         (make_cond_expr_edges): Likewise.
44773         (end_recording_case_labels): Likewise.
44774         (make_gimple_asm_edges): Likewise.
44775         (cleanup_dead_labels): Likewise.
44776         (group_case_labels): Likewise.
44777         (gimple_can_merge_blocks_p): Likewise.
44778         (gimple_merge_blocks): Likewise.
44779         (find_taken_edge): Likewise.  Also handle empty fallthru blocks.
44780         (gimple_duplicate_sese_tail): Avoid last_stmt.
44781         (find_loop_dist_alias): Likewise.
44782         (gimple_block_ends_with_condjump_p): Likewise.
44783         (gimple_purge_dead_eh_edges): Likewise.
44784         (gimple_purge_dead_abnormal_call_edges): Likewise.
44785         (pass_warn_function_return::execute): Likewise.
44786         (execute_fixup_cfg): Likewise.
44787         * tree-eh.cc (redirect_eh_edge_1): Likewise.
44788         (pass_lower_resx::execute): Likewise.
44789         (pass_lower_eh_dispatch::execute): Likewise.
44790         (cleanup_empty_eh): Likewise.
44791         * tree-if-conv.cc (if_convertible_bb_p): Likewise.
44792         (predicate_bbs): Likewise.
44793         (ifcvt_split_critical_edges): Likewise.
44794         * tree-loop-distribution.cc (create_edge_for_control_dependence):
44795         Likewise.
44796         (loop_distribution::transform_reduction_loop): Likewise.
44797         * tree-parloops.cc (transform_to_exit_first_loop_alt): Likewise.
44798         (try_transform_to_exit_first_loop_alt): Likewise.
44799         (transform_to_exit_first_loop): Likewise.
44800         (create_parallel_loop): Likewise.
44801         * tree-scalar-evolution.cc (get_loop_exit_condition): Likewise.
44802         * tree-ssa-dce.cc (mark_last_stmt_necessary): Likewise.
44803         (eliminate_unnecessary_stmts): Likewise.
44804         * tree-ssa-dom.cc
44805         (dom_opt_dom_walker::set_global_ranges_from_unreachable_edges):
44806         Likewise.
44807         * tree-ssa-ifcombine.cc (ifcombine_ifandif): Likewise.
44808         (pass_tree_ifcombine::execute): Likewise.
44809         * tree-ssa-loop-ch.cc (entry_loop_condition_is_static): Likewise.
44810         (should_duplicate_loop_header_p): Likewise.
44811         * tree-ssa-loop-ivcanon.cc (create_canonical_iv): Likewise.
44812         (tree_estimate_loop_size): Likewise.
44813         (try_unroll_loop_completely): Likewise.
44814         * tree-ssa-loop-ivopts.cc (tree_ssa_iv_optimize_loop): Likewise.
44815         * tree-ssa-loop-manip.cc (ip_normal_pos): Likewise.
44816         (canonicalize_loop_ivs): Likewise.
44817         * tree-ssa-loop-niter.cc (determine_value_range): Likewise.
44818         (bound_difference): Likewise.
44819         (number_of_iterations_popcount): Likewise.
44820         (number_of_iterations_cltz): Likewise.
44821         (number_of_iterations_cltz_complement): Likewise.
44822         (simplify_using_initial_conditions): Likewise.
44823         (number_of_iterations_exit_assumptions): Likewise.
44824         (loop_niter_by_eval): Likewise.
44825         (estimate_numbers_of_iterations): Likewise.
44827 2023-04-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
44829         * config/riscv/vector.md: Refine vmadc/vmsbc RA constraint.
44831 2023-04-26  Kewen Lin  <linkw@linux.ibm.com>
44833         PR target/108758
44834         * config/rs6000/rs6000-builtins.def
44835         (__builtin_vsx_scalar_cmp_exp_qp_eq, __builtin_vsx_scalar_cmp_exp_qp_gt
44836         __builtin_vsx_scalar_cmp_exp_qp_lt,
44837         __builtin_vsx_scalar_cmp_exp_qp_unordered): Move from stanza ieee128-hw
44838         to power9-vector.
44840 2023-04-26  Kewen Lin  <linkw@linux.ibm.com>
44842         PR target/109069
44843         * config/rs6000/altivec.md (sldoi_to_mov<mode>): Replace predicate
44844         easy_vector_constant with const_vector_each_byte_same, add
44845         handlings in preparation for !easy_vector_constant, and update
44846         VECTOR_UNIT_ALTIVEC_OR_VSX_P with VECTOR_MEM_ALTIVEC_OR_VSX_P.
44847         * config/rs6000/predicates.md (const_vector_each_byte_same): New
44848         predicate.
44850 2023-04-26  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
44852         * config/riscv/vector.md (*pred_cmp<mode>_merge_tie_mask): New pattern.
44853         (*pred_ltge<mode>_merge_tie_mask): Ditto.
44854         (*pred_cmp<mode>_scalar_merge_tie_mask): Ditto.
44855         (*pred_eqne<mode>_scalar_merge_tie_mask): Ditto.
44856         (*pred_cmp<mode>_extended_scalar_merge_tie_mask): Ditto.
44857         (*pred_eqne<mode>_extended_scalar_merge_tie_mask): Ditto.
44858         (*pred_cmp<mode>_narrow_merge_tie_mask): Ditto.
44860 2023-04-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
44862         * config/riscv/vector.md: Fix redundant vmv1r.v.
44864 2023-04-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
44866         * config/riscv/vector.md: Fix RA constraint.
44868 2023-04-26  Pan Li  <pan2.li@intel.com>
44870         PR target/109272
44871         * tree-ssa-sccvn.cc (vn_reference_eq): add type vector subparts
44872         check for vn_reference equal.
44874 2023-04-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
44876         * config/riscv/riscv-opts.h (enum riscv_autovec_preference_enum): Add enum for
44877         auto-vectorization preference.
44878         (enum riscv_autovec_lmul_enum): Add enum for choosing LMUL of RVV
44879         auto-vectorization.
44880         * config/riscv/riscv.opt: Add compile option for RVV auto-vectorization.
44882 2023-04-26  Jivan Hakobyan  <jivanhakobyan9@gmail.com>
44884         * config/riscv/bitmanip.md: Updated predicates of bclri<mode>_nottwobits
44885         and bclridisi_nottwobits patterns.
44886         * config/riscv/predicates.md: (not_uimm_extra_bit_or_nottwobits): Adjust
44887         predicate to avoid splitting arith constants.
44888         (const_nottwobits_not_arith_operand): New predicate.
44890 2023-04-25  Hans-Peter Nilsson  <hp@axis.com>
44892         * recog.cc (peep2_attempt, peep2_update_life): Correct
44893         head-comment description of parameter match_len.
44895 2023-04-25  Vineet Gupta  <vineetg@rivosinc.com>
44897         * config/riscv/riscv.md: riscv_move_integer() drop in_splitter arg.
44898         riscv_split_symbol() drop in_splitter arg.
44899         * config/riscv/riscv.cc: riscv_move_integer() drop in_splitter arg.
44900         riscv_split_symbol() drop in_splitter arg.
44901         riscv_force_temporary() drop in_splitter arg.
44902         * config/riscv/riscv-protos.h: riscv_move_integer() drop in_splitter arg.
44903         riscv_split_symbol() drop in_splitter arg.
44905 2023-04-25  Eric Botcazou  <ebotcazou@adacore.com>
44907         * tree-ssa.cc (insert_debug_temp_for_var_def): Do not create
44908         superfluous debug temporaries for single GIMPLE assignments.
44910 2023-04-25  Richard Biener  <rguenther@suse.de>
44912         PR tree-optimization/109609
44913         * attr-fnspec.h (arg_max_access_size_given_by_arg_p):
44914         Clarify semantics.
44915         * tree-ssa-alias.cc (check_fnspec): Correctly interpret
44916         the size given by arg_max_access_size_given_by_arg_p as
44917         maximum, not exact, size.
44919 2023-04-25  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
44921         PR target/99195
44922         * config/aarch64/aarch64-simd.md (orn<mode>3): Rename to...
44923         (orn<mode>3<vczle><vczbe>): ... This.
44924         (bic<mode>3): Rename to...
44925         (bic<mode>3<vczle><vczbe>): ... This.
44926         (<su><maxmin><mode>3): Rename to...
44927         (<su><maxmin><mode>3<vczle><vczbe>): ... This.
44929 2023-04-25  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
44931         * config/aarch64/aarch64-simd.md (<su_optab>div<mode>3): New define_expand.
44932         * config/aarch64/iterators.md (VQDIV): New mode iterator.
44933         (vnx2di): New mode attribute.
44935 2023-04-25  Richard Biener  <rguenther@suse.de>
44937         PR rtl-optimization/109585
44938         * tree-ssa-alias.cc (aliasing_component_refs_p): Fix typo.
44940 2023-04-25  Jakub Jelinek  <jakub@redhat.com>
44942         PR target/109566
44943         * config/rs6000/rs6000.cc (rs6000_is_valid_rotate_dot_mask): For
44944         !TARGET_64BIT, don't return true if UINTVAL (mask) << (63 - nb)
44945         is larger than signed int maximum.
44947 2023-04-25  Martin Liska  <mliska@suse.cz>
44949         * doc/gcov.texi: Document the new "calls" field and document
44950         the API bump. Mention also "block_ids" for lines.
44951         * gcov.cc (output_intermediate_json_line): Output info about
44952         calls and extend branches as well.
44953         (generate_results): Bump version to 2.
44954         (output_line_details): Use block ID instead of a non-sensual
44955         index.
44957 2023-04-25  Roger Sayle  <roger@nextmovesoftware.com>
44959         * config/stormy16/stormy16.md (zero_extendqihi2): Restore/fix
44960         length attribute for the first (memory operand) alternative.
44962 2023-04-25  Victor Do Nascimento  <victor.donascimento@arm.com>
44964         * config/aarch64/aarch64-simd.md(aarch64_simd_stp<mode>): New.
44965         * config/aarch64/constraints.md: Make "Umn" relaxed memory
44966         constraint.
44967         * config/aarch64/iterators.md(ldpstp_vel_sz): New.
44969 2023-04-25  Aldy Hernandez  <aldyh@redhat.com>
44971         * value-range.cc (frange::set): Adjust constructor.
44972         * value-range.h (nan_state::nan_state): Replace default
44973         constructor with one taking an argument.
44975 2023-04-25  Aldy Hernandez  <aldyh@redhat.com>
44977         * ipa-cp.cc (ipa_range_contains_p): New.
44978         (decide_whether_version_node): Use it.
44980 2023-04-24  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
44982         * tree-ssa-forwprop.cc (is_combined_permutation_identity): Try to
44983         simplify two successive VEC_PERM_EXPRs with same VLA mask,
44984         where mask chooses elements in reverse order.
44986 2023-04-24  Andrew Pinski  <apinski@marvell.com>
44988         * tree-ssa-phiopt.cc (match_simplify_replacement): Add new arguments
44989         and support diamond shaped basic block form.
44990         (tree_ssa_phiopt_worker): Update call to match_simplify_replacement
44992 2023-04-24  Andrew Pinski  <apinski@marvell.com>
44994         * tree-ssa-phiopt.cc (empty_bb_or_one_feeding_into_p):
44995         Instead of calling last_and_only_stmt, look for the last statement
44996         manually.
44998 2023-04-24  Andrew Pinski  <apinski@marvell.com>
45000         * tree-ssa-phiopt.cc (empty_bb_or_one_feeding_into_p):
45001         New function.
45002         (match_simplify_replacement): Call
45003         empty_bb_or_one_feeding_into_p instead of doing it inline.
45005 2023-04-24  Andrew Pinski  <apinski@marvell.com>
45007         PR tree-optimization/68894
45008         * tree-ssa-phiopt.cc (tree_ssa_phiopt_worker): Remove the
45009         continue for the do_hoist_loads diamond case.
45011 2023-04-24  Andrew Pinski  <apinski@marvell.com>
45013         * tree-ssa-phiopt.cc (tree_ssa_phiopt_worker): Rearrange
45014         code for better code readability.
45016 2023-04-24  Andrew Pinski  <apinski@marvell.com>
45018         PR tree-optimization/109604
45019         * tree-ssa-phiopt.cc (tree_ssa_phiopt_worker): Move the
45020         diamond form check from ...
45021         (minmax_replacement): Here.
45023 2023-04-24  Patrick Palka  <ppalka@redhat.com>
45025         * tree.cc (strip_array_types): Don't define here.
45026         (is_typedef_decl): Don't define here.
45027         (typedef_variant_p): Don't define here.
45028         * tree.h (strip_array_types): Define here.
45029         (is_typedef_decl): Define here.
45030         (typedef_variant_p): Define here.
45032 2023-04-24  Frederik Harwath  <frederik@codesourcery.com>
45034         * doc/generic.texi (OpenMP): Add != to allowed
45035         conditions and state that vars can be unsigned.
45036         * tree.def (OMP_FOR): Likewise.
45038 2023-04-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45040         * config/aarch64/aarch64-simd.md (mulv2di3): New expander.
45042 2023-04-24  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
45044         * doc/install.texi: Consistently use Solaris rather than Solaris 2.
45045         Remove explicit Solaris 11 references.
45046         Markup fixes.
45047         (Options specification, --with-gnu-as): as and gas always differ
45048         on Solaris.
45049         Remove /usr/ccs/bin reference.
45050         (Installing GCC: Binaries, Solaris (SPARC, Intel)): Remove.
45051         (i?86-*-solaris2*): Merge assembler, linker recommendations ...
45052         (*-*-solaris2*): ... here.
45053         Update bundled GCC versions.
45054         Don't refer to pre-built binaries.
45055         Remove /bin/sh warning.
45056         Update assembler, linker recommendations.
45057         Document GNAT bootstrap compiler.
45058         (sparc-sun-solaris2*): Remove non-UltraSPARC reference.
45059         (sparc64-*-solaris2*): Move content...
45060         (sparcv9-*-solaris2*): ...here.
45061         Add GDC for 64-bit bootstrap compilers.
45063 2023-04-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45065         PR target/109406
45066         * config/aarch64/aarch64-sve.md (<optab><mode>3): Handle TARGET_SVE2 MUL
45067         case.
45068         * config/aarch64/aarch64-sve2.md (*aarch64_mul_unpredicated_<mode>): New
45069         pattern.
45071 2023-04-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45073         * config/aarch64/aarch64-simd.md (aarch64_<sur>abal2<mode>): Rename to...
45074         (aarch64_<su>abal2<mode>_insn): ... This.  Use RTL codes instead of unspec.
45075         (aarch64_<su>abal2<mode>): New define_expand.
45076         * config/aarch64/aarch64.cc (aarch64_abd_rtx_p): New function.
45077         (aarch64_rtx_costs): Handle ABD rtxes.
45078         * config/aarch64/aarch64.md (UNSPEC_SABAL2, UNSPEC_UABAL2): Delete.
45079         * config/aarch64/iterators.md (ABAL2): Delete.
45080         (sur): Remove handling of UNSPEC_UABAL2 and UNSPEC_SABAL2.
45082 2023-04-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45084         * config/aarch64/aarch64-simd.md (aarch64_<sur>abal<mode>): Rename to...
45085         (aarch64_<su>abal<mode>): ... This.  Use RTL codes instead of unspec.
45086         (<sur>sadv16qi): Rename to...
45087         (<su>sadv16qi): ... This.  Adjust for the above.
45088         * config/aarch64/aarch64-sve.md (<sur>sad<vsi2qi>): Rename to...
45089         (<su>sad<vsi2qi>): ... This.  Adjust for the above.
45090         * config/aarch64/aarch64.md (UNSPEC_SABAL, UNSPEC_UABAL): Delete.
45091         * config/aarch64/iterators.md (ABAL): Delete.
45092         (sur): Remove handling of UNSPEC_SABAL and UNSPEC_UABAL.
45094 2023-04-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45096         * config/aarch64/aarch64-simd.md (aarch64_<sur>abdl2<mode>): Rename to...
45097         (aarch64_<su>abdl2<mode>_insn): ... This.  Use RTL codes instead of unspec.
45098         (aarch64_<su>abdl2<mode>): New define_expand.
45099         * config/aarch64/aarch64.md (UNSPEC_SABDL2, UNSPEC_UABDL2): Delete.
45100         * config/aarch64/iterators.md (ABDL2): Delete.
45101         (sur): Remove handling of UNSPEC_SABDL2 and UNSPEC_UABDL2.
45103 2023-04-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45105         * config/aarch64/aarch64-simd.md (aarch64_<sur>abdl<mode>): Rename to...
45106         (aarch64_<su>abdl<mode>): ... This.  Use standard RTL ops instead of
45107         unspec.
45108         * config/aarch64/aarch64.md (UNSPEC_SABDL, UNSPEC_UABDL): Delete.
45109         * config/aarch64/iterators.md (ABDL): Delete.
45110         (sur): Remove handling of UNSPEC_SABDL and UNSPEC_UABDL.
45112 2023-04-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45114         * config/aarch64/aarch64-simd.md
45115         (*aarch64_<su>addlv<VDQV_L:mode>_ze<GPI:mode>): New pattern.
45117 2023-04-24  Richard Biener  <rguenther@suse.de>
45119         * gimple-ssa-split-paths.cc (is_feasible_trace): Avoid
45120         last_stmt.
45121         * graphite-scop-detection.cc (single_pred_cond_non_loop_exit):
45122         Likewise.
45123         * ipa-fnsummary.cc (set_cond_stmt_execution_predicate): Likewise.
45124         (set_switch_stmt_execution_predicate): Likewise.
45125         (phi_result_unknown_predicate): Likewise.
45126         * ipa-prop.cc (compute_complex_ancestor_jump_func): Likewise.
45127         (ipa_analyze_indirect_call_uses): Likewise.
45128         * predict.cc (predict_iv_comparison): Likewise.
45129         (predict_extra_loop_exits): Likewise.
45130         (predict_loops): Likewise.
45131         (tree_predict_by_opcode): Likewise.
45132         * gimple-predicate-analysis.cc (predicate::init_from_control_deps):
45133         Likewise.
45134         * gimple-pretty-print.cc (dump_implicit_edges): Likewise.
45135         * tree-ssa-phiopt.cc (tree_ssa_phiopt_worker): Likewise.
45136         (replace_phi_edge_with_variable): Likewise.
45137         (two_value_replacement): Likewise.
45138         (value_replacement): Likewise.
45139         (minmax_replacement): Likewise.
45140         (spaceship_replacement): Likewise.
45141         (cond_removal_in_builtin_zero_pattern): Likewise.
45142         * tree-ssa-reassoc.cc (maybe_optimize_range_tests): Likewise.
45143         * tree-ssa-sccvn.cc (vn_phi_eq): Likewise.
45144         (vn_phi_lookup): Likewise.
45145         (vn_phi_insert): Likewise.
45146         * tree-ssa-structalias.cc (compute_points_to_sets): Likewise.
45147         * tree-ssa-threadbackward.cc (back_threader::maybe_thread_block):
45148         Likewise.
45149         (back_threader_profitability::possibly_profitable_path_p):
45150         Likewise.
45151         * tree-ssa-threadedge.cc (jump_threader::thread_outgoing_edges):
45152         Likewise.
45153         * tree-switch-conversion.cc (pass_convert_switch::execute):
45154         Likewise.
45155         (pass_lower_switch<O0>::execute): Likewise.
45156         * tree-tailcall.cc (tree_optimize_tail_calls_1): Likewise.
45157         * tree-vect-loop-manip.cc (vect_loop_versioning): Likewise.
45158         * tree-vect-slp.cc (vect_slp_function): Likewise.
45159         * tree-vect-stmts.cc (cfun_returns): Likewise.
45160         * tree-vectorizer.cc (vect_loop_vectorized_call): Likewise.
45161         (vect_loop_dist_alias_call): Likewise.
45163 2023-04-24  Richard Biener  <rguenther@suse.de>
45165         * cfgcleanup.cc (outgoing_edges_match): Use FORWARDER_BLOCK_P.
45167 2023-04-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
45169         * config/riscv/riscv-vsetvl.cc
45170         (vector_infos_manager::all_avail_in_compatible_p): New function.
45171         (pass_vsetvl::refine_vsetvls): Optimize vsetvls.
45172         * config/riscv/riscv-vsetvl.h: New function.
45174 2023-04-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
45176         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::pre_vsetvl): Add function
45177         comment for cleanup_insns.
45179 2023-04-24  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
45181         * config/riscv/vector-iterators.md: New unspec to refine fault first load pattern.
45182         * config/riscv/vector.md: Refine fault first load pattern to erase avl from instructions
45183         with the fault first load property.
45185 2023-04-23  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45187         * config/aarch64/aarch64-simd.md (aarch64_float_truncate_lo_): Rename to...
45188         (aarch64_float_truncate_lo_<mode><vczle><vczbe>): ... This.
45190 2023-04-23  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45192         PR target/99195
45193         * config/aarch64/aarch64-simd.md (aarch64_addp<mode>): Rename to...
45194         (aarch64_addp<mode><vczle><vczbe>): ... This.
45196 2023-04-23  Roger Sayle  <roger@nextmovesoftware.com>
45198         * config/stormy16/stormy16.cc (xstormy16_rtx_costs): Rewrite to
45199         provide reasonable values for common arithmetic operations and
45200         immediate operands (in several machine modes).
45202 2023-04-23  Roger Sayle  <roger@nextmovesoftware.com>
45204         * config/stormy16/stormy16.cc (xstormy16_print_operand): Add %h
45205         format specifier to output high_part register name of SImode reg.
45206         * config/stormy16/stormy16.md (extendhisi2): New define_insn.
45207         (zero_extendqihi2): Fix lengths, consistent formatting and add
45208         "and Rx,#255" alternative, for documentation purposes.
45209         (zero_extendhisi2): New define_insn.
45211 2023-04-23  Roger Sayle  <roger@nextmovesoftware.com>
45213         * config/stormy16/stormy16.cc (xstormy16_output_shift): Implement
45214         SImode shifts by two by performing a single bit SImode shift twice.
45216 2023-04-23  Aldy Hernandez  <aldyh@redhat.com>
45218         PR tree-optimization/109593
45219         * value-range.cc (frange::operator==): Handle NANs.
45221 2023-04-23  liuhongt  <hongtao.liu@intel.com>
45223         PR rtl-optimization/108707
45224         * ira-costs.cc (scan_one_insn): Use NO_REGS instead of
45225         GENERAL_REGS when preferred reg_class is not known.
45227 2023-04-22  Andrew Pinski  <apinski@marvell.com>
45229         * tree-ssa-phiopt.cc (tree_ssa_phiopt_worker):
45230         Change the code around slightly to move diamond
45231         handling for do_store_elim/do_hoist_loads out of
45232         the big if/else.
45234 2023-04-22  Andrew Pinski  <apinski@marvell.com>
45236         * tree-ssa-phiopt.cc (tree_ssa_phiopt_worker):
45237         Remove check on empty_block_p.
45239 2023-04-22  Jakub Jelinek  <jakub@redhat.com>
45241         PR bootstrap/109589
45242         * system.h (class auto_mpz): Workaround PR62101 bug in GCC 4.8 and 4.9.
45243         * realmpfr.h (class auto_mpfr): Likewise.
45245 2023-04-22  Jakub Jelinek  <jakub@redhat.com>
45247         PR tree-optimization/109583
45248         * match.pd (fneg/fadd simplify): Don't call related_vector_mode
45249         if vec_mode is not VECTOR_MODE_P.
45251 2023-04-22  Jan Hubicka  <hubicka@ucw.cz>
45252             Ondrej Kubanek  <kubanek0ondrej@gmail.com>
45254         * cfgloopmanip.h (adjust_loop_info_after_peeling): Declare.
45255         * tree-ssa-loop-ch.cc (ch_base::copy_headers): Fix updating of
45256         loop profile and bounds after header duplication.
45257         * tree-ssa-loop-ivcanon.cc (adjust_loop_info_after_peeling):
45258         Break out from try_peel_loop; fix handling of 0 iterations.
45259         (try_peel_loop): Use adjust_loop_info_after_peeling.
45261 2023-04-21  Andrew MacLeod  <amacleod@redhat.com>
45263         PR tree-optimization/109546
45264         * tree-vrp.cc (remove_unreachable::remove_and_update_globals): Do
45265         not fold conditions with ADDR_EXPR early.
45267 2023-04-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45269         * config/aarch64/aarch64.md (aarch64_umax<mode>3_insn): Delete.
45270         (umax<mode>3): Emit raw UMAX RTL instead of going through gen_ function
45271         for umax.
45272         (<optab><mode>3): New define_expand for MAXMIN_NOUMAX codes.
45273         (*aarch64_<optab><mode>3_zero): Define.
45274         (*aarch64_<optab><mode>3_cssc): Likewise.
45275         * config/aarch64/iterators.md (maxminand): New code attribute.
45277 2023-04-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45279         PR target/108779
45280         * config/aarch64/aarch64-opts.h (enum aarch64_tp_reg): Define.
45281         * config/aarch64/aarch64-protos.h (aarch64_output_load_tp):
45282         Define prototype.
45283         * config/aarch64/aarch64.cc (aarch64_tpidr_register): Declare.
45284         (aarch64_override_options_internal): Handle the above.
45285         (aarch64_output_load_tp): New function.
45286         * config/aarch64/aarch64.md (aarch64_load_tp_hard): Call
45287         aarch64_output_load_tp.
45288         * config/aarch64/aarch64.opt (aarch64_tp_reg): Define enum.
45289         (mtp=): New option.
45290         * doc/invoke.texi (AArch64 Options): Document -mtp=.
45292 2023-04-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45294         PR target/99195
45295         * config/aarch64/aarch64-simd.md (add_vec_concat_subst_le): Define.
45296         (add_vec_concat_subst_be): Likewise.
45297         (vczle): Likewise.
45298         (vczbe): Likewise.
45299         (add<mode>3): Rename to...
45300         (add<mode>3<vczle><vczbe>): ... This.
45301         (sub<mode>3): Rename to...
45302         (sub<mode>3<vczle><vczbe>): ... This.
45303         (mul<mode>3): Rename to...
45304         (mul<mode>3<vczle><vczbe>): ... This.
45305         (and<mode>3): Rename to...
45306         (and<mode>3<vczle><vczbe>): ... This.
45307         (ior<mode>3): Rename to...
45308         (ior<mode>3<vczle><vczbe>): ... This.
45309         (xor<mode>3): Rename to...
45310         (xor<mode>3<vczle><vczbe>): ... This.
45311         * config/aarch64/iterators.md (VDZ): Define.
45313 2023-04-21  Patrick Palka  <ppalka@redhat.com>
45315         * tree.cc (walk_tree_1): Avoid repeatedly dereferencing tp
45316         and type_p.
45318 2023-04-21  Jan Hubicka  <jh@suse.cz>
45320         * tree-ssa-loop-ch.cc (ch_base::copy_headers): Fix previous
45321         commit.
45323 2023-04-21  Vineet Gupta  <vineetg@rivosinc.com>
45325         * expmed.h (x_shift*_cost): convert to int [speed][mode][shift].
45326         (shift*_cost_ptr ()): Access x_shift*_cost array directly.
45328 2023-04-21  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
45330         * config/aarch64/aarch64.cc (aarch64_simd_dup_constant): Use
45331         force_reg instead of copy_to_mode_reg.
45332         (aarch64_expand_vector_init): Likewise.
45334 2023-04-21  Uroš Bizjak  <ubizjak@gmail.com>
45336         * config/i386/i386.h (REG_OK_FOR_INDEX_P, REG_OK_FOR_BASE_P): Remove.
45337         (REG_OK_FOR_INDEX_NONSTRICT_P,  REG_OK_FOR_BASE_NONSTRICT_P): Ditto.
45338         (REG_OK_FOR_INDEX_STRICT_P, REG_OK_FOR_BASE_STRICT_P): Ditto.
45339         (FIRST_INDEX_REG, LAST_INDEX_REG): New defines.
45340         (LEGACY_INDEX_REG_P, LEGACY_INDEX_REGNO_P): New macros.
45341         (INDEX_REG_P, INDEX_REGNO_P): Ditto.
45342         (REGNO_OK_FOR_INDEX_P): Use INDEX_REGNO_P predicates.
45343         (REGNO_OK_FOR_INDEX_NONSTRICT_P): New macro.
45344         (EG_OK_FOR_BASE_NONSTRICT_P): Ditto.
45345         * config/i386/predicates.md (index_register_operand):
45346         Use REGNO_OK_FOR_INDEX_P and REGNO_OK_FOR_INDEX_NONSTRICT_P macros.
45347         * config/i386/i386.cc (ix86_legitimate_address_p): Use
45348         REGNO_OK_FOR_BASE_P, REGNO_OK_FOR_BASE_NONSTRICT_P,
45349         REGNO_OK_FOR_INDEX_P and REGNO_OK_FOR_INDEX_NONSTRICT_P macros.
45351 2023-04-21  Jan Hubicka  <hubicka@ucw.cz>
45352             Ondrej Kubanek  <kubanek0ondrej@gmail.com>
45354         * tree-ssa-loop-ch.cc (ch_base::copy_headers): Update loop header and
45355         latch.
45357 2023-04-21  Richard Biener  <rguenther@suse.de>
45359         * is-a.h (safe_is_a): New.
45361 2023-04-21  Richard Biener  <rguenther@suse.de>
45363         * gimple-iterator.h (gimple_stmt_iterator::operator*): Add.
45364         (gphi_iterator::operator*): Likewise.
45366 2023-04-21  Jan Hubicka  <hubicka@ucw.cz>
45367             Michal Jires  <michal@jires.eu>
45369         * ipa-inline.cc (class inline_badness): New class.
45370         (edge_heap_t, edge_heap_node_t): Use inline_badness for badness instead
45371         of sreal.
45372         (update_edge_key): Update.
45373         (lookup_recursive_calls): Likewise.
45374         (recursive_inlining): Likewise.
45375         (add_new_edges_to_heap): Likewise.
45376         (inline_small_functions): Likewise.
45378 2023-04-21  Jan Hubicka  <hubicka@ucw.cz>
45380         * ipa-devirt.cc (odr_types_equivalent_p): Cleanup warned checks.
45382 2023-04-21  Richard Biener  <rguenther@suse.de>
45384         PR tree-optimization/109573
45385         * tree-vect-loop.cc (vectorizable_live_operation): Allow
45386         unhandled SSA copy as well.  Demote assert to checking only.
45388 2023-04-21  Richard Biener  <rguenther@suse.de>
45390         * df-core.cc (df_analyze): Compute RPO on the reverse graph
45391         for DF_BACKWARD problems.
45392         (loop_post_order_compute): Rename to ...
45393         (loop_rev_post_order_compute): ... this, compute a RPO.
45394         (loop_inverted_post_order_compute): Rename to ...
45395         (loop_inverted_rev_post_order_compute): ... this, compute a RPO.
45396         (df_analyze_loop): Use RPO on the forward graph for DF_FORWARD
45397         problems, RPO on the inverted graph for DF_BACKWARD.
45399 2023-04-21  Richard Biener  <rguenther@suse.de>
45401         * cfganal.h (inverted_rev_post_order_compute): Rename
45402         from ...
45403         (inverted_post_order_compute): ... this.  Add struct function
45404         argument, change allocation to a C array.
45405         * cfganal.cc (inverted_rev_post_order_compute): Likewise.
45406         * lcm.cc (compute_antinout_edge): Adjust.
45407         * lra-lives.cc (lra_create_live_ranges_1): Likewise.
45408         * tree-ssa-dce.cc (remove_dead_stmt): Likewise.
45409         * tree-ssa-pre.cc (compute_antic): Likewise.
45411 2023-04-21  Richard Biener  <rguenther@suse.de>
45413         * df.h (df_d::postorder_inverted): Change back to int *,
45414         clarify comments.
45415         * df-core.cc (rest_of_handle_df_finish): Adjust.
45416         (df_analyze_1): Likewise.
45417         (df_analyze): For DF_FORWARD problems use RPO on the forward
45418         graph.  Adjust.
45419         (loop_inverted_post_order_compute): Adjust API.
45420         (df_analyze_loop): Adjust.
45421         (df_get_n_blocks): Likewise.
45422         (df_get_postorder): Likewise.
45424 2023-04-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
45426         PR target/108270
45427         * config/riscv/riscv-vsetvl.cc
45428         (vector_infos_manager::all_empty_predecessor_p): New function.
45429         (pass_vsetvl::backward_demand_fusion): Ditto.
45430         * config/riscv/riscv-vsetvl.h: Ditto.
45432 2023-04-21  Robin Dapp  <rdapp@ventanamicro.com>
45434         PR target/109582
45435         * config/riscv/generic.md: Change standard names to insn names.
45437 2023-04-21  Richard Biener  <rguenther@suse.de>
45439         * lcm.cc (compute_antinout_edge): Use RPO on the inverted graph.
45440         (compute_laterin): Use RPO.
45441         (compute_available): Likewise.
45443 2023-04-21  Peng Fan  <fanpeng@loongson.cn>
45445         * config/loongarch/gnu-user.h (MUSL_DYNAMIC_LINKER): Redefine.
45447 2023-04-21  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
45449         PR target/109547
45450         * config/riscv/riscv-vsetvl.cc (local_eliminate_vsetvl_insn): New function.
45451         (vector_insn_info::skip_avl_compatible_p): Ditto.
45452         (vector_insn_info::merge): Remove default value.
45453         (pass_vsetvl::compute_local_backward_infos): Ditto.
45454         (pass_vsetvl::cleanup_insns): Add local vsetvl elimination.
45455         * config/riscv/riscv-vsetvl.h: Ditto.
45457 2023-04-20  Alejandro Colomar  <alx.manpages@gmail.com>
45459         * doc/extend.texi (Common Function Attributes): Remove duplicate
45460         word.
45462 2023-04-20  Andrew MacLeod  <amacleod@redhat.com>
45464         PR tree-optimization/109564
45465         * gimple-range-fold.cc (fold_using_range::range_of_phi): Do no ignore
45466         UNDEFINED range names when deciding if all PHI arguments are the same,
45468 2023-04-20  Jakub Jelinek  <jakub@redhat.com>
45470         PR tree-optimization/109011
45471         * tree-vect-patterns.cc (vect_recog_ctz_ffs_pattern): Use
45472         .CTZ (X) = .POPCOUNT ((X - 1) & ~X) in preference to
45473         .CTZ (X) = PREC - .POPCOUNT (X | -X).
45475 2023-04-20  Vladimir N. Makarov  <vmakarov@redhat.com>
45477         * lra-constraints.cc (match_reload): Exclude some hard regs for
45478         multi-reg inout reload pseudos used in asm in different mode.
45480 2023-04-20  Uros Bizjak  <ubizjak@gmail.com>
45482         * config/arm/arm.cc (thumb1_legitimate_address_p):
45483         Use VIRTUAL_REGISTER_P predicate.
45484         (arm_eliminable_register): Ditto.
45485         * config/avr/avr.md (push<mode>_1): Ditto.
45486         * config/bfin/predicates.md (register_no_elim_operand): Ditto.
45487         * config/h8300/predicates.md (register_no_sp_elim_operand): Ditto.
45488         * config/i386/predicates.md (register_no_elim_operand): Ditto.
45489         * config/iq2000/predicates.md (call_insn_operand): Ditto.
45490         * config/microblaze/microblaze.h (CALL_INSN_OP): Ditto.
45492 2023-04-20  Uros Bizjak  <ubizjak@gmail.com>
45494         PR target/78952
45495         * config/i386/predicates.md (extract_operator): New predicate.
45496         * config/i386/i386.md (any_extract): Remove code iterator.
45497         (*cmpqi_ext<mode>_1_mem_rex64): Use extract_operator predicate.
45498         (*cmpqi_ext<mode>_1): Ditto.
45499         (*cmpqi_ext<mode>_2): Ditto.
45500         (*cmpqi_ext<mode>_3_mem_rex64): Ditto.
45501         (*cmpqi_ext<mode>_3): Ditto.
45502         (*cmpqi_ext<mode>_4): Ditto.
45503         (*extzvqi_mem_rex64): Ditto.
45504         (*extzvqi): Ditto.
45505         (*insvqi_2): Ditto.
45506         (*extendqi<SWI24:mode>_ext_1): Ditto.
45507         (*addqi_ext<mode>_0): Ditto.
45508         (*addqi_ext<mode>_1): Ditto.
45509         (*addqi_ext<mode>_2): Ditto.
45510         (*subqi_ext<mode>_0): Ditto.
45511         (*subqi_ext<mode>_2): Ditto.
45512         (*testqi_ext<mode>_1): Ditto.
45513         (*testqi_ext<mode>_2): Ditto.
45514         (*andqi_ext<mode>_0): Ditto.
45515         (*andqi_ext<mode>_1): Ditto.
45516         (*andqi_ext<mode>_1_cc): Ditto.
45517         (*andqi_ext<mode>_2): Ditto.
45518         (*<any_or:code>qi_ext<mode>_0): Ditto.
45519         (*<any_or:code>qi_ext<mode>_1): Ditto.
45520         (*<any_or:code>qi_ext<mode>_2): Ditto.
45521         (*xorqi_ext<mode>_1_cc): Ditto.
45522         (*negqi_ext<mode>_2): Ditto.
45523         (*ashlqi_ext<mode>_2): Ditto.
45524         (*<any_shiftrt:insn>qi_ext<mode>_2): Ditto.
45526 2023-04-20  Raphael Zinsly  <rzinsly@ventanamicro.com>
45528         PR target/108248
45529         * config/riscv/bitmanip.md (clz, ctz, pcnt, min, max patterns): Use
45530         <bitmanip_insn> as the type to allow for fine grained control of
45531         scheduling these insns.
45532         * config/riscv/generic.md (generic_alu): Add bitmanip, clz, ctz, pcnt,
45533         min, max.
45534         * config/riscv/riscv.md (type attribute): Add types for clz, ctz,
45535         pcnt, signed and unsigned min/max.
45537 2023-04-20  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
45538             kito-cheng  <kito.cheng@sifive.com>
45540         * config/riscv/riscv.h (enum reg_class): Fix RVV register order.
45542 2023-04-20  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
45543             kito-cheng  <kito.cheng@sifive.com>
45545         PR target/109535
45546         * config/riscv/riscv-vsetvl.cc (count_regno_occurrences): New function.
45547         (pass_vsetvl::cleanup_insns): Fix bug.
45549 2023-04-20  Andrew Stubbs  <ams@codesourcery.com>
45551         * config/gcn/gcn-valu.md (vnsi, VnSI): Add scalar modes.
45552         (ldexp<mode>3): Delete.
45553         (ldexp<mode>3<exec>): Change "B" to "A".
45555 2023-04-20  Jakub Jelinek  <jakub@redhat.com>
45556             Jonathan Wakely  <jwakely@redhat.com>
45558         * tree.h (built_in_function_equal_p): New helper function.
45559         (fndecl_built_in_p): Turn into variadic template to support
45560         1 or more built_in_function arguments.
45561         * builtins.cc (fold_builtin_expect): Use 3 argument fndecl_built_in_p.
45562         * gimplify.cc (goa_stabilize_expr): Likewise.
45563         * cgraphclones.cc (cgraph_node::create_clone): Likewise.
45564         * ipa-fnsummary.cc (compute_fn_summary): Likewise.
45565         * omp-low.cc (setjmp_or_longjmp_p): Likewise.
45566         * cgraph.cc (cgraph_edge::redirect_call_stmt_to_callee,
45567         cgraph_update_edges_for_call_stmt_node,
45568         cgraph_edge::verify_corresponds_to_fndecl,
45569         cgraph_node::verify_node): Likewise.
45570         * tree-stdarg.cc (optimize_va_list_gpr_fpr_size): Likewise.
45571         * gimple-ssa-warn-access.cc (matching_alloc_calls_p): Likewise.
45572         * ipa-prop.cc (try_make_edge_direct_virtual_call): Likewise.
45574 2023-04-20  Jakub Jelinek  <jakub@redhat.com>
45576         PR tree-optimization/109011
45577         * tree-vect-patterns.cc (vect_recog_ctz_ffs_pattern): New function.
45578         (vect_recog_popcount_clz_ctz_ffs_pattern): Move vect_pattern_detected
45579         call later.  Don't punt for IFN_CTZ or IFN_FFS if it doesn't have
45580         direct optab support, but has instead IFN_CLZ, IFN_POPCOUNT or
45581         for IFN_FFS IFN_CTZ support, use vect_recog_ctz_ffs_pattern for that
45582         case.
45583         (vect_vect_recog_func_ptrs): Add ctz_ffs entry.
45585 2023-04-20  Richard Biener  <rguenther@suse.de>
45587         * df-core.cc (rest_of_handle_df_initialize): Remove
45588         computation of df->postorder, df->postorder_inverted and
45589         df->n_blocks.
45591 2023-04-20  Haochen Jiang  <haochen.jiang@intel.com>
45593         * common/config/i386/i386-common.cc
45594         (OPTION_MASK_ISA2_AVX_UNSET): Add OPTION_MASK_ISA2_VAES_UNSET.
45595         (ix86_handle_option): Set AVX flag for VAES.
45596         * config/i386/i386-builtins.cc (ix86_init_mmx_sse_builtins):
45597         Add OPTION_MASK_ISA2_VAES_UNSET.
45598         (def_builtin): Share builtin between AES and VAES.
45599         * config/i386/i386-expand.cc (ix86_check_builtin_isa_match):
45600         Ditto.
45601         * config/i386/i386.md (aes): New isa attribute.
45602         * config/i386/sse.md (aesenc): Add pattern for VAES with xmm.
45603         (aesenclast): Ditto.
45604         (aesdec): Ditto.
45605         (aesdeclast): Ditto.
45606         * config/i386/vaesintrin.h: Remove redundant avx target push.
45607         * config/i386/wmmintrin.h (_mm_aesdec_si128): Change to macro.
45608         (_mm_aesdeclast_si128): Ditto.
45609         (_mm_aesenc_si128): Ditto.
45610         (_mm_aesenclast_si128): Ditto.
45612 2023-04-20  Hu, Lin1  <lin1.hu@intel.com>
45614         * config/i386/avx2intrin.h
45615         (_MM_REDUCE_OPERATOR_BASIC_EPI16): New macro.
45616         (_MM_REDUCE_OPERATOR_MAX_MIN_EP16): Ditto.
45617         (_MM256_REDUCE_OPERATOR_BASIC_EPI16): Ditto.
45618         (_MM256_REDUCE_OPERATOR_MAX_MIN_EP16): Ditto.
45619         (_MM_REDUCE_OPERATOR_BASIC_EPI8): Ditto.
45620         (_MM_REDUCE_OPERATOR_MAX_MIN_EP8): Ditto.
45621         (_MM256_REDUCE_OPERATOR_BASIC_EPI8): Ditto.
45622         (_MM256_REDUCE_OPERATOR_MAX_MIN_EP8): Ditto.
45623         (_mm_reduce_add_epi16): New instrinsics.
45624         (_mm_reduce_mul_epi16): Ditto.
45625         (_mm_reduce_and_epi16): Ditto.
45626         (_mm_reduce_or_epi16): Ditto.
45627         (_mm_reduce_max_epi16): Ditto.
45628         (_mm_reduce_max_epu16): Ditto.
45629         (_mm_reduce_min_epi16): Ditto.
45630         (_mm_reduce_min_epu16): Ditto.
45631         (_mm256_reduce_add_epi16): Ditto.
45632         (_mm256_reduce_mul_epi16): Ditto.
45633         (_mm256_reduce_and_epi16): Ditto.
45634         (_mm256_reduce_or_epi16): Ditto.
45635         (_mm256_reduce_max_epi16): Ditto.
45636         (_mm256_reduce_max_epu16): Ditto.
45637         (_mm256_reduce_min_epi16): Ditto.
45638         (_mm256_reduce_min_epu16): Ditto.
45639         (_mm_reduce_add_epi8): Ditto.
45640         (_mm_reduce_mul_epi8): Ditto.
45641         (_mm_reduce_and_epi8): Ditto.
45642         (_mm_reduce_or_epi8): Ditto.
45643         (_mm_reduce_max_epi8): Ditto.
45644         (_mm_reduce_max_epu8): Ditto.
45645         (_mm_reduce_min_epi8): Ditto.
45646         (_mm_reduce_min_epu8): Ditto.
45647         (_mm256_reduce_add_epi8): Ditto.
45648         (_mm256_reduce_mul_epi8): Ditto.
45649         (_mm256_reduce_and_epi8): Ditto.
45650         (_mm256_reduce_or_epi8): Ditto.
45651         (_mm256_reduce_max_epi8): Ditto.
45652         (_mm256_reduce_max_epu8): Ditto.
45653         (_mm256_reduce_min_epi8): Ditto.
45654         (_mm256_reduce_min_epu8): Ditto.
45655         * config/i386/avx512vlbwintrin.h:
45656         (_mm_mask_reduce_add_epi16): Ditto.
45657         (_mm_mask_reduce_mul_epi16): Ditto.
45658         (_mm_mask_reduce_and_epi16): Ditto.
45659         (_mm_mask_reduce_or_epi16): Ditto.
45660         (_mm_mask_reduce_max_epi16): Ditto.
45661         (_mm_mask_reduce_max_epu16): Ditto.
45662         (_mm_mask_reduce_min_epi16): Ditto.
45663         (_mm_mask_reduce_min_epu16): Ditto.
45664         (_mm256_mask_reduce_add_epi16): Ditto.
45665         (_mm256_mask_reduce_mul_epi16): Ditto.
45666         (_mm256_mask_reduce_and_epi16): Ditto.
45667         (_mm256_mask_reduce_or_epi16): Ditto.
45668         (_mm256_mask_reduce_max_epi16): Ditto.
45669         (_mm256_mask_reduce_max_epu16): Ditto.
45670         (_mm256_mask_reduce_min_epi16): Ditto.
45671         (_mm256_mask_reduce_min_epu16): Ditto.
45672         (_mm_mask_reduce_add_epi8): Ditto.
45673         (_mm_mask_reduce_mul_epi8): Ditto.
45674         (_mm_mask_reduce_and_epi8): Ditto.
45675         (_mm_mask_reduce_or_epi8): Ditto.
45676         (_mm_mask_reduce_max_epi8): Ditto.
45677         (_mm_mask_reduce_max_epu8): Ditto.
45678         (_mm_mask_reduce_min_epi8): Ditto.
45679         (_mm_mask_reduce_min_epu8): Ditto.
45680         (_mm256_mask_reduce_add_epi8): Ditto.
45681         (_mm256_mask_reduce_mul_epi8): Ditto.
45682         (_mm256_mask_reduce_and_epi8): Ditto.
45683         (_mm256_mask_reduce_or_epi8): Ditto.
45684         (_mm256_mask_reduce_max_epi8): Ditto.
45685         (_mm256_mask_reduce_max_epu8): Ditto.
45686         (_mm256_mask_reduce_min_epi8): Ditto.
45687         (_mm256_mask_reduce_min_epu8): Ditto.
45689 2023-04-20  Haochen Jiang  <haochen.jiang@intel.com>
45691         * common/config/i386/i386-common.cc
45692         (OPTION_MASK_ISA_VPCLMULQDQ_SET):
45693         Add OPTION_MASK_ISA_PCLMUL_SET and OPTION_MASK_ISA_AVX_SET.
45694         (OPTION_MASK_ISA_AVX_UNSET):
45695         Add OPTION_MASK_ISA_VPCLMULQDQ_UNSET.
45696         (OPTION_MASK_ISA_PCLMUL_UNSET): Ditto.
45697         * config/i386/i386.md (vpclmulqdqvl): New.
45698         * config/i386/sse.md (pclmulqdq): Add evex encoding.
45699         * config/i386/vpclmulqdqintrin.h: Remove redudant avx target
45700         push.
45702 2023-04-20  Haochen Jiang  <haochen.jiang@intel.com>
45704         * config/i386/avx512vlbwintrin.h
45705         (_mm_mask_blend_epi16): Remove __OPTIMIZE__ wrapper.
45706         (_mm_mask_blend_epi8): Ditto.
45707         (_mm256_mask_blend_epi16): Ditto.
45708         (_mm256_mask_blend_epi8): Ditto.
45709         * config/i386/avx512vlintrin.h
45710         (_mm256_mask_blend_pd): Ditto.
45711         (_mm256_mask_blend_ps): Ditto.
45712         (_mm256_mask_blend_epi64): Ditto.
45713         (_mm256_mask_blend_epi32): Ditto.
45714         (_mm_mask_blend_pd): Ditto.
45715         (_mm_mask_blend_ps): Ditto.
45716         (_mm_mask_blend_epi64): Ditto.
45717         (_mm_mask_blend_epi32): Ditto.
45718         * config/i386/sse.md (VF_AVX512BWHFBF16): Removed.
45719         (VF_AVX512HFBFVL): Move it before the first usage.
45720         (<avx512>_blendm<mode>): Change iterator from VF_AVX512BWHFBF16
45721         to VF_AVX512HFBFVL.
45723 2023-04-20  Haochen Jiang  <haochen.jiang@intel.com>
45725         * common/config/i386/i386-common.cc
45726         (OPTION_MASK_ISA_AVX512VBMI2_SET): Change OPTION_MASK_ISA_AVX512F_SET
45727         to OPTION_MASK_ISA_AVX512BW_SET.
45728         (OPTION_MASK_ISA_AVX512F_UNSET):
45729         Remove OPTION_MASK_ISA_AVX512VBMI2_UNSET.
45730         (OPTION_MASK_ISA_AVX512BW_UNSET):
45731         Add OPTION_MASK_ISA_AVX512VBMI2_UNSET.
45732         * config/i386/avx512vbmi2intrin.h: Do not push avx512bw.
45733         * config/i386/avx512vbmi2vlintrin.h: Ditto.
45734         * config/i386/i386-builtin.def: Remove OPTION_MASK_ISA_AVX512BW.
45735         * config/i386/sse.md (VI12_AVX512VLBW): Removed.
45736         (VI12_VI48F_AVX512VLBW): Rename to VI12_VI48F_AVX512VL.
45737         (compress<mode>_mask): Change iterator from VI12_AVX512VLBW to
45738         VI12_AVX512VL.
45739         (compressstore<mode>_mask): Ditto.
45740         (expand<mode>_mask): Ditto.
45741         (expand<mode>_maskz): Ditto.
45742         (*expand<mode>_mask): Change iterator from VI12_VI48F_AVX512VLBW to
45743         VI12_VI48F_AVX512VL.
45745 2023-04-20  Haochen Jiang  <haochen.jiang@intel.com>
45747         * common/config/i386/i386-common.cc
45748         (OPTION_MASK_ISA_AVX512BITALG_SET):
45749         Change OPTION_MASK_ISA_AVX512F_SET
45750         to OPTION_MASK_ISA_AVX512BW_SET.
45751         (OPTION_MASK_ISA_AVX512F_UNSET):
45752         Remove OPTION_MASK_ISA_AVX512BITALG_SET.
45753         (OPTION_MASK_ISA_AVX512BW_UNSET):
45754         Add OPTION_MASK_ISA_AVX512BITALG_SET.
45755         * config/i386/avx512bitalgintrin.h: Do not push avx512bw.
45756         * config/i386/i386-builtin.def:
45757         Remove redundant OPTION_MASK_ISA_AVX512BW.
45758         * config/i386/sse.md (VI1_AVX512VLBW): Removed.
45759         (avx512vl_vpshufbitqmb<mode><mask_scalar_merge_name>):
45760         Change the iterator from VI1_AVX512VLBW to VI1_AVX512VL.
45762 2023-04-20  Haochen Jiang  <haochen.jiang@intel.com>
45764         * config/i386/i386-expand.cc
45765         (ix86_check_builtin_isa_match): Correct wrong comments.
45766         Add a new macro SHARE_BUILTIN and refactor the current if
45767         clauses to macro.
45769 2023-04-20  Mo, Zewei  <zewei.mo@intel.com>
45771         * config/i386/cpuid.h: Open a new section for Extended Features
45772         Leaf (%eax == 7, %ecx == 0) and Extended Features Sub-leaf (%eax == 7,
45773         %ecx == 1).
45775 2023-04-20  Hu, Lin1  <lin1.hu@intel.com>
45777         * config/i386/sse.md: Modify insn vperm{i,f}
45778         and vshuf{i,f}.
45780 2023-04-19  Max Filippov  <jcmvbkbc@gmail.com>
45782         * config/xtensa/xtensa-opts.h: New header.
45783         * config/xtensa/xtensa.h (STRICT_ALIGNMENT): Redefine as
45784         xtensa_strict_align.
45785         * config/xtensa/xtensa.cc (xtensa_option_override): When
45786         -m[no-]strict-align is not specified in the command line set
45787         xtensa_strict_align to 0 if the hardware supports both unaligned
45788         loads and stores or to 1 otherwise.
45789         * config/xtensa/xtensa.opt (mstrict-align): New option.
45790         * doc/invoke.texi (Xtensa Options): Document -m[no-]strict-align.
45792 2023-04-19  Max Filippov  <jcmvbkbc@gmail.com>
45794         * config/xtensa/xtensa-dynconfig.cc (xtensa_get_config_v4): New
45795         function.
45797 2023-04-19  Andrew Pinski  <apinski@marvell.com>
45799         * config/i386/i386.md (*movsicc_noc_zext_1): New pattern.
45801 2023-04-19  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
45803         * config/riscv/riscv-modes.def (FLOAT_MODE): Add chunk 128 support.
45804         (VECTOR_BOOL_MODE): Ditto.
45805         (ADJUST_NUNITS): Ditto.
45806         (ADJUST_ALIGNMENT): Ditto.
45807         (ADJUST_BYTESIZE): Ditto.
45808         (ADJUST_PRECISION): Ditto.
45809         (RVV_MODES): Ditto.
45810         (VECTOR_MODE_WITH_PREFIX): Ditto.
45811         * config/riscv/riscv-v.cc (ENTRY): Ditto.
45812         (get_vlmul): Ditto.
45813         (get_ratio): Ditto.
45814         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_TYPE): Ditto.
45815         * config/riscv/riscv-vector-builtins.def (DEF_RVV_TYPE): Ditto.
45816         (vbool64_t): Ditto.
45817         (vbool32_t): Ditto.
45818         (vbool16_t): Ditto.
45819         (vbool8_t): Ditto.
45820         (vbool4_t): Ditto.
45821         (vbool2_t): Ditto.
45822         (vbool1_t): Ditto.
45823         (vint8mf8_t): Ditto.
45824         (vuint8mf8_t): Ditto.
45825         (vint8mf4_t): Ditto.
45826         (vuint8mf4_t): Ditto.
45827         (vint8mf2_t): Ditto.
45828         (vuint8mf2_t): Ditto.
45829         (vint8m1_t): Ditto.
45830         (vuint8m1_t): Ditto.
45831         (vint8m2_t): Ditto.
45832         (vuint8m2_t): Ditto.
45833         (vint8m4_t): Ditto.
45834         (vuint8m4_t): Ditto.
45835         (vint8m8_t): Ditto.
45836         (vuint8m8_t): Ditto.
45837         (vint16mf4_t): Ditto.
45838         (vuint16mf4_t): Ditto.
45839         (vint16mf2_t): Ditto.
45840         (vuint16mf2_t): Ditto.
45841         (vint16m1_t): Ditto.
45842         (vuint16m1_t): Ditto.
45843         (vint16m2_t): Ditto.
45844         (vuint16m2_t): Ditto.
45845         (vint16m4_t): Ditto.
45846         (vuint16m4_t): Ditto.
45847         (vint16m8_t): Ditto.
45848         (vuint16m8_t): Ditto.
45849         (vint32mf2_t): Ditto.
45850         (vuint32mf2_t): Ditto.
45851         (vint32m1_t): Ditto.
45852         (vuint32m1_t): Ditto.
45853         (vint32m2_t): Ditto.
45854         (vuint32m2_t): Ditto.
45855         (vint32m4_t): Ditto.
45856         (vuint32m4_t): Ditto.
45857         (vint32m8_t): Ditto.
45858         (vuint32m8_t): Ditto.
45859         (vint64m1_t): Ditto.
45860         (vuint64m1_t): Ditto.
45861         (vint64m2_t): Ditto.
45862         (vuint64m2_t): Ditto.
45863         (vint64m4_t): Ditto.
45864         (vuint64m4_t): Ditto.
45865         (vint64m8_t): Ditto.
45866         (vuint64m8_t): Ditto.
45867         (vfloat32mf2_t): Ditto.
45868         (vfloat32m1_t): Ditto.
45869         (vfloat32m2_t): Ditto.
45870         (vfloat32m4_t): Ditto.
45871         (vfloat32m8_t): Ditto.
45872         (vfloat64m1_t): Ditto.
45873         (vfloat64m2_t): Ditto.
45874         (vfloat64m4_t): Ditto.
45875         (vfloat64m8_t): Ditto.
45876         * config/riscv/riscv-vector-switch.def (ENTRY): Ditto.
45877         * config/riscv/riscv.cc (riscv_legitimize_poly_move): Ditto.
45878         (riscv_convert_vector_bits): Ditto.
45879         * config/riscv/riscv.md:
45880         * config/riscv/vector-iterators.md:
45881         * config/riscv/vector.md
45882         (@pred_indexed_<order>store<VNX32_QH:mode><VNX32_QHI:mode>): Ditto.
45883         (@pred_indexed_<order>store<VNX32_QHS:mode><VNX32_QHSI:mode>): Ditto.
45884         (@pred_indexed_<order>store<VNX64_Q:mode><VNX64_Q:mode>): Ditto.
45885         (@pred_indexed_<order>store<VNX64_QH:mode><VNX64_QHI:mode>): Ditto.
45886         (@pred_indexed_<order>store<VNX128_Q:mode><VNX128_Q:mode>): Ditto.
45887         (@pred_reduc_<reduc><mode><vlmul1_zve64>): Ditto.
45888         (@pred_widen_reduc_plus<v_su><mode><vwlmul1_zve64>): Ditto.
45889         (@pred_reduc_plus<order><mode><vlmul1_zve64>): Ditto.
45890         (@pred_widen_reduc_plus<order><mode><vwlmul1_zve64>): Ditto.
45892 2023-04-19  Pan Li  <pan2.li@intel.com>
45894         * simplify-rtx.cc (simplify_context::simplify_binary_operation_1):
45895         Align IOR (A | (~A) -> -1) optimization MODE_CLASS condition to AND.
45897 2023-04-19  Uros Bizjak  <ubizjak@gmail.com>
45899         PR target/78904
45900         PR target/78952
45901         * config/i386/i386.md (*cmpqi_ext<mode>_1_mem_rex64): New insn pattern.
45902         (*cmpqi_ext<mode>_1): Use nonimmediate_operand predicate
45903         for operand 0. Use any_extract code iterator.
45904         (*cmpqi_ext<mode>_1 peephole2): New peephole2 pattern.
45905         (*cmpqi_ext<mode>_2): Use any_extract code iterator.
45906         (*cmpqi_ext<mode>_3_mem_rex64): New insn pattern.
45907         (*cmpqi_ext<mode>_1): Use general_operand predicate
45908         for operand 1. Use any_extract code iterator.
45909         (*cmpqi_ext<mode>_3 peephole2): New peephole2 pattern.
45910         (*cmpqi_ext<mode>_4): Use any_extract code iterator.
45912 2023-04-19  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
45914         * config/aarch64/aarch64-simd.md (aarch64_saddw2<mode>): Delete.
45915         (aarch64_uaddw2<mode>): Delete.
45916         (aarch64_ssubw2<mode>): Delete.
45917         (aarch64_usubw2<mode>): Delete.
45918         (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w2<mode>): New define_expand.
45920 2023-04-19  Richard Biener  <rguenther@suse.de>
45922         * tree-ssa-structalias.cc (do_ds_constraint): Use
45923         solve_add_graph_edge.
45925 2023-04-19  Richard Biener  <rguenther@suse.de>
45927         * tree-ssa-structalias.cc (solve_add_graph_edge): New function,
45928         split out from ...
45929         (do_sd_constraint): ... here.
45931 2023-04-19  Richard Biener  <rguenther@suse.de>
45933         * tree-cfg.cc (gimple_can_merge_blocks_p): Remove condition
45934         rejecting the merge when A contains only a non-local label.
45936 2023-04-19  Uros Bizjak  <ubizjak@gmail.com>
45938         * rtl.h (VIRTUAL_REGISTER_P): New predicate.
45939         (VIRTUAL_REGISTER_NUM_P): Ditto.
45940         (REGNO_PTR_FRAME_P): Use VIRTUAL_REGISTER_NUM_P predicate.
45941         * expr.cc (force_operand): Use VIRTUAL_REGISTER_P predicate.
45942         * function.cc (instantiate_decl_rtl): Ditto.
45943         * rtlanal.cc (rtx_addr_can_trap_p_1): Ditto.
45944         (nonzero_address_p): Ditto.
45945         (refers_to_regno_p): Use VIRTUAL_REGISTER_NUM_P predicate.
45947 2023-04-19  Aldy Hernandez  <aldyh@redhat.com>
45949         * value-range.h (Value_Range::Value_Range): Avoid pointer sharing.
45951 2023-04-19  Richard Biener  <rguenther@suse.de>
45953         * system.h (auto_mpz::operator->()): New.
45954         * realmpfr.h (auto_mpfr::operator->()): New.
45955         * builtins.cc (do_mpfr_lgamma_r): Use auto_mpfr.
45956         * real.cc (real_from_string): Likewise.
45957         (dconst_e_ptr): Likewise.
45958         (dconst_sqrt2_ptr): Likewise.
45959         * tree-ssa-loop-niter.cc (refine_value_range_using_guard):
45960         Use auto_mpz.
45961         (bound_difference_of_offsetted_base): Likewise.
45962         (number_of_iterations_ne): Likewise.
45963         (number_of_iterations_lt_to_ne): Likewise.
45964         * ubsan.cc: Include realmpfr.h.
45965         (ubsan_instrument_float_cast): Use auto_mpfr.
45967 2023-04-19  Richard Biener  <rguenther@suse.de>
45969         * tree-ssa-structalias.cc (solve_graph): Remove self-copy
45970         edges, remove edges from escaped after special-casing them.
45972 2023-04-19  Richard Biener  <rguenther@suse.de>
45974         * tree-ssa-structalias.cc (do_sd_constraint): Fixup escape
45975         special casing.
45977 2023-04-19  Richard Biener  <rguenther@suse.de>
45979         * tree-ssa-structalias.cc (do_sd_constraint): Do not write
45980         to the LHS varinfo solution member.
45982 2023-04-19  Richard Biener  <rguenther@suse.de>
45984         * tree-ssa-structalias.cc (topo_visit): Look at the real
45985         destination of edges.
45987 2023-04-19  Richard Biener  <rguenther@suse.de>
45989         PR tree-optimization/44794
45990         * tree-ssa-loop-manip.cc (tree_transform_and_unroll_loop):
45991         If an epilogue loop is required set its iteration upper bound.
45993 2023-04-19  Xi Ruoyao  <xry111@xry111.site>
45995         PR target/109465
45996         * config/loongarch/loongarch-protos.h
45997         (loongarch_expand_block_move): Add a parameter as alignment RTX.
45998         * config/loongarch/loongarch.h:
45999         (LARCH_MAX_MOVE_BYTES_PER_LOOP_ITER): Remove.
46000         (LARCH_MAX_MOVE_BYTES_STRAIGHT): Remove.
46001         (LARCH_MAX_MOVE_OPS_PER_LOOP_ITER): Define.
46002         (LARCH_MAX_MOVE_OPS_STRAIGHT): Define.
46003         (MOVE_RATIO): Use LARCH_MAX_MOVE_OPS_PER_LOOP_ITER instead of
46004         LARCH_MAX_MOVE_BYTES_PER_LOOP_ITER.
46005         * config/loongarch/loongarch.cc (loongarch_expand_block_move):
46006         Take the alignment from the parameter, but set it to
46007         UNITS_PER_WORD if !TARGET_STRICT_ALIGN.  Limit the length of
46008         straight-line implementation with LARCH_MAX_MOVE_OPS_STRAIGHT
46009         instead of LARCH_MAX_MOVE_BYTES_STRAIGHT.
46010         (loongarch_block_move_straight): When there are left-over bytes,
46011         half the mode size instead of falling back to byte mode at once.
46012         (loongarch_block_move_loop): Limit the length of loop body with
46013         LARCH_MAX_MOVE_OPS_PER_LOOP_ITER instead of
46014         LARCH_MAX_MOVE_BYTES_PER_LOOP_ITER.
46015         * config/loongarch/loongarch.md (cpymemsi): Pass the alignment
46016         to loongarch_expand_block_move.
46018 2023-04-19  Xi Ruoyao  <xry111@xry111.site>
46020         * config/loongarch/loongarch.cc
46021         (loongarch_setup_incoming_varargs): Don't save more GARs than
46022         cfun->va_list_gpr_size / UNITS_PER_WORD.
46024 2023-04-19  Richard Biener  <rguenther@suse.de>
46026         * tree-ssa-loop-manip.cc (determine_exit_conditions): Fix
46027         no epilogue condition.
46029 2023-04-19  Richard Biener  <rguenther@suse.de>
46031         * gimple.h (gimple_assign_load): Outline...
46032         * gimple.cc (gimple_assign_load): ... here.  Avoid
46033         get_base_address and instead just strip the outermost
46034         handled component, treating a remaining handled component
46035         as load.
46037 2023-04-19  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
46039         * config/aarch64/aarch64-simd-builtins.def (neg): Delete builtins
46040         definition.
46041         * config/aarch64/arm_fp16.h (vnegh_f16): Reimplement using normal negation.
46043 2023-04-19  Jakub Jelinek  <jakub@redhat.com>
46045         PR tree-optimization/109011
46046         * tree-vect-patterns.cc (vect_recog_popcount_pattern): Rename to ...
46047         (vect_recog_popcount_clz_ctz_ffs_pattern): ... this.  Handle also
46048         CLZ, CTZ and FFS.  Remove vargs variable, use
46049         gimple_build_call_internal rather than gimple_build_call_internal_vec.
46050         (vect_vect_recog_func_ptrs): Adjust popcount entry.
46052 2023-04-19  Jakub Jelinek  <jakub@redhat.com>
46054         PR target/109040
46055         * dse.cc (replace_read): If read_reg is a SUBREG of a word mode
46056         REG, for WORD_REGISTER_OPERATIONS copy SUBREG_REG of it into
46057         a new REG rather than the SUBREG.
46059 2023-04-19  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
46061         * config/aarch64/aarch64-simd.md (aarch64_simd_vec_set_zero<mode>):
46062         New pattern.
46064 2023-04-19  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
46066         PR target/108840
46067         * config/aarch64/aarch64.cc (aarch64_rtx_costs): Merge ASHIFT and
46068         ROTATE, ROTATERT, LSHIFTRT, ASHIFTRT cases.  Handle subregs in op1.
46070 2023-04-19  Richard Biener  <rguenther@suse.de>
46072         PR rtl-optimization/109237
46073         * cse.cc (insn_live_p): Remove NEXT_INSN walk, instead check
46074         TREE_VISITED on INSN_VAR_LOCATION_DECL.
46075         (delete_trivially_dead_insns): Maintain TREE_VISITED on
46076         active debug bind INSN_VAR_LOCATION_DECL.
46078 2023-04-19  Richard Biener  <rguenther@suse.de>
46080         PR rtl-optimization/109237
46081         * cfgcleanup.cc (bb_is_just_return): Walk insns backwards.
46083 2023-04-19  Christophe Lyon  <christophe.lyon@arm.com>
46085         * doc/install.texi (enable-decimal-float): Add AArch64.
46087 2023-04-19  liuhongt  <hongtao.liu@intel.com>
46089         PR rtl-optimization/109351
46090         * ira.cc (setup_class_subset_and_memory_move_costs): Check
46091         hard_regno_mode_ok before setting lowest memory move cost for
46092         the mode with different reg classes.
46094 2023-04-18  Jason Merrill  <jason@redhat.com>
46096         * doc/invoke.texi: Remove stray @gol.
46098 2023-04-18  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
46100         * ifcvt.cc (cond_move_process_if_block): Consider the result of
46101         targetm.noce_conversion_profitable_p() when replacing the original
46102         sequence with the converted one.
46104 2023-04-18  Mark Harmstone  <mark@harmstone.com>
46106         * common.opt (gcodeview): Add new option.
46107         * gcc.cc (driver_handle_option); Handle OPT_gcodeview.
46108         * opts.cc (command_handle_option): Similarly.
46109         * doc/invoke.texi: Add documentation for -gcodeview.
46111 2023-04-18  Andrew Pinski  <apinski@marvell.com>
46113         * tree-ssa-phiopt.cc (tree_ssa_phiopt_worker): Remove declaration.
46114         (make_pass_phiopt): Make execute out of line.
46115         (tree_ssa_cs_elim): Move code into ...
46116         (pass_cselim::execute): here.
46118 2023-04-18  Sam James  <sam@gentoo.org>
46120         * system.h: Drop unused INCLUDE_PTHREAD_H.
46122 2023-04-18  Kevin Lee  <kevinl@rivosinc.com>
46124         * tree-vect-data-refs.cc (vect_grouped_store_supported): Add new
46125         condition.
46127 2023-04-18  Sinan Lin  <sinan.lin@linux.alibaba.com>
46129         * config/riscv/bitmanip.md (rotr<mode>3 expander): Enable for ZBKB.
46130         (bswapdi2, bswapsi2): Similarly.
46132 2023-04-18  Uros Bizjak  <ubizjak@gmail.com>
46134         PR target/94908
46135         * config/i386/i386-builtin.def (__builtin_ia32_insertps128):
46136         Use CODE_FOR_sse4_1_insertps_v4sf.
46137         * config/i386/i386-expand.cc (expand_vec_perm_insertps): New.
46138         (expand_vec_perm_1): Call expand_vec_per_insertps.
46139         * config/i386/i386.md ("unspec"): Declare UNSPEC_INSERTPS here.
46140         * config/i386/mmx.md (mmxscalarmode): New mode attribute.
46141         (@sse4_1_insertps_<mode>): New insn pattern.
46142         * config/i386/sse.md (@sse4_1_insertps_<mode>): Macroize insn
46143         pattern from sse4_1_insertps using VI4F_128 mode iterator.
46145 2023-04-18  Aldy Hernandez  <aldyh@redhat.com>
46147         * value-range.cc (gt_ggc_mx): New.
46148         (gt_pch_nx): New.
46149         * value-range.h (class vrange): Add GTY marker.
46150         (class frange): Same.
46151         (gt_ggc_mx): Remove.
46152         (gt_pch_nx): Remove.
46154 2023-04-18  Victor L. Do Nascimento  <victor.donascimento@arm.com>
46156         * lra-constraints.cc (constraint_unique): New.
46157         (process_address_1): Apply constraint_unique test.
46158         * recog.cc (constrain_operands): Allow relaxed memory
46159         constaints.
46161 2023-04-18  Kito Cheng  <kito.cheng@sifive.com>
46163         * doc/extend.texi (Target Builtins): Add RISC-V Vector
46164         Intrinsics.
46165         (RISC-V Vector Intrinsics): Document GCC implemented which
46166         version of RISC-V vector intrinsics and its reference.
46168 2023-04-18  Richard Biener  <rguenther@suse.de>
46170         PR middle-end/108786
46171         * bitmap.h (bitmap_clear_first_set_bit): New.
46172         * bitmap.cc (bitmap_first_set_bit_worker): Rename from
46173         bitmap_first_set_bit and add optional clearing of the bit.
46174         (bitmap_first_set_bit): Wrap bitmap_first_set_bit_worker.
46175         (bitmap_clear_first_set_bit): Likewise.
46176         * df-core.cc (df_worklist_dataflow_doublequeue): Use
46177         bitmap_clear_first_set_bit.
46178         * graphite-scop-detection.cc (scop_detection::merge_sese):
46179         Likewise.
46180         * sanopt.cc (sanitize_asan_mark_unpoison): Likewise.
46181         (sanitize_asan_mark_poison): Likewise.
46182         * tree-cfgcleanup.cc (cleanup_tree_cfg_noloop): Likewise.
46183         * tree-into-ssa.cc (rewrite_blocks): Likewise.
46184         * tree-ssa-dce.cc (simple_dce_from_worklist): Likewise.
46185         * tree-ssa-sccvn.cc (do_rpo_vn_1): Likewise.
46187 2023-04-18  Richard Biener  <rguenther@suse.de>
46189         * tree-ssa-structalias.cc (dump_sa_stats): Split out from...
46190         (dump_sa_points_to_info): ... this function.
46191         (compute_points_to_sets): Guard large dumps with TDF_DETAILS,
46192         and call dump_sa_stats guarded with TDF_STATS.
46193         (ipa_pta_execute): Likewise.
46194         (compute_may_aliases): Guard dump_alias_info with
46195         TDF_DETAILS|TDF_ALIAS.
46197 2023-04-18  Andrew Pinski  <apinski@marvell.com>
46199         * tree-ssa-phiopt.cc (gimple_simplify_phiopt): Dump
46200         the expression that is being tried when TDF_FOLDING
46201         is true.
46202         (phiopt_worker::match_simplify_replacement): Dump
46203         the sequence which was created by gimple_simplify_phiopt
46204         when TDF_FOLDING is true.
46206 2023-04-18  Andrew Pinski  <apinski@marvell.com>
46208         * tree-ssa-phiopt.cc (match_simplify_replacement):
46209         Simplify code that does the movement slightly.
46211 2023-04-18  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
46213         * config/aarch64/aarch64.md (@aarch64_rev16<mode>): Change to
46214         define_expand.
46215         (rev16<mode>2): Rename to...
46216         (aarch64_rev16<mode>2_alt1): ... This.
46217         (rev16<mode>2_alt): Rename to...
46218         (*aarch64_rev16<mode>2_alt2): ... This.
46220 2023-04-18  Aldy Hernandez  <aldyh@redhat.com>
46222         * emit-rtl.cc (init_emit_once): Initialize dconstm0.
46223         * gimple-range-op.cc (class cfn_signbit): Remove dconstm0
46224         declaration.
46225         * range-op-float.cc (zero_range): Use dconstm0.
46226         (zero_to_inf_range): Same.
46227         * real.h (dconstm0): New.
46228         * value-range.cc (frange::flush_denormals_to_zero): Use dconstm0.
46229         (frange::set_zero): Do not declare dconstm0.
46231 2023-04-18  Richard Biener  <rguenther@suse.de>
46233         * system.h (class auto_mpz): New,
46234         * realmpfr.h (class auto_mpfr): Likewise.
46235         * fold-const-call.cc (do_mpfr_arg1): Use auto_mpfr.
46236         (do_mpfr_arg2): Likewise.
46237         * tree-ssa-loop-niter.cc (bound_difference): Use auto_mpz;
46239 2023-04-18  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
46241         * config/aarch64/aarch64-builtins.cc (aarch64_init_simd_intrinsics): Take
46242         builtin flags from intrinsic data rather than hardcoded FLAG_AUTO_FP.
46244 2023-04-18  Aldy Hernandez  <aldyh@redhat.com>
46246         * value-range.cc (frange::operator==): Adjust for NAN.
46247         (range_tests_nan): Remove some NAN tests.
46249 2023-04-18  Aldy Hernandez  <aldyh@redhat.com>
46251         * inchash.cc (hash::add_real_value): New.
46252         * inchash.h (class hash): Add add_real_value.
46253         * value-range.cc (add_vrange): New.
46254         * value-range.h (inchash::add_vrange): New.
46256 2023-04-18  Richard Biener  <rguenther@suse.de>
46258         PR tree-optimization/109539
46259         * gimple-ssa-warn-access.cc (pass_waccess::check_pointer_uses):
46260         Re-implement pointer relatedness for PHIs.
46262 2023-04-18  Andrew Stubbs  <ams@codesourcery.com>
46264         * config/gcn/gcn-valu.md (SV_SFDF): New iterator.
46265         (SV_FP): New iterator.
46266         (scalar_mode, SCALAR_MODE): Add identity mappings for scalar modes.
46267         (recip<mode>2): Unify the two patterns using SV_FP.
46268         (div_scale<mode><exec_vcc>): New insn.
46269         (div_fmas<mode><exec>): New insn.
46270         (div_fixup<mode><exec>): New insn.
46271         (div<mode>3): Unify the two expanders and rewrite using hardfp.
46272         * config/gcn/gcn.cc (gcn_md_reorg): Support "vccwait" attribute.
46273         * config/gcn/gcn.md (unspec): Add UNSPEC_DIV_SCALE, UNSPEC_DIV_FMAS,
46274         and UNSPEC_DIV_FIXUP.
46275         (vccwait): New attribute.
46277 2023-04-18  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
46279         * config/aarch64/aarch64.cc (aarch64_validate_mcpu): Add hint to use -march
46280         if the argument matches that.
46282 2023-04-18  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
46284         * config/aarch64/atomics.md
46285         (*aarch64_atomic_load<ALLX:mode>_rcpc_zext):
46286         Use SD_HSDI for destination mode iterator.
46288 2023-04-18  Jin Ma  <jinma@linux.alibaba.com>
46290         * common/config/riscv/riscv-common.cc (multi_letter_subset_rank): Swap the order
46291         of z-extensions and s-extensions.
46292         (riscv_subset_list::parse): Likewise.
46294 2023-04-18  Jakub Jelinek  <jakub@redhat.com>
46296         PR tree-optimization/109240
46297         * match.pd (fneg/fadd): Rewrite such that it handles both plus as
46298         first vec_perm operand and minus as second using fneg/fadd and
46299         minus as first vec_perm operand and plus as second using fneg/fsub.
46301 2023-04-18  Aldy Hernandez  <aldyh@redhat.com>
46303         * data-streamer.cc (bp_pack_real_value): New.
46304         (bp_unpack_real_value): New.
46305         * data-streamer.h (bp_pack_real_value):  New.
46306         (bp_unpack_real_value): New.
46307         * tree-streamer-in.cc (unpack_ts_real_cst_value_fields): Use
46308         bp_unpack_real_value.
46309         * tree-streamer-out.cc (pack_ts_real_cst_value_fields): Use
46310         bp_pack_real_value.
46312 2023-04-18  Aldy Hernandez  <aldyh@redhat.com>
46314         * wide-int.h (WIDE_INT_MAX_HWIS): New.
46315         (class fixed_wide_int_storage): Use it.
46316         (trailing_wide_ints <N>::set_precision): Use it.
46317         (trailing_wide_ints <N>::extra_size): Use it.
46319 2023-04-18  Xi Ruoyao  <xry111@xry111.site>
46321         * config/loongarch/loongarch-protos.h
46322         (loongarch_addu16i_imm12_operand_p): New function prototype.
46323         (loongarch_split_plus_constant): Likewise.
46324         * config/loongarch/loongarch.cc
46325         (loongarch_addu16i_imm12_operand_p): New function.
46326         (loongarch_split_plus_constant): Likewise.
46327         * config/loongarch/loongarch.h (ADDU16I_OPERAND): New macro.
46328         (DUAL_IMM12_OPERAND): Likewise.
46329         (DUAL_ADDU16I_OPERAND): Likewise.
46330         * config/loongarch/constraints.md (La, Lb, Lc, Ld, Le): New
46331         constraint.
46332         * config/loongarch/predicates.md (const_dual_imm12_operand): New
46333         predicate.
46334         (const_addu16i_operand): Likewise.
46335         (const_addu16i_imm12_di_operand): Likewise.
46336         (const_addu16i_imm12_si_operand): Likewise.
46337         (plus_di_operand): Likewise.
46338         (plus_si_operand): Likewise.
46339         (plus_si_extend_operand): Likewise.
46340         * config/loongarch/loongarch.md (add<mode>3): Convert to
46341         define_insn_and_split.  Use plus_<mode>_operand predicate
46342         instead of arith_operand.  Add alternatives for La, Lb, Lc, Ld,
46343         and Le constraints.
46344         (*addsi3_extended): Convert to define_insn_and_split.  Use
46345         plus_si_extend_operand instead of arith_operand.  Add
46346         alternatives for La and Le alternatives.
46348 2023-04-18  Aldy Hernandez  <aldyh@redhat.com>
46350         * value-range.h (Value_Range::Value_Range): New.
46351         (Value_Range::contains_p): New.
46353 2023-04-18  Aldy Hernandez  <aldyh@redhat.com>
46355         * value-range.h (class vrange): Make m_discriminator const.
46356         (class irange): Make m_max_ranges const.  Adjust constructors
46357         accordingly.
46358         (class unsupported_range): Construct vrange appropriately.
46359         (class frange): Same.
46361 2023-04-18  Lulu Cheng  <chenglulu@loongson.cn>
46363         * config/loongarch/loongarch.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Remove the macro
46364         definition.
46366 2023-04-18  Lulu Cheng  <chenglulu@loongson.cn>
46368         * doc/extend.texi: Add section for LoongArch Base Built-in functions.
46370 2023-04-18  Fei Gao  <gaofei@eswincomputing.com>
46372         * config/riscv/riscv.cc (riscv_first_stack_step): Make codes more
46373         readable.
46374         (riscv_expand_epilogue): Likewise.
46376 2023-04-17  Fei Gao  <gaofei@eswincomputing.com>
46378         * config/riscv/riscv.cc (riscv_expand_prologue): Consider save-restore in
46379         stack allocation.
46380         (riscv_expand_epilogue): Consider save-restore in stack deallocation.
46382 2023-04-17  Andrew Pinski  <apinski@marvell.com>
46384         * tree-ssa-phiopt.cc (gate_hoist_loads): Remove
46385         prototype.
46387 2023-04-17  Aldy Hernandez  <aldyh@redhat.com>
46389         * gimple-ssa-warn-alloca.cc (pass_walloca::execute): Do not export
46390         global ranges.
46392 2023-04-17  Fei Gao  <gaofei@eswincomputing.com>
46394         * config/riscv/riscv.cc (riscv_first_stack_step): Add a new function
46395         parameter remaining_size.
46396         (riscv_compute_frame_info): Adapt new riscv_first_stack_step interface.
46397         (riscv_expand_prologue): Likewise.
46398         (riscv_expand_epilogue): Likewise.
46400 2023-04-17  Feng Wang  <wangfeng@eswincomputing.com>
46402         * config/riscv/bitmanip.md (rotrsi3_sext): Support generating
46403         roriw for constant counts.
46404         * rtl.h (reverse_rotate_by_imm_p): Add function declartion
46405         * simplify-rtx.cc (reverse_rotate_by_imm_p): New function.
46406         (simplify_context::simplify_binary_operation_1): Use it.
46407         * expmed.cc (expand_shift_1): Likewise.
46409 2023-04-17  Martin Jambor  <mjambor@suse.cz>
46411         PR ipa/107769
46412         PR ipa/109318
46413         * cgraph.h (symtab_node::find_reference): Add parameter use_type.
46414         * ipa-prop.h (ipa_pass_through_data): New flag refdesc_decremented.
46415         (ipa_zap_jf_refdesc): New function.
46416         (ipa_get_jf_pass_through_refdesc_decremented): Likewise.
46417         (ipa_set_jf_pass_through_refdesc_decremented): Likewise.
46418         * ipa-cp.cc (ipcp_discover_new_direct_edges): Provide a value for
46419         the new parameter of find_reference.
46420         (adjust_references_in_caller): Likewise. Make sure the constant jump
46421         function is not used to decrement a refdec counter again.  Only
46422         decrement refdesc counters when the pass_through jump function allows
46423         it.  Added a detailed dump when decrementing refdesc counters.
46424         * ipa-prop.cc (ipa_print_node_jump_functions_for_edge): Dump new flag.
46425         (ipa_set_jf_simple_pass_through): Initialize the new flag.
46426         (ipa_set_jf_unary_pass_through): Likewise.
46427         (ipa_set_jf_arith_pass_through): Likewise.
46428         (remove_described_reference): Provide a value for the new parameter of
46429         find_reference.
46430         (update_jump_functions_after_inlining): Zap refdesc of new jfunc if
46431         the previous pass_through had a flag mandating that we do so.
46432         (propagate_controlled_uses): Likewise.  Only decrement refdesc
46433         counters when the pass_through jump function allows it.
46434         (ipa_edge_args_sum_t::duplicate): Provide a value for the new
46435         parameter of find_reference.
46436         (ipa_write_jump_function): Assert the new flag does not have to be
46437         streamed.
46438         * symtab.cc (symtab_node::find_reference): Add parameter use_type, use
46439         it in searching.
46441 2023-04-17  Philipp Tomsich  <philipp.tomsich@vrull.eu>
46442             Di Zhao  <di.zhao@amperecomputing.com>
46444         * config/aarch64/aarch64-tuning-flags.def (AARCH64_EXTRA_TUNING_OPTION):
46445         Add AARCH64_EXTRA_TUNE_NO_LDP_COMBINE.
46446         * config/aarch64/aarch64.cc (aarch64_operands_ok_for_ldpstp):
46447         Check for the above tuning option when processing loads.
46449 2023-04-17  Richard Biener  <rguenther@suse.de>
46451         PR tree-optimization/109524
46452         * tree-vrp.cc (remove_unreachable::m_list): Change to a
46453         vector of pairs of block indices.
46454         (remove_unreachable::maybe_register_block): Adjust.
46455         (remove_unreachable::remove_and_update_globals): Likewise.
46456         Deal with removed blocks.
46458 2023-04-16  Jeff Law  <jlaw@ventanamicro>
46460         PR target/109508
46461         * config/riscv/riscv.cc (riscv_expand_conditional_move): For
46462         TARGET_SFB_ALU, force the true arm into a register.
46464 2023-04-15  John David Anglin  <danglin@gcc.gnu.org>
46466         PR target/104989
46467         * config/pa/pa-protos.h (pa_function_arg_size): Update prototype.
46468         * config/pa/pa.cc (pa_function_arg): Return NULL_RTX if argument
46469         size is zero.
46470         (pa_arg_partial_bytes): Don't call pa_function_arg_size twice.
46471         (pa_function_arg_size): Change return type to int.  Return zero
46472         for arguments larger than 1 GB.  Update comments.
46474 2023-04-15  Jakub Jelinek  <jakub@redhat.com>
46476         PR tree-optimization/109154
46477         * tree-if-conv.cc (predicate_scalar_phi): For complex PHIs, emit just
46478         args_len - 1 COND_EXPRs rather than args_len.  Formatting fix.
46480 2023-04-15  Jason Merrill  <jason@redhat.com>
46482         PR c++/109514
46483         * gimple-ssa-warn-access.cc (pass_waccess::check_dangling_stores):
46484         Overhaul lhs_ref.ref analysis.
46486 2023-04-14  Richard Biener  <rguenther@suse.de>
46488         PR tree-optimization/109502
46489         * tree-vect-stmts.cc (vectorizable_assignment): Fix
46490         check for conversion between mask and non-mask types.
46492 2023-04-14  Jeff Law  <jlaw@ventanamicro.com>
46493             Jakub Jelinek  <jakub@redhat.com>
46495         PR target/108947
46496         PR target/109040
46497         * combine.cc (simplify_and_const_int_1): Compute nonzero_bits in
46498         word_mode rather than mode if WORD_REGISTER_OPERATIONS and mode is
46499         smaller than word_mode.
46500         * simplify-rtx.cc (simplify_context::simplify_binary_operation_1)
46501         <case AND>: Likewise.
46503 2023-04-14  Jakub Jelinek  <jakub@redhat.com>
46505         * loop-iv.cc (iv_number_of_iterations): Use gen_int_mode instead
46506         of GEN_INT.
46508 2023-04-13  Andrew MacLeod  <amacleod@redhat.com>
46510         PR tree-optimization/108139
46511         PR tree-optimization/109462
46512         * gimple-range-cache.cc (ranger_cache::fill_block_cache): Remove
46513         equivalency check for PHI nodes.
46514         * gimple-range-fold.cc (fold_using_range::range_of_phi): Ensure def
46515         does not dominate single-arg equivalency edges.
46517 2023-04-13  Richard Sandiford  <richard.sandiford@arm.com>
46519         PR target/108910
46520         * config/aarch64/aarch64.cc (aarch64_function_arg_alignment): Do
46521         not trust TYPE_ALIGN for pointer types; use POINTER_SIZE instead.
46523 2023-04-13  Richard Biener  <rguenther@suse.de>
46525         PR tree-optimization/109491
46526         * tree-ssa-sccvn.cc (expressions_equal_p): Restore the
46527         NULL operands test.
46529 2023-04-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
46531         PR target/109479
46532         * config/riscv/riscv-vector-builtins-types.def (vint8mf8_t): Fix predicate.
46533         (vint16mf4_t): Ditto.
46534         (vint32mf2_t): Ditto.
46535         (vint64m1_t): Ditto.
46536         (vint64m2_t): Ditto.
46537         (vint64m4_t): Ditto.
46538         (vint64m8_t): Ditto.
46539         (vuint8mf8_t): Ditto.
46540         (vuint16mf4_t): Ditto.
46541         (vuint32mf2_t): Ditto.
46542         (vuint64m1_t): Ditto.
46543         (vuint64m2_t): Ditto.
46544         (vuint64m4_t): Ditto.
46545         (vuint64m8_t): Ditto.
46546         (vfloat32mf2_t): Ditto.
46547         (vbool64_t): Ditto.
46548         * config/riscv/riscv-vector-builtins.cc (register_builtin_type): Add comments.
46549         (register_vector_type): Ditto.
46550         (check_required_extensions): Fix condition.
46551         * config/riscv/riscv-vector-builtins.h (RVV_REQUIRE_ZVE64): Remove it.
46552         (RVV_REQUIRE_ELEN_64): New define.
46553         (RVV_REQUIRE_MIN_VLEN_64): Ditto.
46554         * config/riscv/riscv-vector-switch.def (TARGET_VECTOR_FP32): Remove it.
46555         (TARGET_VECTOR_FP64): Ditto.
46556         (ENTRY): Fix predicate.
46557         * config/riscv/vector-iterators.md: Fix predicate.
46559 2023-04-12  Jakub Jelinek  <jakub@redhat.com>
46561         PR tree-optimization/109410
46562         * tree-ssa-reassoc.cc (build_and_add_sum): Split edge from entry
46563         block if first statement of the function is a call to returns_twice
46564         function.
46566 2023-04-12  Jakub Jelinek  <jakub@redhat.com>
46568         PR target/109458
46569         * config/i386/i386.cc: Include rtl-error.h.
46570         (ix86_print_operand): For z modifier warning, use warning_for_asm
46571         if this_is_asm_operands.  For Z modifier errors, use %c and code
46572         instead of hardcoded Z.
46574 2023-04-12  Costas Argyris  <costas.argyris@gmail.com>
46576         * config/i386/x-mingw32-utf8: Remove extrataneous $@
46578 2023-04-12  Andrew MacLeod  <amacleod@redhat.com>
46580         PR tree-optimization/109462
46581         * gimple-range-cache.cc (ranger_cache::fill_block_cache): Don't
46582         check for equivalences if NAME is a phi node.
46584 2023-04-12  Richard Biener  <rguenther@suse.de>
46586         PR tree-optimization/109473
46587         * tree-vect-loop.cc (vect_create_epilog_for_reduction):
46588         Convert scalar result to the computation type before performing
46589         the reduction adjustment.
46591 2023-04-12  Richard Biener  <rguenther@suse.de>
46593         PR tree-optimization/109469
46594         * tree-vect-slp.cc (vect_slp_function): Skip region starts with
46595         a returns-twice call.
46597 2023-04-12  Richard Biener  <rguenther@suse.de>
46599         PR tree-optimization/109434
46600         * tree-ssa-dse.cc (initialize_ao_ref_for_dse): Properly
46601         handle possibly throwing calls when processing the LHS
46602         and may-defs are not OK.
46604 2023-04-11  Lin Sinan  <mynameisxiaou@gmail.com>
46606         * config/riscv/predicates.md (uimm_extra_bit_or_twobits): Adjust
46607         predicate to avoid splitting arith constants.
46609 2023-04-11  Yanzhang Wang  <yanzhang.wang@intel.com>
46610             Pan Li  <pan2.li@intel.com>
46611             Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
46612             Kito Cheng  <kito.cheng@sifive.com>
46614         PR target/109104
46615         * config/riscv/riscv-protos.h (emit_hard_vlmax_vsetvl): New.
46616         * config/riscv/riscv-v.cc (emit_hard_vlmax_vsetvl): New.
46617         (emit_vlmax_vsetvl): Use emit_hard_vlmax_vsetvl.
46618         * config/riscv/riscv.cc (vector_zero_call_used_regs): New.
46619         (riscv_zero_call_used_regs): New.
46620         (TARGET_ZERO_CALL_USED_REGS): New.
46622 2023-04-11  Martin Liska  <mliska@suse.cz>
46624         PR driver/108241
46625         * opts.cc (finish_options): Drop also
46626         x_flag_var_tracking_assignments.
46628 2023-04-11  Andre Vieira  <andre.simoesdiasvieira@arm.com>
46630         PR tree-optimization/108888
46631         * tree-if-conv.cc (predicate_statements): Fix gimple call check.
46633 2023-04-11  Haochen Gui  <guihaoc@gcc.gnu.org>
46635         PR target/108812
46636         * config/rs6000/vsx.md (vsx_sign_extend_qi_<mode>): Rename to...
46637         (vsx_sign_extend_v16qi_<mode>): ... this.
46638         (vsx_sign_extend_hi_<mode>): Rename to...
46639         (vsx_sign_extend_v8hi_<mode>): ... this.
46640         (vsx_sign_extend_si_v2di): Rename to...
46641         (vsx_sign_extend_v4si_v2di): ... this.
46642         (vsignextend_qi_<mode>): Remove.
46643         (vsignextend_hi_<mode>): Remove.
46644         (vsignextend_si_v2di): Remove.
46645         (vsignextend_v2di_v1ti): Remove.
46646         (*xxspltib_<mode>_split): Replace gen_vsx_sign_extend_qi_v2di with
46647         gen_vsx_sign_extend_v16qi_v2di and gen_vsx_sign_extend_qi_v4si
46648         with gen_vsx_sign_extend_v16qi_v4si.
46649         * config/rs6000/rs6000.md (split for DI constant generation):
46650         Replace gen_vsx_sign_extend_qi_si with gen_vsx_sign_extend_v16qi_si.
46651         (split for HSDI constant generation): Replace gen_vsx_sign_extend_qi_di
46652         with gen_vsx_sign_extend_v16qi_di and gen_vsx_sign_extend_qi_si
46653         with gen_vsx_sign_extend_v16qi_si.
46654         * config/rs6000/rs6000-builtins.def (__builtin_altivec_vsignextsb2d):
46655         Set bif-pattern to vsx_sign_extend_v16qi_v2di.
46656         (__builtin_altivec_vsignextsb2w): Set bif-pattern to
46657         vsx_sign_extend_v16qi_v4si.
46658         (__builtin_altivec_visgnextsh2d): Set bif-pattern to
46659         vsx_sign_extend_v8hi_v2di.
46660         (__builtin_altivec_vsignextsh2w): Set bif-pattern to
46661         vsx_sign_extend_v8hi_v4si.
46662         (__builtin_altivec_vsignextsw2d): Set bif-pattern to
46663         vsx_sign_extend_si_v2di.
46664         (__builtin_altivec_vsignext): Set bif-pattern to
46665         vsx_sign_extend_v2di_v1ti.
46666         * config/rs6000/rs6000-builtin.cc (lxvrse_expand_builtin): Replace
46667         gen_vsx_sign_extend_qi_v2di with gen_vsx_sign_extend_v16qi_v2di,
46668         gen_vsx_sign_extend_hi_v2di with gen_vsx_sign_extend_v8hi_v2di and
46669         gen_vsx_sign_extend_si_v2di with gen_vsx_sign_extend_v4si_v2di.
46671 2023-04-10   Michael Meissner  <meissner@linux.ibm.com>
46673         PR target/70243
46674         * config/rs6000/vsx.md (vsx_fmav4sf4): Do not generate vmaddfp.
46675         (vsx_nfmsv4sf4): Do not generate vnmsubfp.
46677 2023-04-10  Haochen Jiang  <haochen.jiang@intel.com>
46679         * config/i386/i386.h (PTA_GRANITERAPIDS): Add PTA_AMX_COMPLEX.
46681 2023-04-10  Haochen Jiang  <haochen.jiang@intel.com>
46683         * common/config/i386/cpuinfo.h (get_available_features):
46684         Detect AMX-COMPLEX.
46685         * common/config/i386/i386-common.cc
46686         (OPTION_MASK_ISA2_AMX_COMPLEX_SET,
46687         OPTION_MASK_ISA2_AMX_COMPLEX_UNSET): New.
46688         (ix86_handle_option): Handle -mamx-complex.
46689         * common/config/i386/i386-cpuinfo.h (enum processor_features):
46690         Add FEATURE_AMX_COMPLEX.
46691         * common/config/i386/i386-isas.h: Add ISA_NAME_TABLE_ENTRY for
46692         amx-complex.
46693         * config.gcc: Add amxcomplexintrin.h.
46694         * config/i386/cpuid.h (bit_AMX_COMPLEX): New.
46695         * config/i386/i386-c.cc (ix86_target_macros_internal): Define
46696         __AMX_COMPLEX__.
46697         * config/i386/i386-isa.def (AMX_COMPLEX): Add DEF_PTA(AMX_COMPLEX).
46698         * config/i386/i386-options.cc (ix86_valid_target_attribute_inner_p):
46699         Handle amx-complex.
46700         * config/i386/i386.opt: Add option -mamx-complex.
46701         * config/i386/immintrin.h: Include amxcomplexintrin.h.
46702         * doc/extend.texi: Document amx-complex.
46703         * doc/invoke.texi: Document -mamx-complex.
46704         * doc/sourcebuild.texi: Document target amx-complex.
46705         * config/i386/amxcomplexintrin.h: New file.
46707 2023-04-08  Jakub Jelinek  <jakub@redhat.com>
46709         PR tree-optimization/109392
46710         * tree-vect-generic.cc (tree_vec_extract): Handle failure
46711         of maybe_push_res_to_seq better.
46713 2023-04-08  Jakub Jelinek  <jakub@redhat.com>
46715         * Makefile.in (CORETYPES_H): Depend on align.h, poly-int.h and
46716         poly-int-types.h.
46717         (SYSTEM_H): Depend on $(HASHTAB_H).
46718         * config/riscv/t-riscv (build/genrvv-type-indexer.o): Remove unused
46719         dependency on $(RTL_BASE_H), remove redundant dependency on
46720         insn-modes.h.
46722 2023-04-06  Richard Earnshaw  <rearnsha@arm.com>
46724         PR target/107674
46725         * config/arm/arm.cc (arm_effective_regno): New function.
46726         (mve_vector_mem_operand): Use it.
46728 2023-04-06  Andrew MacLeod  <amacleod@redhat.com>
46730         PR tree-optimization/109417
46731         * gimple-range-gori.cc (gori_compute::may_recompute_p): Check if
46732         dependency is in SSA_NAME_FREE_LIST.
46734 2023-04-06  Andrew Pinski  <apinski@marvell.com>
46736         PR tree-optimization/109427
46737         * params.opt (-param=vect-induction-float=):
46738         Fix option attribute typo for IntegerRange.
46740 2023-04-05  Jeff Law  <jlaw@ventanamicro>
46742         PR target/108892
46743         * combine.cc (combine_instructions): Force re-recognition when
46744         after restoring the body of an insn to its original form.
46746 2023-04-05  Martin Jambor  <mjambor@suse.cz>
46748         PR ipa/108959
46749         * ipa-sra.cc (zap_useless_ipcp_results): New function.
46750         (process_isra_node_results): Call it.
46752 2023-04-05  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
46754         * config/riscv/vector.md: Fix incorrect operand order.
46756 2023-04-05  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
46758         * config/riscv/riscv-vsetvl.cc
46759         (pass_vsetvl::compute_local_backward_infos): Update user vsetvl in local
46760         demand fusion.
46762 2023-04-05  Li Xu  <xuli1@eswincomputing.com>
46764         * config/riscv/riscv-vector-builtins.def: Fix typo.
46765         * config/riscv/riscv.cc (riscv_dwarf_poly_indeterminate_value): Ditto.
46766         * config/riscv/vector-iterators.md: Ditto.
46768 2023-04-04  Hans-Peter Nilsson  <hp@axis.com>
46770         * doc/md.texi (Including Patterns): Fix page break.
46772 2023-04-04  Jakub Jelinek  <jakub@redhat.com>
46774         PR tree-optimization/109386
46775         * range-op-float.cc (foperator_lt::op1_range, foperator_lt::op2_range,
46776         foperator_le::op1_range, foperator_le::op2_range,
46777         foperator_gt::op1_range, foperator_gt::op2_range,
46778         foperator_ge::op1_range, foperator_ge::op2_range): Make r varying for
46779         BRS_FALSE case even if the other op is maybe_isnan, not just
46780         known_isnan.
46781         (foperator_unordered_lt::op1_range, foperator_unordered_lt::op2_range,
46782         foperator_unordered_le::op1_range, foperator_unordered_le::op2_range,
46783         foperator_unordered_gt::op1_range, foperator_unordered_gt::op2_range,
46784         foperator_unordered_ge::op1_range, foperator_unordered_ge::op2_range):
46785         Make r varying for BRS_TRUE case even if the other op is maybe_isnan,
46786         not just known_isnan.
46788 2023-04-04  Marek Polacek  <polacek@redhat.com>
46790         PR sanitizer/109107
46791         * fold-const.cc (fold_binary_loc): Use TYPE_OVERFLOW_SANITIZED
46792         when associating.
46793         * match.pd: Use TYPE_OVERFLOW_SANITIZED.
46795 2023-04-04  Stam Markianos-Wright  <stam.markianos-wright@arm.com>
46797         * config/arm/mve.md (mve_vcvtq_n_to_f_<supf><mode>): Swap operands.
46798         (mve_vcreateq_f<mode>): Swap operands.
46800 2023-04-04  Andrew Stubbs  <ams@codesourcery.com>
46802         * config/gcn/gcn-valu.md (one_cmpl<mode>2<exec>): New.
46804 2023-04-04  Jakub Jelinek  <jakub@redhat.com>
46806         PR target/109384
46807         * common/config/riscv/riscv-common.cc (riscv_subset_list::parse):
46808         Reword diagnostics about zfinx conflict with f, formatting fixes.
46810 2023-04-04  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
46812         * config/sol2.h (LIB_SPEC): Don't link with -lpthread.
46814 2023-04-04  Richard Biener  <rguenther@suse.de>
46816         PR tree-optimization/109304
46817         * tree-profile.cc (tree_profiling): Use symtab node
46818         availability to decide whether to skip adjusting calls.
46819         Do not adjust calls to internal functions.
46821 2023-04-04  Kewen Lin  <linkw@linux.ibm.com>
46823         PR target/108807
46824         * config/rs6000/rs6000.cc (rs6000_expand_vector_set_var_p9): Fix gen
46825         function for permutation control vector by considering big endianness.
46827 2023-04-04  Kewen Lin  <linkw@linux.ibm.com>
46829         PR target/108699
46830         * config/rs6000/altivec.md (*p9v_parity<mode>2): Rename to ...
46831         (rs6000_vprtyb<mode>2): ... this.
46832         * config/rs6000/rs6000-builtins.def (VPRTYBD): Replace parityv2di2 with
46833         rs6000_vprtybv2di2.
46834         (VPRTYBW): Replace parityv4si2 with rs6000_vprtybv4si2.
46835         (VPRTYBQ): Replace parityv1ti2 with rs6000_vprtybv1ti2.
46836         * config/rs6000/vector.md (parity<mode>2 with VEC_IP): Expand with
46837         popcountv16qi2 and the corresponding rs6000_vprtyb<mode>2.
46839 2023-04-04  Hans-Peter Nilsson  <hp@axis.com>
46840             Sandra Loosemore  <sandra@codesourcery.com>
46842         * doc/md.texi (Insn Splitting): Tweak wording for readability.
46844 2023-04-03  Martin Jambor  <mjambor@suse.cz>
46846         PR ipa/109303
46847         * ipa-prop.cc (determine_known_aggregate_parts): Check that the
46848         offset + size will be representable in unsigned int.
46850 2023-04-03  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
46852         * configure.ac (ZSTD_LIB): Move before zstd.h check.
46853         Unset gcc_cv_header_zstd_h without libzstd.
46854         * configure: Regenerate.
46856 2023-04-03  Martin Liska  <mliska@suse.cz>
46858         * doc/invoke.texi: Document new param.
46860 2023-04-03  Cupertino Miranda  <cupertino.miranda@oracle.com>
46862         * doc/sourcebuild.texi (const_volatile_readonly_section): Document
46863         new check_effective_target function.
46865 2023-04-03  Li Xu  <xuli1@eswincomputing.com>
46867         * config/riscv/riscv-vector-builtins.def (vuint32m8_t): Fix typo.
46868         (vfloat32m8_t): Likewise
46870 2023-04-03  liuhongt  <hongtao.liu@intel.com>
46872         * doc/md.texi: Document signbitm2.
46874 2023-04-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
46875             kito-cheng  <kito.cheng@sifive.com>
46877         * config/riscv/vector.md: Fix RA constraint.
46879 2023-04-02  Juzhe-Zhong  <juzhe.zhong@rivai.ai>
46881         * config/riscv/riscv-protos.h (gen_avl_for_scalar_move): New function.
46882         * config/riscv/riscv-v.cc (gen_avl_for_scalar_move): New function.
46883         * config/riscv/vector.md: Fix scalar move bug.
46885 2023-04-01  Jakub Jelinek  <jakub@redhat.com>
46887         * range-op-float.cc (foperator_equal::fold_range): If at least
46888         one of the op ranges is not singleton and neither is NaN and all
46889         4 bounds are zero, return [1, 1].
46890         (foperator_not_equal::fold_range): In the same case return [0, 0].
46892 2023-04-01  Jakub Jelinek  <jakub@redhat.com>
46894         * range-op-float.cc (foperator_equal::fold_range): Perform the
46895         non-singleton handling regardless of maybe_isnan (op1, op2).
46896         (foperator_not_equal::fold_range): Likewise.
46897         (foperator_lt::fold_range, foperator_le::fold_range,
46898         foperator_gt::fold_range, foperator_ge::fold_range): Perform the
46899         real_* comparison check which results in range_false (type)
46900         even if maybe_isnan (op1, op2).  Simplify.
46901         (foperator_ltgt): New class.
46902         (fop_ltgt): New variable.
46903         (floating_op_table::floating_op_table): Handle LTGT_EXPR using
46904         fop_ltgt.
46906 2023-04-01  Jakub Jelinek  <jakub@redhat.com>
46908         PR target/109254
46909         * builtins.cc (apply_args_size): If targetm.calls.get_raw_arg_mode
46910         returns VOIDmode, handle it like if the register isn't used for
46911         passing arguments at all.
46912         (apply_result_size): If targetm.calls.get_raw_result_mode returns
46913         VOIDmode, handle it like if the register isn't used for returning
46914         results at all.
46915         * target.def (get_raw_result_mode, get_raw_arg_mode): Document what it
46916         means to return VOIDmode.
46917         * doc/tm.texi: Regenerated.
46918         * config/aarch64/aarch64.cc (aarch64_function_value_regno_p): Return
46919         TARGET_SVE for P0_REGNUM.
46920         (aarch64_function_arg_regno_p): Also return true for p0-p3.
46921         (aarch64_get_reg_raw_mode): Return VOIDmode for PR_REGNUM_P regs.
46923 2023-03-31  Vladimir N. Makarov  <vmakarov@redhat.com>
46925         * lra-constraints.cc: (combine_reload_insn): New function.
46927 2023-03-31  Jakub Jelinek  <jakub@redhat.com>
46929         PR tree-optimization/91645
46930         * range-op-float.cc (foperator_unordered_lt::fold_range,
46931         foperator_unordered_le::fold_range,
46932         foperator_unordered_gt::fold_range,
46933         foperator_unordered_ge::fold_range,
46934         foperator_unordered_equal::fold_range): Call the ordered
46935         fold_range on ranges with cleared NaNs.
46936         * value-query.cc (range_query::get_tree_range): Handle also
46937         COMPARISON_CLASS_P trees.
46939 2023-03-31  Kito Cheng  <kito.cheng@sifive.com>
46940             Andrew Pinski  <pinskia@gmail.com>
46942         PR target/109328
46943         * config/riscv/t-riscv: Add missing dependencies.
46945 2023-03-31  liuhongt  <hongtao.liu@intel.com>
46947         * config/i386/i386.cc (inline_memory_move_cost): Return 100
46948         for MASK_REGS when MODE_SIZE > 8.
46950 2023-03-31  liuhongt  <hongtao.liu@intel.com>
46952         PR target/85048
46953         * config/i386/i386-builtin.def (BDESC): Adjust icode name from
46954         ufloat/ufix to floatuns/fixuns.
46955         * config/i386/i386-expand.cc
46956         (ix86_expand_vector_convert_uns_vsivsf): Adjust comments.
46957         * config/i386/sse.md
46958         (ufloat<sseintvecmodelower><mode>2<mask_name><round_name>):
46959         Renamed to ..
46960         (<mask_codefor>floatuns<sseintvecmodelower><mode>2<mask_name><round_name>):.. this.
46961         (<mask_codefor><avx512>_ufix_notrunc<sf2simodelower><mode><mask_name><round_name>):
46962         Renamed to ..
46963         (<mask_codefor><avx512>_fixuns_notrunc<sf2simodelower><mode><mask_name><round_name>):
46964         .. this.
46965         (<fixsuffix>fix_truncv16sfv16si2<mask_name><round_saeonly_name>):
46966         Renamed to ..
46967         (fix<fixunssuffix>_truncv16sfv16si2<mask_name><round_saeonly_name>):.. this.
46968         (ufloat<si2dfmodelower><mode>2<mask_name>): Renamed to ..
46969         (floatuns<si2dfmodelower><mode>2<mask_name>): .. this.
46970         (ufloatv2siv2df2<mask_name>): Renamed to ..
46971         (<mask_codefor>floatunsv2siv2df2<mask_name>): .. this.
46972         (ufix_notrunc<mode><si2dfmodelower>2<mask_name><round_name>):
46973         Renamed to ..
46974         (fixuns_notrunc<mode><si2dfmodelower>2<mask_name><round_name>):
46975         .. this.
46976         (ufix_notruncv2dfv2si2): Renamed to ..
46977         (fixuns_notruncv2dfv2si2):.. this.
46978         (ufix_notruncv2dfv2si2_mask): Renamed to ..
46979         (fixuns_notruncv2dfv2si2_mask): .. this.
46980         (*ufix_notruncv2dfv2si2_mask_1): Renamed to ..
46981         (*fixuns_notruncv2dfv2si2_mask_1): .. this.
46982         (ufix_truncv2dfv2si2): Renamed to ..
46983         (*fixuns_truncv2dfv2si2): .. this.
46984         (ufix_truncv2dfv2si2_mask): Renamed to ..
46985         (fixuns_truncv2dfv2si2_mask): .. this.
46986         (*ufix_truncv2dfv2si2_mask_1): Renamed to ..
46987         (*fixuns_truncv2dfv2si2_mask_1): .. this.
46988         (ufix_truncv4dfv4si2<mask_name>): Renamed to ..
46989         (fixuns_truncv4dfv4si2<mask_name>): .. this.
46990         (ufix_notrunc<mode><sseintvecmodelower>2<mask_name><round_name>):
46991         Renamed to ..
46992         (fixuns_notrunc<mode><sseintvecmodelower>2<mask_name><round_name>):
46993         .. this.
46994         (ufix_trunc<mode><sseintvecmodelower>2<mask_name>): Renamed to ..
46995         (<mask_codefor>fixuns_trunc<mode><sseintvecmodelower>2<mask_name>):
46996         .. this.
46998 2023-03-30  Andrew MacLeod  <amacleod@redhat.com>
47000         PR tree-optimization/109154
47001         * gimple-range-gori.cc (gori_compute::may_recompute_p): Add depth limit.
47002         * gimple-range-gori.h (may_recompute_p): Add depth param.
47003         * params.opt (ranger-recompute-depth): New param.
47005 2023-03-30  Jason Merrill  <jason@redhat.com>
47007         PR c++/107897
47008         PR c++/108887
47009         * cgraph.h: Move reset() from cgraph_node to symtab_node.
47010         * cgraphunit.cc (symtab_node::reset): Adjust.  Also call
47011         remove_from_same_comdat_group.
47013 2023-03-30  Richard Biener  <rguenther@suse.de>
47015         PR tree-optimization/107561
47016         * gimple-ssa-warn-access.cc (get_size_range): Add flags
47017         argument and pass it on.
47018         (check_access): When querying for the size range pass
47019         SR_ALLOW_ZERO when the known destination size is zero.
47021 2023-03-30  Richard Biener  <rguenther@suse.de>
47023         PR tree-optimization/109342
47024         * tree-ssa-sccvn.cc (vn_nary_op_get_predicated_value): New
47025         overload for edge.  When that edge is a backedge use
47026         dominated_by_p directly.
47028 2023-03-30  liuhongt  <hongtao.liu@intel.com>
47030         * config/i386/i386-expand.cc (expand_vec_perm_blend): Generate
47031         vpblendd instead of vpblendw for V4SI under avx2.
47033 2023-03-29  Hans-Peter Nilsson  <hp@axis.com>
47035         * config/cris/cris.cc (cris_rtx_costs) [CONST_INT]: Return 0
47036         for many quick operands, for register-sized modes.
47038 2023-03-29  Jiawei  <jiawei@iscas.ac.cn>
47040         * common/config/riscv/riscv-common.cc (riscv_subset_list::parse):
47041         New check.
47043 2023-03-29  Martin Liska  <mliska@suse.cz>
47045         PR bootstrap/109310
47046         * configure.ac: Emit a warning for deprecated option
47047         --enable-link-mutex.
47048         * configure: Regenerate.
47050 2023-03-29  Richard Biener  <rguenther@suse.de>
47052         PR tree-optimization/109331
47053         * tree-ssa-forwprop.cc (pass_forwprop::execute): When we
47054         discover a taken edge make sure to cleanup the CFG.
47056 2023-03-29  Richard Biener  <rguenther@suse.de>
47058         PR tree-optimization/109327
47059         * tree-ssa-forwprop.cc (pass_forwprop::execute): Deal with
47060         already removed stmts when draining to_remove.
47062 2023-03-29  Richard Biener  <rguenther@suse.de>
47064         PR ipa/106124
47065         * dwarf2out.cc (lookup_type_die): Reset TREE_ASM_WRITTEN
47066         so we can re-create the DIE for the type if required.
47068 2023-03-29  Jakub Jelinek  <jakub@redhat.com>
47069             Richard Biener  <rguenther@suse.de>
47071         PR tree-optimization/109301
47072         * tree-ssa-math-opts.cc (pass_data_cse_sincos): Change
47073         properties_provided from PROP_gimple_opt_math to 0.
47074         (pass_data_expand_powcabs): Change properties_provided from 0 to
47075         PROP_gimple_opt_math.
47077 2023-03-29  Richard Biener  <rguenther@suse.de>
47079         PR tree-optimization/109154
47080         * tree-if-conv.cc (gen_phi_arg_condition): Handle single
47081         inverted condition specially by inverting at the caller.
47082         (gen_phi_arg_condition): Swap COND_EXPR arms if requested.
47084 2023-03-28  David Malcolm  <dmalcolm@redhat.com>
47086         PR c/107002
47087         * diagnostic-show-locus.cc (column_range::column_range): Factor
47088         out assertion conditional into...
47089         (column_range::valid_p): ...this new function.
47090         (line_corrections::add_hint): Don't attempt to consolidate hints
47091         if it would lead to invalid column_range instances.
47093 2023-03-28  Kito Cheng  <kito.cheng@sifive.com>
47095         PR target/109312
47096         * config/riscv/riscv-c.cc (riscv_ext_version_value): New.
47097         (riscv_cpu_cpp_builtins): Define __riscv_v_intrinsic and
47098         minor refactor.
47100 2023-03-28  Alexander Monakov  <amonakov@ispras.ru>
47102         PR rtl-optimization/109187
47103         * haifa-sched.cc (autopref_rank_for_schedule): Avoid use of overflowing
47104         subtraction in three-way comparison.
47106 2023-03-28  Andrew MacLeod  <amacleod@redhat.com>
47108         PR tree-optimization/109265
47109         PR tree-optimization/109274
47110         * gimple-range-gori.cc (gori_compute::compute_operand_range): Do
47111         not create a relation record is op1 and op2 are the same symbol.
47112         (gori_compute::compute_operand1_range): Pass op1 == op2 to the
47113         handler for this stmt, but create a new record only if this statement
47114         generates a relation based on the ranges.
47115         (gori_compute::compute_operand2_range): Ditto.
47116         * value-relation.h (value_relation::set_relation): Always create the
47117         record that is requested.
47119 2023-03-28  Richard Biener  <rguenther@suse.de>
47121         PR tree-optimization/107087
47122         * tree-ssa-forwprop.cc (pass_forwprop::execute): Track
47123         executable regions to avoid useless work and to better
47124         propagate degenerate PHIs.
47126 2023-03-28  Costas Argyris  <costas.argyris@gmail.com>
47128         * config/i386/x-mingw32-utf8: update comments.
47130 2023-03-28  Richard Sandiford  <richard.sandiford@arm.com>
47132         PR target/109072
47133         * config/aarch64/aarch64-protos.h (aarch64_vector_load_decl): Declare.
47134         * config/aarch64/aarch64.h (machine_function::vector_load_decls): New
47135         variable.
47136         * config/aarch64/aarch64-builtins.cc (aarch64_record_vector_load_arg):
47137         New function.
47138         (aarch64_general_gimple_fold_builtin): Delay folding of vld1 until
47139         after inlining.  Record which decls are loaded from.  Fix handling
47140         of vops for loads and stores.
47141         * config/aarch64/aarch64.cc (aarch64_vector_load_decl): New function.
47142         (aarch64_accesses_vector_load_decl_p): Likewise.
47143         (aarch64_vector_costs::m_stores_to_vector_load_decl): New member
47144         variable.
47145         (aarch64_vector_costs::add_stmt_cost): If the function has a vld1
47146         that loads from a decl, treat vector stores to those decls as
47147         zero cost.
47148         (aarch64_vector_costs::finish_cost): ...and in that case,
47149         if the vector code does nothing more than a store, give the
47150         prologue a zero cost as well.
47152 2023-03-28  Richard Biener  <rguenther@suse.de>
47154         PR bootstrap/84402
47155         PR tree-optimization/108129
47156         * genmatch.cc (lower_for): For (match ...) delay
47157         substituting into the match operator if possible.
47158         (dt_operand::gen_gimple_expr): For user_id look at the
47159         first substitute for determining how to access operands.
47160         (dt_operand::gen_generic_expr): Likewise.
47161         (dt_node::gen_kids): Properly sort user_ids according
47162         to their substitutes.
47163         (dt_node::gen_kids_1): Code-generate user_id matching.
47165 2023-03-28  Jakub Jelinek  <jakub@redhat.com>
47166             Jonathan Wakely  <jwakely@redhat.com>
47168         * gcov-tool.cc (do_merge, do_merge_stream, do_rewrite, do_overlap):
47169         Use subcommand rather than sub-command in function comments.
47171 2023-03-28  Jakub Jelinek  <jakub@redhat.com>
47173         PR tree-optimization/109154
47174         * value-range.h (frange::flush_denormals_to_zero): Make it public
47175         rather than private.
47176         * value-range.cc (frange::set): Don't call flush_denormals_to_zero
47177         here.
47178         * range-op-float.cc (range_operator_float::fold_range): Call
47179         flush_denormals_to_zero.
47181 2023-03-28  Jakub Jelinek  <jakub@redhat.com>
47183         PR middle-end/106190
47184         * sanopt.cc (pass_sanopt::execute): Return TODO_cleanup_cfg if any
47185         of the IFN_{UB,HWA,A}SAN_* internal fns are lowered.
47187 2023-03-28  Jakub Jelinek  <jakub@redhat.com>
47189         * range-op-float.cc (float_widen_lhs_range): Use pass get_nan_state
47190         as 4th argument to set to avoid clear_nan and union_ calls.
47192 2023-03-28  Jakub Jelinek  <jakub@redhat.com>
47194         PR target/109276
47195         * config/i386/i386.cc (assign_386_stack_local): For DImode
47196         with SLOT_FLOATxFDI_387 and -m32 -mpreferred-stack-boundary=2 pass
47197         align 32 rather than 0 to assign_stack_local.
47199 2023-03-28  Eric Botcazou  <ebotcazou@adacore.com>
47201         PR target/109140
47202         * config/sparc/sparc.cc (sparc_expand_vcond): Call signed_condition
47203         on operand #3 to get the final condition code.  Use std::swap.
47204         * config/sparc/sparc.md (vcondv8qiv8qi): New VIS 4 expander.
47205         (fucmp<gcond:code>8<P:mode>_vis): Move around.
47206         (fpcmpu<gcond:code><GCM:gcm_name><P:mode>_vis): Likewise.
47207         (vcondu<GCM:mode><GCM:mode>): New VIS 4 expander.
47209 2023-03-28  Eric Botcazou  <ebotcazou@adacore.com>
47211         * doc/gm2.texi: Add missing Next, Previous and Top fields to most
47212         top-level sections.
47214 2023-03-28  Costas Argyris  <costas.argyris@gmail.com>
47216         * config.host: Pull in i386/x-mingw32-utf8 Makefile
47217         fragment and reference utf8rc-mingw32.o explicitly
47218         for mingw hosts.
47219         * config/i386/sym-mingw32.cc: prevent name mangling of
47220         stub symbol.
47221         * config/i386/x-mingw32-utf8: Make utf8rc-mingw32.o
47222         depend on manifest file explicitly.
47224 2023-03-28  Richard Biener  <rguenther@suse.de>
47226         Revert:
47227         2023-03-27  Richard Biener  <rguenther@suse.de>
47229         PR rtl-optimization/109237
47230         * cfgcleanup.cc (bb_is_just_return): Walk insns backwards.
47232 2023-03-28  Richard Biener  <rguenther@suse.de>
47234         * common.opt (gdwarf): Remove Negative(gdwarf-).
47236 2023-03-28  Richard Biener  <rguenther@suse.de>
47238         * common.opt (gdwarf): Add RejectNegative.
47239         (gdwarf-): Likewise.
47240         (ggdb): Likewise.
47241         (gvms): Likewise.
47243 2023-03-28  Hans-Peter Nilsson  <hp@axis.com>
47245         * config/cris/constraints.md ("T"): Correct to
47246         define_memory_constraint.
47248 2023-03-28  Hans-Peter Nilsson  <hp@axis.com>
47250         * config/cris/cris.md (BW2): New mode-iterator.
47251         (lra_szext_decomposed, lra_szext_decomposed_indirect_with_offset): New
47252         peephole2s.
47254 2023-03-28  Hans-Peter Nilsson  <hp@axis.com>
47256         * config/cris/cris.md ("*add<mode>3_addi"): Improve to bail only
47257         for possible eliminable compares.
47259 2023-03-28  Hans-Peter Nilsson  <hp@axis.com>
47261         * config/cris/constraints.md ("R"): Remove unused constraint.
47263 2023-03-27  Jonathan Wakely  <jwakely@redhat.com>
47265         PR gcov-profile/109297
47266         * gcov-tool.cc (merge_usage): Fix "subcomand" typo.
47267         (merge_stream_usage): Likewise.
47268         (overlap_usage): Likewise.
47270 2023-03-27  Christoph Müllner  <christoph.muellner@vrull.eu>
47272         PR target/109296
47273         * config/riscv/thead.md: Add missing mode specifiers.
47275 2023-03-27  Philipp Tomsich  <philipp.tomsich@vrull.eu>
47276             Jiangning Liu  <jiangning.liu@amperecomputing.com>
47277             Manolis Tsamis  <manolis.tsamis@vrull.eu>
47279         * config/aarch64/aarch64.cc: Update vector costs for ampere1.
47281 2023-03-27  Richard Biener  <rguenther@suse.de>
47283         PR rtl-optimization/109237
47284         * cfgcleanup.cc (bb_is_just_return): Walk insns backwards.
47286 2023-03-27  Richard Biener  <rguenther@suse.de>
47288         PR lto/109263
47289         * lto-wrapper.cc (run_gcc): Parse alternate debug options
47290         as well, they always enable debug.
47292 2023-03-27  Kewen Lin  <linkw@linux.ibm.com>
47294         PR target/109167
47295         * config/rs6000/emmintrin.h (_mm_bslli_si128): Move the implementation
47296         from ...
47297         (_mm_slli_si128): ... here.  Change to call _mm_bslli_si128 directly.
47299 2023-03-27  Kewen Lin  <linkw@linux.ibm.com>
47301         PR target/109082
47302         * config/rs6000/emmintrin.h (_mm_bslli_si128): Check __N is not less
47303         than zero when calling vec_sld.
47304         (_mm_bsrli_si128): Return __A if __N is zero, check __N is bigger than
47305         zero when calling vec_sld.
47306         (_mm_slli_si128): Return __A if _imm5 is zero, check _imm5 is bigger
47307         than zero when calling vec_sld.
47309 2023-03-27  Sandra Loosemore  <sandra@codesourcery.com>
47311         * doc/generic.texi (OpenMP): Document OMP_SIMD, OMP_DISTRIBUTE,
47312         OMP_TASKLOOP, and OMP_LOOP with OMP_FOR.  Document how collapsed
47313         loops are represented and which fields are vectors.  Add
47314         documentation for OMP_FOR_PRE_BODY field.  Document internal
47315         form of non-rectangular loops and OMP_FOR_NON_RECTANGULAR.
47316         * tree.def (OMP_FOR): Make documentation consistent with the
47317         Texinfo manual, to fill some gaps and correct errors.
47319 2023-03-26  Andreas Schwab  <schwab@linux-m68k.org>
47321         PR target/106282
47322         * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Define.
47323         * config/m68k/m68k.cc (m68k_final_prescan_insn): Define.
47324         (handle_move_double): Call it before handle_movsi.
47325         * config/m68k/m68k-protos.h: Declare it.
47327 2023-03-26  Jakub Jelinek  <jakub@redhat.com>
47329         PR tree-optimization/109230
47330         * match.pd (fneg/fadd simplify): Verify also odd permutation indexes.
47332 2023-03-26  Jakub Jelinek  <jakub@redhat.com>
47334         PR ipa/105685
47335         * predict.cc (compute_function_frequency): Don't call
47336         warn_function_cold if function already has cold attribute.
47338 2023-03-26  Gerald Pfeifer  <gerald@pfeifer.com>
47340         * doc/install.texi: Remove anachronistic note
47341         related to languages built and separate source tarballs.
47343 2023-03-25  David Malcolm  <dmalcolm@redhat.com>
47345         PR analyzer/109098
47346         * diagnostic-format-sarif.cc (read_until_eof): Delete.
47347         (maybe_read_file): Delete.
47348         (sarif_builder::maybe_make_artifact_content_object): Use
47349         get_source_file_content rather than maybe_read_file.
47350         Reject it if it's not valid UTF-8.
47351         * input.cc (file_cache_slot::get_full_file_content): New.
47352         (get_source_file_content): New.
47353         (selftest::check_cpp_valid_utf8_p): New.
47354         (selftest::test_cpp_valid_utf8_p): New.
47355         (selftest::input_cc_tests): Call selftest::test_cpp_valid_utf8_p.
47356         * input.h (get_source_file_content): New prototype.
47358 2023-03-24  David Malcolm  <dmalcolm@redhat.com>
47360         * doc/analyzer.texi (Debugging the Analyzer): Add notes on useful
47361         debugging options.
47362         (Special Functions for Debugging the Analyzer): Convert to a
47363         table, and rewrite in places.
47364         (Other Debugging Techniques): Add notes on how to compare two
47365         different exploded graphs.
47367 2023-03-24  David Malcolm  <dmalcolm@redhat.com>
47369         PR other/109163
47370         * json.cc: Update comments to indicate that we now preserve
47371         insertion order of keys within objects.
47372         (object::print): Traverse keys in insertion order.
47373         (object::set): Preserve insertion order of keys.
47374         (selftest::test_writing_objects): Add an additional key to verify
47375         that we preserve insertion order.
47376         * json.h (object::m_keys): New field.
47378 2023-03-24  Andrew MacLeod  <amacleod@redhat.com>
47380         PR tree-optimization/109238
47381         * gimple-range-cache.cc (ranger_cache::resolve_dom): Ignore
47382         predecessors which this block dominates.
47384 2023-03-24  Richard Biener  <rguenther@suse.de>
47386         PR tree-optimization/106912
47387         * tree-profile.cc (tree_profiling): Update stmts only when
47388         profiling or testing coverage.  Make sure to update calls
47389         fntype, stripping 'const' there.
47391 2023-03-24  Jakub Jelinek  <jakub@redhat.com>
47393         PR middle-end/109258
47394         * builtins.cc (inline_expand_builtin_bytecmp): Return NULL_RTX early
47395         if target == const0_rtx.
47397 2023-03-24  Alexandre Oliva  <oliva@adacore.com>
47399         * doc/sourcebuild.texi (weak_undefined, posix_memalign):
47400         Document options and effective targets.
47402 2023-03-24  Costas Argyris  <costas.argyris@gmail.com>
47404         * config/i386/x-mingw32-utf8: Make HOST_EXTRA_OBJS_SYMBOL
47405         optional.
47407 2023-03-23  Pat Haugen  <pthaugen@linux.ibm.com>
47409         * config/rs6000/rs6000.md (*mod<mode>3, umod<mode>3): Add
47410         non-earlyclobber alternative.
47412 2023-03-23  Andrew Pinski  <apinski@marvell.com>
47414         PR c/84900
47415         * fold-const.cc (maybe_lvalue_p): Treat COMPOUND_LITERAL_EXPR
47416         as a lvalue.
47418 2023-03-23  Richard Biener  <rguenther@suse.de>
47420         PR tree-optimization/107569
47421         * tree-ssa-sccvn.cc (eliminate_dom_walker::eliminate_stmt):
47422         Do not push SSA names with zero uses as available leader.
47423         (process_bb): Likewise.
47425 2023-03-23  Richard Biener  <rguenther@suse.de>
47427         PR tree-optimization/109262
47428         * tree-ssa-forwprop.cc (pass_forwprop::execute): When
47429         combining a piecewise complex load avoid touching loads
47430         that throw internally.  Use fun, not cfun throughout.
47432 2023-03-23  Jakub Jelinek  <jakub@redhat.com>
47434         * value-range.cc (irange::irange_union, irange::intersect): Fix
47435         comment spelling bugs.
47436         * gimple-range-trace.cc (range_tracer::do_header): Likewise.
47437         * gimple-range-trace.h: Likewise.
47438         * gimple-range-edge.cc: Likewise.
47439         (gimple_outgoing_range_stmt_p,
47440         gimple_outgoing_range::switch_edge_range,
47441         gimple_outgoing_range::edge_range_p): Likewise.
47442         * gimple-range.cc (gimple_ranger::prefill_stmt_dependencies,
47443         gimple_ranger::fold_stmt, gimple_ranger::register_transitive_infer,
47444         assume_query::assume_query, assume_query::calculate_phi): Likewise.
47445         * gimple-range-edge.h: Likewise.
47446         * value-range.h (Value_Range::set, Value_Range::lower_bound,
47447         Value_Range::upper_bound, frange::set_undefined): Likewise.
47448         * gimple-range-gori.h (range_def_chain::depend, gori_map::m_outgoing,
47449         gori_compute): Likewise.
47450         * gimple-range-fold.h (fold_using_range): Likewise.
47451         * gimple-range-path.cc (path_range_query::compute_ranges_in_phis):
47452         Likewise.
47453         * gimple-range-gori.cc (range_def_chain::in_chain_p,
47454         range_def_chain::dump, gori_map::calculate_gori,
47455         gori_compute::compute_operand_range_switch,
47456         gori_compute::logical_combine, gori_compute::refine_using_relation,
47457         gori_compute::compute_operand1_range, gori_compute::may_recompute_p):
47458         Likewise.
47459         * gimple-range.h: Likewise.
47460         (enable_ranger): Likewise.
47461         * range-op.h (empty_range_varying): Likewise.
47462         * value-query.h (value_query): Likewise.
47463         * gimple-range-cache.cc (block_range_cache::set_bb_range,
47464         block_range_cache::dump, ssa_global_cache::clear_global_range,
47465         temporal_cache::temporal_value, temporal_cache::current_p,
47466         ranger_cache::range_of_def, ranger_cache::propagate_updated_value,
47467         ranger_cache::range_from_dom, ranger_cache::register_inferred_value):
47468         Likewise.
47469         * gimple-range-fold.cc (fur_edge::get_phi_operand,
47470         fur_stmt::get_operand, gimple_range_adjustment,
47471         fold_using_range::range_of_phi,
47472         fold_using_range::relation_fold_and_or): Likewise.
47473         * value-range-storage.h (irange_storage_slot::MAX_INTS): Likewise.
47474         * value-query.cc (range_query::value_of_expr,
47475         range_query::value_on_edge, range_query::query_relation): Likewise.
47476         * tree-vrp.cc (remove_unreachable::remove_and_update_globals,
47477         intersect_range_with_nonzero_bits): Likewise.
47478         * gimple-range-infer.cc (gimple_infer_range::check_assume_func,
47479         exit_range): Likewise.
47480         * value-relation.h: Likewise.
47481         (equiv_oracle, relation_trio::relation_trio, value_relation,
47482         value_relation::value_relation, pe_min): Likewise.
47483         * range-op-float.cc (range_operator_float::rv_fold,
47484         frange_arithmetic, foperator_unordered_equal::op1_range,
47485         foperator_div::rv_fold): Likewise.
47486         * gimple-range-op.cc (cfn_clz::fold_range): Likewise.
47487         * value-relation.cc (equiv_oracle::query_relation,
47488         equiv_oracle::register_equiv, equiv_oracle::add_equiv_to_block,
47489         value_relation::apply_transitive, relation_chain_head::find_relation,
47490         dom_oracle::query_relation, dom_oracle::find_relation_block,
47491         dom_oracle::find_relation_dom, path_oracle::register_equiv): Likewise.
47492         * range-op.cc (range_operator::wi_fold_in_parts_equiv,
47493         create_possibly_reversed_range, adjust_op1_for_overflow,
47494         operator_mult::wi_fold, operator_exact_divide::op1_range,
47495         operator_cast::lhs_op1_relation, operator_cast::fold_pair,
47496         operator_cast::fold_range, operator_abs::wi_fold, range_op_cast_tests,
47497         range_op_lshift_tests): Likewise.
47499 2023-03-23  Andrew Stubbs  <ams@codesourcery.com>
47501         * config/gcn/gcn.cc (gcn_class_max_nregs): Handle vectors in SGPRs.
47502         (move_callee_saved_registers): Detect the bug condition early.
47504 2023-03-23  Andrew Stubbs  <ams@codesourcery.com>
47506         * config/gcn/gcn-protos.h (gcn_stepped_zero_int_parallel_p): New.
47507         * config/gcn/gcn-valu.md (V_1REG_ALT): New.
47508         (V_2REG_ALT): New.
47509         (vec_extract<V_1REG:mode><V_1REG_ALT:mode>_nop): New.
47510         (vec_extract<V_2REG:mode><V_2REG_ALT:mode>_nop): New.
47511         (vec_extract<V_ALL:mode><V_ALL_ALT:mode>): Use new patterns.
47512         * config/gcn/gcn.cc (gcn_stepped_zero_int_parallel_p): New.
47513         * config/gcn/predicates.md (ascending_zero_int_parallel): New.
47515 2023-03-23  Jakub Jelinek  <jakub@redhat.com>
47517         PR tree-optimization/109176
47518         * tree-vect-generic.cc (expand_vector_condition): If a has
47519         vector boolean type and is a comparison, also check if both
47520         the comparison and VEC_COND_EXPR could be successfully expanded
47521         individually.
47523 2023-03-23  Pan Li  <pan2.li@intel.com>
47524             Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
47526         PR target/108654
47527         PR target/108185
47528         * config/riscv/riscv-modes.def (ADJUST_BYTESIZE): Adjust size
47529         for vector mask modes.
47530         * config/riscv/riscv.cc (riscv_v_adjust_bytesize): New.
47531         * config/riscv/riscv.h (riscv_v_adjust_bytesize): New.
47533 2023-03-23  Songhe Zhu  <zhusonghe@eswincomputing.com>
47535         * config/riscv/multilib-generator: Adjusting the loop of 'alt' in 'alts'.
47537 2023-03-23  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
47539         PR target/109244
47540         * config/riscv/riscv-protos.h (emit_vlmax_vsetvl): Define as global.
47541         (emit_vlmax_op): Ditto.
47542         * config/riscv/riscv-v.cc (get_sew): New function.
47543         (emit_vlmax_vsetvl): Adapt function.
47544         (emit_pred_op): Ditto.
47545         (emit_vlmax_op): Ditto.
47546         (emit_nonvlmax_op): Ditto.
47547         (legitimize_move): Fix LRA ICE.
47548         (gen_no_side_effects_vsetvl_rtx): Adapt function.
47549         * config/riscv/vector.md (@mov<V_FRACT:mode><P:mode>_lra): New pattern.
47550         (@mov<VB:mode><P:mode>_lra): Ditto.
47551         (*mov<V_FRACT:mode><P:mode>_lra): Ditto.
47552         (*mov<VB:mode><P:mode>_lra): Ditto.
47554 2023-03-23  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
47556         PR target/109228
47557         * config/riscv/riscv-vector-builtins-bases.cc (class vlenb): Add
47558         __riscv_vlenb support.
47559         (BASE): Ditto.
47560         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
47561         * config/riscv/riscv-vector-builtins-functions.def (vlenb): Ditto.
47562         * config/riscv/riscv-vector-builtins-shapes.cc (struct vlenb_def): Ditto.
47563         (SHAPE): Ditto.
47564         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
47565         * config/riscv/riscv-vector-builtins.cc: Ditto.
47567 2023-03-23  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
47568             kito-cheng  <kito.cheng@sifive.com>
47570         * config/riscv/riscv-vsetvl.cc (reg_available_p): Fix bugs.
47571         (pass_vsetvl::compute_local_backward_infos): Fix bugs.
47572         (pass_vsetvl::need_vsetvl): Fix bugs.
47573         (pass_vsetvl::backward_demand_fusion): Fix bugs.
47574         (pass_vsetvl::demand_fusion): Fix bugs.
47575         (eliminate_insn): Fix bugs.
47576         (insert_vsetvl): Ditto.
47577         (pass_vsetvl::emit_local_forward_vsetvls): Ditto.
47578         * config/riscv/riscv-vsetvl.h (enum vsetvl_type): Ditto.
47579         * config/riscv/vector.md: Ditto.
47581 2023-03-23  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
47582             kito-cheng  <kito.cheng@sifive.com>
47584         * config/riscv/riscv-vector-builtins-bases.cc: Fix ternary bug.
47585         * config/riscv/vector-iterators.md (nmsac): Ditto.
47586         (nmsub): Ditto.
47587         (msac): Ditto.
47588         (msub): Ditto.
47589         (nmadd): Ditto.
47590         (nmacc): Ditto.
47591         * config/riscv/vector.md (@pred_mul_<optab><mode>): Ditto.
47592         (@pred_mul_plus<mode>): Ditto.
47593         (*pred_madd<mode>): Ditto.
47594         (*pred_macc<mode>): Ditto.
47595         (*pred_mul_plus<mode>): Ditto.
47596         (@pred_mul_plus<mode>_scalar): Ditto.
47597         (*pred_madd<mode>_scalar): Ditto.
47598         (*pred_macc<mode>_scalar): Ditto.
47599         (*pred_mul_plus<mode>_scalar): Ditto.
47600         (*pred_madd<mode>_extended_scalar): Ditto.
47601         (*pred_macc<mode>_extended_scalar): Ditto.
47602         (*pred_mul_plus<mode>_extended_scalar): Ditto.
47603         (@pred_minus_mul<mode>): Ditto.
47604         (*pred_<madd_nmsub><mode>): Ditto.
47605         (*pred_nmsub<mode>): Ditto.
47606         (*pred_<macc_nmsac><mode>): Ditto.
47607         (*pred_nmsac<mode>): Ditto.
47608         (*pred_mul_<optab><mode>): Ditto.
47609         (*pred_minus_mul<mode>): Ditto.
47610         (@pred_mul_<optab><mode>_scalar): Ditto.
47611         (@pred_minus_mul<mode>_scalar): Ditto.
47612         (*pred_<madd_nmsub><mode>_scalar): Ditto.
47613         (*pred_nmsub<mode>_scalar): Ditto.
47614         (*pred_<macc_nmsac><mode>_scalar): Ditto.
47615         (*pred_nmsac<mode>_scalar): Ditto.
47616         (*pred_mul_<optab><mode>_scalar): Ditto.
47617         (*pred_minus_mul<mode>_scalar): Ditto.
47618         (*pred_<madd_nmsub><mode>_extended_scalar): Ditto.
47619         (*pred_nmsub<mode>_extended_scalar): Ditto.
47620         (*pred_<macc_nmsac><mode>_extended_scalar): Ditto.
47621         (*pred_nmsac<mode>_extended_scalar): Ditto.
47622         (*pred_mul_<optab><mode>_extended_scalar): Ditto.
47623         (*pred_minus_mul<mode>_extended_scalar): Ditto.
47624         (*pred_<madd_msub><mode>): Ditto.
47625         (*pred_<macc_msac><mode>): Ditto.
47626         (*pred_<madd_msub><mode>_scalar): Ditto.
47627         (*pred_<macc_msac><mode>_scalar): Ditto.
47628         (@pred_neg_mul_<optab><mode>): Ditto.
47629         (@pred_mul_neg_<optab><mode>): Ditto.
47630         (*pred_<nmadd_msub><mode>): Ditto.
47631         (*pred_<nmsub_nmadd><mode>): Ditto.
47632         (*pred_<nmacc_msac><mode>): Ditto.
47633         (*pred_<nmsac_nmacc><mode>): Ditto.
47634         (*pred_neg_mul_<optab><mode>): Ditto.
47635         (*pred_mul_neg_<optab><mode>): Ditto.
47636         (@pred_neg_mul_<optab><mode>_scalar): Ditto.
47637         (@pred_mul_neg_<optab><mode>_scalar): Ditto.
47638         (*pred_<nmadd_msub><mode>_scalar): Ditto.
47639         (*pred_<nmsub_nmadd><mode>_scalar): Ditto.
47640         (*pred_<nmacc_msac><mode>_scalar): Ditto.
47641         (*pred_<nmsac_nmacc><mode>_scalar): Ditto.
47642         (*pred_neg_mul_<optab><mode>_scalar): Ditto.
47643         (*pred_mul_neg_<optab><mode>_scalar): Ditto.
47644         (@pred_widen_neg_mul_<optab><mode>): Ditto.
47645         (@pred_widen_mul_neg_<optab><mode>): Ditto.
47646         (@pred_widen_neg_mul_<optab><mode>_scalar): Ditto.
47647         (@pred_widen_mul_neg_<optab><mode>_scalar): Ditto.
47649 2023-03-23  liuhongt  <hongtao.liu@intel.com>
47651         * builtins.cc (builtin_memset_read_str): Replace
47652         targetm.gen_memset_scratch_rtx with gen_reg_rtx.
47653         (builtin_memset_gen_str): Ditto.
47654         * config/i386/i386-expand.cc
47655         (ix86_convert_const_wide_int_to_broadcast): Replace
47656         ix86_gen_scratch_sse_rtx with gen_reg_rtx.
47657         (ix86_expand_vector_move): Ditto.
47658         * config/i386/i386-protos.h (ix86_gen_scratch_sse_rtx):
47659         Removed.
47660         * config/i386/i386.cc (ix86_gen_scratch_sse_rtx): Removed.
47661         (TARGET_GEN_MEMSET_SCRATCH_RTX): Removed.
47662         * doc/tm.texi: Remove TARGET_GEN_MEMSET_SCRATCH_RTX.
47663         * doc/tm.texi.in: Ditto.
47664         * target.def: Ditto.
47666 2023-03-22  Vladimir N. Makarov  <vmakarov@redhat.com>
47668         * lra.cc (lra): Do not repeat inheritance and live range splitting
47669         when asm error is found.
47671 2023-03-22  Andrew Jenner  <andrew@codesourcery.com>
47673         * config/gcn/gcn-protos.h (gcn_expand_dpp_swap_pairs_insn)
47674         (gcn_expand_dpp_distribute_even_insn)
47675         (gcn_expand_dpp_distribute_odd_insn): Declare.
47676         * config/gcn/gcn-valu.md (@dpp_swap_pairs<mode>)
47677         (@dpp_distribute_even<mode>, @dpp_distribute_odd<mode>)
47678         (cmul<conj_op><mode>3, cml<addsub_as><mode>4, vec_addsub<mode>3)
47679         (cadd<rot><mode>3, vec_fmaddsub<mode>4, vec_fmsubadd<mode>4)
47680         (fms<mode>4<exec>, fms<mode>4_negop2<exec>, fms<mode>4)
47681         (fms<mode>4_negop2): New patterns.
47682         * config/gcn/gcn.cc (gcn_expand_dpp_swap_pairs_insn)
47683         (gcn_expand_dpp_distribute_even_insn)
47684         (gcn_expand_dpp_distribute_odd_insn): New functions.
47685         * config/gcn/gcn.md: Add entries to unspec enum.
47687 2023-03-22  Aldy Hernandez  <aldyh@redhat.com>
47689         PR tree-optimization/109008
47690         * value-range.cc (frange::set): Add nan_state argument.
47691         * value-range.h (class nan_state): New.
47692         (frange::get_nan_state): New.
47694 2023-03-22  Martin Liska  <mliska@suse.cz>
47696         * configure: Regenerate.
47698 2023-03-21  Joseph Myers  <joseph@codesourcery.com>
47700         * stor-layout.cc (finalize_type_size): Copy TYPE_TYPELESS_STORAGE
47701         to variants.
47703 2023-03-21  Andrew MacLeod  <amacleod@redhat.com>
47705         PR tree-optimization/109192
47706         * gimple-range-gori.cc (gori_compute::compute_operand_range):
47707         Terminate gori calculations if a relation is not relevant.
47708         * value-relation.h (value_relation::set_relation): Allow
47709         equality between op1 and op2 if they are the same.
47711 2023-03-21  Richard Biener  <rguenther@suse.de>
47713         PR tree-optimization/109219
47714         * tree-vect-loop.cc (vectorizable_reduction): Check
47715         slp_node, not STMT_SLP_TYPE.
47716         * tree-vect-stmts.cc (vectorizable_condition): Likewise.
47717         * tree-vect-slp.cc (vect_slp_analyze_node_operations_1):
47718         Remove assertion on STMT_SLP_TYPE.
47720 2023-03-21  Jakub Jelinek  <jakub@redhat.com>
47722         PR tree-optimization/109215
47723         * tree.h (enum special_array_member): Adjust comments for int_0
47724         and trail_0.
47725         * tree.cc (component_ref_sam_type): Clear zero_elts if memtype
47726         has zero sized element type and the array has variable number of
47727         elements or constant one or more elements.
47728         (component_ref_size): Adjust comments, formatting fix.
47730 2023-03-21  Arsen Arsenović  <arsen@aarsen.me>
47732         * configure.ac: Add check for the Texinfo 6.8
47733         CONTENTS_OUTPUT_LOCATION customization variable and set it if
47734         supported.
47735         * configure: Regenerate.
47736         * Makefile.in (MAKEINFO_TOC_INLINE_FLAG): New variable.  Set by
47737         configure.ac to -c CONTENTS_OUTPUT_LOCATION=inline if
47738         CONTENTS_OUTPUT_LOCATION support is detected, empty otherwise.
47739         ($(build_htmldir)/%/index.html): Pass MAKEINFO_TOC_INLINE_FLAG.
47741 2023-03-21  Arsen Arsenović  <arsen@aarsen.me>
47743         * doc/extend.texi: Associate use_hazard_barrier_return index
47744         entry with its attribute.
47745         * doc/invoke.texi: Associate -fcanon-prefix-map index entry with
47746         its attribute
47748 2023-03-21  Arsen Arsenović  <arsen@aarsen.me>
47750         * doc/implement-c.texi: Remove usage of @gol.
47751         * doc/invoke.texi: Ditto.
47752         * doc/sourcebuild.texi: Ditto.
47753         * doc/include/gcc-common.texi: Remove @gol.  In new Makeinfo and
47754         texinfo.tex versions, the bug it was working around appears to
47755         be gone.
47757 2023-03-21  Arsen Arsenović  <arsen@aarsen.me>
47759         * doc/include/texinfo.tex: Update to 2023-01-17.19.
47761 2023-03-21  Arsen Arsenović  <arsen@aarsen.me>
47763         * doc/include/gcc-common.texi: Add @defbuiltin{,x} and
47764         @enddefbuiltin for defining built-in functions.
47765         * doc/extend.texi: Apply @defbuiltin{,x} to many, but not all,
47766         places where it should be used.
47768 2023-03-21  Arsen Arsenović  <arsen@aarsen.me>
47770         * doc/extend.texi (Formatted Output Function Checking): New
47771         subsection for  grouping together printf et al.
47772         (Exception handling) Fix missing @ sign before copyright
47773         header, which lead to the copyright line leaking into
47774         '(gcc)Exception handling'.
47775         * doc/gcc.texi: Set document language to en_US.
47776         (@copying): Wrap front cover texts in quotations, move in manual
47777         description text.
47779 2023-03-21  Arsen Arsenović  <arsen@aarsen.me>
47781         * doc/gcc.texi: Add the Indices appendix, to make texinfo
47782         generate nice indices overview page.
47784 2023-03-21  Richard Biener  <rguenther@suse.de>
47786         PR tree-optimization/109170
47787         * gimple-range-op.cc (cfn_pass_through_arg1): New.
47788         (gimple_range_op_handler::maybe_builtin_call): Handle
47789         __builtin_expect via cfn_pass_through_arg1.
47791 2023-03-20   Michael Meissner  <meissner@linux.ibm.com>
47793         PR target/109067
47794         * config/rs6000/rs6000.cc (create_complex_muldiv): Delete.
47795         (init_float128_ieee): Delete code to switch complex multiply and divide
47796         for long double.
47797         (complex_multiply_builtin_code): New helper function.
47798         (complex_divide_builtin_code): Likewise.
47799         (rs6000_mangle_decl_assembler_name): Add support for mangling the name
47800         of complex 128-bit multiply and divide built-in functions.
47802 2023-03-20  Peter Bergner  <bergner@linux.ibm.com>
47804         PR target/109178
47805         * config/rs6000/rs6000-builtin.cc (stv_expand_builtin): Use tmode.
47807 2023-03-19  Jonny Grant  <jg@jguk.org>
47809         * doc/extend.texi (Common Function Attributes) <nonnull>:
47810         Correct typo.
47812 2023-03-18  Peter Bergner  <bergner@linux.ibm.com>
47814         PR rtl-optimization/109179
47815         * lra-constraints.cc (combine_reload_insn): Enforce TO is not a debug
47816         insn or note.  Move the tests earlier to guard lra_get_insn_recog_data.
47818 2023-03-17  Jakub Jelinek  <jakub@redhat.com>
47820         PR target/105554
47821         * function.h (push_struct_function): Add ABSTRACT_P argument defaulted
47822         to false.
47823         * function.cc (push_struct_function): Add ABSTRACT_P argument, pass it
47824         to allocate_struct_function instead of false.
47825         * tree-inline.cc (initialize_cfun): Don't copy DECL_ARGUMENTS
47826         nor DECL_RESULT here.  Pass true as ABSTRACT_P to
47827         push_struct_function.  Call targetm.target_option.relayout_function
47828         after it.
47829         (tree_function_versioning): Formatting fix.
47831 2023-03-17  Vladimir N. Makarov  <vmakarov@redhat.com>
47833         * lra-constraints.cc: Include hooks.h.
47834         (combine_reload_insn): New function.
47835         (lra_constraints): Call it.
47837 2023-03-17  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
47838             kito-cheng  <kito.cheng@sifive.com>
47840         * config/riscv/riscv-v.cc (legitimize_move): Allow undef value
47841         as legitimate value.
47842         * config/riscv/riscv-vector-builtins.cc
47843         (function_expander::use_ternop_insn): Fix bugs of ternary intrinsic.
47844         (function_expander::use_widen_ternop_insn): Ditto.
47845         * config/riscv/vector.md (@vundefined<mode>): New pattern.
47846         (pred_mul_<optab><mode>_undef_merge): Remove.
47847         (*pred_mul_<optab><mode>_undef_merge_scalar): Ditto.
47848         (*pred_mul_<optab><mode>_undef_merge_extended_scalar): Ditto.
47849         (pred_neg_mul_<optab><mode>_undef_merge): Ditto.
47850         (*pred_neg_mul_<optab><mode>_undef_merge_scalar): Ditto.
47852 2023-03-17  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
47854         PR target/109092
47855         * config/riscv/riscv.md: Fix subreg bug.
47857 2023-03-17  Jakub Jelinek  <jakub@redhat.com>
47859         PR middle-end/108685
47860         * omp-expand.cc (expand_omp_for_ordered_loops): Add L0_BB argument,
47861         use its loop_father rather than BODY_BB's loop_father.
47862         (expand_omp_for_generic): Adjust expand_omp_for_ordered_loops caller.
47863         If broken_loop with ordered > collapse and at least one of those
47864         extra loops aren't guaranteed to have at least one iteration, change
47865         l0_bb's loop_father to entry_bb's loop_father.  Set cont_bb's
47866         loop_father to l0_bb's loop_father rather than l1_bb's.
47868 2023-03-17  Jakub Jelinek  <jakub@redhat.com>
47870         PR plugins/108634
47871         * gdbhooks.py (TreePrinter.to_string): Wrap
47872         gdb.parse_and_eval('tree_code_type') in a try block, parse
47873         and eval 'tree_code_type_tmpl<0>::tree_code_type' instead if it
47874         raises exception.  Update comments for the recent tree_code_type
47875         changes.
47877 2023-03-17  Sandra Loosemore  <sandra@codesourcery.com>
47879         * doc/extend.texi (BPF Built-in Functions): Fix numerous markup
47880         issues.  Add more line breaks to example so it doesn't overflow
47881         the margins.
47883 2023-03-17  Sandra Loosemore  <sandra@codesourcery.com>
47885         * doc/extend.texi (Common Function Attributes) <access>: Fix bad
47886         line breaks in examples.
47887         <malloc>: Fix bad line breaks in running text, also copy-edit
47888         for consistency.
47889         (Extended Asm) <Generic Operand Modifiers>: Fix @multitable width.
47890         * doc/invoke.texi (Option Summary) <Developer Options>: Fix misplaced
47891         @gol.
47892         (C++ Dialect Options) <-fcontracts>: Add line break in example.
47893         <-Wctad-maybe-unsupported>: Likewise.
47894         <-Winvalid-constexpr>: Likewise.
47895         (Warning Options) <-Wdangling-pointer>: Likewise.
47896         <-Winterference-size>: Likewise.
47897         <-Wvla-parameter>: Likewise.
47898         (Static Analyzer Options): Fix bad line breaks in running text,
47899         plus add some missing markup.
47900         (Optimize Options) <openacc-privatization>: Fix more bad line
47901         breaks in running text.
47903 2023-03-16  Uros Bizjak  <ubizjak@gmail.com>
47905         * config/i386/i386-expand.cc (expand_vec_perm_pblendv):
47906         Handle 8-byte modes only with TARGET_MMX_WITH_SSE.
47907         (expand_vec_perm_2perm_pblendv): Ditto.
47909 2023-03-16  Martin Liska  <mliska@suse.cz>
47911         PR middle-end/106133
47912         * gcc.cc (driver_handle_option): Use x_main_input_basename
47913         if x_dump_base_name is null.
47914         * opts.cc (common_handle_option): Likewise.
47916 2023-03-16  Richard Biener  <rguenther@suse.de>
47918         PR tree-optimization/109123
47919         * gimple-ssa-warn-access.cc (pass_waccess::warn_invalid_pointer):
47920         Do not emit -Wuse-after-free late.
47921         (pass_waccess::check_call): Always check call pointer uses.
47923 2023-03-16  Richard Biener  <rguenther@suse.de>
47925         PR tree-optimization/109141
47926         * tree-dfa.h (renumber_gimple_stmt_uids_in_block): New.
47927         * tree-dfa.cc (renumber_gimple_stmt_uids_in_block): Split
47928         out from ...
47929         (renumber_gimple_stmt_uids): ... here and
47930         (renumber_gimple_stmt_uids_in_blocks): ... here.
47931         * gimple-ssa-warn-access.cc (pass_waccess::use_after_inval_p):
47932         Use renumber_gimple_stmt_uids_in_block to also assign UIDs
47933         to PHIs.
47934         (pass_waccess::check_pointer_uses): Process all PHIs.
47936 2023-03-15  David Malcolm  <dmalcolm@redhat.com>
47938         PR analyzer/109097
47939         * diagnostic-format-sarif.cc (class sarif_invocation): New.
47940         (class sarif_ice_notification): New.
47941         (sarif_builder::m_invocation_obj): New field.
47942         (sarif_invocation::add_notification_for_ice): New.
47943         (sarif_invocation::prepare_to_flush): New.
47944         (sarif_ice_notification::sarif_ice_notification): New.
47945         (sarif_builder::sarif_builder): Add m_invocation_obj.
47946         (sarif_builder::end_diagnostic): Special-case DK_ICE and
47947         DK_ICE_NOBT.
47948         (sarif_builder::flush_to_file): Call prepare_to_flush on
47949         m_invocation_obj.  Pass the latter to make_top_level_object.
47950         (sarif_builder::make_result_object): Move creation of "locations"
47951         array to...
47952         (sarif_builder::make_locations_arr): ...this new function.
47953         (sarif_builder::make_top_level_object): Add "invocation_obj" param
47954         and pass it to make_run_object.
47955         (sarif_builder::make_run_object): Add "invocation_obj" param and
47956         use it.
47957         (sarif_ice_handler): New callback.
47958         (diagnostic_output_format_init_sarif): Wire up sarif_ice_handler.
47959         * diagnostic.cc (diagnostic_initialize): Initialize new field
47960         "ice_handler_cb".
47961         (diagnostic_action_after_output): If it is set, make one attempt
47962         to call ice_handler_cb.
47963         * diagnostic.h (diagnostic_context::ice_handler_cb): New field.
47965 2023-03-15  Uros Bizjak  <ubizjak@gmail.com>
47967         * config/i386/i386-expand.cc (expand_vec_perm_blend):
47968         Handle 8-byte modes only with TARGET_MMX_WITH_SSE. Handle V2SFmode
47969         and fix V2HImode handling.
47970         (expand_vec_perm_1): Try to emit BLEND instruction
47971         before MOVSS/MOVSD.
47972         * config/i386/mmx.md (*mmx_blendps): New insn pattern.
47974 2023-03-15  Tobias Burnus  <tobias@codesourcery.com>
47976         * omp-low.cc (omp_runtime_api_call): Add omp_in_explicit_task.
47978 2023-03-15  Richard Biener  <rguenther@suse.de>
47980         * gimple-ssa-warn-access.cc (pass_waccess::check_pointer_uses):
47981         Do not diagnose clobbers.
47983 2023-03-15  Richard Biener  <rguenther@suse.de>
47985         PR tree-optimization/109139
47986         * tree-ssa-live.cc (remove_unused_locals): Look at the
47987         base address for unused decls on the LHS of .DEFERRED_INIT.
47989 2023-03-15  Xi Ruoyao  <xry111@xry111.site>
47991         PR other/109086
47992         * builtins.cc (inline_string_cmp): Force the character
47993         difference into "result" pseudo-register, instead of reassign
47994         the pseudo-register.
47996 2023-03-15  Christoph Müllner  <christoph.muellner@vrull.eu>
47998         * config.gcc: Add thead.o to RISC-V extra_objs.
47999         * config/riscv/peephole.md: Add mempair peephole passes.
48000         * config/riscv/riscv-protos.h (riscv_split_64bit_move_p): New
48001         prototype.
48002         (th_mempair_operands_p): Likewise.
48003         (th_mempair_order_operands): Likewise.
48004         (th_mempair_prepare_save_restore_operands): Likewise.
48005         (th_mempair_save_restore_regs): Likewise.
48006         (th_mempair_output_move): Likewise.
48007         * config/riscv/riscv.cc (riscv_save_reg): Move code.
48008         (riscv_restore_reg): Move code.
48009         (riscv_for_each_saved_reg): Add code to emit mempair insns.
48010         * config/riscv/t-riscv: Add thead.cc.
48011         * config/riscv/thead.md (*th_mempair_load_<GPR:mode>2):
48012         New insn.
48013         (*th_mempair_store_<GPR:mode>2): Likewise.
48014         (*th_mempair_load_extendsidi2): Likewise.
48015         (*th_mempair_load_zero_extendsidi2): Likewise.
48016         * config/riscv/thead.cc: New file.
48018 2023-03-15  Christoph Müllner  <christoph.muellner@vrull.eu>
48020         * config/riscv/constraints.md (TARGET_XTHEADFMV ? FP_REGS : NO_REGS)
48021         New constraint "th_f_fmv".
48022         (TARGET_XTHEADFMV ? GR_REGS : NO_REGS): New constraint
48023         "th_r_fmv".
48024         * config/riscv/riscv.cc (riscv_split_doubleword_move):
48025         Add split code for XTheadFmv.
48026         (riscv_secondary_memory_needed): XTheadFmv does not need
48027         secondary memory.
48028         * config/riscv/riscv.md: Add new UNSPEC_XTHEADFMV and
48029         UNSPEC_XTHEADFMV_HW. Add support for XTheadFmv to
48030         movdf_hardfloat_rv32.
48031         * config/riscv/thead.md (th_fmv_hw_w_x): New INSN.
48032         (th_fmv_x_w): New INSN.
48033         (th_fmv_x_hw): New INSN.
48035 2023-03-15  Christoph Müllner  <christoph.muellner@vrull.eu>
48037         * config/riscv/riscv.md (maddhisi4): New expand.
48038         (msubhisi4): New expand.
48039         * config/riscv/thead.md (*th_mula<mode>): New pattern.
48040         (*th_mulawsi): New pattern.
48041         (*th_mulawsi2): New pattern.
48042         (*th_maddhisi4): New pattern.
48043         (*th_sextw_maddhisi4): New pattern.
48044         (*th_muls<mode>): New pattern.
48045         (*th_mulswsi): New pattern.
48046         (*th_mulswsi2): New pattern.
48047         (*th_msubhisi4): New pattern.
48048         (*th_sextw_msubhisi4): New pattern.
48050 2023-03-15  Christoph Müllner  <christoph.muellner@vrull.eu>
48052         * config/riscv/iterators.md (TARGET_64BIT): Add GPR2 iterator.
48053         * config/riscv/riscv-protos.h (riscv_expand_conditional_move):
48054         Add prototype.
48055         * config/riscv/riscv.cc (riscv_rtx_costs): Add costs for
48056         XTheadCondMov.
48057         (riscv_expand_conditional_move): New function.
48058         (riscv_expand_conditional_move_onesided): New function.
48059         * config/riscv/riscv.md: Add support for XTheadCondMov.
48060         * config/riscv/thead.md (*th_cond_mov<GPR:mode><GPR2:mode>): Add
48061         support for XTheadCondMov.
48062         (*th_cond_gpr_mov<GPR:mode><GPR2:mode>): Likewise.
48064 2023-03-15  Christoph Müllner  <christoph.muellner@vrull.eu>
48066         * config/riscv/bitmanip.md (clzdi2): New expand.
48067         (clzsi2): New expand.
48068         (ctz<mode>2): New expand.
48069         (popcount<mode>2): New expand.
48070         (<bitmanip_optab>si2): Rename INSN.
48071         (*<bitmanip_optab>si2): Hide INSN name.
48072         (<bitmanip_optab>di2): Rename INSN.
48073         (*<bitmanip_optab>di2): Hide INSN name.
48074         (rotrsi3): Remove INSN.
48075         (rotr<mode>3): Add expand.
48076         (*rotrsi3): New INSN.
48077         (rotrdi3): Rename INSN.
48078         (*rotrdi3): Hide INSN name.
48079         (rotrsi3_sext): Rename INSN.
48080         (*rotrsi3_sext): Hide INSN name.
48081         (bswap<mode>2): Remove INSN.
48082         (bswapdi2): Add expand.
48083         (bswapsi2): Add expand.
48084         (*bswap<mode>2): Hide INSN name.
48085         * config/riscv/riscv.cc (riscv_rtx_costs): Add costs for sign
48086         extraction.
48087         * config/riscv/riscv.md (extv<mode>): New expand.
48088         (extzv<mode>): New expand.
48089         * config/riscv/thead.md (*th_srri<mode>3): New INSN.
48090         (*th_ext<mode>): New INSN.
48091         (*th_extu<mode>): New INSN.
48092         (*th_clz<mode>2): New INSN.
48093         (*th_rev<mode>2): New INSN.
48095 2023-03-15  Christoph Müllner  <christoph.muellner@vrull.eu>
48097         * config/riscv/riscv.cc (riscv_rtx_costs): Add xthead:tst cost.
48098         * config/riscv/thead.md (*th_tst<mode>3): New INSN.
48100 2023-03-15  Christoph Müllner  <christoph.muellner@vrull.eu>
48102         * config/riscv/riscv.md: Include thead.md
48103         * config/riscv/thead.md: New file.
48105 2023-03-15  Christoph Müllner  <christoph.muellner@vrull.eu>
48107         * config/riscv/riscv-cores.def (RISCV_CORE): Add "thead-c906".
48109 2023-03-15  Christoph Müllner  <christoph.muellner@vrull.eu>
48111         * common/config/riscv/riscv-common.cc: Add xthead* extensions.
48112         * config/riscv/riscv-opts.h (MASK_XTHEADBA): New.
48113         (MASK_XTHEADBB): New.
48114         (MASK_XTHEADBS): New.
48115         (MASK_XTHEADCMO): New.
48116         (MASK_XTHEADCONDMOV): New.
48117         (MASK_XTHEADFMEMIDX): New.
48118         (MASK_XTHEADFMV): New.
48119         (MASK_XTHEADINT): New.
48120         (MASK_XTHEADMAC): New.
48121         (MASK_XTHEADMEMIDX): New.
48122         (MASK_XTHEADMEMPAIR): New.
48123         (MASK_XTHEADSYNC): New.
48124         (TARGET_XTHEADBA): New.
48125         (TARGET_XTHEADBB): New.
48126         (TARGET_XTHEADBS): New.
48127         (TARGET_XTHEADCMO): New.
48128         (TARGET_XTHEADCONDMOV): New.
48129         (TARGET_XTHEADFMEMIDX): New.
48130         (TARGET_XTHEADFMV): New.
48131         (TARGET_XTHEADINT): New.
48132         (TARGET_XTHEADMAC): New.
48133         (TARGET_XTHEADMEMIDX): New.
48134         (TARGET_XTHEADMEMPAIR): new.
48135         (TARGET_XTHEADSYNC): New.
48136         * config/riscv/riscv.opt: Add riscv_xthead_subext.
48138 2023-03-15  Hu, Lin1  <lin1.hu@intel.com>
48140         PR target/109117
48141         * config/i386/i386-builtin.def (__builtin_ia32_vaesdec_v16qi,
48142         __builtin_ia32_vaesdeclast_v16qi,__builtin_ia32_vaesenc_v16qi,
48143         __builtin_ia32_vaesenclast_v16qi): Require OPTION_MASK_ISA_AVX512VL.
48145 2023-03-14  Jakub Jelinek  <jakub@redhat.com>
48147         PR target/109109
48148         * config/i386/i386-expand.cc (split_double_concat): Fix splitting
48149         when lo is equal to dhi and hi is a MEM which uses dlo register.
48151 2023-03-14  Martin Jambor  <mjambor@suse.cz>
48153         PR ipa/107925
48154         * ipa-cp.cc (update_profiling_info): Drop counts of orig_node to
48155         global0 instead of zeroing when it does not have as many counts as
48156         it should.
48158 2023-03-14  Martin Jambor  <mjambor@suse.cz>
48160         PR ipa/107925
48161         * ipa-cp.cc (update_specialized_profile): Drop orig_node_count to
48162         ipa count, remove assert, lenient_count_portion_handling, dump
48163         also orig_node_count.
48165 2023-03-14  Uros Bizjak  <ubizjak@gmail.com>
48167         * config/i386/i386-expand.cc (expand_vec_perm_movs):
48168         Handle V2SImode for TARGET_MMX_WITH_SSE.
48169         * config/i386/mmx.md (*mmx_movss_<mode>): Rename from *mmx_movss
48170         using V2FI mode iterator to handle both V2SI and V2SF modes.
48172 2023-03-14  Sam James  <sam@gentoo.org>
48174         * config/riscv/genrvv-type-indexer.cc: Avoid calloc() poisoning on musl by
48175         including <sstream> earlier.
48176         * system.h: Add INCLUDE_SSTREAM.
48178 2023-03-14  Richard Biener  <rguenther@suse.de>
48180         * tree-ssa-live.cc (remove_unused_locals): Do not treat
48181         the .DEFERRED_INIT of a variable as use, instead remove
48182         that if it is the only use.
48184 2023-03-14  Eric Botcazou  <ebotcazou@adacore.com>
48186         PR rtl-optimization/107762
48187         * expr.cc (emit_group_store): Revert latest change.
48189 2023-03-14  Andre Vieira  <andre.simoesdiasvieira@arm.com>
48191         PR tree-optimization/109005
48192         * tree-if-conv.cc (get_bitfield_rep): Replace BLKmode check with
48193         aggregate type check.
48195 2023-03-14  Jakub Jelinek  <jakub@redhat.com>
48197         PR tree-optimization/109115
48198         * tree-vect-patterns.cc (vect_recog_divmod_pattern): Don't use
48199         r.upper_bound () on r.undefined_p () range.
48201 2023-03-14  Jan Hubicka  <hubicka@ucw.cz>
48203         PR tree-optimization/106896
48204         * profile-count.cc (profile_count::to_sreal_scale): Synchronize
48205         implementatoin with probability_in; avoid some asserts.
48207 2023-03-13  Max Filippov  <jcmvbkbc@gmail.com>
48209         * config/xtensa/linux.h (TARGET_ASM_FILE_END): New macro.
48211 2023-03-13  Sean Bright  <sean@seanbright.com>
48213         * doc/invoke.texi (Warning Options): Remove errant 'See'
48214         before @xref.
48216 2023-03-13  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
48218         * config/xtensa/xtensa.h (REG_OK_STRICT, REG_OK_FOR_INDEX_P,
48219         REG_OK_FOR_BASE_P): Remove.
48221 2023-03-13  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
48223         * config/riscv/vector-iterators.md (=vd,vr): Fine tune.
48224         (=vd,vd,vr,vr): Ditto.
48225         * config/riscv/vector.md: Ditto.
48227 2023-03-13  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
48229         * config/riscv/riscv-vector-builtins.cc
48230         (function_expander::use_compare_insn): Add operand predicate check.
48232 2023-03-13  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
48234         * config/riscv/vector.md: Fine tune RA constraints.
48236 2023-03-13  Tobias Burnus  <tobias@codesourcery.com>
48238         * config/gcn/mkoffload.cc (main): Pass -save-temps on for the
48239         hsaco assemble/link.
48241 2023-03-13  Richard Biener  <rguenther@suse.de>
48243         PR tree-optimization/109046
48244         * tree-ssa-forwprop.cc (pass_forwprop::execute): Combine
48245         piecewise complex loads.
48247 2023-03-12  Jakub Jelinek  <jakub@redhat.com>
48249         * config/aarch64/aarch64.h (aarch64_bf16_type_node): Remove.
48250         (aarch64_bf16_ptr_type_node): Adjust comment.
48251         * config/aarch64/aarch64.cc (aarch64_gimplify_va_arg_expr): Use
48252         bfloat16_type_node rather than aarch64_bf16_type_node.
48253         (aarch64_libgcc_floating_mode_supported_p,
48254         aarch64_scalar_mode_supported_p): Also support BFmode.
48255         (aarch64_invalid_conversion, aarch64_invalid_unary_op): Remove.
48256         (aarch64_invalid_binary_op): Remove BFmode related rejections.
48257         (TARGET_INVALID_CONVERSION, TARGET_INVALID_UNARY_OP): Don't redefine.
48258         * config/aarch64/aarch64-builtins.cc (aarch64_bf16_type_node): Remove.
48259         (aarch64_int_or_fp_type): Use bfloat16_type_node rather than
48260         aarch64_bf16_type_node.
48261         (aarch64_init_simd_builtin_types): Likewise.
48262         (aarch64_init_bf16_types): Likewise.  Don't create bfloat16_type_node,
48263         which is created in tree.cc already.
48264         * config/aarch64/aarch64-sve-builtins.def (svbfloat16_t): Likewise.
48266 2023-03-12  Roger Sayle  <roger@nextmovesoftware.com>
48268         PR middle-end/109031
48269         * tree-chrec.cc (chrec_apply): When folding "{a, +, a} (x-1)",
48270         ensure that the type of x is as wide or wider than the type of a.
48272 2023-03-12  Tamar Christina  <tamar.christina@arm.com>
48274         PR target/108583
48275         * config/aarch64/aarch64-simd.md (@aarch64_bitmask_udiv<mode>3): Remove.
48276         (*bitmask_shift_plus<mode>): New.
48277         * config/aarch64/aarch64-sve2.md (*bitmask_shift_plus<mode>): New.
48278         (@aarch64_bitmask_udiv<mode>3): Remove.
48279         * config/aarch64/aarch64.cc
48280         (aarch64_vectorize_can_special_div_by_constant,
48281         TARGET_VECTORIZE_CAN_SPECIAL_DIV_BY_CONST): Removed.
48282         (TARGET_VECTORIZE_PREFERRED_DIV_AS_SHIFTS_OVER_MULT,
48283         aarch64_vectorize_preferred_div_as_shifts_over_mult): New.
48285 2023-03-12  Tamar Christina  <tamar.christina@arm.com>
48287         PR target/108583
48288         * target.def (preferred_div_as_shifts_over_mult): New.
48289         * doc/tm.texi.in: Document it.
48290         * doc/tm.texi: Regenerate.
48291         * targhooks.cc (default_preferred_div_as_shifts_over_mult): New.
48292         * targhooks.h (default_preferred_div_as_shifts_over_mult): New.
48293         * tree-vect-patterns.cc (vect_recog_divmod_pattern): Use it.
48295 2023-03-12  Tamar Christina  <tamar.christina@arm.com>
48296             Richard Sandiford  <richard.sandiford@arm.com>
48298         PR target/108583
48299         * tree-ssa-math-opts.cc (convert_mult_to_fma): Inhibit FMA in case not
48300         single use.
48302 2023-03-12  Tamar Christina  <tamar.christina@arm.com>
48303             Andrew MacLeod  <amacleod@redhat.com>
48305         PR target/108583
48306         * gimple-range-op.h (gimple_range_op_handler): Add maybe_non_standard.
48307         * gimple-range-op.cc (gimple_range_op_handler::gimple_range_op_handler):
48308         Use it.
48309         (gimple_range_op_handler::maybe_non_standard): New.
48310         * range-op.cc (class operator_widen_plus_signed,
48311         operator_widen_plus_signed::wi_fold, class operator_widen_plus_unsigned,
48312         operator_widen_plus_unsigned::wi_fold, class operator_widen_mult_signed,
48313         operator_widen_mult_signed::wi_fold, class operator_widen_mult_unsigned,
48314         operator_widen_mult_unsigned::wi_fold,
48315         ptr_op_widen_mult_signed, ptr_op_widen_mult_unsigned,
48316         ptr_op_widen_plus_signed, ptr_op_widen_plus_unsigned): New.
48317         * range-op.h (ptr_op_widen_mult_signed, ptr_op_widen_mult_unsigned,
48318         ptr_op_widen_plus_signed, ptr_op_widen_plus_unsigned): New
48320 2023-03-12  Tamar Christina  <tamar.christina@arm.com>
48322         PR target/108583
48323         * doc/tm.texi (TARGET_VECTORIZE_CAN_SPECIAL_DIV_BY_CONST): Remove.
48324         * doc/tm.texi.in: Likewise.
48325         * explow.cc (round_push, align_dynamic_address): Revert previous patch.
48326         * expmed.cc (expand_divmod): Likewise.
48327         * expmed.h (expand_divmod): Likewise.
48328         * expr.cc (force_operand, expand_expr_divmod): Likewise.
48329         * optabs.cc (expand_doubleword_mod, expand_doubleword_divmod): Likewise.
48330         * target.def (can_special_div_by_const): Remove.
48331         * target.h: Remove tree-core.h include
48332         * targhooks.cc (default_can_special_div_by_const): Remove.
48333         * targhooks.h (default_can_special_div_by_const): Remove.
48334         * tree-vect-generic.cc (expand_vector_operation): Remove hook.
48335         * tree-vect-patterns.cc (vect_recog_divmod_pattern): Remove hook.
48336         * tree-vect-stmts.cc (vectorizable_operation): Remove hook.
48338 2023-03-12  Sandra Loosemore  <sandra@codesourcery.com>
48340         * doc/install.texi2html: Fix issue number typo in comment.
48342 2023-03-12  Gaius Mulley  <gaiusmod2@gmail.com>
48344         * doc/gm2.texi (Elementary data types): Equivalence BOOLEAN with
48345         bool.
48347 2023-03-12  Sandra Loosemore  <sandra@codesourcery.com>
48349         * doc/invoke.texi (Optimize Options):  Add markup to
48350         description of asan-kernel-mem-intrinsic-prefix, and clarify
48351         wording slightly.
48353 2023-03-11  Gerald Pfeifer  <gerald@pfeifer.com>
48355         * doc/extend.texi (Named Address Spaces): Drop a redundant link
48356         to AVR-LibC.
48358 2023-03-11  Jeff Law  <jlaw@ventanamicro>
48360         PR web/88860
48361         * doc/extend.texi: Clarify Attribute Syntax a bit.
48363 2023-03-11  Sandra Loosemore  <sandra@codesourcery.com>
48365         * doc/install.texi (Prerequisites): Suggest using newer versions
48366         of Texinfo.
48367         (Final install): Clean up and modernize discussion of how to
48368         build or obtain the GCC manuals.
48369         * doc/install.texi2html: Update comment to point to the PR instead
48370         of "makeinfo 4.7 brokenness" (it's not specific to that version).
48372 2023-03-10  Jakub Jelinek  <jakub@redhat.com>
48374         PR target/107703
48375         * optabs.cc (expand_fix): For conversions from BFmode to integral,
48376         use shifts to convert it to SFmode first and then convert SFmode
48377         to integral.
48379 2023-03-10  Andrew Pinski  <apinski@marvell.com>
48381         * config/aarch64/aarch64.md: Add a new define_split
48382         to help combine.
48384 2023-03-10  Richard Biener  <rguenther@suse.de>
48386         * tree-ssa-structalias.cc (solve_graph): Immediately
48387         iterate self-cycles.
48389 2023-03-10  Jakub Jelinek  <jakub@redhat.com>
48391         PR tree-optimization/109008
48392         * range-op-float.cc (float_widen_lhs_range): If not
48393         -frounding-math and not IBM double double format, extend lhs
48394         range just by 0.5ulp rather than 1ulp in each direction.
48396 2023-03-10  Jakub Jelinek  <jakub@redhat.com>
48398         PR target/107998
48399         * config.gcc (x86_64-*-cygwin*): Don't add i386/t-cygwin-w64 into
48400         $tmake_file.
48401         * config/i386/t-cygwin-w64: Remove.
48403 2023-03-10  Jakub Jelinek  <jakub@redhat.com>
48405         PR plugins/108634
48406         * tree-core.h (tree_code_type, tree_code_length): For C++11 or
48407         C++14, don't declare as extern const arrays.
48408         (tree_code_type_tmpl, tree_code_length_tmpl): New types with
48409         static constexpr member arrays for C++11 or C++14.
48410         * tree.h (TREE_CODE_CLASS): For C++11 or C++14 use
48411         tree_code_type_tmpl <0>::tree_code_type instead of tree_code_type.
48412         (TREE_CODE_LENGTH): For C++11 or C++14 use
48413         tree_code_length_tmpl <0>::tree_code_length instead of
48414         tree_code_length.
48415         * tree.cc (tree_code_type, tree_code_length): Remove.
48417 2023-03-10  Jakub Jelinek  <jakub@redhat.com>
48419         PR other/108464
48420         * common.opt (fcanon-prefix-map): New option.
48421         * opts.cc: Include file-prefix-map.h.
48422         (flag_canon_prefix_map): New variable.
48423         (common_handle_option): Handle OPT_fcanon_prefix_map.
48424         (gen_command_line_string): Ignore OPT_fcanon_prefix_map.
48425         * file-prefix-map.h (flag_canon_prefix_map): Declare.
48426         * file-prefix-map.cc (struct file_prefix_map): Add canonicalize
48427         member.
48428         (add_prefix_map): Initialize canonicalize member from
48429         flag_canon_prefix_map, and if true canonicalize it using lrealpath.
48430         (remap_filename): Revert 2022-11-01 and 2022-11-07 changes,
48431         use lrealpath result only for map->canonicalize map entries.
48432         * lto-opts.cc (lto_write_options): Ignore OPT_fcanon_prefix_map.
48433         * opts-global.cc (handle_common_deferred_options): Clear
48434         flag_canon_prefix_map at the start and handle OPT_fcanon_prefix_map.
48435         * doc/invoke.texi (-fcanon-prefix-map): Document.
48436         (-ffile-prefix-map, -fdebug-prefix-map, -fprofile-prefix-map): Add
48437         see also for -fcanon-prefix-map.
48438         * doc/cppopts.texi (-fmacro-prefix-map): Likewise.
48440 2023-03-10  Jakub Jelinek  <jakub@redhat.com>
48442         PR c/108079
48443         * cgraphunit.cc (check_global_declaration): Don't warn for unused
48444         variables which have OPT_Wunused_variable warning suppressed.
48446 2023-03-10  Jakub Jelinek  <jakub@redhat.com>
48448         PR tree-optimization/109008
48449         * range-op-float.cc (float_widen_lhs_range): If lb is
48450         minimum representable finite number or ub is maximum
48451         representable finite number, instead of widening it to
48452         -inf or inf widen it to negative or positive 0x0.8p+(EMAX+1).
48453         Temporarily clear flag_finite_math_only when canonicalizing
48454         the widened range.
48456 2023-03-10  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
48458         * config/riscv/riscv-builtins.cc (riscv_gimple_fold_builtin): New function.
48459         * config/riscv/riscv-protos.h (riscv_gimple_fold_builtin): Ditto.
48460         (gimple_fold_builtin):  Ditto.
48461         * config/riscv/riscv-vector-builtins-bases.cc (class read_vl): New class.
48462         (class vleff): Ditto.
48463         (BASE): Ditto.
48464         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
48465         * config/riscv/riscv-vector-builtins-functions.def (read_vl): Ditto.
48466         (vleff): Ditto.
48467         * config/riscv/riscv-vector-builtins-shapes.cc (struct read_vl_def): Ditto.
48468         (struct fault_load_def): Ditto.
48469         (SHAPE): Ditto.
48470         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
48471         * config/riscv/riscv-vector-builtins.cc
48472         (rvv_arg_type_info::get_tree_type): Add size_ptr.
48473         (gimple_folder::gimple_folder): New class.
48474         (gimple_folder::fold): Ditto.
48475         (gimple_fold_builtin): New function.
48476         (get_read_vl_instance): Ditto.
48477         (get_read_vl_decl): Ditto.
48478         * config/riscv/riscv-vector-builtins.def (size_ptr): Add size_ptr.
48479         * config/riscv/riscv-vector-builtins.h (class gimple_folder): New class.
48480         (get_read_vl_instance): New function.
48481         (get_read_vl_decl):  Ditto.
48482         * config/riscv/riscv-vsetvl.cc (fault_first_load_p): Ditto.
48483         (read_vl_insn_p): Ditto.
48484         (available_occurrence_p): Ditto.
48485         (backward_propagate_worthwhile_p): Ditto.
48486         (gen_vsetvl_pat): Adapt for vleff support.
48487         (get_forward_read_vl_insn): New function.
48488         (get_backward_fault_first_load_insn): Ditto.
48489         (source_equal_p): Adapt for vleff support.
48490         (first_ratio_invalid_for_second_sew_p): Remove.
48491         (first_ratio_invalid_for_second_lmul_p): Ditto.
48492         (first_lmul_less_than_second_lmul_p): Ditto.
48493         (first_ratio_less_than_second_ratio_p): Ditto.
48494         (support_relaxed_compatible_p): New function.
48495         (vector_insn_info::operator>): Remove.
48496         (vector_insn_info::operator>=): Refine.
48497         (vector_insn_info::parse_insn): Adapt for vleff support.
48498         (vector_insn_info::compatible_p): Ditto.
48499         (vector_insn_info::update_fault_first_load_avl): New function.
48500         (pass_vsetvl::transfer_after): Adapt for vleff support.
48501         (pass_vsetvl::demand_fusion): Ditto.
48502         (pass_vsetvl::cleanup_insns): Ditto.
48503         * config/riscv/riscv-vsetvl.def (DEF_INCOMPATIBLE_COND): Remove
48504         redundant condtions.
48505         * config/riscv/riscv-vsetvl.h (struct demands_cond): New function.
48506         * config/riscv/riscv.cc (TARGET_GIMPLE_FOLD_BUILTIN): New target hook.
48507         * config/riscv/riscv.md: Adapt for vleff support.
48508         * config/riscv/t-riscv: Ditto.
48509         * config/riscv/vector-iterators.md: New iterator.
48510         * config/riscv/vector.md (read_vlsi): New pattern.
48511         (read_vldi_zero_extend): Ditto.
48512         (@pred_fault_load<mode>): Ditto.
48514 2023-03-10  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
48516         * config/riscv/riscv-vector-builtins.cc
48517         (function_expander::use_ternop_insn): Use maybe_gen_insn instead.
48518         (function_expander::use_widen_ternop_insn): Ditto.
48519         * optabs.cc (maybe_gen_insn): Extend nops handling.
48521 2023-03-10  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
48523         * config/riscv/riscv-vector-builtins-bases.cc: Split indexed load
48524         patterns according to RVV ISA.
48525         * config/riscv/vector-iterators.md: New iterators.
48526         * config/riscv/vector.md
48527         (@pred_indexed_<order>load<VNX1_QHSD:mode><VNX1_QHSDI:mode>): Remove.
48528         (@pred_indexed_<order>load<mode>_same_eew): New pattern.
48529         (@pred_indexed_<order>load<mode>_x2_greater_eew): Ditto.
48530         (@pred_indexed_<order>load<mode>_x4_greater_eew): Ditto.
48531         (@pred_indexed_<order>load<mode>_x8_greater_eew): Ditto.
48532         (@pred_indexed_<order>load<mode>_x2_smaller_eew): Ditto.
48533         (@pred_indexed_<order>load<mode>_x4_smaller_eew): Ditto.
48534         (@pred_indexed_<order>load<mode>_x8_smaller_eew): Ditto.
48535         (@pred_indexed_<order>load<VNX2_QHSD:mode><VNX2_QHSDI:mode>): Remove.
48536         (@pred_indexed_<order>load<VNX4_QHSD:mode><VNX4_QHSDI:mode>): Ditto.
48537         (@pred_indexed_<order>load<VNX8_QHSD:mode><VNX8_QHSDI:mode>): Ditto.
48538         (@pred_indexed_<order>load<VNX16_QHS:mode><VNX16_QHSI:mode>): Ditto.
48539         (@pred_indexed_<order>load<VNX32_QH:mode><VNX32_QHI:mode>): Ditto.
48540         (@pred_indexed_<order>load<VNX64_Q:mode><VNX64_Q:mode>): Ditto.
48542 2023-03-10  Michael Collison  <collison@rivosinc.com>
48544         * tree-vect-loop-manip.cc (vect_do_peeling): Use
48545         result of constant_lower_bound instead of vf for the lower
48546         bound of the epilog loop trip count.
48548 2023-03-09  Tamar Christina  <tamar.christina@arm.com>
48550         * passes.cc (emergency_dump_function): Finish graph generation.
48552 2023-03-09  Tamar Christina  <tamar.christina@arm.com>
48554         * config/aarch64/aarch64.md (tbranch_<code><mode>3): Restrict to SHORT
48555         and bottom bit only.
48557 2023-03-09  Andrew Pinski  <apinski@marvell.com>
48559         PR tree-optimization/108980
48560         * gimple-array-bounds.cc (array_bounds_checker::check_array_ref):
48561         Reorgnize the call to warning for not strict flexible arrays
48562         to be before the check of warned.
48564 2023-03-09  Jason Merrill  <jason@redhat.com>
48566         * doc/extend.texi: Comment out __is_deducible docs.
48568 2023-03-09  Jason Merrill  <jason@redhat.com>
48570         PR c++/105841
48571         * doc/extend.texi (Type Traits):: Document __is_deducible.
48573 2023-03-09  Costas Argyris  <costas.argyris@gmail.com>
48575         PR driver/108865
48576         * config.host: add object for x86_64-*-mingw*.
48577         * config/i386/sym-mingw32.cc: dummy file to attach
48578         symbol.
48579         * config/i386/utf8-mingw32.rc: windres resource file.
48580         * config/i386/winnt-utf8.manifest: XML manifest to
48581         enable UTF-8.
48582         * config/i386/x-mingw32: reference to x-mingw32-utf8.
48583         * config/i386/x-mingw32-utf8: Makefile fragment to
48584         embed UTF-8 manifest.
48586 2023-03-09  Vladimir N. Makarov  <vmakarov@redhat.com>
48588         * lra-constraints.cc (process_alt_operands): Use operand modes for
48589         clobbered regs instead of the biggest access mode.
48591 2023-03-09  Richard Biener  <rguenther@suse.de>
48593         PR middle-end/108995
48594         * fold-const.cc (extract_muldiv_1): Avoid folding
48595         (CST * b) / CST2 when sanitizing overflow and we rely on
48596         overflow being undefined.
48598 2023-03-09  Jakub Jelinek  <jakub@redhat.com>
48599             Richard Biener  <rguenther@suse.de>
48601         PR tree-optimization/109008
48602         * range-op-float.cc (float_widen_lhs_range): New function.
48603         (foperator_plus::op1_range, foperator_minus::op1_range,
48604         foperator_minus::op2_range, foperator_mult::op1_range,
48605         foperator_div::op1_range, foperator_div::op2_range): Use it.
48607 2023-03-07  Jonathan Grant  <jg@jguk.org>
48609         PR sanitizer/81649
48610         * doc/invoke.texi (Instrumentation Options):  Clarify
48611         LeakSanitizer behavior.
48613 2023-03-07  Benson Muite  <benson_muite@emailplus.org>
48615         * doc/install.texi (Prerequisites): Add link to gmplib.org.
48617 2023-03-07  Pan Li  <pan2.li@intel.com>
48618             Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
48620         PR target/108185
48621         PR target/108654
48622         * config/riscv/riscv-modes.def (ADJUST_PRECISION): Adjust VNx*BI
48623         modes.
48624         * config/riscv/riscv.cc (riscv_v_adjust_precision): New.
48625         * config/riscv/riscv.h (riscv_v_adjust_precision): New.
48626         * genmodes.cc (adj_precision): New.
48627         (ADJUST_PRECISION): New.
48628         (emit_mode_adjustments): Handle ADJUST_PRECISION.
48630 2023-03-07  Hans-Peter Nilsson  <hp@axis.com>
48632         * doc/sourcebuild.texi: Document check_effective_target_tail_call.
48634 2023-03-06  Paul-Antoine Arras  <pa@codesourcery.com>
48636         * config/gcn/gcn-valu.md (<expander><mode>3_exec): Add patterns for
48637         {s|u}{max|min} in QI, HI and DI modes.
48638         (<expander><mode>3): Add pattern for {s|u}{max|min} in DI mode.
48639         (cond_<fexpander><mode>): Add pattern for cond_f{max|min}.
48640         (cond_<expander><mode>): Add pattern for cond_{s|u}{max|min}.
48641         * config/gcn/gcn.cc (gcn_spill_class): Allow the exec register to be
48642         saved in SGPRs.
48644 2023-03-06  Richard Biener  <rguenther@suse.de>
48646         PR tree-optimization/109025
48647         * tree-vect-loop.cc (vect_is_simple_reduction): Verify
48648         the inner LC PHI use is the inner loop PHI latch definition
48649         before classifying an outer PHI as double reduction.
48651 2023-03-06  Jan Hubicka  <hubicka@ucw.cz>
48653         PR target/108429
48654         * config/i386/x86-tune.def (X86_TUNE_USE_SCATTER_2PARTS): Enable for
48655         generic.
48656         (X86_TUNE_USE_SCATTER_4PARTS): Likewise.
48657         (X86_TUNE_USE_SCATTER): Likewise.
48659 2023-03-06  Xi Ruoyao  <xry111@xry111.site>
48661         PR target/109000
48662         * config/loongarch/loongarch.h (FP_RETURN): Use
48663         TARGET_*_FLOAT_ABI instead of TARGET_*_FLOAT.
48664         (UNITS_PER_FP_ARG): Likewise.
48666 2023-03-05  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
48668         * config/riscv/riscv-vsetvl.cc (reg_available_p): Fix bug.
48669         (pass_vsetvl::backward_demand_fusion): Ditto.
48671 2023-03-05  Liao Shihua  <shihua@iscas.ac.cn>
48672             SiYu Wu  <siyu@isrc.iscas.ac.cn>
48674         * config/riscv/crypto.md (riscv_sm3p0_<mode>): Add ZKSED's and ZKSH's
48675         instructions.
48676         (riscv_sm3p1_<mode>): New.
48677         (riscv_sm4ed_<mode>): New.
48678         (riscv_sm4ks_<mode>): New.
48679         * config/riscv/riscv-builtins.cc (AVAIL): Add ZKSED's and ZKSH's AVAIL.
48680         * config/riscv/riscv-scalar-crypto.def (RISCV_BUILTIN): Add ZKSED's and
48681         ZKSH's built-in functions.
48683 2023-03-05  Liao Shihua  <shihua@iscas.ac.cn>
48684             SiYu Wu  <siyu@isrc.iscas.ac.cn>
48686         * config/riscv/crypto.md (riscv_sha256sig0_<mode>): Add ZKNH's instructions.
48687         (riscv_sha256sig1_<mode>): New.
48688         (riscv_sha256sum0_<mode>): New.
48689         (riscv_sha256sum1_<mode>): New.
48690         (riscv_sha512sig0h): New.
48691         (riscv_sha512sig0l): New.
48692         (riscv_sha512sig1h): New.
48693         (riscv_sha512sig1l): New.
48694         (riscv_sha512sum0r): New.
48695         (riscv_sha512sum1r): New.
48696         (riscv_sha512sig0): New.
48697         (riscv_sha512sig1): New.
48698         (riscv_sha512sum0): New.
48699         (riscv_sha512sum1): New.
48700         * config/riscv/riscv-builtins.cc (AVAIL): And ZKNH's AVAIL.
48701         * config/riscv/riscv-scalar-crypto.def (RISCV_BUILTIN): And ZKNH's
48702         built-in functions.
48703         (DIRECT_BUILTIN): Add new.
48705 2023-03-05  Liao Shihua  <shihua@iscas.ac.cn>
48706             SiYu Wu  <siyu@isrc.iscas.ac.cn>
48708         * config/riscv/constraints.md (D03): Add constants of bs and rnum.
48709         (DsA): New.
48710         * config/riscv/crypto.md (riscv_aes32dsi): Add ZKND's and ZKNE's instructions.
48711         (riscv_aes32dsmi): New.
48712         (riscv_aes64ds): New.
48713         (riscv_aes64dsm): New.
48714         (riscv_aes64im): New.
48715         (riscv_aes64ks1i): New.
48716         (riscv_aes64ks2): New.
48717         (riscv_aes32esi): New.
48718         (riscv_aes32esmi): New.
48719         (riscv_aes64es): New.
48720         (riscv_aes64esm): New.
48721         * config/riscv/riscv-builtins.cc (AVAIL): Add ZKND's and ZKNE's AVAIL.
48722         * config/riscv/riscv-scalar-crypto.def (DIRECT_BUILTIN): Add ZKND's and
48723         ZKNE's built-in functions.
48725 2023-03-05  Liao Shihua  <shihua@iscas.ac.cn>
48726             SiYu Wu  <siyu@isrc.iscas.ac.cn>
48728         * config/riscv/bitmanip.md: Add ZBKB's instructions.
48729         * config/riscv/riscv-builtins.cc (AVAIL): Add new.
48730         * config/riscv/riscv.md: Add new type for crypto instructions.
48731         * config/riscv/crypto.md: Add Scalar Cryptography extension's machine
48732         description file.
48733         * config/riscv/riscv-scalar-crypto.def: Add Scalar Cryptography
48734         extension's built-in function file.
48736 2023-03-05  Liao Shihua  <shihua@iscas.ac.cn>
48737             SiYu Wu  <siyu@isrc.iscas.ac.cn>
48739         * config/riscv/riscv-builtins.cc (RISCV_FTYPE_NAME2): New.
48740         (RISCV_FTYPE_NAME3): New.
48741         (RISCV_ATYPE_QI): New.
48742         (RISCV_ATYPE_HI): New.
48743         (RISCV_FTYPE_ATYPES2): New.
48744         (RISCV_FTYPE_ATYPES3): New.
48745         * config/riscv/riscv-ftypes.def (2): New.
48746         (3): New.
48748 2023-03-05  Vineet Gupta  <vineetg@rivosinc.com>
48750         * config/riscv/riscv.cc (riscv_rtx_costs): Fixed IN_RANGE() to
48751         use exact_log2().
48753 2023-03-05  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
48754             kito-cheng  <kito.cheng@sifive.com>
48756         * config/riscv/predicates.md (vector_any_register_operand): New predicate.
48757         * config/riscv/riscv-c.cc (riscv_check_builtin_call): New function.
48758         (riscv_register_pragmas): Add builtin function check call.
48759         * config/riscv/riscv-protos.h (RVV_VUNDEF): Adapt macro.
48760         (check_builtin_call): New function.
48761         * config/riscv/riscv-vector-builtins-bases.cc (class vundefined): New class.
48762         (class vreinterpret): Ditto.
48763         (class vlmul_ext): Ditto.
48764         (class vlmul_trunc): Ditto.
48765         (class vset): Ditto.
48766         (class vget): Ditto.
48767         (BASE): Ditto.
48768         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
48769         * config/riscv/riscv-vector-builtins-functions.def (vluxei8): Change name.
48770         (vluxei16): Ditto.
48771         (vluxei32): Ditto.
48772         (vluxei64): Ditto.
48773         (vloxei8): Ditto.
48774         (vloxei16): Ditto.
48775         (vloxei32): Ditto.
48776         (vloxei64): Ditto.
48777         (vsuxei8): Ditto.
48778         (vsuxei16): Ditto.
48779         (vsuxei32): Ditto.
48780         (vsuxei64): Ditto.
48781         (vsoxei8): Ditto.
48782         (vsoxei16): Ditto.
48783         (vsoxei32): Ditto.
48784         (vsoxei64): Ditto.
48785         (vundefined): Add new intrinsic.
48786         (vreinterpret): Ditto.
48787         (vlmul_ext): Ditto.
48788         (vlmul_trunc): Ditto.
48789         (vset): Ditto.
48790         (vget): Ditto.
48791         * config/riscv/riscv-vector-builtins-shapes.cc (struct return_mask_def): New class.
48792         (struct narrow_alu_def): Ditto.
48793         (struct reduc_alu_def): Ditto.
48794         (struct vundefined_def): Ditto.
48795         (struct misc_def): Ditto.
48796         (struct vset_def): Ditto.
48797         (struct vget_def): Ditto.
48798         (SHAPE): Ditto.
48799         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
48800         * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_EEW8_INTERPRET_OPS): New def.
48801         (DEF_RVV_EEW16_INTERPRET_OPS): Ditto.
48802         (DEF_RVV_EEW32_INTERPRET_OPS): Ditto.
48803         (DEF_RVV_EEW64_INTERPRET_OPS): Ditto.
48804         (DEF_RVV_X2_VLMUL_EXT_OPS): Ditto.
48805         (DEF_RVV_X4_VLMUL_EXT_OPS): Ditto.
48806         (DEF_RVV_X8_VLMUL_EXT_OPS): Ditto.
48807         (DEF_RVV_X16_VLMUL_EXT_OPS): Ditto.
48808         (DEF_RVV_X32_VLMUL_EXT_OPS): Ditto.
48809         (DEF_RVV_X64_VLMUL_EXT_OPS): Ditto.
48810         (DEF_RVV_LMUL1_OPS): Ditto.
48811         (DEF_RVV_LMUL2_OPS): Ditto.
48812         (DEF_RVV_LMUL4_OPS): Ditto.
48813         (vint16mf4_t): Ditto.
48814         (vint16mf2_t): Ditto.
48815         (vint16m1_t): Ditto.
48816         (vint16m2_t): Ditto.
48817         (vint16m4_t): Ditto.
48818         (vint16m8_t): Ditto.
48819         (vint32mf2_t): Ditto.
48820         (vint32m1_t): Ditto.
48821         (vint32m2_t): Ditto.
48822         (vint32m4_t): Ditto.
48823         (vint32m8_t): Ditto.
48824         (vint64m1_t): Ditto.
48825         (vint64m2_t): Ditto.
48826         (vint64m4_t): Ditto.
48827         (vint64m8_t): Ditto.
48828         (vuint16mf4_t): Ditto.
48829         (vuint16mf2_t): Ditto.
48830         (vuint16m1_t): Ditto.
48831         (vuint16m2_t): Ditto.
48832         (vuint16m4_t): Ditto.
48833         (vuint16m8_t): Ditto.
48834         (vuint32mf2_t): Ditto.
48835         (vuint32m1_t): Ditto.
48836         (vuint32m2_t): Ditto.
48837         (vuint32m4_t): Ditto.
48838         (vuint32m8_t): Ditto.
48839         (vuint64m1_t): Ditto.
48840         (vuint64m2_t): Ditto.
48841         (vuint64m4_t): Ditto.
48842         (vuint64m8_t): Ditto.
48843         (vint8mf4_t): Ditto.
48844         (vint8mf2_t): Ditto.
48845         (vint8m1_t): Ditto.
48846         (vint8m2_t): Ditto.
48847         (vint8m4_t): Ditto.
48848         (vint8m8_t): Ditto.
48849         (vuint8mf4_t): Ditto.
48850         (vuint8mf2_t): Ditto.
48851         (vuint8m1_t): Ditto.
48852         (vuint8m2_t): Ditto.
48853         (vuint8m4_t): Ditto.
48854         (vuint8m8_t): Ditto.
48855         (vint8mf8_t): Ditto.
48856         (vuint8mf8_t): Ditto.
48857         (vfloat32mf2_t): Ditto.
48858         (vfloat32m1_t): Ditto.
48859         (vfloat32m2_t): Ditto.
48860         (vfloat32m4_t): Ditto.
48861         (vfloat64m1_t): Ditto.
48862         (vfloat64m2_t): Ditto.
48863         (vfloat64m4_t): Ditto.
48864         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_TYPE): Ditto.
48865         (DEF_RVV_EEW8_INTERPRET_OPS): Ditto.
48866         (DEF_RVV_EEW16_INTERPRET_OPS): Ditto.
48867         (DEF_RVV_EEW32_INTERPRET_OPS): Ditto.
48868         (DEF_RVV_EEW64_INTERPRET_OPS): Ditto.
48869         (DEF_RVV_X2_VLMUL_EXT_OPS): Ditto.
48870         (DEF_RVV_X4_VLMUL_EXT_OPS): Ditto.
48871         (DEF_RVV_X8_VLMUL_EXT_OPS): Ditto.
48872         (DEF_RVV_X16_VLMUL_EXT_OPS): Ditto.
48873         (DEF_RVV_X32_VLMUL_EXT_OPS): Ditto.
48874         (DEF_RVV_X64_VLMUL_EXT_OPS): Ditto.
48875         (DEF_RVV_LMUL1_OPS): Ditto.
48876         (DEF_RVV_LMUL2_OPS): Ditto.
48877         (DEF_RVV_LMUL4_OPS): Ditto.
48878         (DEF_RVV_TYPE_INDEX): Ditto.
48879         (required_extensions_p): Adapt for new intrinsic support/
48880         (get_required_extensions): New function.
48881         (check_required_extensions): Ditto.
48882         (unsigned_base_type_p): Remove.
48883         (rvv_arg_type_info::get_scalar_ptr_type): New function.
48884         (get_mode_for_bitsize): Remove.
48885         (rvv_arg_type_info::get_scalar_const_ptr_type): New function.
48886         (rvv_arg_type_info::get_base_vector_type): Ditto.
48887         (rvv_arg_type_info::get_function_type_index): Ditto.
48888         (DEF_RVV_BASE_TYPE): New def.
48889         (function_builder::apply_predication): New class.
48890         (function_expander::mask_mode): Ditto.
48891         (function_checker::function_checker): Ditto.
48892         (function_checker::report_non_ice): Ditto.
48893         (function_checker::report_out_of_range): Ditto.
48894         (function_checker::require_immediate): Ditto.
48895         (function_checker::require_immediate_range): Ditto.
48896         (function_checker::check): Ditto.
48897         (check_builtin_call): Ditto.
48898         * config/riscv/riscv-vector-builtins.def (DEF_RVV_TYPE): New def.
48899         (DEF_RVV_BASE_TYPE): Ditto.
48900         (DEF_RVV_TYPE_INDEX): Ditto.
48901         (vbool64_t): Ditto.
48902         (vbool32_t): Ditto.
48903         (vbool16_t): Ditto.
48904         (vbool8_t): Ditto.
48905         (vbool4_t): Ditto.
48906         (vbool2_t): Ditto.
48907         (vbool1_t): Ditto.
48908         (vuint8mf8_t): Ditto.
48909         (vuint8mf4_t): Ditto.
48910         (vuint8mf2_t): Ditto.
48911         (vuint8m1_t): Ditto.
48912         (vuint8m2_t): Ditto.
48913         (vint8m4_t): Ditto.
48914         (vuint8m4_t): Ditto.
48915         (vint8m8_t): Ditto.
48916         (vuint8m8_t): Ditto.
48917         (vint16mf4_t): Ditto.
48918         (vuint16mf2_t): Ditto.
48919         (vuint16m1_t): Ditto.
48920         (vuint16m2_t): Ditto.
48921         (vuint16m4_t): Ditto.
48922         (vuint16m8_t): Ditto.
48923         (vint32mf2_t): Ditto.
48924         (vuint32m1_t): Ditto.
48925         (vuint32m2_t): Ditto.
48926         (vuint32m4_t): Ditto.
48927         (vuint32m8_t): Ditto.
48928         (vuint64m1_t): Ditto.
48929         (vuint64m2_t): Ditto.
48930         (vuint64m4_t): Ditto.
48931         (vuint64m8_t): Ditto.
48932         (vfloat32mf2_t): Ditto.
48933         (vfloat32m1_t): Ditto.
48934         (vfloat32m2_t): Ditto.
48935         (vfloat32m4_t): Ditto.
48936         (vfloat32m8_t): Ditto.
48937         (vfloat64m1_t): Ditto.
48938         (vfloat64m4_t): Ditto.
48939         (vector): Move it def.
48940         (scalar): Ditto.
48941         (mask): Ditto.
48942         (signed_vector): Ditto.
48943         (unsigned_vector): Ditto.
48944         (unsigned_scalar): Ditto.
48945         (vector_ptr): Ditto.
48946         (scalar_ptr): Ditto.
48947         (scalar_const_ptr): Ditto.
48948         (void): Ditto.
48949         (size): Ditto.
48950         (ptrdiff): Ditto.
48951         (unsigned_long): Ditto.
48952         (long): Ditto.
48953         (eew8_index): Ditto.
48954         (eew16_index): Ditto.
48955         (eew32_index): Ditto.
48956         (eew64_index): Ditto.
48957         (shift_vector): Ditto.
48958         (double_trunc_vector): Ditto.
48959         (quad_trunc_vector): Ditto.
48960         (oct_trunc_vector): Ditto.
48961         (double_trunc_scalar): Ditto.
48962         (double_trunc_signed_vector): Ditto.
48963         (double_trunc_unsigned_vector): Ditto.
48964         (double_trunc_unsigned_scalar): Ditto.
48965         (double_trunc_float_vector): Ditto.
48966         (float_vector): Ditto.
48967         (lmul1_vector): Ditto.
48968         (widen_lmul1_vector): Ditto.
48969         (eew8_interpret): Ditto.
48970         (eew16_interpret): Ditto.
48971         (eew32_interpret): Ditto.
48972         (eew64_interpret): Ditto.
48973         (vlmul_ext_x2): Ditto.
48974         (vlmul_ext_x4): Ditto.
48975         (vlmul_ext_x8): Ditto.
48976         (vlmul_ext_x16): Ditto.
48977         (vlmul_ext_x32): Ditto.
48978         (vlmul_ext_x64): Ditto.
48979         * config/riscv/riscv-vector-builtins.h (DEF_RVV_BASE_TYPE): New def.
48980         (struct function_type_info): New function.
48981         (struct rvv_arg_type_info): Ditto.
48982         (class function_checker): New class.
48983         (rvv_arg_type_info::get_scalar_type): New function.
48984         (rvv_arg_type_info::get_vector_type): Ditto.
48985         (function_expander::ret_mode): New function.
48986         (function_checker::arg_mode): Ditto.
48987         (function_checker::ret_mode): Ditto.
48988         * config/riscv/t-riscv: Add generator.
48989         * config/riscv/vector-iterators.md: New iterators.
48990         * config/riscv/vector.md (vundefined<mode>): New pattern.
48991         (@vundefined<mode>): Ditto.
48992         (@vreinterpret<mode>): Ditto.
48993         (@vlmul_extx2<mode>): Ditto.
48994         (@vlmul_extx4<mode>): Ditto.
48995         (@vlmul_extx8<mode>): Ditto.
48996         (@vlmul_extx16<mode>): Ditto.
48997         (@vlmul_extx32<mode>): Ditto.
48998         (@vlmul_extx64<mode>): Ditto.
48999         (*vlmul_extx2<mode>): Ditto.
49000         (*vlmul_extx4<mode>): Ditto.
49001         (*vlmul_extx8<mode>): Ditto.
49002         (*vlmul_extx16<mode>): Ditto.
49003         (*vlmul_extx32<mode>): Ditto.
49004         (*vlmul_extx64<mode>): Ditto.
49005         * config/riscv/genrvv-type-indexer.cc: New file.
49007 2023-03-05  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
49009         * config/riscv/riscv-protos.h (enum vlen_enum): New enum.
49010         (slide1_sew64_helper): New function.
49011         * config/riscv/riscv-v.cc (compute_vlmax): Ditto.
49012         (get_unknown_min_value): Ditto.
49013         (force_vector_length_operand): Ditto.
49014         (gen_no_side_effects_vsetvl_rtx): Ditto.
49015         (get_vl_x2_rtx): Ditto.
49016         (slide1_sew64_helper): Ditto.
49017         * config/riscv/riscv-vector-builtins-bases.cc (class slideop): New class.
49018         (class vrgather): Ditto.
49019         (class vrgatherei16): Ditto.
49020         (class vcompress): Ditto.
49021         (BASE): Ditto.
49022         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
49023         * config/riscv/riscv-vector-builtins-functions.def (vslideup): Ditto.
49024         (vslidedown): Ditto.
49025         (vslide1up): Ditto.
49026         (vslide1down): Ditto.
49027         (vfslide1up): Ditto.
49028         (vfslide1down): Ditto.
49029         (vrgather): Ditto.
49030         (vrgatherei16): Ditto.
49031         (vcompress): Ditto.
49032         * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_EI16_OPS): New macro.
49033         (vint8mf8_t): Ditto.
49034         (vint8mf4_t): Ditto.
49035         (vint8mf2_t): Ditto.
49036         (vint8m1_t): Ditto.
49037         (vint8m2_t): Ditto.
49038         (vint8m4_t): Ditto.
49039         (vint16mf4_t): Ditto.
49040         (vint16mf2_t): Ditto.
49041         (vint16m1_t): Ditto.
49042         (vint16m2_t): Ditto.
49043         (vint16m4_t): Ditto.
49044         (vint16m8_t): Ditto.
49045         (vint32mf2_t): Ditto.
49046         (vint32m1_t): Ditto.
49047         (vint32m2_t): Ditto.
49048         (vint32m4_t): Ditto.
49049         (vint32m8_t): Ditto.
49050         (vint64m1_t): Ditto.
49051         (vint64m2_t): Ditto.
49052         (vint64m4_t): Ditto.
49053         (vint64m8_t): Ditto.
49054         (vuint8mf8_t): Ditto.
49055         (vuint8mf4_t): Ditto.
49056         (vuint8mf2_t): Ditto.
49057         (vuint8m1_t): Ditto.
49058         (vuint8m2_t): Ditto.
49059         (vuint8m4_t): Ditto.
49060         (vuint16mf4_t): Ditto.
49061         (vuint16mf2_t): Ditto.
49062         (vuint16m1_t): Ditto.
49063         (vuint16m2_t): Ditto.
49064         (vuint16m4_t): Ditto.
49065         (vuint16m8_t): Ditto.
49066         (vuint32mf2_t): Ditto.
49067         (vuint32m1_t): Ditto.
49068         (vuint32m2_t): Ditto.
49069         (vuint32m4_t): Ditto.
49070         (vuint32m8_t): Ditto.
49071         (vuint64m1_t): Ditto.
49072         (vuint64m2_t): Ditto.
49073         (vuint64m4_t): Ditto.
49074         (vuint64m8_t): Ditto.
49075         (vfloat32mf2_t): Ditto.
49076         (vfloat32m1_t): Ditto.
49077         (vfloat32m2_t): Ditto.
49078         (vfloat32m4_t): Ditto.
49079         (vfloat32m8_t): Ditto.
49080         (vfloat64m1_t): Ditto.
49081         (vfloat64m2_t): Ditto.
49082         (vfloat64m4_t): Ditto.
49083         (vfloat64m8_t): Ditto.
49084         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_EI16_OPS): Ditto.
49085         * config/riscv/riscv.md: Adjust RVV instruction types.
49086         * config/riscv/vector-iterators.md (down): New iterator.
49087         (=vd,vr): New attribute.
49088         (UNSPEC_VSLIDE1UP): New unspec.
49089         * config/riscv/vector.md (@pred_slide<ud><mode>): New pattern.
49090         (*pred_slide<ud><mode>): Ditto.
49091         (*pred_slide<ud><mode>_extended): Ditto.
49092         (@pred_gather<mode>): Ditto.
49093         (@pred_gather<mode>_scalar): Ditto.
49094         (@pred_gatherei16<mode>): Ditto.
49095         (@pred_compress<mode>): Ditto.
49097 2023-03-05  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
49099         * config/riscv/riscv-vector-builtins.cc: Remove void_type_node.
49101 2023-03-05  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
49103         * config/riscv/constraints.md (Wb1): New constraint.
49104         * config/riscv/predicates.md
49105         (vector_least_significant_set_mask_operand): New predicate.
49106         (vector_broadcast_mask_operand): Ditto.
49107         * config/riscv/riscv-protos.h (enum vlmul_type): Adjust.
49108         (gen_scalar_move_mask): New function.
49109         * config/riscv/riscv-v.cc (gen_scalar_move_mask): Ditto.
49110         * config/riscv/riscv-vector-builtins-bases.cc (class vmv): New class.
49111         (class vmv_s): Ditto.
49112         (BASE): Ditto.
49113         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
49114         * config/riscv/riscv-vector-builtins-functions.def (vmv_x): Ditto.
49115         (vmv_s): Ditto.
49116         (vfmv_f): Ditto.
49117         (vfmv_s): Ditto.
49118         * config/riscv/riscv-vector-builtins-shapes.cc (struct scalar_move_def): Ditto.
49119         (SHAPE): Ditto.
49120         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
49121         * config/riscv/riscv-vector-builtins.cc (function_expander::mask_mode): Ditto.
49122         (function_expander::use_exact_insn): New function.
49123         (function_expander::use_contiguous_load_insn): New function.
49124         (function_expander::use_contiguous_store_insn): New function.
49125         (function_expander::use_ternop_insn): New function.
49126         (function_expander::use_widen_ternop_insn): New function.
49127         (function_expander::use_scalar_move_insn): New function.
49128         * config/riscv/riscv-vector-builtins.def (s): New operand suffix.
49129         * config/riscv/riscv-vector-builtins.h
49130         (function_expander::add_scalar_move_mask_operand): New class.
49131         * config/riscv/riscv-vsetvl.cc (ignore_vlmul_insn_p): New function.
49132         (scalar_move_insn_p): Ditto.
49133         (has_vsetvl_killed_avl_p): Ditto.
49134         (anticipatable_occurrence_p): Ditto.
49135         (insert_vsetvl): Ditto.
49136         (get_vl_vtype_info): Ditto.
49137         (calculate_sew): Ditto.
49138         (calculate_vlmul): Ditto.
49139         (incompatible_avl_p): Ditto.
49140         (different_sew_p): Ditto.
49141         (different_lmul_p): Ditto.
49142         (different_ratio_p): Ditto.
49143         (different_tail_policy_p): Ditto.
49144         (different_mask_policy_p): Ditto.
49145         (possible_zero_avl_p): Ditto.
49146         (first_ratio_invalid_for_second_sew_p): Ditto.
49147         (first_ratio_invalid_for_second_lmul_p): Ditto.
49148         (second_ratio_invalid_for_first_sew_p): Ditto.
49149         (second_ratio_invalid_for_first_lmul_p): Ditto.
49150         (second_sew_less_than_first_sew_p): Ditto.
49151         (first_sew_less_than_second_sew_p): Ditto.
49152         (compare_lmul): Ditto.
49153         (second_lmul_less_than_first_lmul_p): Ditto.
49154         (first_lmul_less_than_second_lmul_p): Ditto.
49155         (first_ratio_less_than_second_ratio_p): Ditto.
49156         (second_ratio_less_than_first_ratio_p): Ditto.
49157         (DEF_INCOMPATIBLE_COND): Ditto.
49158         (greatest_sew): Ditto.
49159         (first_sew): Ditto.
49160         (second_sew): Ditto.
49161         (first_vlmul): Ditto.
49162         (second_vlmul): Ditto.
49163         (first_ratio): Ditto.
49164         (second_ratio): Ditto.
49165         (vlmul_for_first_sew_second_ratio): Ditto.
49166         (ratio_for_second_sew_first_vlmul): Ditto.
49167         (DEF_SEW_LMUL_FUSE_RULE): Ditto.
49168         (always_unavailable): Ditto.
49169         (avl_unavailable_p): Ditto.
49170         (sew_unavailable_p): Ditto.
49171         (lmul_unavailable_p): Ditto.
49172         (ge_sew_unavailable_p): Ditto.
49173         (ge_sew_lmul_unavailable_p): Ditto.
49174         (ge_sew_ratio_unavailable_p): Ditto.
49175         (DEF_UNAVAILABLE_COND): Ditto.
49176         (same_sew_lmul_demand_p): Ditto.
49177         (propagate_avl_across_demands_p): Ditto.
49178         (reg_available_p): Ditto.
49179         (avl_info::has_non_zero_avl): Ditto.
49180         (vl_vtype_info::has_non_zero_avl): Ditto.
49181         (vector_insn_info::operator>=): Refactor.
49182         (vector_insn_info::parse_insn): Adjust for scalar move.
49183         (vector_insn_info::demand_vl_vtype): Remove.
49184         (vector_insn_info::compatible_p): New function.
49185         (vector_insn_info::compatible_avl_p): Ditto.
49186         (vector_insn_info::compatible_vtype_p): Ditto.
49187         (vector_insn_info::available_p): Ditto.
49188         (vector_insn_info::merge): Ditto.
49189         (vector_insn_info::fuse_avl): Ditto.
49190         (vector_insn_info::fuse_sew_lmul): Ditto.
49191         (vector_insn_info::fuse_tail_policy): Ditto.
49192         (vector_insn_info::fuse_mask_policy): Ditto.
49193         (vector_insn_info::dump): Ditto.
49194         (vector_infos_manager::release): Ditto.
49195         (pass_vsetvl::compute_local_backward_infos): Adjust for scalar move support.
49196         (pass_vsetvl::get_backward_fusion_type): Adjust for scalar move support.
49197         (pass_vsetvl::hard_empty_block_p): Ditto.
49198         (pass_vsetvl::backward_demand_fusion): Ditto.
49199         (pass_vsetvl::forward_demand_fusion): Ditto.
49200         (pass_vsetvl::refine_vsetvls): Ditto.
49201         (pass_vsetvl::cleanup_vsetvls): Ditto.
49202         (pass_vsetvl::commit_vsetvls): Ditto.
49203         (pass_vsetvl::propagate_avl): Ditto.
49204         * config/riscv/riscv-vsetvl.h (enum demand_status): New class.
49205         (struct demands_pair): Ditto.
49206         (struct demands_cond): Ditto.
49207         (struct demands_fuse_rule): Ditto.
49208         * config/riscv/vector-iterators.md: New iterator.
49209         * config/riscv/vector.md (@pred_broadcast<mode>): New pattern.
49210         (*pred_broadcast<mode>): Ditto.
49211         (*pred_broadcast<mode>_extended_scalar): Ditto.
49212         (@pred_extract_first<mode>): Ditto.
49213         (*pred_extract_first<mode>): Ditto.
49214         (@pred_extract_first_trunc<mode>): Ditto.
49215         * config/riscv/riscv-vsetvl.def: New file.
49217 2023-03-05  Lin Sinan  <sinan.lin@linux.alibaba.com>
49219         * config/riscv/bitmanip.md: allow 0 constant in max/min
49220         pattern.
49222 2023-03-05  Lin Sinan  <sinan.lin@linux.alibaba.com>
49224         * config/riscv/bitmanip.md: Fix wrong index in the check.
49226 2023-03-04  Jakub Jelinek  <jakub@redhat.com>
49228         PR middle-end/109006
49229         * vec.cc (test_auto_alias): Adjust comment for removal of
49230         m_vecdata.
49231         * read-rtl-function.cc (function_reader::parse_block): Likewise.
49232         * gdbhooks.py: Likewise.
49234 2023-03-04  Jakub Jelinek  <jakub@redhat.com>
49236         PR testsuite/108973
49237         * selftest-diagnostic.cc
49238         (test_diagnostic_context::test_diagnostic_context): Set
49239         caret_max_width to 80.
49241 2023-03-03  Alexandre Oliva  <oliva@adacore.com>
49243         * gimple-ssa-warn-access.cc
49244         (pass_waccess::check_dangling_stores): Skip non-stores.
49246 2023-03-03  Alexandre Oliva  <oliva@adacore.com>
49248         * config/arm/vfp.md (*thumb2_movsi_vfp): Drop blank after tab
49249         after vmsr and vmrs, and lower the case of P0.
49251 2023-03-03  Jonathan Wakely  <jwakely@redhat.com>
49253         PR middle-end/109006
49254         * gdbhooks.py (VecPrinter): Handle vec<T> as well as vec<T>*.
49256 2023-03-03  Jonathan Wakely  <jwakely@redhat.com>
49258         PR middle-end/109006
49259         * gdbhooks.py (VecPrinter): Adjust for new vec layout.
49261 2023-03-03  Jakub Jelinek  <jakub@redhat.com>
49263         PR c/108986
49264         * gimple-ssa-warn-access.cc (pass_waccess::maybe_check_access_sizes):
49265         Return immediately if OPT_Wnonnull or OPT_Wstringop_overflow_ is
49266         suppressed on stmt.  For [static %E] warning, print access_nelts
49267         rather than access_size.  Fix up comment wording.
49269 2023-03-03  Robin Dapp  <rdapp@linux.ibm.com>
49271         * config/s390/driver-native.cc (s390_host_detect_local_cpu): Use
49272         arch14 instead of z16.
49274 2023-03-03  Anthony Green  <green@moxielogic.com>
49276         * config/moxie/moxie.cc (TARGET_LRA_P): Remove.
49278 2023-03-03  Anthony Green  <green@moxielogic.com>
49280         * config/moxie/constraints.md (A, B, W): Change
49281         define_constraint to define_memory_constraint.
49283 2023-03-03  Xi Ruoyao  <xry111@xry111.site>
49285         * toplev.cc (process_options): Fix the spelling of
49286         "-fstack-clash-protection".
49288 2023-03-03  Richard Biener  <rguenther@suse.de>
49290         PR tree-optimization/109002
49291         * tree-ssa-pre.cc (compute_partial_antic_aux): Properly
49292         PHI-translate ANTIC_IN.
49294 2023-03-03  Jakub Jelinek  <jakub@redhat.com>
49296         PR tree-optimization/108988
49297         * gimple-fold.cc (gimple_fold_builtin_fputs): Fold len to
49298         size_type_node before passing it as argument to fwrite.  Formatting
49299         fixes.
49301 2023-03-03  Richard Biener  <rguenther@suse.de>
49303         PR target/108738
49304         * config/i386/i386.opt (--param x86-stv-max-visits): New param.
49305         * doc/invoke.texi (--param x86-stv-max-visits): Document it.
49306         * config/i386/i386-features.h (scalar_chain::max_visits): New.
49307         (scalar_chain::build): Add bitmap parameter, return boolean.
49308         (scalar_chain::add_insn): Likewise.
49309         (scalar_chain::analyze_register_chain): Likewise.
49310         * config/i386/i386-features.cc (scalar_chain::scalar_chain):
49311         Initialize max_visits.
49312         (scalar_chain::analyze_register_chain): When we exhaust
49313         max_visits, abort.  Also abort when running into any
49314         disallowed insn.
49315         (scalar_chain::add_insn): Propagate abort.
49316         (scalar_chain::build): Likewise.  When aborting amend
49317         the set of disallowed insn with the insns set.
49318         (convert_scalars_to_vector): Adjust.  Do not convert aborted
49319         chains.
49321 2023-03-03  Richard Biener  <rguenther@suse.de>
49323         PR debug/108772
49324         * dwarf2out.cc (dwarf2out_late_global_decl): Do not
49325         generate a DIE for a function scope static.
49327 2023-03-03  Alexandre Oliva  <oliva@adacore.com>
49329         * config/vx-common.h (WINT_TYPE): Alias to "wchar_t".
49331 2023-03-02  Jakub Jelinek  <jakub@redhat.com>
49333         PR target/108883
49334         * target.h (emit_support_tinfos_callback): New typedef.
49335         * targhooks.h (default_emit_support_tinfos): Declare.
49336         * targhooks.cc (default_emit_support_tinfos): New function.
49337         * target.def (emit_support_tinfos): New target hook.
49338         * doc/tm.texi.in (emit_support_tinfos): Document it.
49339         * doc/tm.texi: Regenerated.
49340         * config/i386/i386.cc (ix86_emit_support_tinfos): New function.
49341         (TARGET_EMIT_SUPPORT_TINFOS): Redefine.
49343 2023-03-02  Vladimir N. Makarov  <vmakarov@redhat.com>
49345         * ira-costs.cc: Include print-rtl.h.
49346         (record_reg_classes, scan_one_insn): Add code to print debug info.
49347         (record_operand_costs): Find and use smaller cost for hard reg
49348         move.
49350 2023-03-02  Kwok Cheung Yeung  <kcy@codesourcery.com>
49351             Paul-Antoine Arras  <pa@codesourcery.com>
49353         * builtins.cc (mathfn_built_in_explicit): New.
49354         * config/gcn/gcn.cc: Include case-cfn-macros.h.
49355         (mathfn_built_in_explicit): Add prototype.
49356         (gcn_vectorize_builtin_vectorized_function): New.
49357         (gcn_libc_has_function): New.
49358         (TARGET_LIBC_HAS_FUNCTION): Define.
49359         (TARGET_VECTORIZE_BUILTIN_VECTORIZED_FUNCTION): Define.
49361 2023-03-02  Richard Sandiford  <richard.sandiford@arm.com>
49363         PR tree-optimization/108979
49364         * tree-vect-stmts.cc (vectorizable_operation): Don't mask
49365         operations on invariants.
49367 2023-03-02  Robin Dapp  <rdapp@linux.ibm.com>
49369         * config/s390/predicates.md (vll_bias_operand): Add -1 bias.
49370         * config/s390/s390.cc (s390_option_override_internal): Make
49371         partial vector usage the default from z13 on.
49372         * config/s390/vector.md (len_load_v16qi): Add.
49373         (len_store_v16qi): Add.
49375 2023-03-02  Andre Vieira  <andre.simoesdiasvieira@arm.com>
49377         * simplify-rtx.cc (simplify_context::simplify_subreg): Use byte instead
49378         of constant 0 offset.
49380 2023-03-02  Robert Suchanek  <robert.suchanek@imgtec.com>
49382         * config/mips/mips.cc (mips_set_text_contents_type): Use HOST_WIDE_INT
49383         instead of long.
49384         * config/mips/mips-protos.h (mips_set_text_contents_type): Likewise.
49386 2023-03-02  Junxian Zhu  <zhujunxian@oss.cipunited.com>
49388         * config.gcc: add -with-{no-}msa build option.
49389         * config/mips/mips.h: Likewise.
49390         * doc/install.texi: Likewise.
49392 2023-03-02  Richard Sandiford  <richard.sandiford@arm.com>
49394         PR tree-optimization/108603
49395         * explow.cc (convert_memory_address_addr_space_1): Only wrap
49396         the result of a recursive call in a CONST if no instructions
49397         were emitted.
49399 2023-03-02  Richard Sandiford  <richard.sandiford@arm.com>
49401         PR tree-optimization/108430
49402         * tree-vect-stmts.cc (vectorizable_condition): Fix handling
49403         of inverted condition.
49405 2023-03-02  Jakub Jelinek  <jakub@redhat.com>
49407         PR c++/108934
49408         * fold-const.cc (native_interpret_expr) <case REAL_CST>: Before memcmp
49409         comparison copy the bytes from ptr to a temporary buffer and clearing
49410         padding bits in there.
49412 2023-03-01  Tobias Burnus  <tobias@codesourcery.com>
49414         PR middle-end/108545
49415         * gimplify.cc (struct tree_operand_hash_no_se): New.
49416         (omp_index_mapping_groups_1, omp_index_mapping_groups,
49417         omp_reindex_mapping_groups, omp_mapped_by_containing_struct,
49418         omp_tsort_mapping_groups_1, omp_tsort_mapping_groups,
49419         oacc_resolve_clause_dependencies, omp_build_struct_sibling_lists,
49420         gimplify_scan_omp_clauses): Use tree_operand_hash_no_se instead
49421         of tree_operand_hash.
49423 2023-03-01  LIU Hao  <lh_mouse@126.com>
49425         PR pch/14940
49426         * config/i386/host-mingw32.cc (mingw32_gt_pch_get_address):
49427         Remove the size limit `pch_VA_max_size`
49429 2023-03-01  Tobias Burnus  <tobias@codesourcery.com>
49431         PR middle-end/108546
49432         * omp-low.cc (lower_omp_target): Remove optional handling
49433         on the receiver side, i.e. inside target (data), for
49434         use_device_ptr.
49436 2023-03-01  Jakub Jelinek  <jakub@redhat.com>
49438         PR debug/108967
49439         * cfgexpand.cc (expand_debug_expr): Handle WIDEN_{PLUS,MINUS}_EXPR
49440         and VEC_WIDEN_{PLUS,MINUS}_{HI,LO}_EXPR.
49442 2023-03-01  Richard Biener  <rguenther@suse.de>
49444         PR tree-optimization/108970
49445         * tree-vect-loop-manip.cc (slpeel_can_duplicate_loop_p):
49446         Check we can copy the BBs.
49447         (slpeel_tree_duplicate_loop_to_edge_cfg): Avoid redundant
49448         check.
49449         (vect_do_peeling): Streamline error handling.
49451 2023-03-01  Richard Biener  <rguenther@suse.de>
49453         PR tree-optimization/108950
49454         * tree-vect-patterns.cc (vect_recog_widen_sum_pattern):
49455         Check oprnd0 is defined in the loop.
49456         * tree-vect-loop.cc (vectorizable_reduction): Record all
49457         operands vector types, compute that of invariants and
49458         properly update their SLP nodes.
49460 2023-03-01  Kewen Lin  <linkw@linux.ibm.com>
49462         PR target/108240
49463         * config/rs6000/rs6000.cc (rs6000_option_override_internal): Allow
49464         implicit powerpc64 setting to be unset if 64 bit is enabled implicitly.
49466 2023-02-28  Qing Zhao  <qing.zhao@oracle.com>
49468         PR middle-end/107411
49469         PR middle-end/107411
49470         * gimplify.cc (gimple_add_init_for_auto_var): Use sprintf to replace
49471         xasprintf.
49472         * tree-ssa-uninit.cc (warn_uninit): Handle the case when the
49473         LHS varaible of a .DEFERRED_INIT call doesn't have a DECL_NAME.
49475 2023-02-28  Jakub Jelinek  <jakub@redhat.com>
49477         PR sanitizer/108894
49478         * ubsan.cc (ubsan_expand_bounds_ifn): Emit index >= bound
49479         comparison rather than index > bound.
49480         * gimple-fold.cc (gimple_fold_call): Use tree_int_cst_lt
49481         rather than tree_int_cst_le for IFN_UBSAN_BOUND comparison.
49482         * doc/invoke.texi (-fsanitize=bounds): Document that whether
49483         flexible array member-like arrays are instrumented or not depends
49484         on -fstrict-flex-arrays* options of strict_flex_array attributes.
49485         (-fsanitize=bounds-strict): Document that flexible array members
49486         are not instrumented.
49488 2023-02-27  Uroš Bizjak  <ubizjak@gmail.com>
49490         PR target/108922
49491         Revert:
49492         * config/i386/i386.md (fmodxf3): Enable for flag_finite_math_only only.
49493         (fmod<mode>3): Ditto.
49494         (fpremxf4_i387): Ditto.
49495         (reminderxf3): Ditto.
49496         (reminder<mode>3): Ditto.
49497         (fprem1xf4_i387): Ditto.
49499 2023-02-27  Roger Sayle  <roger@nextmovesoftware.com>
49501         * simplify-rtx.cc (simplify_unary_operation_1) <case FFS>: Avoid
49502         generating FFS with mismatched operand and result modes, by using
49503         an explicit SIGN_EXTEND/ZERO_EXTEND.
49504         <case POPCOUNT>: Likewise, for POPCOUNT of ZERO_EXTEND.
49505         <case PARITY>: Likewise, for PARITY of {ZERO,SIGN}_EXTEND.
49507 2023-02-27  Patrick Palka  <ppalka@redhat.com>
49509         * hash-table.h (gt_pch_nx(hash_table<D>)): Remove static.
49510         * lra-int.h (lra_change_class): Likewise.
49511         * recog.h (which_op_alt): Likewise.
49512         * sel-sched-ir.h (sel_bb_empty_or_nop_p): Declare inline
49513         instead of static.
49515 2023-02-27  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
49517         * config/xtensa/xtensa-protos.h (xtensa_match_CLAMPS_imms_p):
49518         New prototype.
49519         * config/xtensa/xtensa.cc (xtensa_match_CLAMPS_imms_p):
49520         New function.
49521         * config/xtensa/xtensa.h (TARGET_CLAMPS): New macro definition.
49522         * config/xtensa/xtensa.md (*xtensa_clamps): New insn pattern.
49524 2023-02-27  Max Filippov  <jcmvbkbc@gmail.com>
49526         * config/xtensa/xtensa-dynconfig.cc (xtensa_get_config_v2)
49527         (xtensa_get_config_v3): New functions.
49529 2023-02-27  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
49531         * config/aarch64/aarch64-simd.md (aarch64_abs<mode>): Fix typo in comment.
49533 2023-02-27  Lulu Cheng  <chenglulu@loongson.cn>
49535         * config/host-linux.cc (TRY_EMPTY_VM_SPACE): Modify the value of
49536         the macro to 0x1000000000.
49538 2023-02-25  Gaius Mulley  <gaiusmod2@gmail.com>
49540         PR modula2/108261
49541         * doc/gm2.texi (-fm2-pathname): New option documented.
49542         (-fm2-pathnameI): New option documented.
49543         (-fm2-prefix=): New option documented.
49544         (-fruntime-modules=): Update default module list.
49546 2023-02-25  Max Filippov  <jcmvbkbc@gmail.com>
49548         PR target/108919
49549         * config/xtensa/xtensa-protos.h
49550         (xtensa_prepare_expand_call): Rename to xtensa_expand_call.
49551         * config/xtensa/xtensa.cc (xtensa_prepare_expand_call): Rename
49552         to xtensa_expand_call.
49553         (xtensa_expand_call): Emit the call and add a clobber expression
49554         for the static chain to it in case of windowed ABI.
49555         * config/xtensa/xtensa.md (call, call_value, sibcall)
49556         (sibcall_value): Call xtensa_expand_call and complete expansion
49557         right after that call.
49559 2023-02-24  Richard Biener  <rguenther@suse.de>
49561         * vec.h (vec<T, A, vl_embed>::m_vecdata): Remove.
49562         (vec<T, A, vl_embed>::m_vecpfx): Align as T to avoid
49563         changing alignment of vec<T, A, vl_embed> and simplifying
49564         address.
49565         (vec<T, A, vl_embed>::address): Compute as this + 1.
49566         (vec<T, A, vl_embed>::embedded_size): Use sizeof the
49567         vector instead of the offset of the m_vecdata member.
49568         (auto_vec<T, N>::m_data): Turn storage into
49569         uninitialized unsigned char.
49570         (auto_vec<T, N>::auto_vec): Allow allocation of one
49571         stack member.  Initialize m_vec in a special way to
49572         avoid later stringop overflow diagnostics.
49573         * vec.cc (test_auto_alias): New.
49574         (vec_cc_tests): Call it.
49576 2023-02-24  Richard Biener  <rguenther@suse.de>
49578         * vec.h (vec<T, A, vl_embed>::lower_bound): Adjust to
49579         take a const reference to the object, use address to
49580         access data.
49581         (vec<T, A, vl_embed>::contains): Use address to access data.
49582         (vec<T, A, vl_embed>::operator[]): Use address instead of
49583         m_vecdata to access data.
49584         (vec<T, A, vl_embed>::iterate): Likewise.
49585         (vec<T, A, vl_embed>::copy): Likewise.
49586         (vec<T, A, vl_embed>::quick_push): Likewise.
49587         (vec<T, A, vl_embed>::pop): Likewise.
49588         (vec<T, A, vl_embed>::quick_insert): Likewise.
49589         (vec<T, A, vl_embed>::ordered_remove): Likewise.
49590         (vec<T, A, vl_embed>::unordered_remove): Likewise.
49591         (vec<T, A, vl_embed>::block_remove): Likewise.
49592         (vec<T, A, vl_heap>::address): Likewise.
49594 2023-02-24  Martin Liska  <mliska@suse.cz>
49596         PR sanitizer/108834
49597         * asan.cc (asan_add_global): Use proper TU name for normal
49598         global variables (and aux_base_name for the artificial one).
49600 2023-02-24  Jakub Jelinek  <jakub@redhat.com>
49602         * config/i386/i386-builtin.def: Update description of BDESC
49603         and BDESC_FIRST in file comment to include mask2.
49605 2023-02-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
49607         * config/aarch64/aarch64-cores.def (FLAGS): Update comment.
49609 2023-02-24  Jakub Jelinek  <jakub@redhat.com>
49611         PR middle-end/108854
49612         * cgraphclones.cc (duplicate_thunk_for_node): If no parameter
49613         changes are needed, copy at least DECL_ARGUMENTS PARM_DECL
49614         nodes and adjust their DECL_CONTEXT.
49616 2023-02-24  Jakub Jelinek  <jakub@redhat.com>
49618         PR target/108881
49619         * config/i386/i386-builtin.def (__builtin_ia32_cvtne2ps2bf16_v16bf,
49620         __builtin_ia32_cvtne2ps2bf16_v16bf_mask,
49621         __builtin_ia32_cvtne2ps2bf16_v16bf_maskz,
49622         __builtin_ia32_cvtne2ps2bf16_v8bf,
49623         __builtin_ia32_cvtne2ps2bf16_v8bf_mask,
49624         __builtin_ia32_cvtne2ps2bf16_v8bf_maskz,
49625         __builtin_ia32_cvtneps2bf16_v8sf_mask,
49626         __builtin_ia32_cvtneps2bf16_v8sf_maskz,
49627         __builtin_ia32_cvtneps2bf16_v4sf_mask,
49628         __builtin_ia32_cvtneps2bf16_v4sf_maskz,
49629         __builtin_ia32_dpbf16ps_v8sf, __builtin_ia32_dpbf16ps_v8sf_mask,
49630         __builtin_ia32_dpbf16ps_v8sf_maskz, __builtin_ia32_dpbf16ps_v4sf,
49631         __builtin_ia32_dpbf16ps_v4sf_mask,
49632         __builtin_ia32_dpbf16ps_v4sf_maskz): Require also
49633         OPTION_MASK_ISA_AVX512VL.
49635 2023-02-24  Sebastian Huber  <sebastian.huber@embedded-brains.de>
49637         * config/riscv/t-rtems: Keep only -mcmodel=medany 64-bit multilibs.
49638         Add non-compact 32-bit multilibs.
49640 2023-02-24  Junxian Zhu  <zhujunxian@oss.cipunited.com>
49642         * config/mips/mips.md (*clo<mode>2): New pattern.
49644 2023-02-24  Prachi Godbole  <prachi.godbole@imgtec.com>
49646         * config/mips/mips.h (machine_function): New variable
49647         use_hazard_barrier_return_p.
49648         * config/mips/mips.md (UNSPEC_JRHB): New unspec.
49649         (mips_hb_return_internal): New insn pattern.
49650         * config/mips/mips.cc (mips_attribute_table): Add attribute
49651         use_hazard_barrier_return.
49652         (mips_use_hazard_barrier_return_p): New static function.
49653         (mips_function_attr_inlinable_p): Likewise.
49654         (mips_compute_frame_info): Set use_hazard_barrier_return_p.
49655         Emit error for unsupported architecture choice.
49656         (mips_function_ok_for_sibcall, mips_can_use_return_insn):
49657         Return false for use_hazard_barrier_return.
49658         (mips_expand_epilogue): Emit hazard barrier return.
49659         * doc/extend.texi: Document use_hazard_barrier_return.
49661 2023-02-23  Max Filippov  <jcmvbkbc@gmail.com>
49663         * config/xtensa/xtensa-dynconfig.cc (config.h, system.h)
49664         (coretypes.h, diagnostic.h, intl.h): Use "..." instead of <...>
49665         for the gcc-internal headers.
49667 2023-02-23  Max Filippov  <jcmvbkbc@gmail.com>
49669         * config/xtensa/t-xtensa (xtensa-dynconfig.o): Use $(COMPILE)
49670         and $(POSTCOMPILE) instead of manual dependency listing.
49671         * config/xtensa/xtensa-dynconfig.c: Rename to ...
49672         * config/xtensa/xtensa-dynconfig.cc: ... this.
49674 2023-02-23  Arsen Arsenović  <arsen@aarsen.me>
49676         * doc/cfg.texi: Reorder index entries around @items.
49677         * doc/cpp.texi: Ditto.
49678         * doc/cppenv.texi: Ditto.
49679         * doc/cppopts.texi: Ditto.
49680         * doc/generic.texi: Ditto.
49681         * doc/install.texi: Ditto.
49682         * doc/extend.texi: Ditto.
49683         * doc/invoke.texi: Ditto.
49684         * doc/md.texi: Ditto.
49685         * doc/rtl.texi: Ditto.
49686         * doc/tm.texi.in: Ditto.
49687         * doc/trouble.texi: Ditto.
49688         * doc/tm.texi: Regenerate.
49690 2023-02-23  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
49692         * config/xtensa/xtensa.md: New peephole2 pattern that eliminates
49693         the occurrence of general-purpose register used only once and for
49694         transferring intermediate value.
49696 2023-02-23  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
49698         * config/xtensa/xtensa.cc (machine_function): Add new member
49699         'eliminated_callee_saved_bmp'.
49700         (xtensa_can_eliminate_callee_saved_reg_p): New function to
49701         determine whether the register can be eliminated or not.
49702         (xtensa_expand_prologue): Add invoking the above function and
49703         elimination the use of callee-saved register by using its stack
49704         slot through the stack pointer (or the frame pointer if needed)
49705         directly.
49706         (xtensa_expand_prologue): Modify to not emit register restoration
49707         insn from its stack slot if the register is already eliminated.
49709 2023-02-23  Jakub Jelinek  <jakub@redhat.com>
49711         PR translation/108890
49712         * config/xtensa/xtensa-dynconfig.c (xtensa_load_config): Drop _()s
49713         around fatal_error format strings.
49715 2023-02-23  Richard Biener  <rguenther@suse.de>
49717         * tree-ssa-structalias.cc (handle_lhs_call): Do not
49718         re-create rhsc, only truncate it.
49720 2023-02-23  Jakub Jelinek  <jakub@redhat.com>
49722         PR middle-end/106258
49723         * ipa-prop.cc (try_make_edge_direct_virtual_call): Handle
49724         BUILT_IN_UNREACHABLE_TRAP like BUILT_IN_UNREACHABLE.
49726 2023-02-23  Richard Biener  <rguenther@suse.de>
49728         * tree-if-conv.cc (tree_if_conversion): Properly manage
49729         memory of refs and the contained data references.
49731 2023-02-23  Richard Biener  <rguenther@suse.de>
49733         PR tree-optimization/108888
49734         * tree-if-conv.cc (if_convertible_stmt_p): Set PLF_2 on
49735         calls to predicate.
49736         (predicate_statements): Only predicate calls with PLF_2.
49738 2023-02-23  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
49740         * config/xtensa/xtensa.md
49741         (zero_cost_loop_start, zero_cost_loop_end, loop_end):
49742         Add missing "SI:" to PLUS RTXes.
49744 2023-02-23  Max Filippov  <jcmvbkbc@gmail.com>
49746         PR target/108876
49747         * config/xtensa/xtensa.cc (xtensa_expand_epilogue):
49748         Emit (use (reg:SI A0_REG)) at the end in the sibling call
49749         (i.e. the same place as (return) in the normal call).
49751 2023-02-23  Max Filippov  <jcmvbkbc@gmail.com>
49753         Revert:
49754         2023-02-21  Max Filippov  <jcmvbkbc@gmail.com>
49756         PR target/108876
49757         * config/xtensa/xtensa.cc (xtensa_expand_epilogue): Drop emit_use
49758         for A0_REG.
49759         * config/xtensa/xtensa.md (sibcall, sibcall_internal)
49760         (sibcall_value, sibcall_value_internal): Add 'use' expression
49761         for A0_REG.
49763 2023-02-23  Arsen Arsenović  <arsen@aarsen.me>
49765         * doc/cppdiropts.texi: Reorder @opindex commands to precede
49766         @items they relate to.
49767         * doc/cppopts.texi: Ditto.
49768         * doc/cppwarnopts.texi: Ditto.
49769         * doc/invoke.texi: Ditto.
49770         * doc/lto.texi: Ditto.
49772 2023-02-22  Andrew Stubbs  <ams@codesourcery.com>
49774         * internal-fn.cc (expand_MASK_CALL): New.
49775         * internal-fn.def (MASK_CALL): New.
49776         * internal-fn.h (expand_MASK_CALL): New prototype.
49777         * omp-simd-clone.cc (simd_clone_adjust_argument_types): Set vector_type
49778         for mask arguments also.
49779         * tree-if-conv.cc: Include cgraph.h.
49780         (if_convertible_stmt_p): Do if conversions for calls to SIMD calls.
49781         (predicate_statements): Convert functions to IFN_MASK_CALL.
49782         * tree-vect-loop.cc (vect_get_datarefs_in_loop): Recognise
49783         IFN_MASK_CALL as a SIMD function call.
49784         * tree-vect-stmts.cc (vectorizable_simd_clone_call): Handle
49785         IFN_MASK_CALL as an inbranch SIMD function call.
49786         Generate the mask vector arguments.
49788 2023-02-22  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
49790         * config/riscv/riscv-vector-builtins-bases.cc (class reducop): New class.
49791         (class widen_reducop): Ditto.
49792         (class freducop): Ditto.
49793         (class widen_freducop): Ditto.
49794         (BASE): Ditto.
49795         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
49796         * config/riscv/riscv-vector-builtins-functions.def (vredsum): Add reduction support.
49797         (vredmaxu): Ditto.
49798         (vredmax): Ditto.
49799         (vredminu): Ditto.
49800         (vredmin): Ditto.
49801         (vredand): Ditto.
49802         (vredor): Ditto.
49803         (vredxor): Ditto.
49804         (vwredsum): Ditto.
49805         (vwredsumu): Ditto.
49806         (vfredusum): Ditto.
49807         (vfredosum): Ditto.
49808         (vfredmax): Ditto.
49809         (vfredmin): Ditto.
49810         (vfwredosum): Ditto.
49811         (vfwredusum): Ditto.
49812         * config/riscv/riscv-vector-builtins-shapes.cc (struct reduc_alu_def): Ditto.
49813         (SHAPE): Ditto.
49814         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
49815         * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_WI_OPS): New macro.
49816         (DEF_RVV_WU_OPS): Ditto.
49817         (DEF_RVV_WF_OPS): Ditto.
49818         (vint8mf8_t): Ditto.
49819         (vint8mf4_t): Ditto.
49820         (vint8mf2_t): Ditto.
49821         (vint8m1_t): Ditto.
49822         (vint8m2_t): Ditto.
49823         (vint8m4_t): Ditto.
49824         (vint8m8_t): Ditto.
49825         (vint16mf4_t): Ditto.
49826         (vint16mf2_t): Ditto.
49827         (vint16m1_t): Ditto.
49828         (vint16m2_t): Ditto.
49829         (vint16m4_t): Ditto.
49830         (vint16m8_t): Ditto.
49831         (vint32mf2_t): Ditto.
49832         (vint32m1_t): Ditto.
49833         (vint32m2_t): Ditto.
49834         (vint32m4_t): Ditto.
49835         (vint32m8_t): Ditto.
49836         (vuint8mf8_t): Ditto.
49837         (vuint8mf4_t): Ditto.
49838         (vuint8mf2_t): Ditto.
49839         (vuint8m1_t): Ditto.
49840         (vuint8m2_t): Ditto.
49841         (vuint8m4_t): Ditto.
49842         (vuint8m8_t): Ditto.
49843         (vuint16mf4_t): Ditto.
49844         (vuint16mf2_t): Ditto.
49845         (vuint16m1_t): Ditto.
49846         (vuint16m2_t): Ditto.
49847         (vuint16m4_t): Ditto.
49848         (vuint16m8_t): Ditto.
49849         (vuint32mf2_t): Ditto.
49850         (vuint32m1_t): Ditto.
49851         (vuint32m2_t): Ditto.
49852         (vuint32m4_t): Ditto.
49853         (vuint32m8_t): Ditto.
49854         (vfloat32mf2_t): Ditto.
49855         (vfloat32m1_t): Ditto.
49856         (vfloat32m2_t): Ditto.
49857         (vfloat32m4_t): Ditto.
49858         (vfloat32m8_t): Ditto.
49859         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_WI_OPS): Ditto.
49860         (DEF_RVV_WU_OPS): Ditto.
49861         (DEF_RVV_WF_OPS): Ditto.
49862         (required_extensions_p): Add reduction support.
49863         (rvv_arg_type_info::get_base_vector_type): Ditto.
49864         (rvv_arg_type_info::get_tree_type): Ditto.
49865         * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Ditto.
49866         * config/riscv/riscv.md: Ditto.
49867         * config/riscv/vector-iterators.md (minu): Ditto.
49868         * config/riscv/vector.md (@pred_reduc_<reduc><mode><vlmul1>): New patern.
49869         (@pred_reduc_<reduc><mode><vlmul1_zve32>): Ditto.
49870         (@pred_widen_reduc_plus<v_su><mode><vwlmul1>): Ditto.
49871         (@pred_widen_reduc_plus<v_su><mode><vwlmul1_zve32>):Ditto.
49872         (@pred_reduc_plus<order><mode><vlmul1>): Ditto.
49873         (@pred_reduc_plus<order><mode><vlmul1_zve32>): Ditto.
49874         (@pred_widen_reduc_plus<order><mode><vwlmul1>): Ditto.
49876 2023-02-22  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
49878         * config/riscv/iterators.md: New iterator.
49879         * config/riscv/riscv-vector-builtins-bases.cc (class widen_binop): New class.
49880         (enum ternop_type): New enum.
49881         (class vmacc): New class.
49882         (class imac): Ditto.
49883         (class vnmsac): Ditto.
49884         (enum widen_ternop_type): New enum.
49885         (class vmadd): Ditto.
49886         (class vnmsub): Ditto.
49887         (class iwmac): Ditto.
49888         (class vwmacc): Ditto.
49889         (class vwmaccu): Ditto.
49890         (class vwmaccsu): Ditto.
49891         (class vwmaccus): Ditto.
49892         (class reverse_binop): Ditto.
49893         (class vfmacc): Ditto.
49894         (class vfnmsac): Ditto.
49895         (class vfmadd): Ditto.
49896         (class vfnmsub): Ditto.
49897         (class vfnmacc): Ditto.
49898         (class vfmsac): Ditto.
49899         (class vfnmadd): Ditto.
49900         (class vfmsub): Ditto.
49901         (class vfwmacc): Ditto.
49902         (class vfwnmacc): Ditto.
49903         (class vfwmsac): Ditto.
49904         (class vfwnmsac): Ditto.
49905         (class float_misc): Ditto.
49906         (class fcmp): Ditto.
49907         (class vfclass): Ditto.
49908         (class vfcvt_x): Ditto.
49909         (class vfcvt_rtz_x): Ditto.
49910         (class vfcvt_f): Ditto.
49911         (class vfwcvt_x): Ditto.
49912         (class vfwcvt_rtz_x): Ditto.
49913         (class vfwcvt_f): Ditto.
49914         (class vfncvt_x): Ditto.
49915         (class vfncvt_rtz_x): Ditto.
49916         (class vfncvt_f): Ditto.
49917         (class vfncvt_rod_f): Ditto.
49918         (BASE): Ditto.
49919         * config/riscv/riscv-vector-builtins-bases.h:
49920         * config/riscv/riscv-vector-builtins-functions.def (vzext): Ditto.
49921         (vsext): Ditto.
49922         (vfadd): Ditto.
49923         (vfsub): Ditto.
49924         (vfrsub): Ditto.
49925         (vfwadd): Ditto.
49926         (vfwsub): Ditto.
49927         (vfmul): Ditto.
49928         (vfdiv): Ditto.
49929         (vfrdiv): Ditto.
49930         (vfwmul): Ditto.
49931         (vfmacc): Ditto.
49932         (vfnmsac): Ditto.
49933         (vfmadd): Ditto.
49934         (vfnmsub): Ditto.
49935         (vfnmacc): Ditto.
49936         (vfmsac): Ditto.
49937         (vfnmadd): Ditto.
49938         (vfmsub): Ditto.
49939         (vfwmacc): Ditto.
49940         (vfwnmacc): Ditto.
49941         (vfwmsac): Ditto.
49942         (vfwnmsac): Ditto.
49943         (vfsqrt): Ditto.
49944         (vfrsqrt7): Ditto.
49945         (vfrec7): Ditto.
49946         (vfmin): Ditto.
49947         (vfmax): Ditto.
49948         (vfsgnj): Ditto.
49949         (vfsgnjn): Ditto.
49950         (vfsgnjx): Ditto.
49951         (vfneg): Ditto.
49952         (vfabs): Ditto.
49953         (vmfeq): Ditto.
49954         (vmfne): Ditto.
49955         (vmflt): Ditto.
49956         (vmfle): Ditto.
49957         (vmfgt): Ditto.
49958         (vmfge): Ditto.
49959         (vfclass): Ditto.
49960         (vfmerge): Ditto.
49961         (vfmv_v): Ditto.
49962         (vfcvt_x): Ditto.
49963         (vfcvt_xu): Ditto.
49964         (vfcvt_rtz_x): Ditto.
49965         (vfcvt_rtz_xu): Ditto.
49966         (vfcvt_f): Ditto.
49967         (vfwcvt_x): Ditto.
49968         (vfwcvt_xu): Ditto.
49969         (vfwcvt_rtz_x): Ditto.
49970         (vfwcvt_rtz_xu): Ditto.
49971         (vfwcvt_f): Ditto.
49972         (vfncvt_x): Ditto.
49973         (vfncvt_xu): Ditto.
49974         (vfncvt_rtz_x): Ditto.
49975         (vfncvt_rtz_xu): Ditto.
49976         (vfncvt_f): Ditto.
49977         (vfncvt_rod_f): Ditto.
49978         * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_def): Ditto.
49979         (struct move_def): Ditto.
49980         * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_WEXTF_OPS): New macro.
49981         (DEF_RVV_CONVERT_I_OPS): Ditto.
49982         (DEF_RVV_CONVERT_U_OPS): Ditto.
49983         (DEF_RVV_WCONVERT_I_OPS): Ditto.
49984         (DEF_RVV_WCONVERT_U_OPS): Ditto.
49985         (DEF_RVV_WCONVERT_F_OPS): Ditto.
49986         (vfloat64m1_t): Ditto.
49987         (vfloat64m2_t): Ditto.
49988         (vfloat64m4_t): Ditto.
49989         (vfloat64m8_t): Ditto.
49990         (vint32mf2_t): Ditto.
49991         (vint32m1_t): Ditto.
49992         (vint32m2_t): Ditto.
49993         (vint32m4_t): Ditto.
49994         (vint32m8_t): Ditto.
49995         (vint64m1_t): Ditto.
49996         (vint64m2_t): Ditto.
49997         (vint64m4_t): Ditto.
49998         (vint64m8_t): Ditto.
49999         (vuint32mf2_t): Ditto.
50000         (vuint32m1_t): Ditto.
50001         (vuint32m2_t): Ditto.
50002         (vuint32m4_t): Ditto.
50003         (vuint32m8_t): Ditto.
50004         (vuint64m1_t): Ditto.
50005         (vuint64m2_t): Ditto.
50006         (vuint64m4_t): Ditto.
50007         (vuint64m8_t): Ditto.
50008         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_CONVERT_I_OPS): Ditto.
50009         (DEF_RVV_CONVERT_U_OPS): Ditto.
50010         (DEF_RVV_WCONVERT_I_OPS): Ditto.
50011         (DEF_RVV_WCONVERT_U_OPS): Ditto.
50012         (DEF_RVV_WCONVERT_F_OPS): Ditto.
50013         (DEF_RVV_F_OPS): Ditto.
50014         (DEF_RVV_WEXTF_OPS): Ditto.
50015         (required_extensions_p): Adjust for floating-point support.
50016         (check_required_extensions): Ditto.
50017         (unsigned_base_type_p): Ditto.
50018         (get_mode_for_bitsize): Ditto.
50019         (rvv_arg_type_info::get_base_vector_type): Ditto.
50020         (rvv_arg_type_info::get_tree_type): Ditto.
50021         * config/riscv/riscv-vector-builtins.def (v_f): New define.
50022         (f): New define.
50023         (f_v): New define.
50024         (xu_v): New define.
50025         (f_w): New define.
50026         (xu_w): New define.
50027         * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): New enum.
50028         (function_expander::arg_mode): New function.
50029         * config/riscv/vector-iterators.md (sof): New iterator.
50030         (vfrecp): Ditto.
50031         (copysign): Ditto.
50032         (n): Ditto.
50033         (msac): Ditto.
50034         (msub): Ditto.
50035         (fixuns_trunc): Ditto.
50036         (floatuns): Ditto.
50037         * config/riscv/vector.md (@pred_broadcast<mode>): New pattern.
50038         (@pred_<optab><mode>): Ditto.
50039         (@pred_<optab><mode>_scalar): Ditto.
50040         (@pred_<optab><mode>_reverse_scalar): Ditto.
50041         (@pred_<copysign><mode>): Ditto.
50042         (@pred_<copysign><mode>_scalar): Ditto.
50043         (@pred_mul_<optab><mode>): Ditto.
50044         (pred_mul_<optab><mode>_undef_merge): Ditto.
50045         (*pred_<madd_nmsub><mode>): Ditto.
50046         (*pred_<macc_nmsac><mode>): Ditto.
50047         (*pred_mul_<optab><mode>): Ditto.
50048         (@pred_mul_<optab><mode>_scalar): Ditto.
50049         (*pred_mul_<optab><mode>_undef_merge_scalar): Ditto.
50050         (*pred_<madd_nmsub><mode>_scalar): Ditto.
50051         (*pred_<macc_nmsac><mode>_scalar): Ditto.
50052         (*pred_mul_<optab><mode>_scalar): Ditto.
50053         (@pred_neg_mul_<optab><mode>): Ditto.
50054         (pred_neg_mul_<optab><mode>_undef_merge): Ditto.
50055         (*pred_<nmadd_msub><mode>): Ditto.
50056         (*pred_<nmacc_msac><mode>): Ditto.
50057         (*pred_neg_mul_<optab><mode>): Ditto.
50058         (@pred_neg_mul_<optab><mode>_scalar): Ditto.
50059         (*pred_neg_mul_<optab><mode>_undef_merge_scalar): Ditto.
50060         (*pred_<nmadd_msub><mode>_scalar): Ditto.
50061         (*pred_<nmacc_msac><mode>_scalar): Ditto.
50062         (*pred_neg_mul_<optab><mode>_scalar): Ditto.
50063         (@pred_<misc_op><mode>): Ditto.
50064         (@pred_class<mode>): Ditto.
50065         (@pred_dual_widen_<optab><mode>): Ditto.
50066         (@pred_dual_widen_<optab><mode>_scalar): Ditto.
50067         (@pred_single_widen_<plus_minus:optab><mode>): Ditto.
50068         (@pred_single_widen_<plus_minus:optab><mode>_scalar): Ditto.
50069         (@pred_widen_mul_<optab><mode>): Ditto.
50070         (@pred_widen_mul_<optab><mode>_scalar): Ditto.
50071         (@pred_widen_neg_mul_<optab><mode>): Ditto.
50072         (@pred_widen_neg_mul_<optab><mode>_scalar): Ditto.
50073         (@pred_cmp<mode>): Ditto.
50074         (*pred_cmp<mode>): Ditto.
50075         (*pred_cmp<mode>_narrow): Ditto.
50076         (@pred_cmp<mode>_scalar): Ditto.
50077         (*pred_cmp<mode>_scalar): Ditto.
50078         (*pred_cmp<mode>_scalar_narrow): Ditto.
50079         (@pred_eqne<mode>_scalar): Ditto.
50080         (*pred_eqne<mode>_scalar): Ditto.
50081         (*pred_eqne<mode>_scalar_narrow): Ditto.
50082         (@pred_merge<mode>_scalar): Ditto.
50083         (@pred_fcvt_x<v_su>_f<mode>): Ditto.
50084         (@pred_<fix_cvt><mode>): Ditto.
50085         (@pred_<float_cvt><mode>): Ditto.
50086         (@pred_widen_fcvt_x<v_su>_f<mode>): Ditto.
50087         (@pred_widen_<fix_cvt><mode>): Ditto.
50088         (@pred_widen_<float_cvt><mode>): Ditto.
50089         (@pred_extend<mode>): Ditto.
50090         (@pred_narrow_fcvt_x<v_su>_f<mode>): Ditto.
50091         (@pred_narrow_<fix_cvt><mode>): Ditto.
50092         (@pred_narrow_<float_cvt><mode>): Ditto.
50093         (@pred_trunc<mode>): Ditto.
50094         (@pred_rod_trunc<mode>): Ditto.
50096 2023-02-22  Jakub Jelinek  <jakub@redhat.com>
50098         PR middle-end/106258
50099         * cgraph.cc (cgraph_edge::redirect_call_stmt_to_callee,
50100         cgraph_update_edges_for_call_stmt_node, cgraph_node::verify_node):
50101         Handle BUILT_IN_UNREACHABLE_TRAP like BUILT_IN_UNREACHABLE.
50102         * cgraphclones.cc (cgraph_node::create_clone): Likewise.
50104 2023-02-22  Thomas Schwinge  <thomas@codesourcery.com>
50106         * common.opt (-Wcomplain-wrong-lang): New.
50107         * doc/invoke.texi (-Wno-complain-wrong-lang): Document it.
50108         * opts-common.cc (prune_options): Handle it.
50109         * opts-global.cc (complain_wrong_lang): Use it.
50111 2023-02-21  David Malcolm  <dmalcolm@redhat.com>
50113         PR analyzer/108830
50114         * doc/invoke.texi: Document -fno-analyzer-suppress-followups.
50116 2023-02-21  Max Filippov  <jcmvbkbc@gmail.com>
50118         PR target/108876
50119         * config/xtensa/xtensa.cc (xtensa_expand_epilogue): Drop emit_use
50120         for A0_REG.
50121         * config/xtensa/xtensa.md (sibcall, sibcall_internal)
50122         (sibcall_value, sibcall_value_internal): Add 'use' expression
50123         for A0_REG.
50125 2023-02-21  Richard Biener  <rguenther@suse.de>
50127         PR tree-optimization/108691
50128         * tree-ssa-dce.cc (eliminate_unnecessary_stmts): Remove
50129         assert about calls_setjmp not becoming true when it was false.
50131 2023-02-21  Richard Biener  <rguenther@suse.de>
50133         PR tree-optimization/108793
50134         * tree-ssa-loop-niter.cc (number_of_iterations_until_wrap):
50135         Use convert operands to niter_type when computing num.
50137 2023-02-21  Richard Biener  <rguenther@suse.de>
50139         Revert:
50140         2023-02-13  Richard Biener  <rguenther@suse.de>
50142         PR tree-optimization/108691
50143         * tree-cfg.cc (notice_special_calls): When the CFG is built
50144         honor gimple_call_ctrl_altering_p.
50145         * cfgexpand.cc (expand_call_stmt): Clear cfun->calls_setjmp
50146         temporarily if the call is not control-altering.
50147         * calls.cc (emit_call_1): Do not add REG_SETJMP if
50148         cfun->calls_setjmp is not set.  Do not alter cfun->calls_setjmp.
50150 2023-02-21  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
50152         * config/xtensa/xtensa.cc (xtensa_call_save_reg): Change to return
50153         true if register A0 (return address register) when -Og is specified.
50155 2023-02-20  Uroš Bizjak  <ubizjak@gmail.com>
50157         * config/i386/predicates.md
50158         (general_x64constmem_operand): New predicate.
50159         * config/i386/i386.md (*cmpqi_ext<mode>_1):
50160         Use nonimm_x64constmem_operand.
50161         (*cmpqi_ext<mode>_3): Use general_x64constmem_operand.
50162         (*addqi_ext<mode>_1): Ditto.
50163         (*testqi_ext<mode>_1): Ditto.
50164         (*andqi_ext<mode>_1): Ditto.
50165         (*andqi_ext<mode>_1_cc): Ditto.
50166         (*<any_or:code>qi_ext<mode>_1): Ditto.
50167         (*xorqi_ext<mode>_1_cc): Ditto.
50169 2023-02-20  Jakub Jelinek  <jakub2redhat.com>
50171         PR target/108862
50172         * config/rs6000/rs6000.md (umaddditi4): Swap gen_maddlddi4 with
50173         gen_umadddi4_highpart{,_le}.
50175 2023-02-20  Kito Cheng  <kito.cheng@sifive.com>
50177         * config/riscv/riscv.md (prefetch): Use r instead of p for the
50178         address operand.
50179         (riscv_prefetchi_<mode>): Ditto.
50181 2023-02-20  Richard Biener  <rguenther@suse.de>
50183         PR tree-optimization/108816
50184         * tree-vect-loop-manip.cc (vect_loop_versioning): Adjust
50185         versioning condition split prerequesite, assert required
50186         invariant.
50188 2023-02-20  Richard Biener  <rguenther@suse.de>
50190         PR tree-optimization/108825
50191         * tree-ssa-loop-manip.cc (verify_loop_closed_ssa): For
50192         loop-local verfication only verify there's no pending SSA
50193         update.
50195 2023-02-20  Richard Biener  <rguenther@suse.de>
50197         PR tree-optimization/108819
50198         * tree-ssa-loop-niter.cc (number_of_iterations_cltz): Check
50199         we have an SSA name as iv_2 as expected.
50201 2023-02-18  Jakub Jelinek  <jakub@redhat.com>
50203         PR tree-optimization/108819
50204         * tree-ssa-reassoc.cc (update_ops): Fold new stmt in place.
50206 2023-02-18  Jakub Jelinek  <jakub@redhat.com>
50208         PR target/108832
50209         * config/i386/i386-protos.h (ix86_replace_reg_with_reg): Declare.
50210         * config/i386/i386-expand.cc (ix86_replace_reg_with_reg): New
50211         function.
50212         * config/i386/i386.md: Replace replace_rtx calls in all peephole2s
50213         with ix86_replace_reg_with_reg.
50215 2023-02-18  Gerald Pfeifer  <gerald@pfeifer.com>
50217         * doc/invoke.texi (AVR Options): Update link to AVR-LibC.
50219 2023-02-18  Xi Ruoyao  <xry111@xry111.site>
50221         * config.gcc (triplet_abi): Set its value based on $with_abi,
50222         instead of $target.
50223         (la_canonical_triplet): Set it after $triplet_abi is set
50224         correctly.
50225         * config/loongarch/t-linux (MULTILIB_OSDIRNAMES): Make the
50226         multiarch tuple for lp64d "loongarch64-linux-gnu" (without
50227         "f64" suffix).
50229 2023-02-18  Andrew Pinski  <apinski@marvell.com>
50231         * match.pd: Remove #if GIMPLE around the
50232         "1 - a" pattern
50234 2023-02-18  Andrew Pinski  <apinski@marvell.com>
50236         * value-query.h (get_range_query): Return the global ranges
50237         for a nullptr func.
50239 2023-02-17  Siddhesh Poyarekar  <siddhesh@gotplt.org>
50241         * doc/invoke.texi (@item -Wall): Fix typo in
50242         -Wuse-after-free.
50244 2023-02-17  Uroš Bizjak  <ubizjak@gmail.com>
50246         PR target/108831
50247         * config/i386/predicates.md
50248         (nonimm_x64constmem_operand): New predicate.
50249         * config/i386/i386.md (*addqi_ext<mode>_0): New insn pattern.
50250         (*subqi_ext<mode>_0): Ditto.
50251         (*andqi_ext<mode>_0): Ditto.
50252         (*<any_or:code>qi_ext<mode>_0): Ditto.
50254 2023-02-17  Uroš Bizjak  <ubizjak@gmail.com>
50256         PR target/108805
50257         * simplify-rtx.cc (simplify_context::simplify_subreg): Use
50258         int_outermode instead of GET_MODE (tem) to prevent
50259         VOIDmode from entering simplify_gen_subreg.
50261 2023-02-17  Richard Biener  <rguenther@suse.de>
50263         PR tree-optimization/108821
50264         * tree-ssa-loop-im.cc (sm_seq_valid_bb): We can also not
50265         move volatile accesses.
50267 2023-02-17  Richard Biener  <rguenther@suse.de>
50269         * tree-ssa.cc (ssa_undefined_value_p): Assert we are not
50270         called on virtual operands.
50271         * tree-ssa-sccvn.cc (vn_phi_lookup): Guard
50272         ssa_undefined_value_p calls.
50273         (vn_phi_insert): Likewise.
50274         (set_ssa_val_to): Likewise.
50275         (visit_phi): Avoid extra work with equivalences for
50276         virtual operand PHIs.
50278 2023-02-17  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50280         * config/riscv/riscv-vector-builtins-bases.cc (class mask_logic): New
50281         class.
50282         (class mask_nlogic): Ditto.
50283         (class mask_notlogic): Ditto.
50284         (class vmmv): Ditto.
50285         (class vmclr): Ditto.
50286         (class vmset): Ditto.
50287         (class vmnot): Ditto.
50288         (class vcpop): Ditto.
50289         (class vfirst): Ditto.
50290         (class mask_misc): Ditto.
50291         (class viota): Ditto.
50292         (class vid): Ditto.
50293         (BASE): Ditto.
50294         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
50295         * config/riscv/riscv-vector-builtins-functions.def (vmand): Ditto.
50296         (vmnand): Ditto.
50297         (vmandn): Ditto.
50298         (vmxor): Ditto.
50299         (vmor): Ditto.
50300         (vmnor): Ditto.
50301         (vmorn): Ditto.
50302         (vmxnor): Ditto.
50303         (vmmv): Ditto.
50304         (vmclr): Ditto.
50305         (vmset): Ditto.
50306         (vmnot): Ditto.
50307         (vcpop): Ditto.
50308         (vfirst): Ditto.
50309         (vmsbf): Ditto.
50310         (vmsif): Ditto.
50311         (vmsof): Ditto.
50312         (viota): Ditto.
50313         (vid): Ditto.
50314         * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_def): Ditto.
50315         (struct mask_alu_def): Ditto.
50316         (SHAPE): Ditto.
50317         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
50318         * config/riscv/riscv-vector-builtins.cc: Ditto.
50319         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::cleanup_insns): Fix bug
50320         for dest it scalar RVV intrinsics.
50321         * config/riscv/vector-iterators.md (sof): New iterator.
50322         * config/riscv/vector.md (@pred_<optab>n<mode>): New pattern.
50323         (@pred_<optab>not<mode>): New pattern.
50324         (@pred_popcount<VB:mode><P:mode>): New pattern.
50325         (@pred_ffs<VB:mode><P:mode>): New pattern.
50326         (@pred_<misc_op><mode>): New pattern.
50327         (@pred_iota<mode>): New pattern.
50328         (@pred_series<mode>): New pattern.
50330 2023-02-17  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50332         * config/riscv/riscv-vector-builtins-functions.def (vadc): Rename.
50333         (vsbc): Ditto.
50334         (vmerge): Ditto.
50335         (vmv_v): Ditto.
50336         * config/riscv/riscv-vector-builtins.cc: Ditto.
50338 2023-02-17  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50339             kito-cheng  <kito.cheng@sifive.com>
50341         * config/riscv/riscv-protos.h (sew64_scalar_helper): New function.
50342         * config/riscv/riscv-v.cc (has_vi_variant_p): Adjust.
50343         (sew64_scalar_helper): New function.
50344         * config/riscv/vector.md: Normalization.
50346 2023-02-17  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50348         * config/riscv/riscv-vector-builtins-functions.def (vsetvlmax): Rearrange.
50349         (vsm): Ditto.
50350         (vsse): Ditto.
50351         (vsoxei64): Ditto.
50352         (vsub): Ditto.
50353         (vand): Ditto.
50354         (vor): Ditto.
50355         (vxor): Ditto.
50356         (vsll): Ditto.
50357         (vsra): Ditto.
50358         (vsrl): Ditto.
50359         (vmin): Ditto.
50360         (vmax): Ditto.
50361         (vminu): Ditto.
50362         (vmaxu): Ditto.
50363         (vmul): Ditto.
50364         (vmulh): Ditto.
50365         (vmulhu): Ditto.
50366         (vmulhsu): Ditto.
50367         (vdiv): Ditto.
50368         (vrem): Ditto.
50369         (vdivu): Ditto.
50370         (vremu): Ditto.
50371         (vnot): Ditto.
50372         (vsext): Ditto.
50373         (vzext): Ditto.
50374         (vwadd): Ditto.
50375         (vwsub): Ditto.
50376         (vwmul): Ditto.
50377         (vwmulu): Ditto.
50378         (vwmulsu): Ditto.
50379         (vwaddu): Ditto.
50380         (vwsubu): Ditto.
50381         (vsbc): Ditto.
50382         (vmsbc): Ditto.
50383         (vnsra): Ditto.
50384         (vmerge): Ditto.
50385         (vmv_v): Ditto.
50386         (vmsne): Ditto.
50387         (vmslt): Ditto.
50388         (vmsgt): Ditto.
50389         (vmsle): Ditto.
50390         (vmsge): Ditto.
50391         (vmsltu): Ditto.
50392         (vmsgtu): Ditto.
50393         (vmsleu): Ditto.
50394         (vmsgeu): Ditto.
50395         (vnmsac): Ditto.
50396         (vmadd): Ditto.
50397         (vnmsub): Ditto.
50398         (vwmacc): Ditto.
50399         (vsadd): Ditto.
50400         (vssub): Ditto.
50401         (vssubu): Ditto.
50402         (vaadd): Ditto.
50403         (vasub): Ditto.
50404         (vasubu): Ditto.
50405         (vsmul): Ditto.
50406         (vssra): Ditto.
50407         (vssrl): Ditto.
50408         (vnclip): Ditto.
50410 2023-02-17  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50412         * config/riscv/vector.md (@pred_<optab><mode>): Rearrange.
50413         (@pred_<optab><mode>_scalar): Ditto.
50414         (*pred_<optab><mode>_scalar): Ditto.
50415         (*pred_<optab><mode>_extended_scalar): Ditto.
50417 2023-02-17  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50419         * config/riscv/riscv-protos.h (riscv_run_selftests): Remove 'extern'.
50420         (init_builtins): Ditto.
50421         (mangle_builtin_type): Ditto.
50422         (verify_type_context): Ditto.
50423         (handle_pragma_vector):  Ditto.
50424         (builtin_decl): Ditto.
50425         (expand_builtin): Ditto.
50426         (const_vec_all_same_in_range_p): Ditto.
50427         (legitimize_move): Ditto.
50428         (emit_vlmax_op): Ditto.
50429         (emit_nonvlmax_op): Ditto.
50430         (get_vlmul): Ditto.
50431         (get_ratio): Ditto.
50432         (get_ta): Ditto.
50433         (get_ma): Ditto.
50434         (get_avl_type): Ditto.
50435         (calculate_ratio): Ditto.
50436         (enum vlmul_type): Ditto.
50437         (simm5_p): Ditto.
50438         (neg_simm5_p): Ditto.
50439         (has_vi_variant_p): Ditto.
50441 2023-02-17  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50443         * config/riscv/riscv-protos.h (simm32_p): Remove.
50444         * config/riscv/riscv-v.cc (simm32_p): Ditto.
50445         * config/riscv/vector.md: Use immediate_operand
50446         instead of riscv_vector::simm32_p.
50448 2023-02-16  Gerald Pfeifer  <gerald@pfeifer.com>
50450         * doc/invoke.texi (Optimize Options): Reword the explanation
50451         getting minimal, maximal and default values of a parameter.
50453 2023-02-16  Patrick Palka  <ppalka@redhat.com>
50455         * addresses.h: Mechanically drop 'static' from 'static inline'
50456         functions via s/^static inline/inline/g.
50457         * asan.h: Likewise.
50458         * attribs.h: Likewise.
50459         * basic-block.h: Likewise.
50460         * bitmap.h: Likewise.
50461         * cfghooks.h: Likewise.
50462         * cfgloop.h: Likewise.
50463         * cgraph.h: Likewise.
50464         * cselib.h: Likewise.
50465         * data-streamer.h: Likewise.
50466         * debug.h: Likewise.
50467         * df.h: Likewise.
50468         * diagnostic.h: Likewise.
50469         * dominance.h: Likewise.
50470         * dumpfile.h: Likewise.
50471         * emit-rtl.h: Likewise.
50472         * except.h: Likewise.
50473         * expmed.h: Likewise.
50474         * expr.h: Likewise.
50475         * fixed-value.h: Likewise.
50476         * gengtype.h: Likewise.
50477         * gimple-expr.h: Likewise.
50478         * gimple-iterator.h: Likewise.
50479         * gimple-predict.h: Likewise.
50480         * gimple-range-fold.h: Likewise.
50481         * gimple-ssa.h: Likewise.
50482         * gimple.h: Likewise.
50483         * graphite.h: Likewise.
50484         * hard-reg-set.h: Likewise.
50485         * hash-map.h: Likewise.
50486         * hash-set.h: Likewise.
50487         * hash-table.h: Likewise.
50488         * hwint.h: Likewise.
50489         * input.h: Likewise.
50490         * insn-addr.h: Likewise.
50491         * internal-fn.h: Likewise.
50492         * ipa-fnsummary.h: Likewise.
50493         * ipa-icf-gimple.h: Likewise.
50494         * ipa-inline.h: Likewise.
50495         * ipa-modref.h: Likewise.
50496         * ipa-prop.h: Likewise.
50497         * ira-int.h: Likewise.
50498         * ira.h: Likewise.
50499         * lra-int.h: Likewise.
50500         * lra.h: Likewise.
50501         * lto-streamer.h: Likewise.
50502         * memmodel.h: Likewise.
50503         * omp-general.h: Likewise.
50504         * optabs-query.h: Likewise.
50505         * optabs.h: Likewise.
50506         * plugin.h: Likewise.
50507         * pretty-print.h: Likewise.
50508         * range.h: Likewise.
50509         * read-md.h: Likewise.
50510         * recog.h: Likewise.
50511         * regs.h: Likewise.
50512         * rtl-iter.h: Likewise.
50513         * rtl.h: Likewise.
50514         * sbitmap.h: Likewise.
50515         * sched-int.h: Likewise.
50516         * sel-sched-ir.h: Likewise.
50517         * sese.h: Likewise.
50518         * sparseset.h: Likewise.
50519         * ssa-iterators.h: Likewise.
50520         * system.h: Likewise.
50521         * target-globals.h: Likewise.
50522         * target.h: Likewise.
50523         * timevar.h: Likewise.
50524         * tree-chrec.h: Likewise.
50525         * tree-data-ref.h: Likewise.
50526         * tree-iterator.h: Likewise.
50527         * tree-outof-ssa.h: Likewise.
50528         * tree-phinodes.h: Likewise.
50529         * tree-scalar-evolution.h: Likewise.
50530         * tree-sra.h: Likewise.
50531         * tree-ssa-alias.h: Likewise.
50532         * tree-ssa-live.h: Likewise.
50533         * tree-ssa-loop-manip.h: Likewise.
50534         * tree-ssa-loop.h: Likewise.
50535         * tree-ssa-operands.h: Likewise.
50536         * tree-ssa-propagate.h: Likewise.
50537         * tree-ssa-sccvn.h: Likewise.
50538         * tree-ssa.h: Likewise.
50539         * tree-ssanames.h: Likewise.
50540         * tree-streamer.h: Likewise.
50541         * tree-switch-conversion.h: Likewise.
50542         * tree-vectorizer.h: Likewise.
50543         * tree.h: Likewise.
50544         * wide-int.h: Likewise.
50546 2023-02-16  Jakub Jelinek  <jakub@redhat.com>
50548         PR tree-optimization/108657
50549         * tree-ssa-dse.cc (initialize_ao_ref_for_dse): If lhs of stmt
50550         exists and is not a SSA_NAME, call ao_ref_init even if the stmt
50551         is a call to internal or builtin function.
50553 2023-02-16  Jonathan Wakely  <jwakely@redhat.com>
50555         * doc/invoke.texi (C++ Dialect Options): Suggest adding a
50556         using-declaration to unhide functions.
50558 2023-02-16  Jakub Jelinek  <jakub@redhat.com>
50560         PR tree-optimization/108783
50561         * tree-ssa-reassoc.cc (eliminate_redundant_comparison): If lcode
50562         is equal to TREE_CODE (t), op1 to newop1 and op2 to newop2, set
50563         t to curr->op.  Otherwise, punt if either newop1 or newop2 are
50564         SSA_NAME_OCCURS_IN_ABNORMAL_PHI SSA_NAMEs.
50566 2023-02-16  Richard Biener  <rguenther@suse.de>
50568         PR tree-optimization/108791
50569         * tree-ssa-forwprop.cc (optimize_vector_load): Build
50570         the ADDR_EXPR of a TARGET_MEM_REF using a more meaningful
50571         type.
50573 2023-02-15  Eric Botcazou  <ebotcazou@adacore.com>
50575         PR target/90458
50576         * config/i386/i386.cc (ix86_compute_frame_layout): Disable the
50577         effects of -fstack-clash-protection for TARGET_STACK_PROBE.
50578         (ix86_expand_prologue): Likewise.
50580 2023-02-15  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
50582         * config/bpf/bpf.cc (bpf_option_override): Fix doubled space.
50584 2023-02-15  Uroš Bizjak  <ubizjak@gmail.com>
50586         * config/i386/i386.md (*cmpqi_ext<mode>_1): Use
50587         int248_register_operand predicate in zero_extract sub-RTX.
50588         (*cmpqi_ext<mode>_2): Ditto.
50589         (*cmpqi_ext<mode>_3): Ditto.
50590         (*cmpqi_ext<mode>_4): Ditto.
50591         (*extzvqi_mem_rex64): Ditto.
50592         (*extzvqi): Ditto.
50593         (*insvqi_1_mem_rex64): Ditto.
50594         (@insv<mode>_1): Ditto.
50595         (*insvqi_1): Ditto.
50596         (*insvqi_2): Ditto.
50597         (*insvqi_3): Ditto.
50598         (*extendqi<SWI24:mode>_ext_1): Ditto.
50599         (*addqi_ext<mode>_1): Ditto.
50600         (*addqi_ext<mode>_2): Ditto.
50601         (*subqi_ext<mode>_2): Ditto.
50602         (*testqi_ext<mode>_1): Ditto.
50603         (*testqi_ext<mode>_2): Ditto.
50604         (*andqi_ext<mode>_1): Ditto.
50605         (*andqi_ext<mode>_1_cc): Ditto.
50606         (*andqi_ext<mode>_2): Ditto.
50607         (*<any_or:code>qi_ext<mode>_1): Ditto.
50608         (*<any_or:code>qi_ext<mode>_2): Ditto.
50609         (*xorqi_ext<mode>_1_cc): Ditto.
50610         (*negqi_ext<mode>_2): Ditto.
50611         (*ashlqi_ext<mode>_2): Ditto.
50612         (*<any_shiftrt:insn>qi_ext<mode>_2): Ditto.
50614 2023-02-15  Uroš Bizjak  <ubizjak@gmail.com>
50616         * config/i386/predicates.md (int248_register_operand):
50617         Rename from extr_register_operand.
50618         * config/i386/i386.md (*extv<mode>): Update for renamed predicate.
50619         (*extzx<mode>): Ditto.
50620         (*ashl<dwi>3_doubleword_mask): Use int248_register_operand predicate.
50621         (*ashl<mode>3_mask): Ditto.
50622         (*<any_shiftrt:insn><mode>3_mask): Ditto.
50623         (*<any_shiftrt:insn><dwi>3_doubleword_mask): Ditto.
50624         (*<any_rotate:insn><mode>3_mask): Ditto.
50625         (*<btsc><mode>_mask): Ditto.
50626         (*btr<mode>_mask): Ditto.
50627         (*jcc_bt<mode>_mask_1): Ditto.
50629 2023-02-15  Richard Biener  <rguenther@suse.de>
50631         PR middle-end/26854
50632         * df-core.cc (df_worklist_propagate_forward): Put later
50633         blocks on worklist and only earlier blocks on pending.
50634         (df_worklist_propagate_backward): Likewise.
50635         (df_worklist_dataflow_doublequeue): Change the iteration
50636         to process new blocks in the same iteration if that
50637         maintains the iteration order.
50639 2023-02-15  Marek Polacek  <polacek@redhat.com>
50641         PR middle-end/106080
50642         * gimple-ssa-warn-access.cc (is_auto_decl): Remove.  Use auto_var_p
50643         instead.
50645 2023-02-15  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50647         * config/riscv/predicates.md: Refine codes.
50648         * config/riscv/riscv-protos.h (RVV_VUNDEF): New macro.
50649         * config/riscv/riscv-v.cc: Refine codes.
50650         * config/riscv/riscv-vector-builtins-bases.cc (enum ternop_type): New
50651         enum.
50652         (class imac): New class.
50653         (enum widen_ternop_type): New enum.
50654         (class iwmac): New class.
50655         (BASE): New class.
50656         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
50657         * config/riscv/riscv-vector-builtins-functions.def (vmacc): Ditto.
50658         (vnmsac): Ditto.
50659         (vmadd): Ditto.
50660         (vnmsub): Ditto.
50661         (vwmacc): Ditto.
50662         (vwmaccu): Ditto.
50663         (vwmaccsu): Ditto.
50664         (vwmaccus): Ditto.
50665         * config/riscv/riscv-vector-builtins.cc
50666         (function_builder::apply_predication): Adjust for multiply-add support.
50667         (function_expander::add_vundef_operand): Refine codes.
50668         (function_expander::use_ternop_insn): New function.
50669         (function_expander::use_widen_ternop_insn): Ditto.
50670         * config/riscv/riscv-vector-builtins.h: New function.
50671         * config/riscv/vector.md (@pred_mul_<optab><mode>): New pattern.
50672         (pred_mul_<optab><mode>_undef_merge): Ditto.
50673         (*pred_<madd_nmsub><mode>): Ditto.
50674         (*pred_<macc_nmsac><mode>): Ditto.
50675         (*pred_mul_<optab><mode>): Ditto.
50676         (@pred_mul_<optab><mode>_scalar): Ditto.
50677         (*pred_mul_<optab><mode>_undef_merge_scalar): Ditto.
50678         (*pred_<madd_nmsub><mode>_scalar): Ditto.
50679         (*pred_<macc_nmsac><mode>_scalar): Ditto.
50680         (*pred_mul_<optab><mode>_scalar): Ditto.
50681         (*pred_mul_<optab><mode>_undef_merge_extended_scalar): Ditto.
50682         (*pred_<madd_nmsub><mode>_extended_scalar): Ditto.
50683         (*pred_<macc_nmsac><mode>_extended_scalar): Ditto.
50684         (*pred_mul_<optab><mode>_extended_scalar): Ditto.
50685         (@pred_widen_mul_plus<su><mode>): Ditto.
50686         (@pred_widen_mul_plus<su><mode>_scalar): Ditto.
50687         (@pred_widen_mul_plussu<mode>): Ditto.
50688         (@pred_widen_mul_plussu<mode>_scalar): Ditto.
50689         (@pred_widen_mul_plusus<mode>_scalar): Ditto.
50691 2023-02-15  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50693         * config/riscv/predicates.md (vector_mask_operand): Refine the codes.
50694         (vector_all_trues_mask_operand): New predicate.
50695         (vector_undef_operand): New predicate.
50696         (ltge_operator): New predicate.
50697         (comparison_except_ltge_operator): New predicate.
50698         (comparison_except_eqge_operator): New predicate.
50699         (ge_operator): New predicate.
50700         * config/riscv/riscv-v.cc (has_vi_variant_p): Add compare support.
50701         * config/riscv/riscv-vector-builtins-bases.cc (class icmp): New class.
50702         (BASE): Ditto.
50703         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
50704         * config/riscv/riscv-vector-builtins-functions.def (vmseq): Ditto.
50705         (vmsne): Ditto.
50706         (vmslt): Ditto.
50707         (vmsgt): Ditto.
50708         (vmsle): Ditto.
50709         (vmsge): Ditto.
50710         (vmsltu): Ditto.
50711         (vmsgtu): Ditto.
50712         (vmsleu): Ditto.
50713         (vmsgeu): Ditto.
50714         * config/riscv/riscv-vector-builtins-shapes.cc
50715         (struct return_mask_def): Adjust for compare support.
50716         * config/riscv/riscv-vector-builtins.cc
50717         (function_expander::use_compare_insn): New function.
50718         * config/riscv/riscv-vector-builtins.h
50719         (function_expander::add_integer_operand): Ditto.
50720         * config/riscv/riscv.cc (riscv_print_operand): Add compare support.
50721         * config/riscv/riscv.md: Add vector min/max attributes.
50722         * config/riscv/vector-iterators.md (xnor): New iterator.
50723         * config/riscv/vector.md (@pred_cmp<mode>): New pattern.
50724         (*pred_cmp<mode>): Ditto.
50725         (*pred_cmp<mode>_narrow): Ditto.
50726         (@pred_ltge<mode>): Ditto.
50727         (*pred_ltge<mode>): Ditto.
50728         (*pred_ltge<mode>_narrow): Ditto.
50729         (@pred_cmp<mode>_scalar): Ditto.
50730         (*pred_cmp<mode>_scalar): Ditto.
50731         (*pred_cmp<mode>_scalar_narrow): Ditto.
50732         (@pred_eqne<mode>_scalar): Ditto.
50733         (*pred_eqne<mode>_scalar): Ditto.
50734         (*pred_eqne<mode>_scalar_narrow): Ditto.
50735         (*pred_cmp<mode>_extended_scalar): Ditto.
50736         (*pred_cmp<mode>_extended_scalar_narrow): Ditto.
50737         (*pred_eqne<mode>_extended_scalar): Ditto.
50738         (*pred_eqne<mode>_extended_scalar_narrow): Ditto.
50739         (@pred_ge<mode>_scalar): Ditto.
50740         (@pred_<optab><mode>): Ditto.
50741         (@pred_n<optab><mode>): Ditto.
50742         (@pred_<optab>n<mode>): Ditto.
50743         (@pred_not<mode>): Ditto.
50745 2023-02-15  Martin Jambor  <mjambor@suse.cz>
50747         PR ipa/108679
50748         * ipa-sra.cc (push_param_adjustments_for_index): Do not omit
50749         creation of non-scalar replacements even if IPA-CP knows their
50750         contents.
50752 2023-02-15  Jakub Jelinek  <jakub@redhat.com>
50754         PR target/108787
50755         PR target/103109
50756         * config/rs6000/rs6000.md (<u>maddditi4): Change into umaddditi4 only
50757         expander, change operand 3 to be TImode, emit maddlddi4 and
50758         umadddi4_highpart{,_le} with its low half and finally add the high
50759         half to the result.
50761 2023-02-15  Martin Liska  <mliska@suse.cz>
50763         * doc/invoke.texi: Document --param=asan-kernel-mem-intrinsic-prefix.
50765 2023-02-15  Richard Biener  <rguenther@suse.de>
50767         * sanopt.cc (sanitize_asan_mark_unpoison): Use bitmap
50768         for with_poison and alias worklist to it.
50769         (sanitize_asan_mark_poison): Likewise.
50771 2023-02-15  Richard Biener  <rguenther@suse.de>
50773         PR target/108738
50774         * config/i386/i386-features.cc (scalar_chain::add_to_queue):
50775         Combine bitmap test and set.
50776         (scalar_chain::add_insn): Likewise.
50777         (scalar_chain::analyze_register_chain): Remove redundant
50778         attempt to add to queue and instead strengthen assert.
50779         Sink common attempts to mark the def dual-mode.
50780         (scalar_chain::add_to_queue): Remove redundant insn bitmap
50781         check.
50783 2023-02-15  Richard Biener  <rguenther@suse.de>
50785         PR target/108738
50786         * config/i386/i386-features.cc (convert_scalars_to_vector):
50787         Switch candidates bitmaps to tree view before building the chains.
50789 2023-02-15  Hans-Peter Nilsson  <hp@axis.com>
50791         * reload1.cc (gen_reload): Correct rtx parameter for fatal_insn
50792         "failure trying to reload" call.
50794 2023-02-15  Hans-Peter Nilsson  <hp@axis.com>
50796         * gdbinit.in (phrs): New command.
50797         * sel-sched-dump.cc (debug_hard_reg_set): Remove debug-function.
50798         * ira-color.cc (debug_hard_reg_set): New, calling print_hard_reg_set.
50800 2023-02-14  David Faust  <david.faust@oracle.com>
50802         PR target/108790
50803         * config/bpf/constraints.md (q): New memory constraint.
50804         * config/bpf/bpf.md (zero_extendhidi2): Use it here.
50805         (zero_extendqidi2): Likewise.
50806         (zero_extendsidi2): Likewise.
50807         (*mov<MM:mode>): Likewise.
50809 2023-02-14  Andrew Pinski  <apinski@marvell.com>
50811         PR tree-optimization/108355
50812         PR tree-optimization/96921
50813         * match.pd: Add pattern for "1 - bool_val".
50815 2023-02-14  Richard Biener  <rguenther@suse.de>
50817         * tree-ssa-sccvn.cc (vn_phi_compute_hash): Key skipping
50818         basic block index hashing on the availability of ->cclhs.
50819         (vn_phi_eq): Avoid re-doing sanity checks for CSE but
50820         rely on ->cclhs availability.
50821         (vn_phi_lookup): Set ->cclhs only when we are eventually
50822         going to CSE the PHI.
50823         (vn_phi_insert): Likewise.
50825 2023-02-14  Eric Botcazou  <ebotcazou@adacore.com>
50827         * gimplify.cc (gimplify_save_expr): Add missing guard.
50829 2023-02-14  Richard Biener  <rguenther@suse.de>
50831         PR tree-optimization/108782
50832         * tree-vect-loop.cc (vect_phi_first_order_recurrence_p):
50833         Make sure we're not vectorizing an inner loop.
50835 2023-02-14  Jakub Jelinek  <jakub@redhat.com>
50837         PR sanitizer/108777
50838         * params.opt (-param=asan-kernel-mem-intrinsic-prefix=): New param.
50839         * asan.h (asan_memfn_rtl): Declare.
50840         * asan.cc (asan_memfn_rtls): New variable.
50841         (asan_memfn_rtl): New function.
50842         * builtins.cc (expand_builtin): If
50843         param_asan_kernel_mem_intrinsic_prefix and function is
50844         kernel-{,hw}address sanitized, emit calls to
50845         __{,hw}asan_{memcpy,memmove,memset} rather than
50846         {memcpy,memmove,memset}.  Use sanitize_flags_p (SANITIZE_ADDRESS)
50847         instead of flag_sanitize & SANITIZE_ADDRESS to check if
50848         asan_intercepted_p functions shouldn't be expanded inline.
50850 2023-02-14  Richard Sandiford  <richard.sandiford@arm.com>
50852         PR tree-optimization/96373
50853         * tree-vect-stmts.cc (vectorizable_operation): Predicate trapping
50854         operations on the loop mask.  Reject partial vectors if this isn't
50855         possible.
50857 2023-02-13  Richard Sandiford  <richard.sandiford@arm.com>
50859         PR rtl-optimization/108681
50860         * lra-spills.cc (lra_final_code_change): Extend subreg replacement
50861         code to handle bare uses and clobbers.
50863 2023-02-13  Vladimir N. Makarov  <vmakarov@redhat.com>
50865         * ira.cc (ira_update_equiv_info_by_shuffle_insn): Clear equiv
50866         caller_save_p flag when clearing defined_p flag.
50867         (setup_reg_equiv): Ditto.
50868         * lra-constraints.cc (lra_constraints): Ditto.
50870 2023-02-13  Uroš Bizjak  <ubizjak@gmail.com>
50872         PR target/108516
50873         * config/i386/predicates.md (extr_register_operand):
50874         New special predicate.
50875         * config/i386/i386.md (*extv<mode>): Use extr_register_operand
50876         as operand 1 predicate.
50877         (*exzv<mode>): Ditto.
50878         (*extendqi<SWI24:mode>_ext_1): New insn pattern.
50880 2023-02-13  Richard Biener  <rguenther@suse.de>
50882         PR tree-optimization/28614
50883         * tree-ssa-sccvn.cc (can_track_predicate_on_edge): Avoid
50884         walking all edges in most cases.
50885         (vn_nary_op_insert_pieces_predicated): Avoid repeated
50886         calls to can_track_predicate_on_edge unless checking is
50887         enabled.
50888         (process_bb): Instead call it once here for each edge
50889         we register possibly multiple predicates on.
50891 2023-02-13  Richard Biener  <rguenther@suse.de>
50893         PR tree-optimization/108691
50894         * tree-cfg.cc (notice_special_calls): When the CFG is built
50895         honor gimple_call_ctrl_altering_p.
50896         * cfgexpand.cc (expand_call_stmt): Clear cfun->calls_setjmp
50897         temporarily if the call is not control-altering.
50898         * calls.cc (emit_call_1): Do not add REG_SETJMP if
50899         cfun->calls_setjmp is not set.  Do not alter cfun->calls_setjmp.
50901 2023-02-13  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
50903         PR target/108102
50904         * config/s390/s390.cc (s390_bb_fallthru_entry_likely): Remove.
50905         (struct s390_sched_state): Initialise to zero.
50906         (s390_sched_variable_issue): For better debuggability also emit
50907         the current side.
50908         (s390_sched_init): Unconditionally reset scheduler state.
50910 2023-02-13  Richard Sandiford  <richard.sandiford@arm.com>
50912         * ifcvt.h (noce_if_info::cond_inverted): New field.
50913         * ifcvt.cc (cond_move_convert_if_block): Swap the then and else
50914         values when cond_inverted is true.
50915         (noce_find_if_block): Allow the condition to be inverted when
50916         handling conditional moves.
50918 2023-02-13  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
50920         * config/s390/predicates.md (execute_operation): Use
50921         constrain_operands instead of extract_constrain_insn in order to
50922         determine wheter there exists a valid alternative.
50924 2023-02-13  Claudiu Zissulescu  <claziss@gmail.com>
50926         * common/config/arc/arc-common.cc (arc_option_optimization_table):
50927         Remove millicode from list.
50929 2023-02-13  Martin Liska  <mliska@suse.cz>
50931         * doc/invoke.texi: Document ira-simple-lra-insn-threshold.
50933 2023-02-13  Richard Biener  <rguenther@suse.de>
50935         PR tree-optimization/106722
50936         * tree-ssa-dce.cc (mark_last_stmt_necessary): Return
50937         whether we marked a stmt.
50938         (mark_control_dependent_edges_necessary): When
50939         mark_last_stmt_necessary didn't mark any stmt make sure
50940         to mark its control dependent edges.
50941         (propagate_necessity): Likewise.
50943 2023-02-13  Kito Cheng  <kito.cheng@sifive.com>
50945         * config/riscv/riscv.h (RISCV_DWARF_VLENB): New.
50946         (DWARF_FRAME_REGISTERS): New.
50947         (DWARF_REG_TO_UNWIND_COLUMN): New.
50949 2023-02-12  Gerald Pfeifer  <gerald@pfeifer.com>
50951         * doc/sourcebuild.texi: Remove (broken) direct reference to
50952         "The GNU configure and build system".
50954 2023-02-12  Jin Ma  <jinma@linux.alibaba.com>
50956         * config/riscv/riscv.cc (riscv_adjust_libcall_cfi_prologue): Change
50957         gen_add3_insn to gen_rtx_SET.
50958         (riscv_adjust_libcall_cfi_epilogue): Likewise.
50960 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50962         * config/riscv/riscv-vector-builtins-bases.cc (class sat_op): New class.
50963         (class vnclip): Ditto.
50964         (BASE): Ditto.
50965         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
50966         * config/riscv/riscv-vector-builtins-functions.def (vaadd): Ditto.
50967         (vasub): Ditto.
50968         (vaaddu): Ditto.
50969         (vasubu): Ditto.
50970         (vsmul): Ditto.
50971         (vssra): Ditto.
50972         (vssrl): Ditto.
50973         (vnclipu): Ditto.
50974         (vnclip): Ditto.
50975         * config/riscv/vector-iterators.md (su): Add instruction.
50976         (aadd): Ditto.
50977         (vaalu): Ditto.
50978         * config/riscv/vector.md (@pred_<sat_op><mode>): New pattern.
50979         (@pred_<sat_op><mode>_scalar): Ditto.
50980         (*pred_<sat_op><mode>_scalar): Ditto.
50981         (*pred_<sat_op><mode>_extended_scalar): Ditto.
50982         (@pred_narrow_clip<v_su><mode>): Ditto.
50983         (@pred_narrow_clip<v_su><mode>_scalar): Ditto.
50985 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
50987         * config/riscv/constraints.md (Wbr): Remove unused constraint.
50988         * config/riscv/predicates.md: Fix move operand predicate.
50989         * config/riscv/riscv-vector-builtins-bases.cc (class vnshift): New class.
50990         (class vncvt_x): Ditto.
50991         (class vmerge): Ditto.
50992         (class vmv_v): Ditto.
50993         (BASE): Ditto.
50994         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
50995         * config/riscv/riscv-vector-builtins-functions.def (vsra): Ditto.
50996         (vsrl): Ditto.
50997         (vnsrl): Ditto.
50998         (vnsra): Ditto.
50999         (vncvt_x): Ditto.
51000         (vmerge): Ditto.
51001         (vmv_v): Ditto.
51002         * config/riscv/riscv-vector-builtins-shapes.cc (struct narrow_alu_def): Ditto.
51003         (struct move_def): Ditto.
51004         (SHAPE): Ditto.
51005         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
51006         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_WEXTI_OPS): New variable.
51007         (DEF_RVV_WEXTU_OPS): Ditto
51008         * config/riscv/riscv-vector-builtins.def (x_x_w): Fix type for suffix.
51009         (v_v): Ditto.
51010         (v_x): Ditto.
51011         (x_w): Ditto.
51012         (x): Ditto.
51013         * config/riscv/riscv.cc (riscv_print_operand): Refine ASM printting rule.
51014         * config/riscv/vector-iterators.md (nmsac):New iterator.
51015         (nmsub): New iterator.
51016         * config/riscv/vector.md (@pred_merge<mode>): New pattern.
51017         (@pred_merge<mode>_scalar): New pattern.
51018         (*pred_merge<mode>_scalar): New pattern.
51019         (*pred_merge<mode>_extended_scalar): New pattern.
51020         (@pred_narrow_<optab><mode>): New pattern.
51021         (@pred_narrow_<optab><mode>_scalar): New pattern.
51022         (@pred_trunc<mode>): New pattern.
51024 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51026         * config/riscv/riscv-vector-builtins-bases.cc (class vmadc): New class.
51027         (class vmsbc): Ditto.
51028         (BASE): Define new class.
51029         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
51030         * config/riscv/riscv-vector-builtins-functions.def (vmadc): New define.
51031         (vmsbc): Ditto.
51032         * config/riscv/riscv-vector-builtins-shapes.cc (struct return_mask_def):
51033         New class.
51034         (SHAPE): Ditto.
51035         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
51036         * config/riscv/riscv-vector-builtins.cc
51037         (function_expander::use_exact_insn): Adjust for new support
51038         * config/riscv/riscv-vector-builtins.h
51039         (function_base::has_merge_operand_p): New function.
51040         * config/riscv/vector-iterators.md: New iterator.
51041         * config/riscv/vector.md (@pred_madc<mode>): New pattern.
51042         (@pred_msbc<mode>): Ditto.
51043         (@pred_madc<mode>_scalar): Ditto.
51044         (@pred_msbc<mode>_scalar): Ditto.
51045         (*pred_madc<mode>_scalar): Ditto.
51046         (*pred_madc<mode>_extended_scalar): Ditto.
51047         (*pred_msbc<mode>_scalar): Ditto.
51048         (*pred_msbc<mode>_extended_scalar): Ditto.
51049         (@pred_madc<mode>_overflow): Ditto.
51050         (@pred_msbc<mode>_overflow): Ditto.
51051         (@pred_madc<mode>_overflow_scalar): Ditto.
51052         (@pred_msbc<mode>_overflow_scalar): Ditto.
51053         (*pred_madc<mode>_overflow_scalar): Ditto.
51054         (*pred_madc<mode>_overflow_extended_scalar): Ditto.
51055         (*pred_msbc<mode>_overflow_scalar): Ditto.
51056         (*pred_msbc<mode>_overflow_extended_scalar): Ditto.
51058 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51060         * config/riscv/riscv-protos.h (simm5_p): Add vadc/vsbc support.
51061         * config/riscv/riscv-v.cc (simm32_p): Ditto.
51062         * config/riscv/riscv-vector-builtins-bases.cc (class vadc): New class.
51063         (class vsbc): Ditto.
51064         (BASE): Ditto.
51065         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
51066         * config/riscv/riscv-vector-builtins-functions.def (vadc): Ditto.
51067         (vsbc): Ditto.
51068         * config/riscv/riscv-vector-builtins-shapes.cc
51069         (struct no_mask_policy_def): Ditto.
51070         (SHAPE): Ditto.
51071         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
51072         * config/riscv/riscv-vector-builtins.cc
51073         (rvv_arg_type_info::get_base_vector_type): Add vadc/vsbc support.
51074         (rvv_arg_type_info::get_tree_type): Ditto.
51075         (function_expander::use_exact_insn): Ditto.
51076         * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Ditto.
51077         (function_base::use_mask_predication_p): New function.
51078         * config/riscv/vector-iterators.md: New iterator.
51079         * config/riscv/vector.md (@pred_adc<mode>): New pattern.
51080         (@pred_sbc<mode>): Ditto.
51081         (@pred_adc<mode>_scalar): Ditto.
51082         (@pred_sbc<mode>_scalar): Ditto.
51083         (*pred_adc<mode>_scalar): Ditto.
51084         (*pred_adc<mode>_extended_scalar): Ditto.
51085         (*pred_sbc<mode>_scalar): Ditto.
51086         (*pred_sbc<mode>_extended_scalar): Ditto.
51088 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51090         * config/riscv/vector.md: use "zero" reg.
51092 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51094         * config/riscv/riscv-vector-builtins-bases.cc (class widen_binop): New
51095         class.
51096         (class vwmulsu): Ditto.
51097         (class vwcvt): Ditto.
51098         (BASE): Add integer widening support.
51099         * config/riscv/riscv-vector-builtins-bases.h: Ditto
51100         * config/riscv/riscv-vector-builtins-functions.def (vwadd): New class.
51101         (vwsub): New class.
51102         (vwmul): New class.
51103         (vwmulu): New class.
51104         (vwmulsu): New class.
51105         (vwaddu): New class.
51106         (vwsubu): New class.
51107         (vwcvt_x): New class.
51108         (vwcvtu_x): New class.
51109         * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_def): New
51110         class.
51111         (struct widen_alu_def): New class.
51112         (SHAPE): New class.
51113         * config/riscv/riscv-vector-builtins-shapes.h: New class.
51114         * config/riscv/riscv-vector-builtins.cc
51115         (rvv_arg_type_info::get_base_vector_type): Add integer widening support.
51116         (rvv_arg_type_info::get_tree_type): Ditto.
51117         * config/riscv/riscv-vector-builtins.def (x_x_v): Change into "x_v"
51118         (x_v): Ditto.
51119         * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Add integer
51120         widening support.
51121         * config/riscv/riscv-vsetvl.cc (change_insn): Fix reg_equal use bug.
51122         * config/riscv/riscv.h (X0_REGNUM): New constant.
51123         * config/riscv/vector-iterators.md: New iterators.
51124         * config/riscv/vector.md
51125         (@pred_dual_widen_<any_widen_binop:optab><any_extend:su><mode>): New
51126         pattern.
51127         (@pred_dual_widen_<any_widen_binop:optab><any_extend:su><mode>_scalar):
51128         Ditto.
51129         (@pred_single_widen_<plus_minus:optab><any_extend:su><mode>): Ditto.
51130         (@pred_single_widen_<plus_minus:optab><any_extend:su><mode>_scalar):
51131         Ditto.
51132         (@pred_widen_mulsu<mode>): Ditto.
51133         (@pred_widen_mulsu<mode>_scalar): Ditto.
51134         (@pred_<optab><mode>): Ditto.
51136 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51137             kito-cheng  <kito.cheng@sifive.com>
51139         * common/config/riscv/riscv-common.cc: Add flag for 'V' extension.
51140         * config/riscv/riscv-vector-builtins-bases.cc (class vmulh): New class.
51141         (BASE): Ditto.
51142         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
51143         * config/riscv/riscv-vector-builtins-functions.def (vmulh): Add vmulh
51144         API support.
51145         (vmulhu): Ditto.
51146         (vmulhsu): Ditto.
51147         * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_FULL_V_I_OPS):
51148         New macro.
51149         (DEF_RVV_FULL_V_U_OPS): Ditto.
51150         (vint8mf8_t): Ditto.
51151         (vint8mf4_t): Ditto.
51152         (vint8mf2_t): Ditto.
51153         (vint8m1_t): Ditto.
51154         (vint8m2_t): Ditto.
51155         (vint8m4_t): Ditto.
51156         (vint8m8_t): Ditto.
51157         (vint16mf4_t): Ditto.
51158         (vint16mf2_t): Ditto.
51159         (vint16m1_t): Ditto.
51160         (vint16m2_t): Ditto.
51161         (vint16m4_t): Ditto.
51162         (vint16m8_t): Ditto.
51163         (vint32mf2_t): Ditto.
51164         (vint32m1_t): Ditto.
51165         (vint32m2_t): Ditto.
51166         (vint32m4_t): Ditto.
51167         (vint32m8_t): Ditto.
51168         (vint64m1_t): Ditto.
51169         (vint64m2_t): Ditto.
51170         (vint64m4_t): Ditto.
51171         (vint64m8_t): Ditto.
51172         (vuint8mf8_t): Ditto.
51173         (vuint8mf4_t): Ditto.
51174         (vuint8mf2_t): Ditto.
51175         (vuint8m1_t): Ditto.
51176         (vuint8m2_t): Ditto.
51177         (vuint8m4_t): Ditto.
51178         (vuint8m8_t): Ditto.
51179         (vuint16mf4_t): Ditto.
51180         (vuint16mf2_t): Ditto.
51181         (vuint16m1_t): Ditto.
51182         (vuint16m2_t): Ditto.
51183         (vuint16m4_t): Ditto.
51184         (vuint16m8_t): Ditto.
51185         (vuint32mf2_t): Ditto.
51186         (vuint32m1_t): Ditto.
51187         (vuint32m2_t): Ditto.
51188         (vuint32m4_t): Ditto.
51189         (vuint32m8_t): Ditto.
51190         (vuint64m1_t): Ditto.
51191         (vuint64m2_t): Ditto.
51192         (vuint64m4_t): Ditto.
51193         (vuint64m8_t): Ditto.
51194         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_FULL_V_I_OPS): Ditto.
51195         (DEF_RVV_FULL_V_U_OPS): Ditto.
51196         (check_required_extensions): Add vmulh support.
51197         (rvv_arg_type_info::get_tree_type): Ditto.
51198         * config/riscv/riscv-vector-builtins.h (RVV_REQUIRE_FULL_V): Ditto.
51199         (enum rvv_base_type): Ditto.
51200         * config/riscv/riscv.opt: Add 'V' extension flag.
51201         * config/riscv/vector-iterators.md (su): New iterator.
51202         * config/riscv/vector.md (@pred_mulh<v_su><mode>): New pattern.
51203         (@pred_mulh<v_su><mode>_scalar): Ditto.
51204         (*pred_mulh<v_su><mode>_scalar): Ditto.
51205         (*pred_mulh<v_su><mode>_extended_scalar): Ditto.
51207 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51209         * config/riscv/iterators.md: Add sign_extend/zero_extend.
51210         * config/riscv/riscv-vector-builtins-bases.cc (class ext): New class.
51211         (BASE): Ditto.
51212         * config/riscv/riscv-vector-builtins-bases.h: Add vsext/vzext support.
51213         * config/riscv/riscv-vector-builtins-functions.def (vsext): New macro
51214         define.
51215         (vzext): Ditto.
51216         * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_def): Adjust
51217         for vsext/vzext support.
51218         * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_WEXTI_OPS): New
51219         macro define.
51220         (DEF_RVV_QEXTI_OPS): Ditto.
51221         (DEF_RVV_OEXTI_OPS): Ditto.
51222         (DEF_RVV_WEXTU_OPS): Ditto.
51223         (DEF_RVV_QEXTU_OPS): Ditto.
51224         (DEF_RVV_OEXTU_OPS): Ditto.
51225         (vint16mf4_t): Ditto.
51226         (vint16mf2_t): Ditto.
51227         (vint16m1_t): Ditto.
51228         (vint16m2_t): Ditto.
51229         (vint16m4_t): Ditto.
51230         (vint16m8_t): Ditto.
51231         (vint32mf2_t): Ditto.
51232         (vint32m1_t): Ditto.
51233         (vint32m2_t): Ditto.
51234         (vint32m4_t): Ditto.
51235         (vint32m8_t): Ditto.
51236         (vint64m1_t): Ditto.
51237         (vint64m2_t): Ditto.
51238         (vint64m4_t): Ditto.
51239         (vint64m8_t): Ditto.
51240         (vuint16mf4_t): Ditto.
51241         (vuint16mf2_t): Ditto.
51242         (vuint16m1_t): Ditto.
51243         (vuint16m2_t): Ditto.
51244         (vuint16m4_t): Ditto.
51245         (vuint16m8_t): Ditto.
51246         (vuint32mf2_t): Ditto.
51247         (vuint32m1_t): Ditto.
51248         (vuint32m2_t): Ditto.
51249         (vuint32m4_t): Ditto.
51250         (vuint32m8_t): Ditto.
51251         (vuint64m1_t): Ditto.
51252         (vuint64m2_t): Ditto.
51253         (vuint64m4_t): Ditto.
51254         (vuint64m8_t): Ditto.
51255         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_WEXTI_OPS): Ditto.
51256         (DEF_RVV_QEXTI_OPS): Ditto.
51257         (DEF_RVV_OEXTI_OPS): Ditto.
51258         (DEF_RVV_WEXTU_OPS): Ditto.
51259         (DEF_RVV_QEXTU_OPS): Ditto.
51260         (DEF_RVV_OEXTU_OPS): Ditto.
51261         (rvv_arg_type_info::get_base_vector_type): Add sign_exted/zero_extend
51262         support.
51263         (rvv_arg_type_info::get_tree_type): Ditto.
51264         * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Ditto.
51265         * config/riscv/vector-iterators.md (z): New attribute.
51266         * config/riscv/vector.md (@pred_<optab><mode>_vf2): New pattern.
51267         (@pred_<optab><mode>_vf4): Ditto.
51268         (@pred_<optab><mode>_vf8): Ditto.
51270 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51272         * config/riscv/iterators.md: Add saturating Addition && Subtraction.
51273         * config/riscv/riscv-v.cc (has_vi_variant_p): Ditto.
51274         * config/riscv/riscv-vector-builtins-bases.cc (BASE): Ditto.
51275         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
51276         * config/riscv/riscv-vector-builtins-functions.def (vsadd): New def.
51277         (vssub): Ditto.
51278         (vsaddu): Ditto.
51279         (vssubu): Ditto.
51280         * config/riscv/vector-iterators.md (sll.vi): Adjust for Saturating
51281         support.
51282         (sll.vv): Ditto.
51283         (%3,%v4): Ditto.
51284         (%3,%4): Ditto.
51285         * config/riscv/vector.md (@pred_<optab><mode>): New pattern.
51286         (@pred_<optab><mode>_scalar): New pattern.
51287         (*pred_<optab><mode>_scalar): New pattern.
51288         (*pred_<optab><mode>_extended_scalar): New pattern.
51290 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51292         * config/riscv/iterators.md: Add neg and not.
51293         * config/riscv/riscv-vector-builtins-bases.cc (class unop): New class.
51294         (BASE): Ditto.
51295         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
51296         * config/riscv/riscv-vector-builtins-functions.def (vadd): Rename binop
51297         into alu.
51298         (vsub): Ditto.
51299         (vand): Ditto.
51300         (vor): Ditto.
51301         (vxor): Ditto.
51302         (vsll): Ditto.
51303         (vsra): Ditto.
51304         (vsrl): Ditto.
51305         (vmin): Ditto.
51306         (vmax): Ditto.
51307         (vminu): Ditto.
51308         (vmaxu): Ditto.
51309         (vmul): Ditto.
51310         (vdiv): Ditto.
51311         (vrem): Ditto.
51312         (vdivu): Ditto.
51313         (vremu): Ditto.
51314         (vrsub): Ditto.
51315         (vneg): Ditto.
51316         (vnot): Ditto.
51317         * config/riscv/riscv-vector-builtins-shapes.cc (struct binop_def): Ditto.
51318         (struct alu_def): Ditto.
51319         (SHAPE): Ditto.
51320         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
51321         * config/riscv/riscv-vector-builtins.cc: Support unary C/C/++.
51322         * config/riscv/vector-iterators.md: New iterator.
51323         * config/riscv/vector.md (@pred_<optab><mode>): New pattern
51325 2023-02-12  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51327         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::compute_probabilities): Skip exit block.
51329 2023-02-11  Jakub Jelinek  <jakub@redhat.com>
51331         PR ipa/108605
51332         * ipa-cp.cc (ipa_agg_value_from_jfunc): Return NULL_TREE also if
51333         item->offset bit position is too large to be representable as
51334         unsigned int byte position.
51336 2023-02-11  Gerald Pfeifer  <gerald@pfeifer.com>
51338         * doc/extend.texi (Other Builtins): Adjust link to WG14 N965.
51340 2023-02-10  Vladimir N. Makarov  <vmakarov@redhat.com>
51342         * ira.cc (update_equiv_regs): Set up ira_reg_equiv for
51343         valid_combine only when ira_use_lra_p is true.
51345 2023-02-10  Vladimir N. Makarov  <vmakarov@redhat.com>
51347         * params.opt (ira-simple-lra-insn-threshold): Add new param.
51348         * ira.cc (ira): Use the param to switch on simple LRA.
51350 2023-02-10  Andrew MacLeod  <amacleod@redhat.com>
51352         PR tree-optimization/108687
51353         * gimple-range-cache.cc (ranger_cache::range_on_edge): Revert
51354         back to RFD_NONE mode for calculations.
51355         (ranger_cache::propagate_cache): Call the internal edge range API
51356         with RFD_READ_ONLY instead of changing the external routine.
51358 2023-02-10  Andrew MacLeod  <amacleod@redhat.com>
51360         PR tree-optimization/108520
51361         * gimple-range-infer.cc (check_assume_func): Invoke
51362         gimple_range_global directly instead using global_range_query.
51363         * value-query.cc (get_range_global): Add function context and
51364         avoid calling nonnull_arg_p if not cfun.
51365         (gimple_range_global): Add function context pointer.
51366         * value-query.h (imple_range_global): Add function context.
51368 2023-02-10  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51370         * config/riscv/constraints.md (Wdm): Adjust constraint.
51371         (Wbr): New constraint.
51372         * config/riscv/predicates.md (reg_or_int_operand): New predicate.
51373         * config/riscv/riscv-protos.h (emit_pred_op): Remove function.
51374         (emit_vlmax_op): New function.
51375         (emit_nonvlmax_op): Ditto.
51376         (simm32_p): Ditto.
51377         (neg_simm5_p): Ditto.
51378         (has_vi_variant_p): Ditto.
51379         * config/riscv/riscv-v.cc (emit_pred_op): Adjust function.
51380         (emit_vlmax_op): New function.
51381         (emit_nonvlmax_op): Ditto.
51382         (expand_const_vector): Adjust function.
51383         (legitimize_move): Ditto.
51384         (simm32_p): New function.
51385         (simm5_p): Ditto.
51386         (neg_simm5_p): Ditto.
51387         (has_vi_variant_p): Ditto.
51388         * config/riscv/riscv-vector-builtins-bases.cc (class vrsub): New class.
51389         (BASE): Ditto.
51390         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
51391         * config/riscv/riscv-vector-builtins-functions.def (vmin): Remove
51392         unsigned cases.
51393         (vmax): Ditto.
51394         (vminu): Remove signed cases.
51395         (vmaxu): Ditto.
51396         (vdiv): Remove unsigned cases.
51397         (vrem): Ditto.
51398         (vdivu): Remove signed cases.
51399         (vremu): Ditto.
51400         (vadd): Adjust.
51401         (vsub): Ditto.
51402         (vrsub): New class.
51403         (vand): Adjust.
51404         (vor): Ditto.
51405         (vxor): Ditto.
51406         (vmul): Ditto.
51407         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_U_OPS): New macro.
51408         * config/riscv/riscv.h: change VL/VTYPE as fixed reg.
51409         * config/riscv/vector-iterators.md: New iterators.
51410         * config/riscv/vector.md (@pred_broadcast<mode>): Adjust pattern for vx
51411         support.
51412         (@pred_<optab><mode>_scalar): New pattern.
51413         (@pred_sub<mode>_reverse_scalar): Ditto.
51414         (*pred_<optab><mode>_scalar): Ditto.
51415         (*pred_<optab><mode>_extended_scalar): Ditto.
51416         (*pred_sub<mode>_reverse_scalar): Ditto.
51417         (*pred_sub<mode>_extended_reverse_scalar): Ditto.
51419 2023-02-10  Richard Biener  <rguenther@suse.de>
51421         PR tree-optimization/108724
51422         * tree-vect-stmts.cc (vectorizable_operation): Avoid
51423         using word_mode vectors when vector lowering will
51424         decompose them to elementwise operations.
51426 2023-02-10  Jakub Jelinek  <jakub@redhat.com>
51428         Revert:
51429         2023-02-09  Martin Liska  <mliska@suse.cz>
51431         PR target/100758
51432         * doc/extend.texi: Document that the function
51433         does not work correctly for old VIA processors.
51435 2023-02-10  Andrew Pinski  <apinski@marvell.com>
51436             Andrew Macleod   <amacleod@redhat.com>
51438         PR tree-optimization/108684
51439         * tree-ssa-dce.cc (simple_dce_from_worklist):
51440         Check all ssa names and not just non-vdef ones
51441         before accepting the inline-asm.
51442         Call unlink_stmt_vdef on the statement before
51443         removing it.
51445 2023-02-09  Vladimir N. Makarov  <vmakarov@redhat.com>
51447         * ira.h (struct ira_reg_equiv_s): Add new field caller_save_p.
51448         * ira.cc (validate_equiv_mem): Check memref address variance.
51449         (no_equiv): Clear caller_save_p flag.
51450         (update_equiv_regs): Define caller save equivalence for
51451         valid_combine.
51452         (setup_reg_equiv): Clear defined_p flag for caller save equivalence.
51453         * lra-constraints.cc (lra_copy_reg_equiv): Add new arg
51454         call_save_p.  Use caller save equivalence depending on the arg.
51455         (split_reg): Adjust the call.
51457 2023-02-09  Jakub Jelinek  <jakub@redhat.com>
51459         PR target/100758
51460         * common/config/i386/cpuinfo.h (get_zhaoxin_cpu): Formatting fixes.
51461         (cpu_indicator_init): Call get_available_features for all CPUs with
51462         max_level >= 1, rather than just Intel, AMD or Zhaoxin.  Formatting
51463         fixes.
51465 2023-02-09  Jakub Jelinek  <jakub@redhat.com>
51467         PR tree-optimization/108688
51468         * match.pd (bit_field_ref [bit_insert]): Simplify BIT_FIELD_REF
51469         of BIT_INSERT_EXPR extracting exactly all inserted bits even
51470         when without mode precision.  Formatting fixes.
51472 2023-02-09  Andrew Pinski  <apinski@marvell.com>
51474         PR tree-optimization/108688
51475         * match.pd (bit_field_ref [bit_insert]): Avoid generating
51476         BIT_FIELD_REFs of non-mode-precision integral operands.
51478 2023-02-09  Martin Liska  <mliska@suse.cz>
51480         PR target/100758
51481         * doc/extend.texi: Document that the function
51482         does not work correctly for old VIA processors.
51484 2023-02-09  Andreas Schwab  <schwab@suse.de>
51486         * lto-wrapper.cc (merge_and_complain): Handle
51487         -funwind-tables and -fasynchronous-unwind-tables.
51488         (append_compiler_options): Likewise.
51490 2023-02-09  Richard Biener  <rguenther@suse.de>
51492         PR tree-optimization/26854
51493         * tree-into-ssa.cc (update_ssa): Turn blocks_to_update to tree
51494         view around insert_updated_phi_nodes_for.
51495         * tree-ssa-alias.cc (maybe_skip_until): Allocate visited bitmap
51496         in tree view.
51497         (walk_aliased_vdefs_1): Likewise.
51499 2023-02-08  Gerald Pfeifer  <gerald@pfeifer.com>
51501         * doc/include/gpl_v3.texi: Change fsf.org to www.fsf.org.
51503 2023-02-08  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
51505         PR target/108505
51506         * config.gcc (tm_mlib_file): Define new variable.
51508 2023-02-08  Jakub Jelinek  <jakub@redhat.com>
51510         PR tree-optimization/108692
51511         * tree-vect-patterns.cc (vect_widened_op_tree): If rhs_code is
51512         widened_code which is different from code, don't call
51513         vect_look_through_possible_promotion but instead just check op is
51514         SSA_NAME with integral type for which vect_is_simple_use is true
51515         and call set_op on this_unprom.
51517 2023-02-08  Andrea Corallo  <andrea.corallo@arm.com>
51519         * config/aarch64/aarch64-protos.h (aarch_ra_sign_key): Remove
51520         declaration.
51521         * config/aarch64/aarch64.cc (aarch_ra_sign_key): Remove
51522         definition.
51523         * config/aarch64/aarch64.opt (aarch64_ra_sign_key): Rename
51524         to 'aarch_ra_sign_key'.
51525         * config/arm/aarch-common.cc (aarch_ra_sign_key): Remove
51526         declaration.
51527         * config/arm/arm-protos.h (aarch_ra_sign_key): Likewise.
51528         * config/arm/arm.cc (enum aarch_key_type): Remove definition.
51529         * config/arm/arm.opt: Define.
51531 2023-02-08  Richard Sandiford  <richard.sandiford@arm.com>
51533         PR tree-optimization/108316
51534         * tree-vect-stmts.cc (get_load_store_type): When using
51535         internal functions for gather/scatter, make sure that the type
51536         of the offset argument is consistent with the offset vector type.
51538 2023-02-08  Vladimir N. Makarov  <vmakarov@redhat.com>
51540         Revert:
51541         2023-02-07  Vladimir N. Makarov  <vmakarov@redhat.com>
51543         * ira.h (struct ira_reg_equiv_s): Add new field caller_save_p.
51544         * ira.cc (validate_equiv_mem): Check memref address variance.
51545         (update_equiv_regs): Define caller save equivalence for
51546         valid_combine.
51547         (setup_reg_equiv): Clear defined_p flag for caller save equivalence.
51548         * lra-constraints.cc (lra_copy_reg_equiv): Add new arg
51549         call_save_p.  Use caller save equivalence depending on the arg.
51550         (split_reg): Adjust the call.
51552 2023-02-08  Jakub Jelinek  <jakub@redhat.com>
51554         * tree.def (SAD_EXPR): Remove outdated comment about missing
51555         WIDEN_MINUS_EXPR.
51557 2023-02-07  Marek Polacek  <polacek@redhat.com>
51559         * doc/invoke.texi: Update -fchar8_t documentation.
51561 2023-02-07  Vladimir N. Makarov  <vmakarov@redhat.com>
51563         * ira.h (struct ira_reg_equiv_s): Add new field caller_save_p.
51564         * ira.cc (validate_equiv_mem): Check memref address variance.
51565         (update_equiv_regs): Define caller save equivalence for
51566         valid_combine.
51567         (setup_reg_equiv): Clear defined_p flag for caller save equivalence.
51568         * lra-constraints.cc (lra_copy_reg_equiv): Add new arg
51569         call_save_p.  Use caller save equivalence depending on the arg.
51570         (split_reg): Adjust the call.
51572 2023-02-07  Richard Biener  <rguenther@suse.de>
51574         PR tree-optimization/26854
51575         * gimple-fold.cc (has_use_on_stmt): Look at stmt operands
51576         instead of immediate uses.
51578 2023-02-07  Jakub Jelinek  <jakub@redhat.com>
51580         PR tree-optimization/106923
51581         * ipa-split.cc (execute_split_functions): Don't split returns_twice
51582         functions.
51584 2023-02-07  Jakub Jelinek  <jakub@redhat.com>
51586         PR tree-optimization/106433
51587         * cgraph.cc (set_const_flag_1): Recurse on simd clones too.
51588         (cgraph_node::set_pure_flag): Call set_pure_flag_1 on simd clones too.
51590 2023-02-07  Jan Hubicka  <jh@suse.cz>
51592         * config/i386/x86-tune.def (X86_TUNE_AVX256_OPTIMAL): Turn off
51593         for znver4.
51595 2023-02-06  Andrew Stubbs  <ams@codesourcery.com>
51597         * config/gcn/mkoffload.cc (gcn_stack_size): New global variable.
51598         (process_asm): Create a constructor for GCN_STACK_SIZE.
51599         (main): Parse the -mstack-size option.
51601 2023-02-06  Alex Coplan  <alex.coplan@arm.com>
51603         PR target/104921
51604         * config/aarch64/aarch64-simd.md (aarch64_bfmlal<bt>_lane<q>v4sf):
51605         Use correct constraint for operand 3.
51607 2023-02-06  Martin Jambor  <mjambor@suse.cz>
51609         * ipa-sra.cc (adjust_parameter_descriptions): Fix a typo in a dump.
51611 2023-02-06  Xi Ruoyao  <xry111@xry111.site>
51613         * config/loongarch/loongarch.md (bytepick_w_ashift_amount):
51614         New define_int_iterator.
51615         (bytepick_d_ashift_amount): Likewise.
51616         (bytepick_imm): New define_int_attr.
51617         (bytepick_w_lshiftrt_amount): Likewise.
51618         (bytepick_d_lshiftrt_amount): Likewise.
51619         (bytepick_w_<bytepick_imm>): New define_insn template.
51620         (bytepick_w_<bytepick_imm>_extend): Likewise.
51621         (bytepick_d_<bytepick_imm>): Likewise.
51622         (bytepick_w): Remove unused define_insn.
51623         (bytepick_d): Likewise.
51624         (UNSPEC_BYTEPICK_W): Remove unused unspec.
51625         (UNSPEC_BYTEPICK_D): Likewise.
51626         * config/loongarch/predicates.md (const_0_to_3_operand):
51627         Remove unused define_predicate.
51628         (const_0_to_7_operand): Likewise.
51630 2023-02-06  Jakub Jelinek  <jakub@redhat.com>
51632         PR tree-optimization/108655
51633         * ubsan.cc (sanitize_unreachable_fn): For -funreachable-traps
51634         or -fsanitize=unreachable -fsanitize-trap=unreachable return
51635         BUILT_IN_UNREACHABLE_TRAP decl rather than BUILT_IN_TRAP.
51637 2023-02-05  Gerald Pfeifer  <gerald@pfeifer.com>
51639         * doc/install.texi (Specific): Remove PW32.
51641 2023-02-03  Jakub Jelinek  <jakub@redhat.com>
51643         PR tree-optimization/108647
51644         * range-op.cc (operator_equal::op1_range,
51645         operator_not_equal::op1_range): Don't test op2 bound
51646         equality if op2.undefined_p (), instead set_varying.
51647         (operator_lt::op1_range, operator_le::op1_range,
51648         operator_gt::op1_range, operator_ge::op1_range): Return false if
51649         op2.undefined_p ().
51650         (operator_lt::op2_range, operator_le::op2_range,
51651         operator_gt::op2_range, operator_ge::op2_range): Return false if
51652         op1.undefined_p ().
51654 2023-02-03  Aldy Hernandez  <aldyh@redhat.com>
51656         PR tree-optimization/108639
51657         * value-range.cc (irange::legacy_equal_p): Compare nonzero bits as
51658         widest_int.
51659         (irange::operator==): Same.
51661 2023-02-03  Aldy Hernandez  <aldyh@redhat.com>
51663         PR tree-optimization/108647
51664         * range-op-float.cc (foperator_lt::op1_range): Handle undefined ranges.
51665         (foperator_lt::op2_range): Same.
51666         (foperator_le::op1_range): Same.
51667         (foperator_le::op2_range): Same.
51668         (foperator_gt::op1_range): Same.
51669         (foperator_gt::op2_range): Same.
51670         (foperator_ge::op1_range): Same.
51671         (foperator_ge::op2_range): Same.
51672         (foperator_unordered_lt::op1_range): Same.
51673         (foperator_unordered_lt::op2_range): Same.
51674         (foperator_unordered_le::op1_range): Same.
51675         (foperator_unordered_le::op2_range): Same.
51676         (foperator_unordered_gt::op1_range): Same.
51677         (foperator_unordered_gt::op2_range): Same.
51678         (foperator_unordered_ge::op1_range): Same.
51679         (foperator_unordered_ge::op2_range): Same.
51681 2023-02-03  Andrew MacLeod  <amacleod@redhat.com>
51683         PR tree-optimization/107570
51684         * tree-vrp.cc (remove_and_update_globals): Reset SCEV.
51686 2023-02-03  Gaius Mulley  <gaiusmod2@gmail.com>
51688         * doc/gm2.texi (Internals): Remove from menu.
51689         (Using): Comment out ifnohtml conditional.
51690         (Documentation): Use gcc url.
51691         (License): Node simplified.
51692         (Copying): New node.  Include gpl_v3_without_node.
51693         (Contributing): Node simplified.
51694         (Internals): Commented out.
51695         (Libraries): Node simplified.
51696         (Indices): Ditto.
51697         (Contents): Ditto.
51698         (Functions): Ditto.
51700 2023-02-03  Christophe Lyon  <christophe.lyon@arm.com>
51702         * config/arm/mve.md (mve_vabavq_p_<supf><mode>): Add length
51703         attribute.
51704         (mve_vqshluq_m_n_s<mode>): Likewise.
51705         (mve_vshlq_m_<supf><mode>): Likewise.
51706         (mve_vsriq_m_n_<supf><mode>): Likewise.
51707         (mve_vsubq_m_<supf><mode>): Likewise.
51709 2023-02-03  Martin Jambor  <mjambor@suse.cz>
51711         PR ipa/108384
51712         * ipa-sra.cc (push_param_adjustments_for_index): Remove a size check
51713         when comparing to an IPA-CP value.
51714         (dump_list_of_param_indices): New function.
51715         (adjust_parameter_descriptions): Check for mismatching IPA-CP values.
51716         Dump removed candidates using dump_list_of_param_indices.
51717         * ipa-param-manipulation.cc
51718         (ipa_param_body_adjustments::modify_expression): Add assert checking
51719         sizes of a VIEW_CONVERT_EXPR will match.
51720         (ipa_param_body_adjustments::modify_assignment): Likewise.
51722 2023-02-03  Monk Chiang  <monk.chiang@sifive.com>
51724         * config/riscv/riscv.h: Remove VL_REGS, VTYPE_REGS class.
51725         * config/riscv/riscv.cc: Ditto.
51727 2023-02-03  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51729         * config/riscv/vector-iterators.md (sll.vi): Fix constraint bug.
51730         (sll.vv): Ditto.
51731         (%3,%4): Ditto.
51732         (%3,%v4): Ditto.
51733         * config/riscv/vector.md: Ditto.
51735 2023-02-03  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
51737         * config/riscv/predicates.md (pmode_reg_or_uimm5_operand): New predicate.
51738         * config/riscv/riscv-vector-builtins-bases.cc: New class.
51739         * config/riscv/riscv-vector-builtins-functions.def (vsll): Ditto.
51740         (vsra): Ditto.
51741         (vsrl): Ditto.
51742         * config/riscv/riscv-vector-builtins.cc: Ditto.
51743         * config/riscv/vector.md (@pred_<optab><mode>_scalar): New pattern.
51745 2023-02-02  Iain Sandoe  <iain@sandoe.co.uk>
51747         * toplev.cc (toplev::main): Only print the version information header
51748         from toplevel main().
51750 2023-02-02  Paul-Antoine Arras  <pa@codesourcery.com>
51752         * config/gcn/gcn-valu.md (cond_<expander><mode>): Add
51753         cond_{ashl|ashr|lshr}
51755 2023-02-02  Richard Sandiford  <richard.sandiford@arm.com>
51757         PR rtl-optimization/108086
51758         * rtl-ssa/insns.h (insn_info): Make m_num_defs a full unsigned int.
51759         Adjust size-related commentary accordingly.
51761 2023-02-02  Richard Sandiford  <richard.sandiford@arm.com>
51763         PR rtl-optimization/108508
51764         * rtl-ssa/accesses.cc (function_info::split_clobber_group): When
51765         the splay tree search gives the first clobber in the second group,
51766         make sure that the root of the first clobber group is updated
51767         correctly.  Enter the new clobber group into the definition splay
51768         tree.
51770 2023-02-02  Jin Ma  <jinma@linux.alibaba.com>
51772         * common/config/riscv/riscv-common.cc (riscv_compute_multilib):
51773         Fix finding best match score.
51775 2023-02-02  Jakub Jelinek  <jakub@redhat.com>
51777         PR debug/106746
51778         PR rtl-optimization/108463
51779         PR target/108484
51780         * cselib.cc (cselib_current_insn): Move declaration earlier.
51781         (cselib_hasher::equal): For debug only locs, temporarily override
51782         cselib_current_insn to their l->setting_insn for the
51783         rtx_equal_for_cselib_1 call, so that unsuccessful comparisons don't
51784         promote some debug locs.
51785         * sched-deps.cc (sched_analyze_2) <case MEM>: For MEMs in DEBUG_INSNs
51786         when using cselib call cselib_lookup_from_insn on the address but
51787         don't substitute it.
51789 2023-02-02  Richard Biener  <rguenther@suse.de>
51791         PR middle-end/108625
51792         * genmatch.cc (expr::gen_transform): Also disallow resimplification
51793         from pushing to lseq with force_leaf.
51794         (dt_simplify::gen_1): Likewise.
51796 2023-02-02  Andrew Stubbs  <ams@codesourcery.com>
51798         * config/gcn/gcn-run.cc: Include libgomp-gcn.h.
51799         (struct kernargs): Replace the common content with kernargs_abi.
51800         (struct heap): Delete.
51801         (main): Read GCN_STACK_SIZE envvar.
51802         Allocate space for the device stacks.
51803         Write the new kernargs fields.
51804         * config/gcn/gcn.cc (gcn_option_override): Remove stack_size_opt.
51805         (default_requested_args): Remove PRIVATE_SEGMENT_BUFFER_ARG and
51806         PRIVATE_SEGMENT_WAVE_OFFSET_ARG.
51807         (gcn_addr_space_convert): Mask the QUEUE_PTR_ARG content.
51808         (gcn_expand_prologue): Move the TARGET_PACKED_WORK_ITEMS to the top.
51809         Set up the stacks from the values in the kernargs, not private.
51810         (gcn_expand_builtin_1): Match the stack configuration in the prologue.
51811         (gcn_hsa_declare_function_name): Turn off the private segment.
51812         (gcn_conditional_register_usage): Ensure QUEUE_PTR is fixed.
51813         * config/gcn/gcn.h (FIXED_REGISTERS): Fix the QUEUE_PTR register.
51814         * config/gcn/gcn.opt (mstack-size): Change the description.
51816 2023-02-02  Andre Vieira  <andre.simoesdiasvieira@arm.com>
51818         PR target/108443
51819         * config/arm/arm.h (VALID_MVE_PRED_MODE): Add V2QI.
51820         * config/arm/arm.cc (thumb2_legitimate_address_p): Use HImode for
51821         addressing MVE predicate modes.
51822         (mve_bool_vec_to_const): Change to represent correct MVE predicate
51823         format.
51824         (arm_hard_regno_mode_ok): Use VALID_MVE_PRED_MODE instead of checking
51825         modes.
51826         (arm_vector_mode_supported_p): Likewise.
51827         (arm_mode_to_pred_mode): Add V2QI.
51828         * config/arm/arm-builtins.cc (UNOP_PRED_UNONE_QUALIFIERS): New
51829         qualifier.
51830         (UNOP_PRED_PRED_QUALIFIERS): New qualifier
51831         (BINOP_PRED_UNONE_PRED_QUALIFIERS): New qualifier.
51832         (v2qi_UP): New macro.
51833         (v4bi_UP): New macro.
51834         (v8bi_UP): New macro.
51835         (v16bi_UP): New macro.
51836         (arm_expand_builtin_args): Make it able to expand the new predicate
51837         modes.
51838         * config/arm/arm-modes.def (V2QI): New mode.
51839         * config/arm/arm-simd-builtin-types.def (Pred1x16_t, Pred2x8_t
51840         Pred4x4_t): Remove unused predicate builtin types.
51841         * config/arm/arm_mve.h (__arm_vctp16q, __arm_vctp32q, __arm_vctp64q,
51842         __arm_vctp8q, __arm_vpnot, __arm_vctp8q_m, __arm_vctp64q_m,
51843         __arm_vctp32q_m, __arm_vctp16q_m): Use predicate modes.
51844         * config/arm/arm_mve_builtins.def (vctp16q, vctp32q, vctp64q, vctp8q,
51845         vpnot, vctp8q_m, vctp16q_m, vctp32q_m, vctp64q_m): Likewise.
51846         * config/arm/constraints.md (DB): Check for VALID_MVE_PRED_MODE instead
51847         of MODE_VECTOR_BOOL.
51848         * config/arm/iterators.md (MVE_7, MVE_7_HI): Add V2QI
51849         (MVE_VPRED): Likewise.
51850         (MVE_vpred): Add V2QI and map upper case predicate modes to lower case.
51851         (MVE_vctp): New mode attribute.
51852         (mode1): Remove.
51853         (VCTPQ): Remove.
51854         (VCTPQ_M): Remove.
51855         * config/arm/mve.md (mve_vctp<mode1>qhi): Rename this...
51856         (mve_vctp<MVE_vctp>q<MVE_vpred>): ... to this. And use new mode
51857         attributes.
51858         (mve_vpnothi): Rename this...
51859         (mve_vpnotv16bi): ... to this.
51860         (mve_vctp<mode1>q_mhi): Rename this...
51861         (mve_vctp<MVE_vctp>q_m<MVE_vpred>):... to this.
51862         (mve_vldrdq_gather_base_z_<supf>v2di,
51863         mve_vldrdq_gather_offset_z_<supf>v2di,
51864         mve_vldrdq_gather_shifted_offset_z_<supf>v2di,
51865         mve_vstrdq_scatter_base_p_<supf>v2di,
51866         mve_vstrdq_scatter_offset_p_<supf>v2di,
51867         mve_vstrdq_scatter_offset_p_<supf>v2di_insn,
51868         mve_vstrdq_scatter_shifted_offset_p_<supf>v2di,
51869         mve_vstrdq_scatter_shifted_offset_p_<supf>v2di_insn,
51870         mve_vstrdq_scatter_base_wb_p_<supf>v2di,
51871         mve_vldrdq_gather_base_wb_z_<supf>v2di,
51872         mve_vldrdq_gather_base_nowb_z_<supf>v2di,
51873         mve_vldrdq_gather_base_wb_z_<supf>v2di_insn):  Use V2QI insead of HI for
51874         predicates.
51875         * config/arm/unspecs.md (VCTP8Q, VCTP16Q, VCTP32Q, VCTP64Q): Replace
51876         these...
51877         (VCTP): ... with this.
51878         (VCTP8Q_M, VCTP16Q_M, VCTP32Q_M, VCTP64Q_M): Replace these...
51879         (VCTP_M): ... with this.
51880         * config/arm/vfp.md (*thumb2_movhi_vfp, *thumb2_movhi_fp16): Use
51881         VALID_MVE_PRED_MODE instead of checking for MODE_VECTOR_BOOL class.
51883 2023-02-02  Andre Vieira  <andre.simoesdiasvieira@arm.com>
51885         PR target/107674
51886         * config/arm/arm.cc (arm_hard_regno_mode_ok): Use new MACRO.
51887         (arm_modes_tieable_p): Make MVE predicate modes tieable.
51888         * config/arm/arm.h (VALID_MVE_PRED_MODE):  New define.
51889         * simplify-rtx.cc (simplify_context::simplify_subreg): Teach
51890         simplify_subreg to simplify subregs where the outermode is not scalar.
51892 2023-02-02  Andre Vieira  <andre.simoesdiasvieira@arm.com>
51894         PR target/107674
51895         * config/arm/arm-builtins.cc (arm_simd_builtin_type): Rewrite to use
51896         new qualifiers parameter and use unsigned short type for MVE predicate.
51897         (arm_init_builtin): Call arm_simd_builtin_type with qualifiers
51898         parameter.
51899         (arm_init_crypto_builtins): Likewise.
51901 2023-02-02  Jakub Jelinek  <jakub@redhat.com>
51903         PR ipa/107300
51904         * builtins.def (BUILT_IN_UNREACHABLE_TRAP): New builtin.
51905         * internal-fn.def (TRAP): Remove.
51906         * internal-fn.cc (expand_TRAP): Remove.
51907         * tree.cc (build_common_builtin_nodes): Define
51908         BUILT_IN_UNREACHABLE_TRAP if not yet defined.
51909         (builtin_decl_unreachable): Use BUILT_IN_UNREACHABLE_TRAP
51910         instead of BUILT_IN_TRAP.
51911         * gimple.cc (gimple_build_builtin_unreachable): Remove
51912         emitting internal function for BUILT_IN_TRAP.
51913         * asan.cc (maybe_instrument_call): Handle BUILT_IN_UNREACHABLE_TRAP.
51914         * cgraph.cc (cgraph_edge::verify_corresponds_to_fndecl): Handle
51915         BUILT_IN_UNREACHABLE_TRAP instead of BUILT_IN_TRAP.
51916         * ipa-devirt.cc (possible_polymorphic_call_target_p): Handle
51917         BUILT_IN_UNREACHABLE_TRAP.
51918         * builtins.cc (expand_builtin, is_inexpensive_builtin): Likewise.
51919         * tree-cfg.cc (verify_gimple_call,
51920         pass_warn_function_return::execute): Likewise.
51921         * attribs.cc (decl_attributes): Don't report exclusions on
51922         BUILT_IN_UNREACHABLE_TRAP either.
51924 2023-02-02  liuhongt  <hongtao.liu@intel.com>
51926         PR tree-optimization/108601
51927         * tree-vectorizer.h (vect_can_peel_nonlinear_iv_p): Removed.
51928         * tree-vect-loop.cc
51929         (vectorizable_nonlinear_induction): Remove
51930         vect_can_peel_nonlinear_iv_p.
51931         (vect_can_peel_nonlinear_iv_p): Don't peel
51932         nonlinear iv(mult or shift) for epilog when vf is not
51933         constant and moved the defination to ..
51934         * tree-vect-loop-manip.cc (vect_can_peel_nonlinear_iv_p):
51935         .. Here.
51937 2023-02-02  Jakub Jelinek  <jakub@redhat.com>
51939         PR middle-end/108435
51940         * tree-nested.cc (convert_nonlocal_omp_clauses)
51941         <case OMP_CLAUSE_LASTPRIVATE>: If info->new_local_var_chain and *seq
51942         is not a GIMPLE_BIND, wrap the sequence into a new GIMPLE_BIND
51943         before calling declare_vars.
51944         (convert_nonlocal_omp_clauses) <case OMP_CLAUSE_LINEAR>: Merge
51945         with the OMP_CLAUSE_LASTPRIVATE handling except for whether
51946         seq is initialized to &OMP_CLAUSE_LASTPRIVATE_GIMPLE_SEQ (clause)
51947         or &OMP_CLAUSE_LINEAR_GIMPLE_SEQ (clause).
51949 2023-02-01  Tamar Christina  <tamar.christina@arm.com>
51951         * common/config/aarch64/aarch64-common.cc
51952         (struct aarch64_option_extension): Add native_detect and document struct
51953         a bit more.
51954         (all_extensions): Set new field native_detect.
51955         * config/aarch64/aarch64.cc (struct aarch64_option_extension): Delete
51956         unused struct.
51958 2023-02-01  Martin Liska  <mliska@suse.cz>
51960         * ipa-devirt.cc (odr_types_equivalent_p): Respect *warned
51961         value if set.
51963 2023-02-01  Andrew MacLeod  <amacleod@redhat.com>
51965         PR tree-optimization/108356
51966         * gimple-range-cache.cc (ranger_cache::range_on_edge): Always
51967         do a search of the DOM tree for a range.
51969 2023-02-01  Martin Liska  <mliska@suse.cz>
51971         PR ipa/108509
51972         * cgraphunit.cc (walk_polymorphic_call_targets): Insert
51973         ony non-null values.
51974         * ipa.cc (walk_polymorphic_call_targets): Likewise.
51976 2023-02-01  Martin Liska  <mliska@suse.cz>
51978         PR driver/108572
51979         * gcc.cc (LINK_COMPRESS_DEBUG_SPEC): Report error only for
51980         -gz=zstd.
51982 2023-02-01  Jakub Jelinek  <jakub@redhat.com>
51984         PR debug/108573
51985         * ree.cc (combine_reaching_defs): Don't return false for paradoxical
51986         subregs in DEBUG_INSNs.
51988 2023-02-01  Richard Sandiford  <richard.sandiford@arm.com>
51990         * compare-elim.cc (find_flags_uses_in_insn): Guard use of SET_SRC.
51992 2023-02-01  Andreas Krebbel  <krebbel@linux.ibm.com>
51994         * config/s390/s390.cc (s390_restore_gpr_p): New function.
51995         (s390_preserve_gpr_arg_in_range_p): New function.
51996         (s390_preserve_gpr_arg_p): New function.
51997         (s390_preserve_fpr_arg_p): New function.
51998         (s390_register_info_stdarg_fpr): Rename to ...
51999         (s390_register_info_arg_fpr): ... this. Add -mpreserve-args handling.
52000         (s390_register_info_stdarg_gpr): Rename to ...
52001         (s390_register_info_arg_gpr): ... this. Add -mpreserve-args handling.
52002         (s390_register_info): Use the renamed functions above.
52003         (s390_optimize_register_info): Likewise.
52004         (save_fpr): Generate CFI for -mpreserve-args.
52005         (save_gprs): Generate CFI for -mpreserve-args. Drop return value.
52006         (s390_emit_prologue): Adjust to changed calling convention of save_gprs.
52007         (s390_optimize_prologue): Likewise.
52008         * config/s390/s390.opt: New option -mpreserve-args
52010 2023-02-01  Andreas Krebbel  <krebbel@linux.ibm.com>
52012         * config/s390/s390.cc (save_gprs): Use gen_frame_mem.
52013         (restore_gprs): Likewise.
52014         (s390_emit_stack_tie): Make the stack_tie to be dependent on the
52015         frame pointer if a frame-pointer is used.
52016         (s390_emit_prologue): Emit stack_tie when frame-pointer is needed.
52017         * config/s390/s390.md (stack_tie): Add a register operand and
52018         rename to ...
52019         (@stack_tie<mode>): ... this.
52021 2023-02-01  Andreas Krebbel  <krebbel@linux.ibm.com>
52023         * dwarf2cfi.cc (dwarf2out_frame_debug_cfa_restore): Add
52024         EMIT_CFI parameter.
52025         (dwarf2out_frame_debug): Add case for REG_CFA_NORESTORE.
52026         * reg-notes.def (REG_CFA_NOTE): New reg note definition.
52028 2023-02-01  Richard Biener  <rguenther@suse.de>
52030         PR middle-end/108500
52031         * dominance.cc (assign_dfs_numbers): Replace recursive DFS
52032         with tree traversal algorithm.
52034 2023-02-01  Jason Merrill  <jason@redhat.com>
52036         * doc/invoke.texi: Document -Wno-changes-meaning.
52038 2023-02-01  David Malcolm  <dmalcolm@redhat.com>
52040         * doc/invoke.texi (Static Analyzer Options): Add notes about
52041         limitations of -fanalyzer.
52043 2023-01-31  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52045         * config/riscv/constraints.md (vj): New.
52046         (vk): Ditto
52047         * config/riscv/iterators.md: Add more opcode.
52048         * config/riscv/predicates.md (vector_arith_operand): New.
52049         (vector_neg_arith_operand): New.
52050         (vector_shift_operand): New.
52051         * config/riscv/riscv-vector-builtins-bases.cc (class binop): New.
52052         * config/riscv/riscv-vector-builtins-bases.h: (vadd): New.
52053         (vsub): Ditto.
52054         (vand): Ditto.
52055         (vor): Ditto.
52056         (vxor): Ditto.
52057         (vsll): Ditto.
52058         (vsra): Ditto.
52059         (vsrl): Ditto.
52060         (vmin): Ditto.
52061         (vmax): Ditto.
52062         (vminu): Ditto.
52063         (vmaxu): Ditto.
52064         (vmul): Ditto.
52065         (vdiv): Ditto.
52066         (vrem): Ditto.
52067         (vdivu): Ditto.
52068         (vremu): Ditto.
52069         * config/riscv/riscv-vector-builtins-functions.def (vadd): New.
52070         (vsub): Ditto.
52071         (vand): Ditto.
52072         (vor): Ditto.
52073         (vxor): Ditto.
52074         (vsll): Ditto.
52075         (vsra): Ditto.
52076         (vsrl): Ditto.
52077         (vmin): Ditto.
52078         (vmax): Ditto.
52079         (vminu): Ditto.
52080         (vmaxu): Ditto.
52081         (vmul): Ditto.
52082         (vdiv): Ditto.
52083         (vrem): Ditto.
52084         (vdivu): Ditto.
52085         (vremu): Ditto.
52086         * config/riscv/riscv-vector-builtins-shapes.cc (struct binop_def): New.
52087         * config/riscv/riscv-vector-builtins-shapes.h (binop): New.
52088         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_I_OPS): New.
52089         (DEF_RVV_U_OPS): New.
52090         (rvv_arg_type_info::get_base_vector_type): Handle
52091         RVV_BASE_shift_vector.
52092         (rvv_arg_type_info::get_tree_type): Ditto.
52093         * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Add
52094         RVV_BASE_shift_vector.
52095         * config/riscv/riscv.cc (riscv_print_operand): Handle 'V'.
52096         * config/riscv/vector-iterators.md: Handle more opcode.
52097         * config/riscv/vector.md (@pred_<optab><mode>): New.
52099 2023-01-31  Philipp Tomsich  <philipp.tomsich@vrull.eu>
52101         PR target/108589
52102         * config/aarch64/aarch64.cc (aarch_macro_fusion_pair_p): Check
52103         REG_P on SET_DEST.
52105 2023-01-31  Richard Sandiford  <richard.sandiford@arm.com>
52107         PR tree-optimization/108608
52108         * tree-vect-loop.cc (vect_transform_reduction): Handle single
52109         def-use cycles that involve function calls rather than tree codes.
52111 2023-01-31  Andrew MacLeod  <amacleod@redhat.com>
52113         PR tree-optimization/108385
52114         * gimple-range-gori.cc (gori_compute::compute_operand_range):
52115         Allow VARYING computations to continue if there is a relation.
52116         * range-op.cc (pointer_plus_operator::op2_range): New.
52118 2023-01-31  Andrew MacLeod  <amacleod@redhat.com>
52120         PR tree-optimization/108359
52121         * range-op.cc (range_operator::wi_fold_in_parts_equiv): New.
52122         (range_operator::fold_range): If op1 is equivalent to op2 then
52123         invoke new fold_in_parts_equiv to operate on sub-components.
52124         * range-op.h (wi_fold_in_parts_equiv): New prototype.
52126 2023-01-31  Andrew MacLeod  <amacleod@redhat.com>
52128         * gimple-range-gori.cc (gori_compute::compute_operand_range): Do
52129         not abort calculations if there is a valid relation available.
52130         (gori_compute::refine_using_relation): Pass correct relation trio.
52131         (gori_compute::compute_operand1_range): Create trio and use it.
52132         (gori_compute::compute_operand2_range): Ditto.
52133         * range-op.cc (operator_plus::op1_range): Use correct trio member.
52134         (operator_minus::op1_range): Use correct trio member.
52135         * value-relation.cc (value_relation::create_trio): New.
52136         * value-relation.h (value_relation::create_trio): New prototype.
52138 2023-01-31  Jakub Jelinek  <jakub@redhat.com>
52140         PR target/108599
52141         * config/i386/i386-expand.cc
52142         (ix86_convert_const_wide_int_to_broadcast): Return nullptr if
52143         CONST_WIDE_INT_NUNITS (op) times HOST_BITS_PER_WIDE_INT isn't
52144         equal to bitsize of mode.
52146 2023-01-31  Jakub Jelinek  <jakub@redhat.com>
52148         PR rtl-optimization/108596
52149         * bb-reorder.cc (fix_up_fall_thru_edges): Handle the case where cur_bb
52150         ends with asm goto and has a crossing fallthrough edge to the same bb
52151         that contains at least one of its labels by restoring EDGE_CROSSING
52152         flag even on possible edge from cur_bb to new_bb successor.
52154 2023-01-31  Jakub Jelinek  <jakub@redhat.com>
52156         PR c++/105593
52157         * config/i386/avx512erintrin.h (_mm512_exp2a23_round_pd,
52158         _mm512_exp2a23_round_ps, _mm512_rcp28_round_pd, _mm512_rcp28_round_ps,
52159         _mm512_rsqrt28_round_pd, _mm512_rsqrt28_round_ps): Use
52160         _mm512_undefined_pd () or _mm512_undefined_ps () instead of using
52161         uninitialized automatic variable __W.
52163 2023-01-31  Gerald Pfeifer  <gerald@pfeifer.com>
52165         * doc/include/fdl.texi: Change fsf.org to www.fsf.org.
52167 2023-01-30  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52169         * config/riscv/riscv-protos.h (get_vector_mode): New function.
52170         * config/riscv/riscv-v.cc (get_vector_mode): Ditto.
52171         * config/riscv/riscv-vector-builtins-bases.cc (enum lst_type): New enum.
52172         (class loadstore): Adjust for indexed loads/stores support.
52173         (BASE): Ditto.
52174         * config/riscv/riscv-vector-builtins-bases.h: New function declare.
52175         * config/riscv/riscv-vector-builtins-functions.def (vluxei8): Ditto.
52176         (vluxei16): Ditto.
52177         (vluxei32): Ditto.
52178         (vluxei64): Ditto.
52179         (vloxei8): Ditto.
52180         (vloxei16): Ditto.
52181         (vloxei32): Ditto.
52182         (vloxei64): Ditto.
52183         (vsuxei8): Ditto.
52184         (vsuxei16): Ditto.
52185         (vsuxei32): Ditto.
52186         (vsuxei64): Ditto.
52187         (vsoxei8): Ditto.
52188         (vsoxei16): Ditto.
52189         (vsoxei32): Ditto.
52190         (vsoxei64): Ditto.
52191         * config/riscv/riscv-vector-builtins-shapes.cc
52192         (struct indexed_loadstore_def): New class.
52193         (SHAPE): Ditto.
52194         * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
52195         * config/riscv/riscv-vector-builtins.cc (required_extensions_p): Adjust
52196         for indexed loads/stores support.
52197         (check_required_extensions): Ditto.
52198         (rvv_arg_type_info::get_base_vector_type): New function.
52199         (rvv_arg_type_info::get_tree_type): Ditto.
52200         (function_builder::add_unique_function): Adjust for indexed loads/stores
52201         support.
52202         (function_expander::use_exact_insn): New function.
52203         * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Adjust for
52204         indexed loads/stores support.
52205         (struct rvv_arg_type_info): Ditto.
52206         (function_expander::index_mode): New function.
52207         (function_base::apply_tail_policy_p): Ditto.
52208         (function_base::apply_mask_policy_p): Ditto.
52209         * config/riscv/vector-iterators.md (unspec): New unspec.
52210         * config/riscv/vector.md (unspec): Ditto.
52211         (@pred_indexed_<order>load<VNX1_QHSD:mode><VNX1_QHSDI:mode>): New
52212         pattern.
52213         (@pred_indexed_<order>store<VNX1_QHSD:mode><VNX1_QHSDI:mode>): Ditto.
52214         (@pred_indexed_<order>load<VNX2_QHSD:mode><VNX2_QHSDI:mode>): Ditto.
52215         (@pred_indexed_<order>store<VNX2_QHSD:mode><VNX2_QHSDI:mode>): Ditto.
52216         (@pred_indexed_<order>load<VNX4_QHSD:mode><VNX4_QHSDI:mode>): Ditto.
52217         (@pred_indexed_<order>store<VNX4_QHSD:mode><VNX4_QHSDI:mode>): Ditto.
52218         (@pred_indexed_<order>load<VNX8_QHSD:mode><VNX8_QHSDI:mode>): Ditto.
52219         (@pred_indexed_<order>store<VNX8_QHSD:mode><VNX8_QHSDI:mode>): Ditto.
52220         (@pred_indexed_<order>load<VNX16_QHS:mode><VNX16_QHSI:mode>): Ditto.
52221         (@pred_indexed_<order>store<VNX16_QHS:mode><VNX16_QHSI:mode>): Ditto.
52222         (@pred_indexed_<order>load<VNX32_QH:mode><VNX32_QHI:mode>): Ditto.
52223         (@pred_indexed_<order>store<VNX32_QH:mode><VNX32_QHI:mode>): Ditto.
52224         (@pred_indexed_<order>load<VNX64_Q:mode><VNX64_Q:mode>): Ditto.
52225         (@pred_indexed_<order>store<VNX64_Q:mode><VNX64_Q:mode>): Ditto.
52227 2023-01-30  Flavio Cruz  <flaviocruz@gmail.com>
52229         * config.gcc: Recognize x86_64-*-gnu* targets and include
52230         i386/gnu64.h.
52231         * config/i386/gnu64.h: Define configuration for new target
52232         including ld.so location.
52234 2023-01-30  Philipp Tomsich  <philipp.tomsich@vrull.eu>
52236         * config/aarch64/aarch64-cores.def (AARCH64_CORE): Update
52237         ampere1a to include SM4.
52239 2023-01-30  Andrew Pinski  <apinski@marvell.com>
52241         PR tree-optimization/108582
52242         * tree-ssa-phiopt.cc (match_simplify_replacement): Add check
52243         for middlebb to have no phi nodes.
52245 2023-01-30  Richard Biener  <rguenther@suse.de>
52247         PR tree-optimization/108574
52248         * tree-ssa-sccvn.cc (visit_phi): Instead of swapping
52249         sameval and def, ignore the equivalence if there's the
52250         danger of oscillating between two values.
52252 2023-01-30  Andreas Schwab  <schwab@suse.de>
52254         * common/config/riscv/riscv-common.cc
52255         (riscv_option_optimization_table)
52256         [TARGET_DEFAULT_ASYNC_UNWIND_TABLES]: Enable
52257         -fasynchronous-unwind-tables and -funwind-tables.
52258         * config.gcc (riscv*-*-linux*): Define
52259         TARGET_DEFAULT_ASYNC_UNWIND_TABLES.
52261 2023-01-30  YunQiang Su  <yunqiang.su@cipunited.com>
52263         * Makefile.in (CROSS_SYSTEM_HEADER_DIR): set according the
52264         value of includedir.
52266 2023-01-30  Richard Biener  <rguenther@suse.de>
52268         PR ipa/108511
52269         * cgraph.cc (possibly_call_in_translation_unit_p): Relax
52270         assert.
52272 2023-01-30  liuhongt  <hongtao.liu@intel.com>
52274         * config/i386/i386.opt: Change AVX512FP16 to AVX512-FP16.
52275         * doc/invoke.texi: Ditto.
52277 2023-01-29  Jan Hubicka  <hubicka@ucw.cz>
52279         * ipa-utils.cc: Include calls.h, cfgloop.h and cfganal.h
52280         (stmt_may_terminate_function_p): If assuming return or EH
52281         volatile asm is safe.
52282         (find_always_executed_bbs): Fix handling of terminating BBS and
52283         infinite loops; add debug output.
52284         * tree-ssa-alias.cc (stmt_kills_ref_p): Fix debug output
52286 2023-01-28  Philipp Tomsich  <philipp.tomsich@vrull.eu>
52288         * config/aarch64/aarch64.cc (aarch64_uxt_size): fix an
52289         off-by-one in checking the permissible shift-amount.
52291 2023-01-28  Gerald Pfeifer  <gerald@pfeifer.com>
52293         * doc/extend.texi (Named Address Spaces): Update link to the
52294         AVR-Libc manual.
52296 2023-01-28  Gerald Pfeifer  <gerald@pfeifer.com>
52298         * doc/standards.texi (Standards): Fix markup.
52300 2023-01-28  Gerald Pfeifer  <gerald@pfeifer.com>
52302         * doc/standards.texi (Standards): Update link to Objective-C book.
52304 2023-01-28  Gerald Pfeifer  <gerald@pfeifer.com>
52306         * doc/invoke.texi (Instrumentation Options): Update reference to
52307         AddressSanitizer.
52309 2023-01-28  Gerald Pfeifer  <gerald@pfeifer.com>
52311         * doc/standards.texi: Update Go1 link.
52313 2023-01-28  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52315         * config/riscv/predicates.md (pmode_reg_or_0_operand): New predicate.
52316         * config/riscv/riscv-vector-builtins-bases.cc (class loadstore):
52317         Support vlse/vsse.
52318         (BASE): Ditto.
52319         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
52320         * config/riscv/riscv-vector-builtins-functions.def (vlse): New class.
52321         (vsse): New class.
52322         * config/riscv/riscv-vector-builtins.cc
52323         (function_expander::use_contiguous_load_insn): Support vlse/vsse.
52324         * config/riscv/vector.md (@pred_strided_load<mode>): New md pattern.
52325         (@pred_strided_store<mode>): Ditto.
52327 2023-01-28  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52329         * config/riscv/vector.md (tail_policy_op_idx): Remove.
52330         (mask_policy_op_idx): Remove.
52331         (avl_type_op_idx): Remove.
52333 2023-01-27  Richard Sandiford  <richard.sandiford@arm.com>
52335         PR tree-optimization/96373
52336         * tree.h (sign_mask_for): Declare.
52337         * tree.cc (sign_mask_for): New function.
52338         (signed_or_unsigned_type_for): For vector types, try to use the
52339         related_int_vector_mode.
52340         * genmatch.cc (commutative_op): Handle conditional internal functions.
52341         * match.pd: Fold an IFN_COND_MUL+copysign into an IFN_COND_XOR+and.
52343 2023-01-27  Richard Sandiford  <richard.sandiford@arm.com>
52345         * tree-vectorizer.cc (vector_costs::compare_inside_loop_cost):
52346         Use the likely minimum VF when bounding the denominators to
52347         the estimated number of iterations.
52349 2023-01-27  Richard Biener  <rguenther@suse.de>
52351         PR target/55522
52352         * doc/invoke.texi (-shared): Clarify effect on -ffast-math
52353         and -Ofast FP environment side-effects.
52355 2023-01-27  Richard Biener  <rguenther@suse.de>
52357         PR target/55522
52358         * config/mips/gnu-user.h (GNU_USER_TARGET_MATHFILE_SPEC):
52359         Don't add crtfastmath.o for -shared.
52361 2023-01-27  Richard Biener  <rguenther@suse.de>
52363         PR target/55522
52364         * config/ia64/linux.h (ENDFILE_SPEC): Don't add crtfastmath.o
52365         for -shared.
52367 2023-01-27  Richard Biener  <rguenther@suse.de>
52369         PR target/55522
52370         * config/alpha/linux.h (ENDFILE_SPEC): Don't add
52371         crtfastmath.o for -shared.
52373 2023-01-27  Andrew MacLeod  <amacleod@redhat.com>
52375         PR tree-optimization/108306
52376         * range-op.cc (operator_lshift::fold_range): Return [0, 0] not
52377         varying for shifts that are always out of void range.
52378         (operator_rshift::fold_range): Return [0, 0] not
52379         varying for shifts that are always out of void range.
52381 2023-01-27  Andrew MacLeod  <amacleod@redhat.com>
52383         PR tree-optimization/108447
52384         * gimple-range-fold.cc (old_using_range::relation_fold_and_or):
52385         Do not attempt to fold HONOR_NAN types.
52387 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52389         * config/riscv/riscv-vector-builtins-shapes.cc (struct loadstore_def):
52390         Remove _m suffix for "vop_m" C++ overloaded API name.
52392 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52394         * config/riscv/riscv-vector-builtins-bases.cc (BASE): Add vlm/vsm support.
52395         * config/riscv/riscv-vector-builtins-bases.h: Ditto.
52396         * config/riscv/riscv-vector-builtins-functions.def (vlm): New define.
52397         (vsm): Ditto.
52398         * config/riscv/riscv-vector-builtins-shapes.cc (struct loadstore_def): Add vlm/vsm support.
52399         * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_B_OPS): Ditto.
52400         (vbool64_t): Ditto.
52401         (vbool32_t): Ditto.
52402         (vbool16_t): Ditto.
52403         (vbool8_t): Ditto.
52404         (vbool4_t): Ditto.
52405         (vbool2_t): Ditto.
52406         (vbool1_t): Ditto.
52407         * config/riscv/riscv-vector-builtins.cc (DEF_RVV_B_OPS): Ditto.
52408         (rvv_arg_type_info::get_tree_type): Ditto.
52409         (function_expander::use_contiguous_load_insn): Ditto.
52410         * config/riscv/vector.md (@pred_store<mode>): Ditto.
52412 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52414         * config/riscv/riscv-vsetvl.cc (vsetvl_insn_p): Add condition to avoid ICE.
52415         (vsetvl_discard_result_insn_p): New function.
52416         (reg_killed_by_bb_p): rename to find_reg_killed_by.
52417         (find_reg_killed_by): New name.
52418         (get_vl): allow it to be called by more functions.
52419         (has_vsetvl_killed_avl_p): Add condition.
52420         (get_avl): allow it to be called by more functions.
52421         (insn_should_be_added_p): New function.
52422         (get_all_nonphi_defs): Refine function.
52423         (get_all_sets): Ditto.
52424         (get_same_bb_set): New function.
52425         (any_insn_in_bb_p): Ditto.
52426         (any_set_in_bb_p): Ditto.
52427         (get_vl_vtype_info): Add VLMAX forward optimization.
52428         (source_equal_p): Fix issues.
52429         (extract_single_source): Refine.
52430         (avl_info::multiple_source_equal_p): New function.
52431         (avl_info::operator==): Adjust for final version.
52432         (vl_vtype_info::operator==): Ditto.
52433         (vl_vtype_info::same_avl_p): Ditto.
52434         (vector_insn_info::parse_insn): Ditto.
52435         (vector_insn_info::available_p): New function.
52436         (vector_insn_info::merge): Adjust for final version.
52437         (vector_insn_info::dump): Add hard_empty.
52438         (pass_vsetvl::hard_empty_block_p): New function.
52439         (pass_vsetvl::backward_demand_fusion): Adjust for final version.
52440         (pass_vsetvl::forward_demand_fusion): Ditto.
52441         (pass_vsetvl::demand_fusion): Ditto.
52442         (pass_vsetvl::cleanup_illegal_dirty_blocks): New function.
52443         (pass_vsetvl::compute_local_properties): Adjust for final version.
52444         (pass_vsetvl::can_refine_vsetvl_p): Ditto.
52445         (pass_vsetvl::refine_vsetvls): Ditto.
52446         (pass_vsetvl::commit_vsetvls): Ditto.
52447         (pass_vsetvl::propagate_avl): New function.
52448         (pass_vsetvl::lazy_vsetvl): Adjust for new version.
52449         * config/riscv/riscv-vsetvl.h (enum def_type): New enum.
52451 2023-01-27  Jakub Jelinek  <jakub@redhat.com>
52453         PR other/108560
52454         * doc/extend.texi: Fix up return type of __builtin_va_arg_pack_len
52455         from size_t to int.
52457 2023-01-27  Jakub Jelinek  <jakub@redhat.com>
52459         PR ipa/106061
52460         * cgraph.cc (cgraph_edge::verify_corresponds_to_fndecl): Allow
52461         redirection of calls to __builtin_trap in addition to redirection
52462         to __builtin_unreachable.
52464 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52466         * config/riscv/riscv-vsetvl.cc (before_p): Fix bug.
52468 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52470         * config/riscv/riscv-vsetvl.cc (gen_vsetvl_pat): Refine function args.
52471         (emit_vsetvl_insn): Ditto.
52473 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52475         * config/riscv/vector.md: Fix constraints.
52477 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52479         * config/riscv/vector-iterators.md: Add TARGET_MIN_VLEN > 32 predicates.
52481 2023-01-27  Patrick Palka  <ppalka@redhat.com>
52482             Jakub Jelinek  <jakub@redhat.com>
52484         * tree-core.h (tree_code_type, tree_code_length): For
52485         C++17 and later, add inline keyword, otherwise don't define
52486         the arrays, but declare extern arrays.
52487         * tree.cc (tree_code_type, tree_code_length): Define these
52488         arrays for C++14 and older.
52490 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52492         * config/riscv/riscv-vsetvl.h: Change it into public.
52494 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52496         * config/riscv/riscv-passes.def (INSERT_PASS_BEFORE): Reorder VSETVL
52497         pass.
52499 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52501         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::execute): Always call split_all_insns.
52503 2023-01-27  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52505         * config/riscv/vector.md: Fix incorrect attributes.
52507 2023-01-27  Richard Biener  <rguenther@suse.de>
52509         PR target/55522
52510         * config/loongarch/gnu-user.h (GNU_USER_TARGET_MATHFILE_SPEC):
52511         Don't add crtfastmath.o for -shared.
52513 2023-01-27  Alexandre Oliva  <oliva@gnu.org>
52515         * doc/options.texi (option, RejectNegative): Mention that
52516         -g-started options are also implicitly negatable.
52518 2023-01-26  Kito Cheng  <kito.cheng@sifive.com>
52520         * config/riscv/riscv-vector-builtins.cc (register_builtin_types):
52521         Use get_typenode_from_name to get fixed-width integer type
52522         nodes.
52523         * config/riscv/riscv-vector-builtins.def: Update define with
52524         fixed-width integer type nodes.
52526 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52528         * config/riscv/riscv-vsetvl.cc (same_bb_and_before_p): Remove it.
52529         (real_insn_and_same_bb_p): New function.
52530         (same_bb_and_after_or_equal_p): Remove it.
52531         (before_p): New function.
52532         (reg_killed_by_bb_p): Ditto.
52533         (has_vsetvl_killed_avl_p): Ditto.
52534         (get_vl): Move location so that we can call it.
52535         (anticipatable_occurrence_p): Fix issue of AVL=REG support.
52536         (available_occurrence_p): Ditto.
52537         (dominate_probability_p): Remove it.
52538         (can_backward_propagate_p): Remove it.
52539         (get_all_nonphi_defs): New function.
52540         (get_all_predecessors): Ditto.
52541         (any_insn_in_bb_p): Ditto.
52542         (insert_vsetvl): Adjust AVL REG.
52543         (source_equal_p): New function.
52544         (extract_single_source): Ditto.
52545         (avl_info::single_source_equal_p): Ditto.
52546         (avl_info::operator==): Adjust for AVL=REG.
52547         (vl_vtype_info::same_avl_p): Ditto.
52548         (vector_insn_info::set_demand_info): Remove it.
52549         (vector_insn_info::compatible_p): Adjust for AVL=REG.
52550         (vector_insn_info::compatible_avl_p): New function.
52551         (vector_insn_info::merge): Adjust AVL=REG.
52552         (vector_insn_info::dump): Ditto.
52553         (pass_vsetvl::merge_successors): Remove it.
52554         (enum fusion_type): New enum.
52555         (pass_vsetvl::get_backward_fusion_type): New function.
52556         (pass_vsetvl::backward_demand_fusion): Adjust for AVL=REG.
52557         (pass_vsetvl::forward_demand_fusion): Ditto.
52558         (pass_vsetvl::demand_fusion): Ditto.
52559         (pass_vsetvl::prune_expressions): Ditto.
52560         (pass_vsetvl::compute_local_properties): Ditto.
52561         (pass_vsetvl::cleanup_vsetvls): Ditto.
52562         (pass_vsetvl::commit_vsetvls): Ditto.
52563         (pass_vsetvl::init): Ditto.
52564         * config/riscv/riscv-vsetvl.h (enum fusion_type): New enum.
52565         (enum merge_type): New enum.
52567 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52569         * config/riscv/riscv-vsetvl.cc
52570         (vector_infos_manager::vector_infos_manager): Add probability.
52571         (vector_infos_manager::dump): Ditto.
52572         (pass_vsetvl::compute_probabilities): Ditto.
52573         * config/riscv/riscv-vsetvl.h (struct vector_block_info): Ditto.
52575 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52577         * config/riscv/riscv-vsetvl.cc (vector_insn_info::operator==): Remove dirty_pat.
52578         (vector_insn_info::merge): Ditto.
52579         (vector_insn_info::dump): Ditto.
52580         (pass_vsetvl::merge_successors): Ditto.
52581         (pass_vsetvl::backward_demand_fusion): Ditto.
52582         (pass_vsetvl::forward_demand_fusion): Ditto.
52583         (pass_vsetvl::commit_vsetvls): Ditto.
52584         * config/riscv/riscv-vsetvl.h: Ditto.
52586 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52588         * config/riscv/riscv-vsetvl.cc (add_label_notes): Rename insn to
52589         rinsn.
52591 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52593         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::backward_demand_fusion): Refine codes.
52595 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52597         * config/riscv/riscv-vsetvl.cc (pass_vsetvl::forward_demand_fusion):
52598         Add pre-check for redundant flow.
52600 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52602         * config/riscv/riscv-vsetvl.cc (vector_infos_manager::create_bitmap_vectors): New function.
52603         (vector_infos_manager::free_bitmap_vectors): Ditto.
52604         (pass_vsetvl::pre_vsetvl): Adjust codes.
52605         * config/riscv/riscv-vsetvl.h: New function declaration.
52607 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52609         * config/riscv/riscv-vsetvl.cc (can_backward_propagate_p): Fix for null iter_bb.
52610         (vector_insn_info::set_demand_info): New function.
52611         (pass_vsetvl::emit_local_forward_vsetvls): Adjust for refinement of Phase 3.
52612         (pass_vsetvl::merge_successors): Ditto.
52613         (pass_vsetvl::compute_global_backward_infos): Ditto.
52614         (pass_vsetvl::backward_demand_fusion): Ditto.
52615         (pass_vsetvl::forward_demand_fusion): Ditto.
52616         (pass_vsetvl::demand_fusion): New function.
52617         (pass_vsetvl::lazy_vsetvl): Adjust for refinement of phase 3.
52618         * config/riscv/riscv-vsetvl.h: New function declaration.
52620 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52622         * config/riscv/riscv-vsetvl.cc (vector_insn_info::operator>=): Fix available condition.
52624 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52626         * config/riscv/riscv-vsetvl.cc (change_vsetvl_insn): New function.
52627         (pass_vsetvl::compute_global_backward_infos): Simplify codes.
52629 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52631         * config/riscv/riscv-vsetvl.cc (loop_basic_block_p): Adjust function.
52632         (backward_propagate_worthwhile_p): Fix non-worthwhile.
52634 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52636         * config/riscv/riscv-vsetvl.cc (change_insn): Adjust in_group in validate_change.
52638 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52640         * config/riscv/riscv-vsetvl.cc (vector_infos_manager::all_same_avl_p): New function.
52641         (pass_vsetvl::can_refine_vsetvl_p): Add AVL check.
52642         (pass_vsetvl::commit_vsetvls): Ditto.
52643         * config/riscv/riscv-vsetvl.h: New function declaration.
52645 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52647         * config/riscv/vector.md:
52649 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52651         * config/riscv/riscv-vector-builtins-bases.cc (class loadstore): use
52652         pred_store for vse.
52653         * config/riscv/riscv-vector-builtins.cc
52654         (function_expander::add_mem_operand): Refine function.
52655         (function_expander::use_contiguous_load_insn): Adjust new
52656         implementation.
52657         (function_expander::use_contiguous_store_insn): Ditto.
52658         * config/riscv/riscv-vector-builtins.h: Refine function.
52659         * config/riscv/vector.md (@pred_store<mode>): New pattern.
52661 2023-01-26  Ju-Zhe Zhong  <juzhe.zhong@rivai.ai>
52663         * config/riscv/riscv-vector-builtins.cc: Change to scalar pointer.
52665 2023-01-26  Marek Polacek  <polacek@redhat.com>
52667         PR middle-end/108543
52668         * opts.cc (parse_sanitizer_options): Don't always clear SANITIZE_ADDRESS
52669         if it was previously set.
52671 2023-01-26  Jakub Jelinek  <jakub@redhat.com>
52673         PR tree-optimization/108540
52674         * range-op-float.cc (foperator_equal::fold_range): If both op1 and op2
52675         are singletons, use range_true even if op1 != op2
52676         when one range is [-0.0, -0.0] and another [0.0, 0.0].  Similarly,
52677         even if intersection of the ranges is empty and one has
52678         zero low bound and another zero high bound, use range_true_and_false
52679         rather than range_false.
52680         (foperator_not_equal::fold_range): If both op1 and op2
52681         are singletons, use range_false even if op1 != op2
52682         when one range is [-0.0, -0.0] and another [0.0, 0.0].  Similarly,
52683         even if intersection of the ranges is empty and one has
52684         zero low bound and another zero high bound, use range_true_and_false
52685         rather than range_true.
52687 2023-01-26  Jakub Jelinek  <jakub@redhat.com>
52689         * value-relation.cc (kind_string): Add const.
52690         (rr_negate_table, rr_swap_table, rr_intersect_table,
52691         rr_union_table, rr_transitive_table): Add static const, change
52692         element type from relation_kind to unsigned char.
52693         (relation_negate, relation_swap, relation_intersect, relation_union,
52694         relation_transitive): Cast rr_*_table element to relation_kind.
52695         (relation_to_code): Add static const.
52696         (relation_tests): Assert VREL_LAST is smaller than UCHAR_MAX.
52698 2023-01-26  Richard Biener  <rguenther@suse.de>
52700         PR tree-optimization/108547
52701         * gimple-predicate-analysis.cc (value_sat_pred_p):
52702         Use widest_int.
52704 2023-01-26  Siddhesh Poyarekar  <siddhesh@gotplt.org>
52706         PR tree-optimization/108522
52707         * tree-object-size.cc (compute_object_offset): Make EXPR
52708         argument non-const.  Call component_ref_field_offset.
52710 2023-01-26  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
52712         * config/aarch64/aarch64-option-extensions.def (cssc): Specify
52713         FEATURE_STRING field.
52715 2023-01-26  Gerald Pfeifer  <gerald@pfeifer.com>
52717         * doc/sourcebuild.texi: Refer to projects as GCC and GDB.
52719 2023-01-25  Iain Sandoe  <iain@sandoe.co.uk>
52721         PR modula2/102343
52722         PR modula2/108182
52723         * gcc.cc: Provide default specs for Modula-2 so that when the
52724         language is not built-in better diagnostics are emitted for
52725         attempts to use .mod or .m2i file extensions.
52727 2023-01-25  Andrea Corallo  <andrea.corallo@arm.com>
52729         * config/arm/mve.md (mve_vqnegq_s<mode>): Fix spacing.
52731 2023-01-25  Andrea Corallo  <andrea.corallo@arm.com>
52733         * config/arm/mve.md (mve_vqabsq_s<mode>): Fix spacing.
52735 2023-01-25  Andrea Corallo  <andrea.corallo@arm.com>
52737         * config/arm/mve.md (mve_vnegq_f<mode>, mve_vnegq_s<mode>):
52738         Fix spacing.
52740 2023-01-25  Andrea Corallo  <andrea.corallo@arm.com>
52742         * config/arm/mve.md (@mve_vclzq_s<mode>): Fix spacing.
52744 2023-01-25  Andrea Corallo  <andrea.corallo@arm.com>
52746         * config/arm/mve.md (mve_vclsq_s<mode>): Fix spacing.
52748 2023-01-25  Richard Biener  <rguenther@suse.de>
52750         PR tree-optimization/108523
52751         * tree-ssa-sccvn.cc (visit_phi): Avoid using the exclusive
52752         backedge value for the result when using predication to
52753         prove equivalence.
52755 2023-01-25  Richard Biener  <rguenther@suse.de>
52757         * doc/lto.texi (Command line options): Reword and update reference
52758         to removed lto_read_all_file_options.
52760 2023-01-25  Richard Sandiford  <richard.sandiford@arm.com>
52762         * config/aarch64/aarch64.md (umax<mode>3): Separate the CNT and CSSC
52763         tests.
52765 2023-01-25  Gerald Pfeifer  <gerald@pfeifer.com>
52767         * doc/contrib.texi: Add Jose E. Marchesi.
52769 2023-01-25  Jakub Jelinek  <jakub@redhat.com>
52771         PR tree-optimization/108498
52772         * gimple-ssa-store-merging.cc (class store_operand_info):
52773         End coment with full stop rather than comma.
52774         (split_group): Likewise.
52775         (merged_store_group::apply_stores): Clear string_concatenation if
52776         start or end aren't on a byte boundary.
52778 2023-01-25  Siddhesh Poyarekar  <siddhesh@gotplt.org>
52779             Jakub Jelinek  <jakub@redhat.com>
52781         PR tree-optimization/108522
52782         * tree-object-size.cc (compute_object_offset): Use
52783         TREE_OPERAND(ref, 2) for COMPONENT_REF when available.
52785 2023-01-24  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
52787         * config/xtensa/xtensa.md:
52788         Fix exit from loops detecting references before overwriting in the
52789         split pattern.
52791 2023-01-24  Vladimir N. Makarov  <vmakarov@redhat.com>
52793         * lra-constraints.cc (get_hard_regno): Remove final_p arg.  Always
52794         do elimination but only for hard register.
52795         (operands_match_p, uses_hard_regs_p, process_alt_operands): Adjust
52796         calls of get_hard_regno.
52798 2023-01-24  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
52800         * config/s390/s390-d.cc (s390_d_target_versions): Fix detection
52801         of CPU version.
52803 2023-01-24  Andre Vieira  <andre.simoesdiasvieira@arm.com>
52805         PR target/108177
52806         * config/arm/mve.md (mve_vstrbq_p_<supf><mode>, mve_vstrhq_p_fv8hf,
52807         mve_vstrhq_p_<supf><mode>, mve_vstrwq_p_<supf>v4si): Add memory operand
52808         as input operand.
52810 2023-01-24  Xianmiao Qu  <cooper.qu@linux.alibaba.com>
52812         * config.gcc(csky-*-linux*): Define CSKY_ENABLE_MULTILIB
52813         and only include 'csky/t-csky-linux' when enable multilib.
52814         * config/csky/csky-linux-elf.h(SYSROOT_SUFFIX_SPEC): Don't
52815         define it when disable multilib.
52817 2023-01-24  Richard Biener  <rguenther@suse.de>
52819         PR tree-optimization/108500
52820         * dominance.h (calculate_dominance_info): Add parameter
52821         to indicate fast-query compute, defaulted to true.
52822         * dominance.cc (calculate_dominance_info): Honor
52823         fast-query compute parameter.
52824         * tree-cfgcleanup.cc (cleanup_tree_cfg_noloop): Do
52825         not compute the dominator fast-query DFS numbers.
52827 2023-01-24  Eric Biggers  <ebiggers@google.com>
52829         PR bootstrap/90543
52830         * optc-save-gen.awk: Fix copy-and-paste error.
52832 2023-01-24  Jakub Jelinek  <jakub@redhat.com>
52834         PR c++/108474
52835         * cgraphbuild.cc: Include gimplify.h.
52836         (record_reference): Replace VAR_DECLs with DECL_HAS_VALUE_EXPR_P with
52837         their corresponding DECL_VALUE_EXPR expressions after unsharing.
52839 2023-01-24  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
52841         PR target/108505
52842         * config.gcc (tm_file): Move the variable out of loop.
52844 2023-01-24  Lulu Cheng  <chenglulu@loongson.cn>
52845             Yang Yujie  <yangyujie@loongson.cn>
52847         PR target/107731
52848         * config/loongarch/loongarch.cc (loongarch_classify_address):
52849         Add precessint for CONST_INT.
52850         (loongarch_print_operand_reloc): Operand modifier 'c' is supported.
52851         (loongarch_print_operand): Increase the processing of '%c'.
52852         * doc/extend.texi: Adds documents for LoongArch operand modifiers.
52853         And port the public operand modifiers information to this document.
52855 2023-01-23  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
52857         * doc/invoke.texi (-mbranch-protection): Update documentation.
52859 2023-01-23  Richard Biener  <rguenther@suse.de>
52861         PR target/55522
52862         * config/sparc/freebsd.h (ENDFILE_SPEC): Don't add crtfastmath.o
52863         for -shared.
52864         * config/sparc/linux.h (ENDFILE_SPEC): Likewise.
52865         * config/sparc/linux64.h (ENDFILE_SPEC): Likewise.
52866         * config/sparc/sp-elf.h (ENDFILE_SPEC): Likewise.
52867         * config/sparc/sp64-elf.h (ENDFILE_SPEC): Likewise.
52869 2023-01-23  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
52871         * config/arm/aout.h (ra_auth_code): Add entry in enum.
52872         * config/arm/arm.cc (emit_multi_reg_push): Add RA_AUTH_CODE register
52873         to dwarf frame expression.
52874         (arm_emit_multi_reg_pop): Restore RA_AUTH_CODE register.
52875         (arm_expand_prologue): Update frame related information and reg notes
52876         for pac/pacbit insn.
52877         (arm_regno_class): Check for pac pseudo reigster.
52878         (arm_dbx_register_number): Assign ra_auth_code register number in dwarf.
52879         (arm_init_machine_status): Set pacspval_needed to zero.
52880         (arm_debugger_regno): Check for PAC register.
52881         (arm_unwind_emit_sequence): Print .save directive with ra_auth_code
52882         register.
52883         (arm_unwind_emit_set): Add entry for IP_REGNUM in switch case.
52884         (arm_unwind_emit): Update REG_CFA_REGISTER case._
52885         * config/arm/arm.h (FIRST_PSEUDO_REGISTER): Modify.
52886         (DWARF_PAC_REGNUM): Define.
52887         (IS_PAC_REGNUM): Likewise.
52888         (enum reg_class): Add PAC_REG entry.
52889         (machine_function): Add pacbti_needed state to structure.
52890         * config/arm/arm.md (RA_AUTH_CODE): Define.
52892 2023-01-23  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
52894         * config.gcc ($tm_file): Update variable.
52895         * config/arm/arm-mlib.h: Create new header file.
52896         * config/arm/t-rmprofile (MULTI_ARCH_DIRS_RM): Rename mbranch-protection
52897         multilib arch directory.
52898         (MULTILIB_REUSE): Add multilib reuse rules.
52899         (MULTILIB_MATCHES): Add multilib match rules.
52901 2023-01-23  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
52903         * config/arm/arm-cpus.in (cortex-m85): Define new CPU.
52904         * config/arm/arm-tables.opt: Regenerate.
52905         * config/arm/arm-tune.md: Likewise.
52906         * doc/invoke.texi (Arm Options): Document -mcpu=cortex-m85.
52907         * (-mfix-cmse-cve-2021-35465): Likewise.
52909 2023-01-23  Richard Biener  <rguenther@suse.de>
52911         PR tree-optimization/108482
52912         * tree-vect-generic.cc (expand_vector_operations): Fold remaining
52913         .LOOP_DIST_ALIAS calls.
52915 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
52917         * config.gcc (arm*-*-*): Add 'aarch-bti-insert.o' object.
52918         * config/arm/arm-protos.h: Update.
52919         * config/arm/aarch-common-protos.h: Declare
52920         'aarch_bti_arch_check'.
52921         * config/arm/arm.cc (aarch_bti_enabled) Update.
52922         (aarch_bti_j_insn_p, aarch_pac_insn_p, aarch_gen_bti_c)
52923         (aarch_gen_bti_j, aarch_bti_arch_check): New functions.
52924         * config/arm/arm.md (bti_nop): New insn.
52925         * config/arm/t-arm (PASSES_EXTRA): Add 'arm-passes.def'.
52926         (aarch-bti-insert.o): New target.
52927         * config/arm/unspecs.md (VUNSPEC_BTI_NOP): New unspec.
52928         * config/arm/aarch-bti-insert.cc (rest_of_insert_bti): Verify arch
52929         compatibility.
52930         (gate): Make use of 'aarch_bti_arch_check'.
52931         * config/arm/arm-passes.def: New file.
52932         * config/aarch64/aarch64.cc (aarch_bti_arch_check): New function.
52934 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
52936         * config.gcc (aarch64*-*-*): Rename 'aarch64-bti-insert.o' into
52937         'aarch-bti-insert.o'.
52938         * config/aarch64/aarch64-protos.h: Remove 'aarch64_bti_enabled'
52939         proto.
52940         * config/aarch64/aarch64.cc (aarch_bti_enabled): Rename.
52941         (aarch_bti_j_insn_p, aarch_pac_insn_p): New functions.
52942         (aarch64_output_mi_thunk)
52943         (aarch64_print_patchable_function_entry)
52944         (aarch64_file_end_indicate_exec_stack): Update renamed function
52945         calls to renamed functions.
52946         * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins): Likewise.
52947         * config/aarch64/t-aarch64 (aarch-bti-insert.o): Update
52948         target.
52949         * config/aarch64/aarch64-bti-insert.cc: Delete.
52950         * config/arm/aarch-bti-insert.cc: New file including and
52951         generalizing code from aarch64-bti-insert.cc.
52952         * config/arm/aarch-common-protos.h: Update.
52954 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
52956         * config/arm/arm.h (arm_arch8m_main): Declare it.
52957         * config/arm/arm-protos.h (arm_current_function_pac_enabled_p):
52958         Declare it.
52959         * config/arm/arm.cc (arm_arch8m_main): Define it.
52960         (arm_option_reconfigure_globals): Set arm_arch8m_main.
52961         (arm_compute_frame_layout, arm_expand_prologue)
52962         (thumb2_expand_return, arm_expand_epilogue)
52963         (arm_conditional_register_usage): Update for pac codegen.
52964         (arm_current_function_pac_enabled_p): New function.
52965         (aarch_bti_enabled) New function.
52966         (use_return_insn): Return zero when pac is enabled.
52967         * config/arm/arm.md (pac_ip_lr_sp, pacbti_ip_lr_sp, aut_ip_lr_sp):
52968         Add new patterns.
52969         * config/arm/unspecs.md (UNSPEC_PAC_NOP)
52970         (VUNSPEC_PACBTI_NOP, VUNSPEC_AUT_NOP): Add unspecs.
52972 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
52974         * config/arm/t-rmprofile: Add multilib rules for march +pacbti and
52975         mbranch-protection.
52977 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
52978             Tejas Belagod   <tbelagod@arm.com>
52980         * config/arm/arm.cc (arm_file_start): Emit EABI attributes for
52981         Tag_PAC_extension, Tag_BTI_extension, TAG_BTI_use, TAG_PACRET_use.
52983 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
52984             Tejas Belagod   <tbelagod@arm.com>
52985             Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
52987         * ginclude/unwind-arm-common.h (_Unwind_VRS_RegClass): Introduce
52988         new pseudo register class _UVRSC_PAC.
52990 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
52991             Tejas Belagod   <tbelagod@arm.com>
52993         * config/arm/arm-c.cc (arm_cpu_builtins): Define
52994         __ARM_FEATURE_BTI_DEFAULT, __ARM_FEATURE_PAC_DEFAULT,
52995         __ARM_FEATURE_PAUTH and __ARM_FEATURE_BTI.
52997 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
52998             Tejas Belagod   <tbelagod@arm.com>
53000         * doc/sourcebuild.texi: Document arm_pacbti_hw.
53002 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
53003             Tejas Belagod   <tbelagod@arm.com>
53004             Richard Earnshaw  <Richard.Earnshaw@arm.com>
53006         * config/arm/arm.cc (arm_configure_build_target): Parse and validate
53007         -mbranch-protection option and initialize appropriate data structures.
53008         * config/arm/arm.opt (-mbranch-protection): New option.
53009         * doc/invoke.texi (Arm Options): Document it.
53011 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
53012             Tejas Belagod   <tbelagod@arm.com>
53014         * config/arm/arm.h (TARGET_HAVE_PACBTI): New macro.
53015         * config/arm/arm-cpus.in (pacbti): New feature.
53016         * doc/invoke.texi (Arm Options): Document it.
53018 2023-01-23  Andrea Corallo  <andrea.corallo@arm.com>
53019             Tejas Belagod   <tbelagod@arm.com>
53021         * common/config/aarch64/aarch64-common.cc: Include aarch-common.h.
53022         (all_architectures): Fix comment.
53023         (aarch64_parse_extension): Rename return type, enum value names.
53024         * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins): Rename
53025         factored out aarch_ra_sign_scope and aarch_ra_sign_key variables.
53026         Also rename corresponding enum values.
53027         * config/aarch64/aarch64-opts.h (aarch64_function_type): Factor
53028         out aarch64_function_type and move it to common code as
53029         aarch_function_type in aarch-common.h.
53030         * config/aarch64/aarch64-protos.h: Include common types header,
53031         move out types aarch64_parse_opt_result and aarch64_key_type to
53032         aarch-common.h
53033         * config/aarch64/aarch64.cc: Move mbranch-protection parsing types
53034         and functions out into aarch-common.h and aarch-common.cc.  Fix up
53035         all the name changes resulting from the move.
53036         * config/aarch64/aarch64.md: Fix up aarch64_ra_sign_key type name change
53037         and enum value.
53038         * config/aarch64/aarch64.opt: Include aarch-common.h to import
53039         type move.  Fix up name changes from factoring out common code and
53040         data.
53041         * config/arm/aarch-common-protos.h: Export factored out routines to both
53042         backends.
53043         * config/arm/aarch-common.cc: Include newly factored out types.
53044         Move all mbranch-protection code and data structures from
53045         aarch64.cc.
53046         * config/arm/aarch-common.h: New header that declares types shared
53047         between aarch32 and aarch64 backends.
53048         * config/arm/arm-protos.h: Declare types and variables that are
53049         made common to aarch64 and aarch32 backends - aarch_ra_sign_key,
53050         aarch_ra_sign_scope and aarch_enable_bti.
53051         * config/arm/arm.opt (config/arm/aarch-common.h): Include header.
53052         (aarch_ra_sign_scope, aarch_enable_bti): Declare variable.
53053         * config/arm/arm.cc: Add missing includes.
53055 2023-01-23  Tobias Burnus  <tobias@codesourcery.com>
53057         * doc/install.texi (amdgcn, nvptx): Require newlib 4.3.0.
53059 2023-01-23  Richard Biener  <rguenther@suse.de>
53061         PR tree-optimization/108449
53062         * cgraphunit.cc (check_global_declaration): Do not turn
53063         undefined statics into externs.
53065 2023-01-22  Dimitar Dimitrov  <dimitar@dinux.eu>
53067         * config/pru/pru.h (CLZ_DEFINED_VALUE_AT_ZERO): Fix value for QI
53068         and HI input modes.
53069         * config/pru/pru.md (clz): Fix generated code for QI and HI
53070         input modes.
53072 2023-01-22  Cupertino Miranda  <cupertino.miranda@oracle.com>
53074         * config/v850/v850.cc (v850_select_section): Put const volatile
53075         objects into read-only sections.
53077 2023-01-20  Tejas Belagod  <tejas.belagod@arm.com>
53079         * config/aarch64/arm_neon.h (vmull_p64, vmull_high_p64, vaeseq_u8,
53080         vaesdq_u8, vaesmcq_u8, vaesimcq_u8): Gate under "nothing+aes".
53081         (vsha1*_u32, vsha256*_u32): Gate under "nothing+sha2".
53083 2023-01-20  Jakub Jelinek  <jakub@redhat.com>
53085         PR tree-optimization/108457
53086         * tree-ssa-loop-niter.cc (build_cltz_expr): Use
53087         SCALAR_INT_TYPE_MODE (utype) directly as C[LT]Z_DEFINED_VALUE_AT_ZERO
53088         argument instead of a temporary.  Formatting fixes.
53090 2023-01-19  Jakub Jelinek  <jakub@redhat.com>
53092         PR tree-optimization/108447
53093         * value-relation.cc (rr_union_table): Fix VREL_UNDEFINED row order.
53094         (relation_tests): Add self-tests for relation_{intersect,union}
53095         commutativity.
53096         * selftest.h (relation_tests): Declare.
53097         * function-tests.cc (test_ranges): Call it.
53099 2023-01-19  H.J. Lu  <hjl.tools@gmail.com>
53101         PR target/108436
53102         * config/i386/i386-expand.cc (ix86_expand_builtin): Check
53103         invalid third argument to __builtin_ia32_prefetch.
53105 2023-01-19  Jakub Jelinek  <jakub@redhat.com>
53107         PR middle-end/108459
53108         * omp-expand.cc (expand_omp_for_init_counts): Use fold_build1 rather
53109         than fold_unary for NEGATE_EXPR.
53111 2023-01-19  Christophe Lyon  <christophe.lyon@arm.com>
53113         PR target/108411
53114         * config/aarch64/aarch64.cc (aarch64_layout_arg): Improve
53115         comment. Move assert about alignment a bit later.
53117 2023-01-19  Jakub Jelinek  <jakub@redhat.com>
53119         PR tree-optimization/108440
53120         * tree-ssa-forwprop.cc: Include gimple-range.h.
53121         (simplify_rotate): For the forms with T2 wider than T and shift counts of
53122         Y and B - Y add & (B - 1) masking for the rotate count if Y could be equal
53123         to B.  For the forms with T2 wider than T and shift counts of
53124         Y and (-Y) & (B - 1), don't punt if range could be [B, B2], but only if
53125         range doesn't guarantee Y < B or Y = N * B.  If range doesn't guarantee
53126         Y < B, also add & (B - 1) masking for the rotate count.  Use lazily created
53127         pass specific ranger instead of get_global_range_query.
53128         (pass_forwprop::execute): Disable that ranger at the end of pass if it has
53129         been created.
53131 2023-01-19  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
53133         * config/aarch64/aarch64-simd.md (aarch64_simd_vec_set<mode>): Use
53134         exact_log2 (INTVAL (operands[2])) >= 0 as condition for gating
53135         the pattern.
53136         (aarch64_simd_vec_copy_lane<mode>): Likewise.
53137         (aarch64_simd_vec_copy_lane_<vswap_width_name><mode>): Likewise.
53139 2023-01-19  Alexandre Oliva  <oliva@adacore.com>
53141         PR debug/106746
53142         * sched-deps.cc (sched_analyze_2): Skip cselib address lookup
53143         within debug insns.
53145 2023-01-18  Martin Jambor  <mjambor@suse.cz>
53147         PR ipa/107944
53148         * cgraph.cc (cgraph_node::remove): Check whether nodes up the
53149         lcone_of chain also do not need the body.
53151 2023-01-18  Richard Biener  <rguenther@suse.de>
53153         Revert:
53154         2022-12-16  Richard Biener  <rguenther@suse.de>
53156         PR middle-end/108086
53157         * tree-inline.cc (remap_ssa_name): Do not unshare the
53158         result from the decl_map.
53160 2023-01-18  Murray Steele  <murray.steele@arm.com>
53162         PR target/108442
53163         * config/arm/arm_mve.h (__arm_vst1q_p_u8): Use prefixed intrinsic
53164         function.
53165         (__arm_vst1q_p_s8): Likewise.
53166         (__arm_vld1q_z_u8): Likewise.
53167         (__arm_vld1q_z_s8): Likewise.
53168         (__arm_vst1q_p_u16): Likewise.
53169         (__arm_vst1q_p_s16): Likewise.
53170         (__arm_vld1q_z_u16): Likewise.
53171         (__arm_vld1q_z_s16): Likewise.
53172         (__arm_vst1q_p_u32): Likewise.
53173         (__arm_vst1q_p_s32): Likewise.
53174         (__arm_vld1q_z_u32): Likewise.
53175         (__arm_vld1q_z_s32): Likewise.
53176         (__arm_vld1q_z_f16): Likewise.
53177         (__arm_vst1q_p_f16): Likewise.
53178         (__arm_vld1q_z_f32): Likewise.
53179         (__arm_vst1q_p_f32): Likewise.
53181 2023-01-18  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
53183         * config/xtensa/xtensa.md (xorsi3_internal):
53184         Rename from the original of "xorsi3".
53185         (xorsi3): New expansion pattern that emits addition rather than
53186         bitwise-XOR when the second source is a constant of -2147483648
53187         if TARGET_DENSITY.
53189 2023-01-18  Kewen Lin  <linkw@linux.ibm.com>
53190             Andrew Pinski  <apinski@marvell.com>
53192         PR target/108396
53193         * config/rs6000/rs6000-overload.def (VEC_VSUBCUQ): Fix typo
53194         vec_vsubcuqP with vec_vsubcuq.
53196 2023-01-18  Kewen Lin  <linkw@linux.ibm.com>
53198         PR target/108348
53199         * config/rs6000/rs6000.cc (rs6000_opaque_type_invalid_use_p): Add the
53200         support for invalid uses of MMA opaque type in function arguments.
53202 2023-01-18  liuhongt  <hongtao.liu@intel.com>
53204         PR target/55522
53205         * config/i386/cygwin.h (ENDFILE_SPEC): Link crtfastmath.o
53206         whenever -mdaz-ftz is specified. Don't link crtfastmath.o when
53207         -share or -mno-daz-ftz is specified.
53208         * config/i386/darwin.h (ENDFILE_SPEC): Ditto.
53209         * config/i386/mingw32.h (ENDFILE_SPEC): Ditto.
53211 2023-01-17  Jose E. Marchesi  <jose.marchesi@oracle.com>
53213         * config/bpf/bpf.cc (bpf_option_override): Disable
53214         -fstack-protector.
53216 2023-01-17  Jakub Jelinek  <jakub@redhat.com>
53218         PR tree-optimization/106523
53219         * tree-ssa-forwprop.cc (simplify_rotate): For the
53220         patterns with (-Y) & (B - 1) in one operand's shift
53221         count and Y in another, if T2 has wider precision than T,
53222         punt if Y could have a value in [B, B2 - 1] range.
53224 2023-01-16  H.J. Lu  <hjl.tools@gmail.com>
53226         PR target/105980
53227         * config/i386/i386.cc (x86_output_mi_thunk): Disable
53228         -mforce-indirect-call for PIC in 32-bit mode.
53230 2023-01-16  Jan Hubicka  <hubicka@ucw.cz>
53232         PR ipa/106077
53233         * ipa-modref.cc (modref_access_analysis::analyze): Use
53234         find_always_executed_bbs.
53235         * ipa-sra.cc (process_scan_results): Likewise.
53236         * ipa-utils.cc (stmt_may_terminate_function_p): New function.
53237         (find_always_executed_bbs): New function.
53238         * ipa-utils.h (stmt_may_terminate_function_p): Declare.
53239         (find_always_executed_bbs): Declare.
53241 2023-01-16  Jan Hubicka  <jh@suse.cz>
53243         * config/i386/i386.cc (ix86_vectorize_builtin_scatter): Guard scatter
53244         by TARGET_USE_SCATTER.
53245         * config/i386/i386.h (TARGET_USE_SCATTER_2PARTS,
53246         TARGET_USE_SCATTER_4PARTS, TARGET_USE_SCATTER): New macros.
53247         * config/i386/x86-tune.def (TARGET_USE_SCATTER_2PARTS,
53248         TARGET_USE_SCATTER_4PARTS, TARGET_USE_SCATTER): New tunes.
53249         (X86_TUNE_AVOID_256FMA_CHAINS, X86_TUNE_AVOID_512FMA_CHAINS): Disable
53250         for znver4.  (X86_TUNE_USE_GATHER): Disable for zen4.
53252 2023-01-16  Richard Biener  <rguenther@suse.de>
53254         PR target/55522
53255         * config/sol2.h (ENDFILE_SPEC): Don't add crtfastmath.o for -shared.
53257 2023-01-16  Stam Markianos-Wright  <stam.markianos-wright@arm.com>
53259         PR target/96795
53260         PR target/107515
53261         * config/arm/arm_mve.h (__ARM_mve_coerce2): Split types.
53262         (__ARM_mve_coerce3): Likewise.
53264 2023-01-16  Andrew Carlotti  <andrew.carlotti@arm.com>
53266         * tree-ssa-loop-niter.cc (build_popcount_expr): Add IFN support.
53268 2023-01-16  Andrew Carlotti  <andrew.carlotti@arm.com>
53270         * tree-ssa-loop-niter.cc (number_of_iterations_cltz): New.
53271         (number_of_iterations_bitcount): Add call to the above.
53272         (number_of_iterations_exit_assumptions): Add EQ_EXPR case for
53273         c[lt]z idiom recognition.
53275 2023-01-16  Andrew Carlotti  <andrew.carlotti@arm.com>
53277         * doc/sourcebuild.texi: Add missing target attributes.
53279 2023-01-16  Andrew Carlotti  <andrew.carlotti@arm.com>
53281         PR tree-optimization/94793
53282         * tree-scalar-evolution.cc (expression_expensive_p): Add checks
53283         for c[lt]z optabs.
53284         * tree-ssa-loop-niter.cc (build_cltz_expr): New.
53285         (number_of_iterations_cltz_complement): New.
53286         (number_of_iterations_bitcount): Add call to the above.
53288 2023-01-16  Jonathan Wakely  <jwakely@redhat.com>
53290         * doc/extend.texi (Common Function Attributes): Fix grammar.
53292 2023-01-16  Jakub Jelinek  <jakub@redhat.com>
53294         PR other/108413
53295         * config/riscv/riscv-vsetvl.h: Add space in between Copyright and (C).
53296         * config/riscv/riscv-vsetvl.cc: Likewise.
53298 2023-01-16  Jakub Jelinek  <jakub@redhat.com>
53300         PR c++/105593
53301         * config/i386/xmmintrin.h (_mm_undefined_ps): Temporarily
53302         disable -Winit-self using pragma GCC diagnostic ignored.
53303         * config/i386/emmintrin.h (_mm_undefined_pd, _mm_undefined_si128):
53304         Likewise.
53305         * config/i386/avxintrin.h (_mm256_undefined_pd, _mm256_undefined_ps,
53306         _mm256_undefined_si256): Likewise.
53307         * config/i386/avx512fintrin.h (_mm512_undefined_pd,
53308         _mm512_undefined_ps, _mm512_undefined_epi32): Likewise.
53309         * config/i386/avx512fp16intrin.h (_mm_undefined_ph,
53310         _mm256_undefined_ph, _mm512_undefined_ph): Likewise.
53312 2023-01-16  Kewen Lin  <linkw@linux.ibm.com>
53314         PR target/108272
53315         * config/rs6000/rs6000.cc (rs6000_opaque_type_invalid_use_p): Add the
53316         support for invalid uses in inline asm, factor out the checking and
53317         erroring to lambda function check_and_error_invalid_use.
53319 2023-01-15  Aldy Hernandez  <aldyh@redhat.com>
53321         PR tree-optimization/107608
53322         * range-op-float.cc (range_operator_float::fold_range): Avoid
53323         folding into INF when flag_trapping_math.
53324         * value-range.h (frange::known_isinf): Return false for possible NANs.
53326 2023-01-15  Xianmiao Qu  <cooper.qu@linux.alibaba.com>
53328         * config.gcc (csky-*-*): Support --with-float=softfp.
53330 2023-01-14  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
53332         * config/xtensa/xtensa-protos.h (order_regs_for_local_alloc):
53333         Rename to xtensa_adjust_reg_alloc_order.
53334         * config/xtensa/xtensa.cc (xtensa_adjust_reg_alloc_order):
53335         Ditto.  And also remove code to reorder register numbers for
53336         leaf functions, rename the tables, and adjust the allocation
53337         order for the call0 ABI to use register A0 more.
53338         (xtensa_leaf_regs): Remove.
53339         * config/xtensa/xtensa.h (REG_ALLOC_ORDER): Cosmetics.
53340         (order_regs_for_local_alloc): Rename as the above.
53341         (LEAF_REGISTERS, LEAF_REG_REMAP, leaf_function): Remove.
53343 2023-01-14  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
53345         * config/aarch64/aarch64-sve.md (aarch64_vec_duplicate_vq<mode>_le):
53346         Change to define_insn_and_split to fold ldr+dup to ld1rq.
53347         * config/aarch64/predicates.md (aarch64_sve_dup_ld1rq_operand): New.
53349 2023-01-14  Alexandre Oliva  <oliva@adacore.com>
53351         * hash-table.h (is_deleted): Precheck !is_empty.
53352         (mark_deleted): Postcheck !is_empty.
53353         (copy constructor): Test is_empty before is_deleted.
53355 2023-01-14  Alexandre Oliva  <oliva@adacore.com>
53357         PR target/40457
53358         * config/arm/arm.md (movmisaligndi): Prefer aligned SImode
53359         moves.
53361 2023-01-13  Eric Botcazou  <ebotcazou@adacore.com>
53363         PR rtl-optimization/108274
53364         * function.cc (thread_prologue_and_epilogue_insns): Also update the
53365         DF information for calls in a few more cases.
53367 2023-01-13  John David Anglin  <danglin@gcc.gnu.org>
53369         * config/pa/pa-linux.h (TARGET_SYNC_LIBCALL): Delete define.
53370         * config/pa/pa.cc (pa_init_libfuncs): Use MAX_SYNC_LIBFUNC_SIZE
53371         define.
53372         * config/pa/pa.h (TARGET_SYNC_LIBCALLS): Use flag_sync_libcalls.
53373         (MAX_SYNC_LIBFUNC_SIZE): Define.
53374         (TARGET_CPU_CPP_BUILTINS): Define __SOFTFP__ when soft float is
53375         enabled.
53376         * config/pa/pa.md (atomic_storeqi): Emit __atomic_exchange_1
53377         libcall when sync libcalls are disabled.
53378         (atomic_storehi, atomic_storesi, atomic_storedi): Likewise.
53379         (atomic_loaddi): Emit __atomic_load_8 libcall when sync libcalls
53380         are disabled on 32-bit target.
53381         * config/pa/pa.opt (matomic-libcalls): New option.
53382         * doc/invoke.texi (HPPA Options): Update.
53384 2023-01-13  Alexander Monakov  <amonakov@ispras.ru>
53386         PR rtl-optimization/108117
53387         PR rtl-optimization/108132
53388         * sched-deps.cc (deps_analyze_insn): Do not schedule across
53389         calls before reload.
53391 2023-01-13  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
53393         * common/config/arm/arm-common.cc (arm_canon_arch_option_1): Ignore cde
53394         options for -mlibarch.
53395         * config/arm/arm-cpus.in (begin cpu cortex-m55): Add cde options.
53396         * doc/invoke.texi (CDE): Document options for Cortex-M55 CPU.
53398 2023-01-13  Qing Zhao  <qing.zhao@oracle.com>
53400         * attribs.cc (strict_flex_array_level_of): Move this function to ...
53401         * attribs.h (strict_flex_array_level_of): Remove the declaration.
53402         * gimple-array-bounds.cc (array_bounds_checker::check_array_ref):
53403         replace the referece to strict_flex_array_level_of with
53404         DECL_NOT_FLEXARRAY.
53405         * tree.cc (component_ref_size): Likewise.
53407 2023-01-13  Richard Biener  <rguenther@suse.de>
53409         PR target/55522
53410         * config/arm/linux-eabi.h (ENDFILE_SPEC): Don't add
53411         crtfastmath.o for -shared.
53412         * config/arm/unknown-elf.h (STARTFILE_SPEC): Likewise.
53414 2023-01-13  Richard Biener  <rguenther@suse.de>
53416         PR target/55522
53417         * config/aarch64/aarch64-elf-raw.h (ENDFILE_SPEC): Don't add
53418         crtfastmath.o for -shared.
53419         * config/aarch64/aarch64-freebsd.h (GNU_USER_TARGET_MATHFILE_SPEC):
53420         Likewise.
53421         * config/aarch64/aarch64-linux.h (GNU_USER_TARGET_MATHFILE_SPEC):
53422         Likewise.
53424 2023-01-13  Richard Sandiford  <richard.sandiford@arm.com>
53426         * config/aarch64/aarch64.cc (aarch64_dwarf_frame_reg_mode): New
53427         function.
53428         (TARGET_DWARF_FRAME_REG_MODE): Define.
53430 2023-01-13  Richard Biener  <rguenther@suse.de>
53432         PR target/107209
53433         * config/aarch64/aarch64.cc (aarch64_gimple_fold_builtin): Don't
53434         update EH info on the fly.
53436 2023-01-13  Richard Biener  <rguenther@suse.de>
53438         PR tree-optimization/108387
53439         * tree-ssa-sccvn.cc (visit_nary_op): Check for SSA_NAME
53440         value before inserting expression into the tables.
53442 2023-01-12  Andrew Pinski  <apinski@marvell.com>
53443             Roger Sayle  <roger@nextmovesoftware.com>
53445         PR tree-optimization/92342
53446         * match.pd ((m1 CMP m2) * d -> (m1 CMP m2) ? d : 0):
53447         Use tcc_comparison and :c for the multiply.
53448         (b & -(a CMP c) -> (a CMP c)?b:0): New pattern.
53450 2023-01-12  Christophe Lyon  <christophe.lyon@arm.com>
53451             Richard Sandiford  <richard.sandiford@arm.com>
53453         PR target/105549
53454         * config/aarch64/aarch64.cc (aarch64_function_arg_alignment):
53455         Check DECL_PACKED for bitfield.
53456         (aarch64_layout_arg): Warn when parameter passing ABI changes.
53457         (aarch64_function_arg_boundary): Do not warn here.
53458         (aarch64_gimplify_va_arg_expr): Warn when parameter passing ABI
53459         changes.
53461 2023-01-12  Christophe Lyon  <christophe.lyon@arm.com>
53462             Richard Sandiford  <richard.sandiford@arm.com>
53464         * config/aarch64/aarch64.cc (aarch64_function_arg_alignment): Fix
53465         comment.
53466         (aarch64_layout_arg): Factorize warning conditions.
53467         (aarch64_function_arg_boundary): Fix typo.
53468         * function.cc (currently_expanding_function_start): New variable.
53469         (expand_function_start): Handle
53470         currently_expanding_function_start.
53471         * function.h (currently_expanding_function_start): Declare.
53473 2023-01-12  Richard Biener  <rguenther@suse.de>
53475         PR tree-optimization/99412
53476         * tree-ssa-reassoc.cc (is_phi_for_stmt): Remove.
53477         (swap_ops_for_binary_stmt): Remove reduction handling.
53478         (rewrite_expr_tree_parallel): Adjust.
53479         (reassociate_bb): Likewise.
53480         * tree-parloops.cc (build_new_reduction): Handle MINUS_EXPR.
53482 2023-01-12  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
53484         * config/xtensa/xtensa.md (ctzsi2, ffssi2):
53485         Rearrange the emitting codes.
53487 2023-01-12  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
53489         * config/xtensa/xtensa.md (*btrue):
53490         Correct value of the attribute "length" that depends on
53491         TARGET_DENSITY and operands, and add '?' character to the register
53492         constraint of the compared operand.
53494 2023-01-12  Alexandre Oliva  <oliva@adacore.com>
53496         * hash-table.h (expand): Check elements and deleted counts.
53497         (verify): Likewise.
53499 2023-01-11  Roger Sayle  <roger@nextmovesoftware.com>
53501         PR tree-optimization/71343
53502         * tree-ssa-sccvn.cc (visit_nary_op) <case LSHIFT_EXPR>: Make
53503         the value number of the expression X << C the same as the value
53504         number for the multiplication X * (1<<C).
53506 2023-01-11  David Faust  <david.faust@oracle.com>
53508         PR target/108293
53509         * config/bpf/bpf.cc (bpf_print_operand): Correct handling for
53510         floating point modes.
53512 2023-01-11  Eric Botcazou  <ebotcazou@adacore.com>
53514         PR tree-optimization/108199
53515         * tree-sra.cc (sra_modify_expr): Deal with reverse storage order
53516         for bit-field references.
53518 2023-01-11  Kewen Lin  <linkw@linux.ibm.com>
53520         * config/rs6000/rs6000.cc (rs6000_option_override_internal): Make
53521         OPTION_MASK_P10_FUSION implicit setting honour Power10 tuning setting.
53522         * config/rs6000/rs6000-cpus.def (ISA_3_1_MASKS_SERVER): Remove
53523         OPTION_MASK_P10_FUSION.
53525 2023-01-11  Richard Biener  <rguenther@suse.de>
53527         PR tree-optimization/107767
53528         * tree-cfgcleanup.cc (phi_alternatives_equal): Export.
53529         * tree-cfgcleanup.h (phi_alternatives_equal): Declare.
53530         * tree-switch-conversion.cc (switch_conversion::collect):
53531         Count unique non-default targets accounting for later
53532         merging opportunities.
53534 2023-01-11  Martin Liska  <mliska@suse.cz>
53536         PR middle-end/107976
53537         * params.opt: Limit JT params.
53538         * stmt.cc (emit_case_dispatch_table): Use auto_vec.
53540 2023-01-11  Richard Biener  <rguenther@suse.de>
53542         PR tree-optimization/108352
53543         * tree-ssa-threadbackward.cc
53544         (back_threader_profitability::profitable_path_p): Adjust
53545         heuristic that allows non-multi-way branch threads creating
53546         irreducible loops.
53547         * doc/invoke.texi (--param fsm-scale-path-blocks): Remove.
53548         (--param fsm-scale-path-stmts): Adjust.
53549         * params.opt (--param=fsm-scale-path-blocks=): Remove.
53550         (-param=fsm-scale-path-stmts=): Adjust description.
53552 2023-01-11  Richard Biener  <rguenther@suse.de>
53554         PR tree-optimization/108353
53555         * tree-ssa-propagate.cc (cfg_blocks_back, ssa_edge_worklist_back):
53556         Remove.
53557         (add_ssa_edge): Simplify.
53558         (add_control_edge): Likewise.
53559         (ssa_prop_init): Likewise.
53560         (ssa_prop_fini): Likewise.
53561         (ssa_propagation_engine::ssa_propagate): Likewise.
53563 2023-01-11  Andreas Krebbel  <krebbel@linux.ibm.com>
53565         * config/s390/s390.md (*not<mode>): New pattern.
53567 2023-01-11  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
53569         * config/xtensa/xtensa.cc (xtensa_insn_cost):
53570         Let insn cost for size be obtained by applying COSTS_N_INSNS()
53571         to instruction length and then dividing by 3.
53573 2023-01-10  Richard Biener  <rguenther@suse.de>
53575         PR tree-optimization/106293
53576         * tree-ssa-dse.cc (dse_classify_store): Use a worklist to
53577         process degenerate PHI defs.
53579 2023-01-10  Roger Sayle  <roger@nextmovesoftware.com>
53581         PR rtl-optimization/106421
53582         * cprop.cc (bypass_block): Check that DEST is local to this
53583         function (non-NULL) before calling find_edge.
53585 2023-01-10  Martin Jambor  <mjambor@suse.cz>
53587         PR ipa/108110
53588         * ipa-param-manipulation.h (ipa_param_body_adjustments): New members
53589         sort_replacements, lookup_first_base_replacement and
53590         m_sorted_replacements_p.
53591         * ipa-param-manipulation.cc: Define INCLUDE_ALGORITHM.
53592         (ipa_param_body_adjustments::register_replacement): Set
53593         m_sorted_replacements_p to false.
53594         (compare_param_body_replacement): New function.
53595         (ipa_param_body_adjustments::sort_replacements): Likewise.
53596         (ipa_param_body_adjustments::common_initialization): Call
53597         sort_replacements.
53598         (ipa_param_body_adjustments::ipa_param_body_adjustments): Initialize
53599         m_sorted_replacements_p.
53600         (ipa_param_body_adjustments::lookup_replacement_1): Rework to use
53601         std::lower_bound.
53602         (ipa_param_body_adjustments::lookup_first_base_replacement): New
53603         function.
53604         (ipa_param_body_adjustments::modify_call_stmt): Use
53605         lookup_first_base_replacement.
53606         * omp-simd-clone.cc (ipa_simd_modify_function_body): Call
53607         adjustments->sort_replacements.
53609 2023-01-10  Richard Biener  <rguenther@suse.de>
53611         PR tree-optimization/108314
53612         * tree-vect-stmts.cc (vectorizable_condition): Do not
53613         perform BIT_NOT_EXPR optimization for EXTRACT_LAST_REDUCTION.
53615 2023-01-10  Xianmiao Qu  <cooper.qu@linux.alibaba.com>
53617         * config/csky/csky-linux-elf.h (SYSROOT_SUFFIX_SPEC): New.
53619 2023-01-10  Xianmiao Qu  <cooper.qu@linux.alibaba.com>
53621         * config/csky/csky.h (MULTILIB_DEFAULTS): Fix float abi option.
53623 2023-01-10  Xianmiao Qu  <cooper.qu@linux.alibaba.com>
53625         * config/csky/csky.cc (csky_cpu_cpp_builtins): Add builtin
53626         defines for soft float abi.
53628 2023-01-10  Xianmiao Qu  <cooper.qu@linux.alibaba.com>
53630         * config/csky/csky.md (smart_bseti): Change condition to CSKY_ISA_FEATURE (E1).
53631         (smart_bclri): Likewise.
53632         (fast_bseti): Change condition to CSKY_ISA_FEATURE (E2).
53633         (fast_bclri): Likewise.
53634         (fast_cmpnesi_i): Likewise.
53635         (*fast_cmpltsi_i): Likewise.
53636         (*fast_cmpgeusi_i): Likewise.
53638 2023-01-10  Xianmiao Qu  <cooper.qu@linux.alibaba.com>
53640         * config/csky/csky_insn_fpuv3.md (l<frm_pattern><fixsuop><mode>si2): Test
53641         flag_fp_int_builtin_inexact || !flag_trapping_math.
53642         (<frm_pattern><mode>2): Likewise.
53644 2023-01-10  Andreas Krebbel  <krebbel@linux.ibm.com>
53646         * config/s390/s390.cc (s390_register_info): Check call_used_regs
53647         instead of hard-coding the register numbers for call saved
53648         registers.
53649         (s390_optimize_register_info): Likewise.
53651 2023-01-09  Eric Botcazou  <ebotcazou@adacore.com>
53653         * doc/gm2.texi (Overview): Fix @node markers.
53654         (Using): Likewise.  Remove subsections that were moved to Overview
53655         from the menu and move others around.
53657 2023-01-09  Richard Biener  <rguenther@suse.de>
53659         PR middle-end/108209
53660         * genmatch.cc (commutative_op): Fix return value for
53661         user-id with non-commutative first replacement.
53663 2023-01-09  Jakub Jelinek  <jakub@redhat.com>
53665         PR target/107453
53666         * calls.cc (expand_call): For calls with
53667         TYPE_NO_NAMED_ARGS_STDARG_P (funtype) use zero for n_named_args.
53668         Formatting fix.
53670 2023-01-09  Richard Biener  <rguenther@suse.de>
53672         PR middle-end/69482
53673         * cfgexpand.cc (discover_nonconstant_array_refs_r): Volatile
53674         qualified accesses also force objects to memory.
53676 2023-01-09  Martin Liska  <mliska@suse.cz>
53678         PR lto/108330
53679         * lto-cgraph.cc (compute_ltrans_boundary): Do not insert
53680         NULL (deleleted value) to a hash_set.
53682 2023-01-08  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
53684         * config/xtensa/xtensa.md (*splice_bits):
53685         New insn_and_split pattern.
53687 2023-01-07  Takayuki 'January June' Suwa  <jjsuwa_sys3175@yahoo.co.jp>
53689         * config/xtensa/xtensa.cc
53690         (xtensa_split_imm_two_addends, xtensa_emit_add_imm):
53691         New helper functions.
53692         (xtensa_set_return_address, xtensa_output_mi_thunk):
53693         Change to use the helper function.
53694         (xtensa_emit_adjust_stack_ptr): Ditto.
53695         And also change to try reusing the content of scratch register
53696         A9 if the register is not modified in the function body.
53698 2023-01-07  LIU Hao  <lh_mouse@126.com>
53700         PR middle-end/108300
53701         * config/xtensa/xtensa-dynconfig.c: Define `WIN32_LEAN_AND_MEAN`
53702         before <windows.h>.
53703         * diagnostic-color.cc: Likewise.
53704         * plugin.cc: Likewise.
53705         * prefix.cc: Likewise.
53707 2023-01-06  Joseph Myers  <joseph@codesourcery.com>
53709         * doc/extend.texi (__builtin_tgmath): Do not restate standard rule
53710         for handling real integer types.
53712 2023-01-06  Tamar Christina  <tamar.christina@arm.com>
53714         Revert:
53715         2022-12-12  Tamar Christina  <tamar.christina@arm.com>
53717         * config/aarch64/aarch64-simd.md (*aarch64_simd_movv2hf): New.
53718         (mov<mode>, movmisalign<mode>, aarch64_dup_lane<mode>,
53719         aarch64_store_lane0<mode>, aarch64_simd_vec_set<mode>,
53720         @aarch64_simd_vec_copy_lane<mode>, vec_set<mode>,
53721         reduc_<optab>_scal_<mode>, reduc_<fmaxmin>_scal_<mode>,
53722         aarch64_reduc_<optab>_internal<mode>, aarch64_get_lane<mode>,
53723         vec_init<mode><Vel>, vec_extract<mode><Vel>): Support V2HF.
53724         (aarch64_simd_dupv2hf): New.
53725         * config/aarch64/aarch64.cc (aarch64_classify_vector_mode):
53726         Add E_V2HFmode.
53727         * config/aarch64/iterators.md (VHSDF_P): New.
53728         (V2F, VMOVE, nunits, Vtype, Vmtype, Vetype, stype, VEL,
53729         Vel, q, vp): Add V2HF.
53730         * config/arm/types.md (neon_fp_reduc_add_h): New.
53732 2023-01-06  Martin Liska  <mliska@suse.cz>
53734         PR middle-end/107966
53735         * doc/options.texi: Fix Var documentation in internal manual.
53737 2023-01-05  Roger Sayle  <roger@nextmovesoftware.com>
53739         Revert:
53740         2023-01-03  Roger Sayle  <roger@nextmovesoftware.com>
53742         * config/i386/i386-expand.cc (ix86_expand_int_movcc): Rewrite
53743         RTL expansion to allow condition (mask) to be shared/reused,
53744         by avoiding overwriting pseudos and adding REG_EQUAL notes.
53746 2023-01-05  Iain Sandoe  <iain@sandoe.co.uk>
53748         * common.opt: Add -static-libgm2.
53749         * config/darwin.h (LINK_SPEC): Handle static-libgm2.
53750         * doc/gm2.texi: Document static-libgm2.
53751         * gcc.cc (driver_handle_option): Allow static-libgm2.
53753 2023-01-05  Tejas Joshi  <TejasSanjay.Joshi@amd.com>
53755         * common/config/i386/i386-common.cc (processor_alias_table):
53756         Use CPU_ZNVER4 for znver4.
53757         * config/i386/i386.md: Add znver4.md.
53758         * config/i386/znver4.md: New.
53760 2023-01-04  Jakub Jelinek  <jakub@redhat.com>
53762         PR tree-optimization/108253
53763         * tree-vrp.cc (maybe_set_nonzero_bits): Handle var with pointer
53764         types.
53766 2023-01-04  Jakub Jelinek  <jakub@redhat.com>
53768         PR middle-end/108237
53769         * generic-match-head.cc: Include tree-pass.h.
53770         (canonicalize_math_p, optimize_vectors_before_lowering_p): Define
53771         to false if cfun and cfun->curr_properties has PROP_gimple_opt_math
53772         resp. PROP_gimple_lvec property set.
53774 2023-01-04  Jakub Jelinek  <jakub@redhat.com>
53776         PR sanitizer/108256
53777         * convert.cc (do_narrow): Punt for MULT_EXPR if original
53778         type doesn't wrap around and -fsanitize=signed-integer-overflow
53779         is on.
53780         * fold-const.cc (fold_unary_loc) <CASE_CONVERT>: Likewise.
53782 2023-01-04  Hu, Lin1  <lin1.hu@intel.com>
53784         * common/config/i386/cpuinfo.h (get_intel_cpu): Handle Emeraldrapids.
53785         * common/config/i386/i386-common.cc: Add Emeraldrapids.
53787 2023-01-04  Hu, Lin1  <lin1.hu@intel.com>
53789         * common/config/i386/cpuinfo.h (get_intel_cpu): Remove case 0xb5
53790         for meteorlake.
53792 2023-01-03  Sandra Loosemore  <sandra@codesourcery.com>
53794         * cgraph.h (struct cgraph_node): Add gc_candidate bit, modify
53795         default constructor to initialize it.
53796         * cgraphunit.cc (expand_all_functions): Save gc_candidate functions
53797         for last and iterate to handle recursive calls.  Delete leftover
53798         candidates at the end.
53799         * omp-simd-clone.cc (simd_clone_create): Set gc_candidate bit
53800         on local clones.
53801         * tree-vect-stmts.cc (vectorizable_simd_clone_call): Clear
53802         gc_candidate bit when a clone is used.
53804 2023-01-03  Florian Weimer  <fweimer@redhat.com>
53806         Revert:
53807         2023-01-02  Florian Weimer  <fweimer@redhat.com>
53809         * dwarf2cfi.cc (init_return_column_size): Remove.
53810         (init_one_dwarf_reg_size): Adjust.
53811         (generate_dwarf_reg_sizes): New function.  Extracted
53812         from expand_builtin_init_dwarf_reg_sizes.
53813         (expand_builtin_init_dwarf_reg_sizes): Call
53814         generate_dwarf_reg_sizes.
53815         * target.def (init_dwarf_reg_sizes_extra): Adjust
53816         hook signature.
53817         * config/msp430/msp430.cc
53818         (msp430_init_dwarf_reg_sizes_extra): Adjust.
53819         * config/rs6000/rs6000.cc
53820         (rs6000_init_dwarf_reg_sizes_extra): Likewise.
53821         * doc/tm.texi: Update.
53823 2023-01-03  Florian Weimer  <fweimer@redhat.com>
53825         Revert:
53826         2023-01-02  Florian Weimer  <fweimer@redhat.com>
53828         * debug.h (dwarf_reg_sizes_constant): Declare.
53829         * dwarf2cfi.cc (dwarf_reg_sizes_constant): New function.
53831 2023-01-03  Siddhesh Poyarekar  <siddhesh@gotplt.org>
53833         PR tree-optimization/105043
53834         * doc/extend.texi (Object Size Checking): Split out into two
53835         subsections and mention _FORTIFY_SOURCE.
53837 2023-01-03  Roger Sayle  <roger@nextmovesoftware.com>
53839         * config/i386/i386-expand.cc (ix86_expand_int_movcc): Rewrite
53840         RTL expansion to allow condition (mask) to be shared/reused,
53841         by avoiding overwriting pseudos and adding REG_EQUAL notes.
53843 2023-01-03  Roger Sayle  <roger@nextmovesoftware.com>
53845         PR target/108229
53846         * config/i386/i386-features.cc
53847         (general_scalar_chain::compute_convert_gain) <case PLUS>: Consider
53848         the gain/cost of converting a MEM operand.
53850 2023-01-03  Jakub Jelinek  <jakub@redhat.com>
53852         PR middle-end/108264
53853         * expr.cc (store_expr): For stores into SUBREG_PROMOTED_* targets
53854         from source which doesn't have scalar integral mode first convert
53855         it to outer_mode.
53857 2023-01-03  Jakub Jelinek  <jakub@redhat.com>
53859         PR rtl-optimization/108263
53860         * cfgrtl.cc (fixup_reorder_chain): Avoid trying to redirect
53861         asm goto to EXIT.
53863 2023-01-02  Alexander Monakov  <amonakov@ispras.ru>
53865         PR target/87832
53866         * config/i386/lujiazui.md (lujiazui_div): New automaton.
53867         (lua_div): New unit.
53868         (lua_idiv_qi): Correct unit in the reservation.
53869         (lua_idiv_qi_load): Ditto.
53870         (lua_idiv_hi): Ditto.
53871         (lua_idiv_hi_load): Ditto.
53872         (lua_idiv_si): Ditto.
53873         (lua_idiv_si_load): Ditto.
53874         (lua_idiv_di): Ditto.
53875         (lua_idiv_di_load): Ditto.
53876         (lua_fdiv_SF): Ditto.
53877         (lua_fdiv_SF_load): Ditto.
53878         (lua_fdiv_DF): Ditto.
53879         (lua_fdiv_DF_load): Ditto.
53880         (lua_fdiv_XF): Ditto.
53881         (lua_fdiv_XF_load): Ditto.
53882         (lua_ssediv_SF): Ditto.
53883         (lua_ssediv_load_SF): Ditto.
53884         (lua_ssediv_V4SF): Ditto.
53885         (lua_ssediv_load_V4SF): Ditto.
53886         (lua_ssediv_V8SF): Ditto.
53887         (lua_ssediv_load_V8SF): Ditto.
53888         (lua_ssediv_SD): Ditto.
53889         (lua_ssediv_load_SD): Ditto.
53890         (lua_ssediv_V2DF): Ditto.
53891         (lua_ssediv_load_V2DF): Ditto.
53892         (lua_ssediv_V4DF): Ditto.
53893         (lua_ssediv_load_V4DF): Ditto.
53895 2023-01-02  Florian Weimer  <fweimer@redhat.com>
53897         * debug.h (dwarf_reg_sizes_constant): Declare.
53898         * dwarf2cfi.cc (dwarf_reg_sizes_constant): New function.
53900 2023-01-02  Florian Weimer  <fweimer@redhat.com>
53902         * dwarf2cfi.cc (init_return_column_size): Remove.
53903         (init_one_dwarf_reg_size): Adjust.
53904         (generate_dwarf_reg_sizes): New function.  Extracted
53905         from expand_builtin_init_dwarf_reg_sizes.
53906         (expand_builtin_init_dwarf_reg_sizes): Call
53907         generate_dwarf_reg_sizes.
53908         * target.def (init_dwarf_reg_sizes_extra): Adjust
53909         hook signature.
53910         * config/msp430/msp430.cc
53911         (msp430_init_dwarf_reg_sizes_extra): Adjust.
53912         * config/rs6000/rs6000.cc
53913         (rs6000_init_dwarf_reg_sizes_extra): Likewise.
53914         * doc/tm.texi: Update.
53916 2023-01-02  Jakub Jelinek  <jakub@redhat.com>
53918         * gcc.cc (process_command): Update copyright notice dates.
53919         * gcov-dump.cc (print_version): Ditto.
53920         * gcov.cc (print_version): Ditto.
53921         * gcov-tool.cc (print_version): Ditto.
53922         * gengtype.cc (create_file): Ditto.
53923         * doc/cpp.texi: Bump @copying's copyright year.
53924         * doc/cppinternals.texi: Ditto.
53925         * doc/gcc.texi: Ditto.
53926         * doc/gccint.texi: Ditto.
53927         * doc/gcov.texi: Ditto.
53928         * doc/install.texi: Ditto.
53929         * doc/invoke.texi: Ditto.
53931 2023-01-01  Roger Sayle  <roger@nextmovesoftware.com>
53932             Uroš Bizjak  <ubizjak@gmail.com>
53934         * config/i386/i386.md (extendditi2): New define_insn.
53935         (define_split): Use DWIH mode iterator to treat new extendditi2
53936         identically to existing extendsidi2_1.
53937         (define_peephole2): Likewise.
53938         (define_peephole2): Likewise.
53939         (define_Split): Likewise.
53942 Copyright (C) 2023 Free Software Foundation, Inc.
53944 Copying and distribution of this file, with or without modification,
53945 are permitted in any medium without royalty provided the copyright
53946 notice and this notice are preserved.