1 2024-09-03 YunQiang Su <syq@gcc.gnu.org>
3 * config/mips/mips-msa.md: (MSA_NO_HADD): we have HADD for
4 S8/U8/S16/U16/S32/U32 only.
5 (reduc_smin_scal_<mode>): New define pattern.
6 (reduc_smax_scal_<mode>): Ditto.
7 (reduc_umin_scal_<mode>): Ditto.
8 (reduc_umax_scal_<mode>): Ditto.
9 (reduc_plus_scal_<mode>): Ditto.
10 (reduc_plus_scal_v4si): Ditto.
11 (reduc_plus_scal_v8hi): Ditto.
12 (reduc_plus_scal_v16qi): Ditto.
13 (reduc_<optab>_scal_<mode>): Ditto.
14 * config/mips/mips-protos.h: New function mips_expand_msa_reduc.
15 * config/mips/mips.cc: New function mips_expand_msa_reduc.
16 * config/mips/mips.md: Define any_bitwise iterator.
18 2024-09-02 Alexandre Oliva <oliva@adacore.com>
21 * doc/sourcebuild.texi (dg-additional-sources): Add linkonly.
23 2024-09-02 Andrew Stubbs <ams@baylibre.com>
25 * config/gcn/gcn-opts.h (TARGET_GCN5_PLUS): Delete.
26 (TARGET_GLOBAL_ADDRSPACE): Delete.
27 (TARGET_FLAT_OFFSETS): Delete.
28 (TARGET_EXPLICIT_CARRY): Delete.
29 (TARGET_MULTIPLY_IMMEDIATE): Delete.
30 * config/gcn/gcn-valu.md (*mov<mode>): Rename "gcn_version" to "cdna".
31 (*mov<mode>_4reg): Likewise.
32 (@mov<mode>_sgprbase): Likwise.
33 (gather<mode>_insn_1offset<exec>): Likewise.
34 (gather<mode>_insn_1offset_ds<exec>): Likewise.
35 (gather<mode>_insn_2offsets<exec>): Likewise.
36 (scatter<mode>_insn_1offset<exec_scatter>): Likewise.
37 (scatter<mode>_insn_1offset_ds<exec_scatter>): Likewise.
38 (scatter<mode>_insn_2offsets<exec_scatter>): Likewise.
39 (gather<mode>_insn_1offset<exec>): Remove TARGET_FLAT_OFFSETS
41 (scatter<mode>_insn_1offset<exec_scatter>): Likewise.
42 (scatter<mode>_insn_1offset<exec_scatter>): Likewise.
43 (add<mode>3<exec_clobber>): Use "_co" instead of "%^".
44 (add<mode>3_dup<exec_clobber>): Likewise.
45 (add<mode>3_vcc<exec_vcc>): Likewise.
46 (add<mode>3_vcc_dup<exec_vcc>): Likewise.
47 (addc<mode>3<exec_vcc>): Likewise.
48 (sub<mode>3<exec_clobber>): Likewise.
49 (sub<mode>3_vcc<exec_vcc>): Likewise.
50 (subc<mode>3<exec_vcc>): Likewise.
51 (*plus_carry_dpp_shr_<mode>): Likewise.
52 (*plus_carry_in_dpp_shr_<mode>): Likewise.
53 * config/gcn/gcn.cc (gcn_flat_address_p): Remove TARGET_FLAT_OFFSETS
55 (gcn_addr_space_legitimate_address_p): Likewise.
56 (gcn_addr_space_legitimize_address): Likewise.
57 (gcn_expand_scalar_to_vector_address): Likewise.
58 (print_operand_address): Likewise, and TARGET_GLOBAL_ADDRSPACE also.
59 (print_operand): Remove "%^" operand code.
60 Remove TARGET_GLOBAL_ADDRSPACE assertion.
61 * config/gcn/gcn.h (STACK_ADDR_SPACE): Remove GCN5 conditional.
62 * config/gcn/gcn.md (gcn_version): Rename attribute ...
63 (cdna): ... to this, and remove the gcn3 and gcn5 values.
64 (enabled): Replace old "gcn_version" logic with new "cdna" logic.
65 (*mov<mode>_insn): Rename "gcn_version" to "cdna".
66 (*movti_insn): Likewise.
67 (addsi3): Use "_co" instead of "%^".
68 (addsi3_scalar_carry): Likewise.
69 (addsi3_scalar_carry_cst): Likewise.
70 (addcsi3_scalar): Likewise.
71 (addcsi3_scalar_zero): Likewise.
72 (addptrdi3): Likewise.
74 (<su>mulsi3_highpart): Remove TARGET_MULTIPLY_IMMEDIATE conditions.
75 (<su>mulsi3_highpart_reg): Remove "gcn_version" attribute.
77 (atomic_fetch_<bare_mnemonic><mode>): Likewise.
78 (atomic_<bare_mnemonic><mode>): Likewise.
79 (sync_compare_and_swap<mode>_insn): Likewise.
80 (atomic_load<mode>): Likewise.
81 (atomic_store<mode>): Likewise.
82 (atomic_exchange<mode>): Likewise.
83 (<su>mulsi3_highpart_imm): Remove both TARGET_MULTIPLY_IMMEDIATE and
85 (<su>mulsidi3): Likewise.
86 (<su>mulsidi3_imm): Likewise.
88 2024-09-02 Andrew Stubbs <ams@baylibre.com>
90 * config/gcn/gcn-opts.h (enum gcn_isa): Delete ISA_GCN3.
91 (TARGET_GCN3): Delete.
92 (TARGET_GCN3_PLUS): Delete.
93 (TARGET_M0_LDS_LIMIT): Delete.
94 * config/gcn/gcn-valu.md
95 (gather<mode>_insn_1offset<exec>): Remove TARGET_GCN3 from conditions.
96 (*<reduc_op>_dpp_shr_<mode>): Likewise.
97 * config/gcn/gcn.cc (enum gcn_isa): Change default to ISA_GCN5.
98 (gcn_expand_prologue): Remove TARGET_M0_LDS_LIMIT feature.
99 (gcn_expand_reduc_scalar): Remove TARGET_GCN3 conditions.
100 * config/gcn/gcn.h (TARGET_CPU_CPP_BUILTINS): Remove TARGET_GCN3.
102 2024-09-02 Andrew Stubbs <ams@baylibre.com>
104 * config.gcc (amdgcn-*-*): Remove "fiji" from with_arch checks.
105 * config/gcn/gcn-hsa.h (ABI_VERSION_SPEC): Remove fiji alternative.
106 (NO_XNACK): Likewise.
107 (NO_SRAM_ECC): Likewise.
108 (ASM_SPEC): Remove "%{}" around ABI_VERSION_SPEC.
109 * config/gcn/gcn-opts.h (enum processor_type): Remove PROCESSOR_FIJI.
110 (TARGET_FIJI): Delete.
111 * config/gcn/gcn.cc (gcn_option_override): Remove Fiji.
112 (gcn_omp_device_kind_arch_isa): Likewise.
113 (output_file_start): Likewise.
114 * config/gcn/gcn.h (TARGET_CPU_CPP_BUILTINS): Likewise.
115 * config/gcn/gcn.opt (gpu_type): Likewise.
116 (march, mtune): Change default to PROCESSOR_VEGA10.
117 * config/gcn/mkoffload.cc (EF_AMDGPU_MACH_AMDGCN_GFX803): Delete.
118 (copy_early_debug_info): Remove elf_flags_actual.
119 Use ELFABIVERSION_AMDGPU_HSA_V4 unconditionally.
120 (get_arch): Remove Fiji.
121 (main): Remove gfx803.
122 * config/gcn/t-omp-device
123 (omp-device-properties-gcn): Remove fiji and gfx803.
124 * doc/install.texi (amdgcn*-*-*): Remove fiji and special instructions.
125 * doc/invoke.texi: Remove fiji.
127 2024-09-02 Richard Sandiford <richard.sandiford@arm.com>
129 * doc/gimple.texi (gimple_asm_basic_p): Document.
130 (gimple_asm_set_basic): Likewise.
131 * gimple.h (GF_ASM_INPUT): Rename to...
132 (GF_ASM_BASIC): ...this.
133 (gimple_asm_set_input): Rename to...
134 (gimple_asm_set_basic): ...this.
135 (gimple_asm_input_p): Rename to...
136 (gimple_asm_basic_p): ...this.
137 * cfgexpand.cc (expand_asm_stmt): Update after above renaming.
138 * gimple.cc (gimple_asm_clobbers_memory_p): Likewise.
139 * gimplify.cc (gimplify_asm_expr): Likewise.
140 * ipa-icf-gimple.cc (func_checker::compare_gimple_asm): Likewise.
141 * tree-cfg.cc (stmt_can_terminate_bb_p): Likewise.
143 2024-09-02 Richard Sandiford <richard.sandiford@arm.com>
145 * doc/generic.texi (ASM_BASIC_P): Document.
146 * tree.h (ASM_INPUT_P): Rename to...
147 (ASM_BASIC_P): ...this.
148 (ASM_VOLATILE_P, ASM_INLINE_P): Reindent.
149 * gimplify.cc (gimplify_asm_expr): Update after above renaming.
150 * tree-core.h (tree_base): Likewise.
152 2024-09-02 Tobias Burnus <tburnus@baylibre.com>
154 * lto-wrapper.cc (run_gcc): Honor -save-temps for
157 2024-09-02 Jakub Jelinek <jakub@redhat.com>
160 * gimple-range-op.cc (cfn_clz::fold_range): If lh is [0,0]
161 and mini is -1, return [-1,-1] range rather than [prec-1,prec-1].
163 2024-09-02 Richard Biener <rguenther@suse.de>
165 * tree-vectorizer.h (_slp_tree::ldst_lanes): New flag to mark
166 load, store and permute nodes.
167 * tree-vect-slp.cc (_slp_tree::_slp_tree): Initialize ldst_lanes.
168 (vect_build_slp_instance): For stores iff the target prefers
169 store-lanes discover single-lane sub-groups, do not perform
170 interleaving lowering but mark the node with ldst_lanes.
171 Also allow i == 0 - fatal failure - for splitting up a store group
172 when we're not doing single-lane discovery already.
173 (vect_lower_load_permutations): When the target supports
174 load lanes and the loads all fit the pattern split out
175 a single level of permutes only and mark the load and
176 permute nodes with ldst_lanes.
177 (vectorizable_slp_permutation_1): Handle the load-lane permute
178 forwarding of vector defs.
179 (vect_analyze_slp): After SLP pattern recog is finished see if
180 there are any SLP instances that would benefit from using
181 load/store-lanes and re-discover those with forced single lanes.
182 * tree-vect-stmts.cc (get_group_load_store_type): Support
183 load/store-lanes for SLP.
184 (vectorizable_store): Support SLP code generation for store-lanes.
185 (vectorizable_load): Support SLP code generation for load-lanes.
186 * tree-vect-loop.cc (vect_analyze_loop_2): Do not cancel SLP
187 when store-lanes can be used.
189 2024-09-02 Richard Biener <rguenther@suse.de>
191 * tree-vect-slp.cc (vect_build_slp_tree_1): Handle NULL stmt.
192 (vect_build_slp_tree_2): Likewise. Release load permutation
193 when there's a NULL in SLP_TREE_SCALAR_STMTS and assert there's
194 no actual permutation in that case.
195 (vllp_cmp): New function.
196 (vect_lower_load_permutations): Likewise.
197 (vect_analyze_slp): Call it.
199 2024-09-02 Xianmiao Qu <cooper.qu@linux.alibaba.com>
201 * config/riscv/riscv.cc (riscv_rtx_costs): Optimize the cost of the
202 DFmode register move for RV32.
204 2024-09-02 Jeff Law <jlaw@ventanamicro.com>
206 PR rtl-optimization/116544
207 * ext-dce.cc (ext_dce_process_uses): Fix thinko in promoted subreg
210 2024-09-02 Levy Hsu <admin@levyhsu.com>
212 * config/i386/i386-expand.cc (ix86_use_mask_cmp_p): Add BFmode
214 * config/i386/sse.md (vec_cmp<mode><avx512fmaskmodelower>): New
215 vec_cmp expand for VBF modes.
217 2024-09-02 Levy Hsu <admin@levyhsu.com>
219 * config/i386/sse.md: Expand VF2H to VF2HB with VBF modes.
221 2024-09-02 Levy Hsu <admin@levyhsu.com>
224 (<code><mode>3): New define expand pattern for BF smaxmin.
226 2024-09-02 Levy Hsu <admin@levyhsu.com>
228 * config/i386/sse.md: Add V8BF/V16BF/V32BF to mode iterator FMAMODEM.
230 2024-09-02 Levy Hsu <admin@levyhsu.com>
232 * config/i386/sse.md (div<mode>3): New expander for BFmode div.
233 (VF_BHSD): New mode iterator with vector BFmodes.
234 (<insn><mode>3<mask_name><round_name>): Change mode to VF_BHSD.
235 (mul<mode>3<mask_name><round_name>): Likewise.
237 2024-09-02 Hu, Lin1 <lin1.hu@intel.com>
239 * config/i386/i386-expand.cc (ix86_expand_fp_compare): Add UNSPEC to
240 support the optimization.
241 * config/i386/i386.cc (ix86_fp_compare_code_to_integer): Add NE/EQ.
242 * config/i386/i386.md (*cmpx<unord><MODEF:mode>): New define_insn.
243 (*cmpx<unord>hf): Ditto.
244 * config/i386/predicates.md (ix86_trivial_fp_comparison_operator):
247 2024-09-02 Hu, Lin1 <lin1.hu@intel.com>
249 * match.pd: Optimize (and ordered non-equal) to
250 (not (or unordered equal))
252 2024-09-02 Haochen Jiang <haochen.jiang@intel.com>
254 * config/i386/sse.md (VI1_AVX512VNNIBW): New.
255 (VI2_AVX10_2): Ditto.
256 (sdot_prod<mode>): Add AVX10.2
257 to auto vectorize and combine 512 bit part.
258 (udot_prod<mode>): Ditto.
259 (sdot_prodv64qi): Removed.
260 (udot_prodv64qi): Ditto.
261 (usdot_prod<mode>): Add AVX10.2 to auto vectorize.
262 (udot_prod<mode>): Ditto.
264 2024-09-02 Pan Li <pan2.li@intel.com>
266 * config/riscv/riscv.cc (riscv_gen_zero_extend_rtx): Merge
267 the zero_extend handing from func riscv_gen_unsigned_xmode_reg.
268 (riscv_gen_unsigned_xmode_reg): Remove.
269 (riscv_expand_ussub): Leverage riscv_gen_zero_extend_rtx
270 instead of riscv_gen_unsigned_xmode_reg.
272 2024-09-01 Andrew Pinski <quic_apinski@quicinc.com>
274 PR tree-optimization/116554
275 * gimple-ssa-strength-reduction.cc: Include tree-ssa-dce.h.
276 (replace_mult_candidate): Add sdce_worklist argument, mark
277 the rhs1/rhs2 for maybe dceing.
278 (replace_unconditional_candidate): Add sdce_worklist argument,
279 Update call to replace_mult_candidate.
280 (replace_conditional_candidate): Add sdce_worklist argument,
281 update call to replace_mult_candidate.
282 (replace_uncond_cands_and_profitable_phis): Add sdce_worklist argument,
283 update call to replace_conditional_candidate,
284 replace_unconditional_candidate, and replace_uncond_cands_and_profitable_phis.
285 (replace_one_candidate): Add sdce_worklist argument, mark
286 the orig_rhs1/orig_rhs2 for maybe dceing.
287 (replace_profitable_candidates): Add sdce_worklist argument,
288 update call to replace_one_candidate and replace_profitable_candidates.
289 (analyze_candidates_and_replace): Call simple_dce_from_worklist and
290 update calls to replace_profitable_candidates, and
291 replace_uncond_cands_and_profitable_phis.
293 2024-08-31 Roger Sayle <roger@nextmovesoftware.com>
295 * config/i386/i386-features.cc (timode_scalar_to_vector_candidate_p):
296 Support the first operand of AND, IOR and XOR being MEM_P, i.e. a
297 read-modify-write insn.
299 2024-08-31 Georg-Johann Lay <avr@gjlay.de>
301 * config/avr/avr-passes.cc (avr_pass_fuse_add) <clone>: Override.
302 * config/avr/avr-passes.def (avr_pass_fuse_add): Run again
303 after pass_cprop_hardreg.
305 2024-08-31 Georg-Johann Lay <avr@gjlay.de>
307 * config/avr/avr-protos.h (avr_split_tiny_move): Rename to
308 avr_split_fake_addressing_move.
309 * config/avr/avr-passes.def: Same.
310 * config/avr/avr-passes.cc: Same.
311 (avr_pass_data_fuse_add) <tv_id>: Set to TV_MACH_DEP.
312 * config/avr/avr.md (split-lpmx): Remove a define_split. Such
313 splits are performed by avr_split_fake_addressing_move.
315 2024-08-31 John David Anglin <danglin@gcc.gnu.org>
317 * config/pa/pa.cc (pa_emit_move_sequence): Remove symbolic
318 memory work arounds for TARGET_ELF32.
319 (pa_legitimate_address_p): Likewise. Allow symbolic
320 operands. Adjust comment.
321 * config/pa/pa.md: Replace reg_or_0_or_nonsymb_mem_operand
322 with reg_or_0_or_mem_operand predicate in various unnamed
324 * config/pa/predicates.md (floating_point_store_memory_operand):
325 Update comment. Remove symbolic memory work arounds for
327 (nonsymb_mem_operand): Rename to mem_operand. Allow
328 symbolic memory operands.
329 (reg_or_0_or_nonsymb_mem_operand): Rename to
330 reg_or_0_or_mem_operand. Allow symbolic memory operands.
332 2024-08-31 Andrew Pinski <quic_apinski@quicinc.com>
334 PR tree-optimization/116098
335 * tree-ssa-phiopt.cc (factor_out_conditional_operation): Ignore
336 nops, labels and predicts for heuristic for conversion with a constant.
338 2024-08-31 Jakub Jelinek <jakub@redhat.com>
341 * doc/extend.texi (unsequenced, reproducible): Document new function
343 * calls.cc (flags_from_decl_or_type): Handle "unsequenced noptr" and
344 "reproducible noptr" attributes.
346 2024-08-31 Georg-Johann Lay <avr@gjlay.de>
348 * config/avr/avr.cc: Follow the convention to not add a space
349 after comma when printing instructions.
351 2024-08-31 Alexandre Oliva <oliva@adacore.com>
353 * expr.cc (categorize_ctor_elements_1): Change p_complete to
354 int, to distinguish complete initialization in presence or
355 absence of uninitialized padding bits.
356 (categorize_ctor_elements): Likewise. Adjust all callers...
357 * expr.h (categorize_ctor_elements): ... and declaration.
358 (type_has_padding_at_level_p): New.
359 * gimple-fold.cc (type_has_padding_at_level_p): New.
360 * fold-const.cc (native_encode_constructor): New.
361 (native_encode_expr): Call it.
362 * gimplify.cc (gimplify_init_constructor): Clear small
363 non-addressable non-volatile objects with padding or
364 other uninitialized fields as an optimization.
366 2024-08-30 Alex Coplan <alex.coplan@arm.com>
368 * gdbhooks.py (VEC_KIND_EMBED): New.
371 (VecPrinter.children): Also handle vectors with vl_ptr layout.
373 2024-08-30 Andrew Pinski <quic_apinski@quicinc.com>
377 * gcc.cc (is_directory): Don't not include /usr/lib and /lib
378 for library directory pathes. Remove library argument.
379 (add_to_obstack): Update call to is_directory.
380 (driver_handle_option): Likewise.
381 (spec_path): Likewise.
383 2024-08-30 Andrew Pinski <quic_apinski@quicinc.com>
386 * tree-core.h (enum tree_index): Remove TI_INTEGER_THREE
387 * tree-ssa-loop-prefetch.cc (issue_prefetch_ref): Call build_int_cst
388 instead of using integer_three_node.
389 * tree.cc (build_common_tree_nodes): Remove initialization
390 of integer_three_node.
391 * tree.h (integer_three_node): Delete.
393 2024-08-30 Andrew Pinski <quic_apinski@quicinc.com>
395 * builtins.cc (expand_builtin_prefetch): Rewrite expansion of the optional
396 arguments to not expand known constants.
398 2024-08-30 Richard Biener <rguenther@suse.de>
400 * tree-vect-stmts.cc (get_group_load_store_type): Check
401 known_ne (remain, 0u) before doing constant_multiple_p.
402 (vectorizable_load): Likewise.
404 2024-08-30 Richard Biener <rguenther@suse.de>
406 * tree-vect-slp.cc (vect_build_slp_tree_2): Disable SLP
407 reassociation for single-lane.
409 2024-08-30 liuhongt <hongtao.liu@intel.com>
412 * config/i386/i386.cc (ix86_check_avx_upper_register): Iterate
413 subrtx to scan for avx upper register.
414 (ix86_check_avx_upper_stores): Inline old
415 ix86_check_avx_upper_register.
416 (ix86_avx_u128_mode_needed): Ditto, and replace
417 FOR_EACH_SUBRTX with call to new
418 ix86_check_avx_upper_register.
420 2024-08-29 David Malcolm <dmalcolm@redhat.com>
423 * diagnostic-event-id.h (diagnostic_event_id_t::zero_based): New.
424 * diagnostic-format-sarif.cc: Include "pretty-print-format-impl.h"
425 and "pretty-print-urlifier.h".
426 (sarif_result::sarif_result): Add param "idx_within_parent".
427 (sarif_result::get_index_within_parent): New accessor.
428 (sarif_result::m_idx_within_parent): New field.
429 (sarif_code_flow::sarif_code_flow): New ctor.
430 (sarif_code_flow::get_parent): New accessor.
431 (sarif_code_flow::get_index_within_parent): New accessor.
432 (sarif_code_flow::m_parent): New field.
433 (sarif_code_flow::m_thread_id_map): New field.
434 (sarif_code_flow::m_thread_flows_arr): New field.
435 (sarif_code_flow::m_all_tfl_objs): New field.
436 (sarif_thread_flow::sarif_thread_flow): Add "parent" and
437 "idx_within_parent" params.
438 (sarif_thread_flow::get_parent): New accessor.
439 (sarif_thread_flow::get_index_within_parent): New accessor.
440 (sarif_thread_flow::m_parent): New field.
441 (sarif_thread_flow::m_idx_within_parent): New field.
442 (sarif_thread_flow_location::sarif_thread_flow_location): New
444 (sarif_thread_flow_location::get_parent): New accessor.
445 (sarif_thread_flow_location::get_index_within_parent): New
447 (sarif_thread_flow_location::m_parent): New field.
448 (sarif_thread_flow_location::m_idx_within_parent): New field.
449 (sarif_builder::get_code_flow_for_event_ids): New accessor.
450 (class sarif_builder::sarif_token_printer): New.
451 (sarif_builder::m_token_printer): New member.
452 (sarif_builder::m_next_result_idx): New field.
453 (sarif_builder::m_current_code_flow): New field.
454 (sarif_code_flow::get_or_append_thread_flow): New.
455 (sarif_code_flow::get_thread_flow): New.
456 (sarif_code_flow::add_location): New.
457 (sarif_code_flow::get_thread_flow_loc_obj): New.
458 (sarif_thread_flow::add_location): Create the new
459 sarif_thread_flow_location internally, rather than passing
460 it in as a parm so that we can keep track of its index in
461 the array. Return a reference to it.
462 (sarif_builder::sarif_builder): Initialize m_token_printer,
463 m_next_result_idx, and m_current_code_flow.
464 (sarif_builder::on_report_diagnostic): Pass index to
466 (sarif_builder::make_result_object): Add "idx_within_parent" param
467 and pass to sarif_result ctor. Pass code flow index to call to
468 make_code_flow_object.
469 (make_sarif_url_for_event): New.
470 (sarif_builder::make_code_flow_object): Add "idx_within_parent"
471 param and pass it to sarif_code_flow ctor. Reimplement walking
472 of events so that we first create threadFlow objects for each
473 thread, then populate them with threadFlowLocation objects, so
474 that the IDs work. Set m_current_code_flow whilst creating the
475 latter, so that we can create correct URIs for "%@".
476 (sarif_builder::make_thread_flow_location_object): Replace with...
477 (sarif_builder::populate_thread_flow_location_object): ...this.
478 (sarif_output_format::get_builder): New accessor.
479 (sarif_begin_embedded_link): New.
480 (sarif_end_embedded_link): New.
481 (sarif_builder::sarif_token_printer::print_tokens): New.
482 (diagnostic_output_format_init_sarif): Add "fmt" param; use it to
483 set the token printer and output format for the context.
484 (diagnostic_output_format_init_sarif_stderr): Move responsibility
485 for setting the context's output format to within
486 diagnostic_output_format_init_sarif.
487 (diagnostic_output_format_init_sarif_file): Likewise.
488 (diagnostic_output_format_init_sarif_stream): Likewise.
489 (test_sarif_diagnostic_context::test_sarif_diagnostic_context):
491 (selftest::test_make_location_object): Provide an idx for the
493 (selftest::get_result_from_log): New.
494 (selftest::get_message_from_log): New.
495 (selftest::test_message_with_embedded_link): New test.
496 (selftest::diagnostic_format_sarif_cc_tests): Call it.
497 * pretty-print-format-impl.h: Include "diagnostic-event-id.h".
498 (pp_token::kind): Add "event_id".
499 (struct pp_token_event_id): New.
500 (is_a_helper <pp_token_event_id *>::test): New.
501 (is_a_helper <const pp_token_event_id *>::test): New.
502 * pretty-print.cc (pp_token::dump): Handle kind::event_id.
503 (pretty_printer::format): Update handling of "%@" in phase 2
504 so that we add a pp_token_event_id, rather that the text "(N)".
505 (default_token_printer): Handle pp_token::kind::event_id by
506 printing the text "(N)".
508 2024-08-29 David Malcolm <dmalcolm@redhat.com>
510 * diagnostic.cc (diagnostic_context::report_diagnostic): Don't
511 pass m_urlifier to pp_format, as urlification now happens in
513 * dump-context.h (class dump_pretty_printer): Update leading
515 (dump_pretty_printer::emit_items): Drop decl.
516 (dump_pretty_printer::set_optinfo): New.
517 (class dump_pretty_printer::stashed_item): Delete class.
518 (class dump_pretty_printer::custom_token_printer): New class.
519 (dump_pretty_printer::format_decoder_cb): Convert param from
520 const char ** to pp_token_list &.
521 (dump_pretty_printer::decode_format): Likewise.
522 (dump_pretty_printer::stash_item): Likewise.
523 (dump_pretty_printer::emit_any_pending_textual_chunks): Drop decl.
524 (dump_pretty_printer::m_stashed_items): Delete field.
525 (dump_pretty_printer::m_token_printer): New member data.
526 * dumpfile.cc (struct wrapped_optinfo_item): New.
527 (dump_pretty_printer::dump_pretty_printer): Update for dropping
528 of field m_stashed_items and new field m_token_printer.
529 (dump_pretty_printer::emit_items): Delete; we now use
530 pp_output_formatted_text..
531 (dump_pretty_printer::emit_any_pending_textual_chunks): Delete.
532 (dump_pretty_printer::stash_item): Convert param from
533 const char ** to pp_token_list &.
534 (dump_pretty_printer::format_decoder_cb): Likewise.
535 (dump_pretty_printer::decode_format): Likewise.
536 (dump_pretty_printer::custom_token_printer::print_tokens): New.
537 (dump_pretty_printer::custom_token_printer::emit_any_pending_textual_chunks):
539 (dump_context::dump_printf_va): Call set_optinfo on the
540 dump_pretty_printer. Replace call to emit_items with a call to
541 pp_output_formatted_text.
542 * opt-problem.cc (opt_problem::opt_problem): Replace call to
543 emit_items with call to set_optinfo and call to
544 pp_output_formatted_text.
545 * pretty-print-format-impl.h (struct pp_token): New.
546 (struct pp_token_text): New.
547 (is_a_helper <pp_token_text *>::test): New.
548 (is_a_helper <const pp_token_text *>::test): New.
549 (struct pp_token_begin_color): New.
550 (is_a_helper <pp_token_begin_color *>::test): New.
551 (is_a_helper <const pp_token_begin_color *>::test): New.
552 (struct pp_token_end_color): New.
553 (struct pp_token_begin_quote): New.
554 (struct pp_token_end_quote): New.
555 (struct pp_token_begin_url): New.
556 (is_a_helper <pp_token_begin_url*>::test): New.
557 (is_a_helper <const pp_token_begin_url*>::test): New.
558 (struct pp_token_end_url): New.
559 (struct pp_token_custom_data): New.
560 (is_a_helper <pp_token_custom_data *>::test): New.
561 (is_a_helper <const pp_token_custom_data *>::test): New.
562 (class pp_token_list): New.
563 (chunk_info::get_args): Drop.
564 (chunk_info::get_quoting_info): Drop.
565 (chunk_info::get_token_lists): New accessor.
566 (chunk_info::append_formatted_chunk): Add obstack & param.
567 (chunk_info::dump): New decls.
568 (chunk_info::m_args): Convert element type from const char * to
569 pp_token_list *. Rewrite/update comment.
570 (chunk_info::m_quotes): Drop field.
571 * pretty-print-markup.h (class pp_token_list): New forward decl.
572 (pp_markup::context::context): Drop urlifier param; add
573 formatted_token_list param.
574 (pp_markup::context::push_back_any_text): New decl.
575 (pp_markup::context::m_urlifier): Drop field.
576 (pp_markup::context::m_formatted_token_list): New field.
577 * pretty-print-urlifier.h: Update comment.
578 * pretty-print.cc: Define INCLUDE_MEMORY. Include
580 (default_token_printer): New forward decl.
581 (obstack_append_string): Delete.
582 (urlify_quoted_string): Delete.
583 (pp_token::pp_token): New.
584 (pp_token::dump): New.
585 (allocate_object): New.
586 (class quoting_info): Delete.
587 (pp_token::operator new): New.
588 (pp_token::operator delete): New.
589 (pp_token_list::operator new): New.
590 (pp_token_list::operator delete): New.
591 (pp_token_list::pp_token_list): New.
592 (pp_token_list::~pp_token_list): New.
593 (pp_token_list::push_back_text): New.
594 (pp_token_list::push_back): New.
595 (pp_token_list::push_back_list): New.
596 (pp_token_list::pop_front): New.
597 (pp_token_list::remove_token): New.
598 (pp_token_list::insert_after): New.
599 (pp_token_list::replace_custom_tokens): New.
600 (pp_token_list::merge_consecutive_text_tokens): New.
601 (pp_token_list::apply_urlifier): New.
602 (pp_token_list::dump): New.
603 (chunk_info::append_formatted_chunk): Add obstack & param and use
604 it to reimplement in terms of token lists.
605 (chunk_info::pop_from_output_buffer): Drop m_quotes.
606 (chunk_info::on_begin_quote): Delete.
607 (chunk_info::dump): New.
608 (chunk_info::on_end_quote): Delete.
609 (push_back_any_text): New.
610 (pretty_printer::format): Drop "urlifier" param and quoting_info
611 logic. Convert "formatters" and "args" from const ** to
612 pp_token_list **. Reimplement so that rather than just
613 accumulating a text buffer in the chunk_obstack for each arg,
614 instead also accumulate a pp_token_list and pp_tokens for each
616 (auto_obstack::operator obstack &): New.
617 (quoting_info::handle_phase_3): Delete.
618 (pp_output_formatted_text): Reimplement in terms of manipulations
619 of pp_token_lists, rather than char buffers. Call
620 default_token_printer, or m_token_printer's print_tokens vfunc.
621 (default_token_printer): New.
622 (pretty_printer::pretty_printer): Initialize m_token_printer in
624 (pp_markup::context::begin_quote): Reimplement to use token list.
625 (pp_markup::context::end_quote): Likewise.
626 (pp_markup::context::begin_highlight_color): Likewise.
627 (pp_markup::context::end_highlight_color): Likewise.
628 (pp_markup::context::push_back_any_text): New.
629 (selftest::test_merge_consecutive_text_tokens): New.
630 (selftest::test_custom_tokens_1): New.
631 (selftest::test_custom_tokens_2): New.
632 (selftest::pp_printf_with_urlifier): Drop "urlifier" param from
634 (selftest::test_urlification): Add test of the example from
635 pretty-print-format-impl.h.
636 (selftest::pretty_print_cc_tests): Call the new selftest
638 * pretty-print.h (class quoting_info): Drop forward decl.
639 (class pp_token_list): New forward decl.
640 (printer_fn): Convert final param from const char ** to
642 (class token_printer): New.
643 (class pretty_printer): Add pp_output_formatted_text as friend.
644 (pretty_printer::set_token_printer): New.
645 (pretty_printer::format): Drop urlifier param as this now happens
647 (pretty_printer::m_format_decoder): Update comment.
648 (pretty_printer::m_token_printer): New field.
649 (pp_format): Drop urlifier param.
650 * tree-diagnostic.cc (default_tree_printer): Convert final param
651 from const char ** to pp_token_list &.
652 * tree-diagnostic.h: Likewise for decl.
654 2024-08-29 David Malcolm <dmalcolm@redhat.com>
656 * dumpfile.cc: Include "pretty-print-format-impl.h".
657 * pretty-print-format-impl.h: New file, based on material from
659 * pretty-print.cc: Include "pretty-print-format-impl.h".
660 * pretty-print.h (chunk_info): Replace full declaration with
661 a forward decl, moving full decl to pretty-print-format-impl.h.
663 2024-08-29 David Malcolm <dmalcolm@redhat.com>
665 * config/aarch64/aarch64.cc: Define INCLUDE_MEMORY.
666 * config/arm/arm.cc: Likewise.
667 * config/i386/i386.cc: Likewise.
668 * config/loongarch/loongarch.cc: Likewise.
669 * config/riscv/riscv-vector-costs.cc: Likewise.
670 * config/riscv/riscv.cc: Likewise.
671 * config/rs6000/rs6000.cc: Likewise.
672 * dump-context.h (dump_context::emit_item): Convert "item" param
674 (dump_pretty_printer::stash_item): Convert "item" param from
675 optinfo_ * to std::unique_ptr<optinfo_item>.
676 (dump_pretty_printer::emit_item): Likewise.
677 * dumpfile.cc: Include "make-unique.h".
678 (make_item_for_dump_gimple_stmt): Replace uses of optinfo_item *
679 with std::unique_ptr<optinfo_item>.
680 (dump_context::dump_gimple_stmt): Likewise.
681 (make_item_for_dump_gimple_expr): Likewise.
682 (dump_context::dump_gimple_expr): Likewise.
683 (make_item_for_dump_generic_expr): Likewise.
684 (dump_context::dump_generic_expr): Likewise.
685 (make_item_for_dump_symtab_node): Likewise.
686 (dump_pretty_printer::emit_items): Likewise.
687 (dump_pretty_printer::emit_any_pending_textual_chunks): Likewise.
688 (dump_pretty_printer::emit_item): Likewise.
689 (dump_pretty_printer::stash_item): Likewise.
690 (dump_pretty_printer::decode_format): Likewise.
691 (dump_context::dump_printf_va): Fix overlong line.
692 (make_item_for_dump_dec): Replace uses of optinfo_item * with
693 std::unique_ptr<optinfo_item>.
694 (dump_context::dump_dec): Likewise.
695 (dump_context::dump_symtab_node): Likewise.
696 (dump_context::begin_scope): Likewise.
697 (dump_context::emit_item): Likewise.
698 * gimple-loop-interchange.cc: Define INCLUDE_MEMORY.
699 * gimple-loop-jam.cc: Likewise.
700 * gimple-loop-versioning.cc: Likewise.
701 * graphite-dependences.cc: Likewise.
702 * graphite-isl-ast-to-gimple.cc: Likewise.
703 * graphite-optimize-isl.cc: Likewise.
704 * graphite-poly.cc: Likewise.
705 * graphite-scop-detection.cc: Likewise.
706 * graphite-sese-to-poly.cc: Likewise.
707 * graphite.cc: Likewise.
708 * opt-problem.cc: Likewise.
709 * optinfo.cc (optinfo::add_item): Convert "item" param from
710 optinfo_ * to std::unique_ptr<optinfo_item>.
711 (optinfo::emit_for_opt_problem): Update for change to
712 dump_context::emit_item.
713 * optinfo.h: Add #error to fail immediately if INCLUDE_MEMORY
714 wasn't defined, rather than fail to find std::unique_ptr.
715 (optinfo::add_item): Convert "item" param from optinfo_ * to
716 std::unique_ptr<optinfo_item>.
717 * sese.cc: Define INCLUDE_MEMORY.
718 * targhooks.cc: Likewise.
719 * tree-data-ref.cc: Likewise.
720 * tree-if-conv.cc: Likewise.
721 * tree-loop-distribution.cc: Likewise.
722 * tree-parloops.cc: Likewise.
723 * tree-predcom.cc: Likewise.
724 * tree-ssa-live.cc: Likewise.
725 * tree-ssa-loop-ivcanon.cc: Likewise.
726 * tree-ssa-loop-ivopts.cc: Likewise.
727 * tree-ssa-loop-prefetch.cc: Likewise.
728 * tree-ssa-loop-unswitch.cc: Likewise.
729 * tree-ssa-phiopt.cc: Likewise.
730 * tree-ssa-threadbackward.cc: Likewise.
731 * tree-ssa-threadupdate.cc: Likewise.
732 * tree-vect-data-refs.cc: Likewise.
733 * tree-vect-generic.cc: Likewise.
734 * tree-vect-loop-manip.cc: Likewise.
735 * tree-vect-loop.cc: Likewise.
736 * tree-vect-patterns.cc: Likewise.
737 * tree-vect-slp-patterns.cc: Likewise.
738 * tree-vect-slp.cc: Likewise.
739 * tree-vect-stmts.cc: Likewise.
740 * tree-vectorizer.cc: Likewise.
742 2024-08-29 John David Anglin <danglin@gcc.gnu.org>
744 * config/pa/pa.cc (load_reg): Don't generate load with
745 unscaled index address when !TARGET_NO_SPACE_REGS.
746 (pa_legitimate_address_p): Only allow unscaled index
747 addresses when TARGET_NO_SPACE_REGS.
749 2024-08-29 Andrew Pinski <quic_apinski@quicinc.com>
752 * internal-fn.cc (expand_POPCOUNT): Use OPTAB_WIDEN for PLUS and
755 2024-08-29 Richard Sandiford <richard.sandiford@arm.com>
758 * rtlanal.cc (strip_address_mutations): Allow subregs around
759 constant displacements.
761 2024-08-29 Richard Sandiford <richard.sandiford@arm.com>
763 * dse.cc (find_shift_sequence): Allow smallest_int_mode_for_size
765 * optabs.cc (expand_twoval_binop_libfunc): Likewise.
767 2024-08-29 Georg-Johann Lay <avr@gjlay.de>
770 * config/avr/avr-modes.def (CCN, CCZN): New CC_MODEs.
771 * config/avr/avr-protos.h (avr_cond_branch): New from
773 (avr_out_plus_set_N, avr_op8_ZN_operator, avr_cmp0_code)
774 (avr_out_op8_set_ZN, avr_len_op8_set_ZN): New protos.
775 (ccn_reg_rtx, cczn_reg_rtx): New declarations.
776 * config/avr/avr.cc (avr_cond_branch): New from ret_cond_branch.
777 (avr_cond_string): Add bool cc_overflow_unusable argument.
778 (avr_print_operand) ['L']: Like 'j' but overflow unusable.
779 ['K']: Like 'k' but overflow unusable.
780 (avr_out_plus_set_ZN): Remove handling of QImode.
781 (avr_out_plus_set_N, avr_op8_ZN_operator, avr_cmp0_code)
782 (avr_out_op8_set_ZN, avr_len_op8_set_ZN): New functions.
783 (avr_adjust_insn_length) [ADJUST_LEN_ADD_SET_N]: Hande case.
784 (avr_class_max_nregs): All MODE_CCs occupy one hard reg.
785 (avr_hard_regno_nregs): Same.
786 (avr_hard_regno_mode_ok) [REG_CC]: Allow all MODE_CC.
787 (pass_manager.h, context.h, tree-pass.h): Include them.
788 (ccn_reg_rtx, cczn_reg_rtx): New GTY variables.
789 (avr_init_expanders): Initialize them.
790 (avr_option_override): Run peephole2 a second time.
791 * config/avr/avr.md (adjust_len) [add_set_N]: New attr value.
792 (ALLCC, HI_SI): New mode iterators.
793 (CCname): New mode attribute.
794 (eqnegtle, cmp_signed, op8_ZN): New code iterators.
795 (swap, SWAP): New code attributes.
796 (branch): Handle CCNmode and CCZNmode. Assimilate...
797 (difficult_branch): ...this insn.
799 (gen_add_for_<code>_<mode>): Adjust to CCNmode and CCZNmode. Use
800 HISI as mode iterator. Extend peephole2s that produce them.
801 (*add.for.eqne.<mode>): Extend to *add.for.cc[z]n.<mode>.
802 (*ashift.for.ccn.<mode>): New insn and peephole2 to make them.
803 (*sub.for.cczn.<mode>, *sub-extend<mode>.for.cczn.<mode>):
804 New insns and peephole2s to make them.
805 (*op8.for.cczn.<code>): New insn and peephole2 to make them.
806 * config/avr/predicates.md (const_1_to_3_operand)
807 (abs1_abs2_operand, signed_comparison_operator)
808 (op8_ZN_operator): New predicates.
810 2024-08-29 Arsen Arsenović <arsen@aarsen.me>
813 * coroutine-passes.cc (execute_early_expand_coro_ifns): Don't
816 2024-08-29 Georg-Johann Lay <avr@gjlay.de>
818 * config.gcc (extra_objs) [target=avr]: Add avr-passes.o.
819 * config/avr/t-avr (avr-passes.o): New rule to make it.
820 * config/avr/avr.cc (#define INCLUDE_VECTOR): Remove.
821 (cfganal.h, cfgrtl.h, context.h, tree-pass.h, print-rtl.h): Don't
823 (avr_strict_signed_p, avr_strict_unsigned_p, avr_2comparisons_rhs)
824 (make_avr_pass_recompute_notes, make_avr_pass_casesi)
825 (make_avr_pass_ifelse, make_avr_pass_pre_proep, avr_split_tiny_move)
826 (emit_move_ccc, emit_move_ccc_after, reg_seen_between_p)
827 (avr_maybe_adjust_cfa, avr_redundant_compare_regs)
828 (avr_parallel_insn_from_insns, avr_is_casesi_sequence)
829 (avr_optimize_casesi, avr_redundant_compare, make_avr_pass_fuse_add)
830 (avr_optimize_2ifelse, avr_rest_of_handle_ifelse)
831 (avr_casei_sequence_check_operands)
833 (avr_pass_data_fuse_add, avr_pass_data_ifelse)
834 (avr_pass_data_casesi, avr_pass_data_recompute_notes)
835 (avr_pass_data_pre_proep): Move objects...
836 (avr_pass_fuse_add, avr_pass_pre_proep, avr_pass_recompute_notes)
837 (avr_pass_ifelse, avr_pass_casesi, AVR_LdSt_Props): Move classes...
838 * config/avr/avr-passes.cc: ... to this new C++ module.
839 (struct Ranges): Move to...
840 * config/avr/ranges.h: ...this new file.
841 * config/avr/avr-protos.h: Adjust comments.
843 2024-08-29 Robin Dapp <rdapp@ventanamicro.com>
846 * config/riscv/autovec.md (vec_extract<mode><v_half>): Add
847 vector-vector extract for VLS modes.
848 * config/riscv/riscv.cc (riscv_can_change_mode_class): Forbid
849 VLS modes larger than one vector.
850 * config/riscv/vector-iterators.md: Add vector-vector extract
853 2024-08-29 Roger Sayle <roger@nextmovesoftware.com>
855 * config/i386/i386-features.cc (timode_immed_const_gain): New
856 function to determine the gain/cost on a CONST_WIDE_INT.
857 (timode_scalar_chain::compute_convert_gain): Fix whitespace.
858 <case CONST_WIDE_INT>: Provide more accurate estimates using
859 timode_immed_const_gain.
860 <case AND>: Handle CONSTANT_SCALAR_INT_P (src).
862 2024-08-29 Mark Harmstone <mark@harmstone.com>
864 * dwarf2codeview.cc (enum cv_leaf_type): Add LF_MFUNC_ID.
865 (write_lf_mfunc_id): New function.
866 (add_lf_func_id): New function.
867 (add_lf_mfunc_id): New function.
868 (add_function): Call add_lf_func_id or add_lf_mfunc_id.
870 2024-08-29 Mark Harmstone <mark@harmstone.com>
872 * dwarf2codeview.cc (enum cv_leaf_type): Add LF_MFUNCTION,
873 LF_METHODLIST, LF_METHOD, and LF_ONEMETHOD.
874 (struct codeview_subtype): Add lf_onemethod and lf_method to union.
875 (struct lf_methodlist_entry): New type.
876 (struct codeview_custom_type): Add lf_mfunc_id, lf_mfunction, and
877 lf_methodlist to union.
878 (struct codeview_method): New type.
879 (struct method_hasher): New type.
880 (get_type_num_subroutine_type): Add forward declaration.
881 (write_lf_fieldlist): Handle LF_ONEMETHOD and LF_METHOD.
882 (write_lf_mfunction): New function.
883 (write_lf_methodlist): New function.
884 (write_custom_types): Handle LF_MFUNCTION and LF_METHODLIST.
885 (add_struct_function): New function.
886 (get_mfunction_type): New function.
887 (is_templated_func): New function.
888 (get_type_num_struct): Handle DW_TAG_subprogram child DIEs.
889 (get_type_num_subroutine_type): Add containing_class_type, this_type,
890 and this_adjustment params, and handle creating LF_MFUNCTION types as
891 well as LF_PROCEDURE.
892 (get_type_num): New params for get_type_num_subroutine_type.
893 (add_function): New params for get_type_num_subroutine_type.
894 * dwarf2codeview.h (CV_METHOD_VANILLA, CV_METHOD_VIRTUAL): Define.
895 (CV_METHOD_STATIC, CV_METHOD_FRIEND, CV_METHOD_INTRO): Likewise.
896 (CV_METHOD_PUREVIRT, CV_METHOD_PUREINTRO): Likewise.
898 2024-08-29 Mark Harmstone <mark@harmstone.com>
900 * dwarf2codeview.cc (enum cv_leaf_type): Add LF_STMEMBER.
901 (struct codeview_subtype): Add lf_static_member to union.
902 (write_lf_fieldlist): Handle LF_STMEMBER.
903 (add_struct_member): New function.
904 (add_struct_static_member): New function.
905 (get_accessibility): New function.
906 (get_type_num_struct): Split out into add_struct_member and
907 get_accessibility, and handle static members.
909 2024-08-29 Mark Harmstone <mark@harmstone.com>
911 * dwarf2codeview.cc (enum cf_leaf_type): Add LF_STRING_ID.
912 (struct codeview_custom_type): Add lf_string_id to union.
913 (struct string_id_hasher): New type.
914 (string_id_htab): New global variable.
915 (write_lf_string_id): New function.
916 (write_custom_types): Call write_lf_string_id.
917 (codeview_debug_finish): Free string_id_htab.
918 (add_string_id): New function.
919 (get_scope_string_id): New function.
920 (add_function): Call get_scope_string_id and set scope.
922 2024-08-29 Mark Harmstone <mark@harmstone.com>
924 * dwarf2codeview.cc (get_name): New function.
925 (add_enum_forward_def): Call get_name.
926 (get_type_num_enumeration_type): Call get_name.
927 (add_struct_forward_def): Call get_name.
928 (get_type_num_struct): Call get_name.
929 (add_variable): Call get_name.
930 (add function): Call get_name.
931 * dwarf2out.cc (get_die_parent): Rename to dw_get_die_parent and make
933 (generate_type_signature): Handle renamed get_die_parent.
934 * dwarf2out.h (dw_get_die_parent): Add declaration.
936 2024-08-28 Andrew Pinski <quic_apinski@quicinc.com>
938 * internal-fn.cc (expand_POPCOUNT): Dump the costs for
941 2024-08-28 Jonathan Wakely <jwakely@redhat.com>
943 * doc/contrib.texi (Contributors): Add Dhruv Matani.
945 2024-08-28 Georg-Johann Lay <avr@gjlay.de>
947 * config/avr/avr.cc (INCLUDE_VECTOR): Define it.
948 (cfganal.h): Include it.
949 (Ranges): New struct.
950 (avr_2comparisons_rhs, avr_redundant_compare_regs)
951 (avr_strict_signed_p, avr_strict_unsigned_p): New static functions.
952 (avr_redundant_compare): Overhaul: Allow more cases.
953 (avr_optimize_2ifelse): New static function, outsourced from...
954 (avr_rest_of_handle_ifelse): ...this method.
956 2024-08-28 Richard Sandiford <richard.sandiford@arm.com>
958 * config/aarch64/tuning_models/generic.h (generic_sve_vector_cost):
959 Set gather_load_x32_init_cost and gather_load_x64_init_cost to 0.
961 2024-08-28 Richard Sandiford <richard.sandiford@arm.com>
963 * config/aarch64/aarch64.cc (aarch64_detect_vector_stmt_subtype)
964 (aarch64_vector_costs::add_stmt_cost): Use the x64 cost rather
965 than x32 cost for all VNx2 modes.
967 2024-08-28 Richard Sandiford <richard.sandiford@arm.com>
969 * tree.h (ASM_INPUT_P): Fix documentation.
971 2024-08-28 Filip Kastl <fkastl@suse.cz>
973 PR tree-optimization/116355
974 * tree-switch-conversion.cc (can_log2): Add capability to
975 suggest converting the operand to a different type.
976 (gen_log2): Add capability to generate a conversion in case the
977 operand is of a type incompatible with the logarithm operation.
978 (can_pow2p): New function.
979 (gen_pow2p): Rewrite to use __builtin_popcount instead of
980 manually inserting an internal fn call or bitmagic. Also add
981 capability to generate a conversion.
982 (switch_conversion::is_exp_index_transform_viable): Call
983 can_pow2p. Store types suggested by can_log2 and gen_log2.
984 (switch_conversion::exp_index_transform): Params of gen_pow2p
985 and gen_log2 changed so update their calls.
986 * tree-switch-conversion.h: Add m_exp_index_transform_log2_type
987 and m_exp_index_transform_pow2p_type to switch_conversion class
988 to track type conversions needed to generate the "is power of 2"
989 and logarithm operations.
991 2024-08-28 Alex Coplan <alex.coplan@arm.com>
994 * doc/sourcebuild.texi: Document ltrans-rtl value of kind for
997 2024-08-28 Richard Biener <rguenther@suse.de>
999 * tree-vect-slp.cc (debug): Add overload for slp_instance.
1001 2024-08-28 Richard Biener <rguenther@suse.de>
1003 * tree-vect-slp.cc (vect_build_slp_store_interleaving):
1004 Fix reference counting.
1005 (vect_build_slp_instance): Release rhs_nodes.
1007 2024-08-28 Richard Biener <rguenther@suse.de>
1009 * tree-vect-slp.cc (vect_build_slp_store_interleaving): Split
1011 (vect_build_slp_instance): Here.
1013 2024-08-28 Pan Li <pan2.li@intel.com>
1015 * tree-vect-patterns.cc (vect_recog_sat_add_pattern): Add fold
1016 convert for const_int to the type of operand 0.
1018 2024-08-28 Kito Cheng <kito.cheng@sifive.com>
1020 * config/riscv/vector.md (mode_idx): Add vrol and vror.
1022 2024-08-28 Pan Li <pan2.li@intel.com>
1024 * match.pd: Add the matching for signed .SAT_ADD.
1025 * tree-ssa-math-opts.cc (gimple_signed_integer_sat_add): Add new
1027 (match_unsigned_saturation_add): Try signed .SAT_ADD and rename
1029 (match_saturation_add): ... here.
1030 (math_opts_dom_walker::after_dom_children): Update the above renamed
1033 2024-08-27 Andreas Schwab <schwab@linux-m68k.org>
1036 * config/m68k/m68k.cc (m68k_decompose_index): Accept ASHIFT like
1038 (m68k_rtx_costs) [PLUS]: Likewise.
1039 (m68k_legitimize_address): Likewise.
1041 2024-08-27 Patrick O'Neill <patrick@rivosinc.com>
1043 * config/riscv/riscv-v.cc (expand_vector_init_insert_elems): Relocate.
1044 (expand_vector_init_trailing_same_elem): Ditto.
1046 2024-08-27 Patrick O'Neill <patrick@rivosinc.com>
1048 * config/riscv/riscv-v.cc (expand_const_vector): Allow non-duplicate
1049 to fall through other patterns before asserting.
1051 2024-08-27 Patrick O'Neill <patrick@rivosinc.com>
1053 * config/riscv/riscv-v.h (valid_vec_immediate_p): Add new helper.
1054 * config/riscv/riscv-v.cc (valid_vec_immediate_p): Ditto.
1055 (expand_const_vector): Use new helper.
1056 * config/riscv/riscv.cc (riscv_const_insns): Handle 0.0 floating-point
1059 2024-08-27 Patrick O'Neill <patrick@rivosinc.com>
1061 * config/riscv/riscv-v.cc (class rvv_builder): Move to riscv-v.h.
1062 * config/riscv/riscv.cc (riscv_const_insns): Emit placeholder costs for
1063 bool/stepped const vectors.
1064 * config/riscv/riscv-v.h: New file.
1066 2024-08-27 Patrick O'Neill <patrick@rivosinc.com>
1068 * config/riscv/riscv-v.cc (expand_const_vector): Use tmp register if
1071 2024-08-27 Patrick O'Neill <patrick@rivosinc.com>
1073 * config/riscv/riscv.cc (riscv_const_insns): Relocate.
1075 2024-08-27 Patrick O'Neill <patrick@rivosinc.com>
1077 * config/riscv/riscv-v.cc (expand_const_vector): Fix STEP size in
1080 2024-08-27 Christophe Lyon <christophe.lyon@linaro.org>
1082 * config/arm/vfp.md (movdi_vfp, thumb2_movdf_vfp): Handle MVE
1085 2024-08-27 H.J. Lu <hjl.tools@gmail.com>
1087 * doc/sourcebuild.texi (check-function-bodies): Add an optional
1088 argument for matched output lines.
1090 2024-08-27 Michael Matz <matz@suse.de>
1093 * lra.cc (setup_sp_offset): Start with sp_offset from
1094 before the new sequence, not from after.
1096 2024-08-27 Michael Matz <matz@suse.de>
1099 * lra-eliminations.cc (init_elim_table): Use -1 as initializer.
1100 (update_reg_eliminate): Accept -1 as not-yet-used marker.
1101 (eliminate_regs_in_insn): Use previous_sp_offset only when
1104 2024-08-27 Michael Matz <matz@suse.de>
1107 * final.cc (walk_alter_subreg): Recurse on AHIFT.
1109 2024-08-27 Richard Sandiford <richard.sandiford@arm.com>
1111 PR middle-end/116413
1112 * rtl.h (address_info): Update commentary.
1113 * rtlanal.cc (valid_base_or_index_term_p): New function, split
1115 (get_base_term, get_index_term): ...here. Handle elimination PLUSes.
1117 2024-08-27 Richard Sandiford <richard.sandiford@arm.com>
1119 PR middle-end/116321
1120 * lra-constraints.cc (get_hard_regno): Only apply eliminations
1121 to existing hard registers.
1122 (get_reg_class): Likewise.
1124 2024-08-27 Richard Biener <rguenther@suse.de>
1126 PR tree-optimization/116460
1127 * tree-ssa-forwprop.cc (pass_forwprop::execute): First do
1128 simple_dce_from_worklist and then remove stmts in to_remove.
1129 Track defs to be removed in to_remove_defs.
1131 2024-08-27 Pan Li <pan2.li@intel.com>
1133 * config/riscv/riscv.cc (riscv_expand_ussub): Gen xmode for the
1134 second operand, aka y in parameter.
1135 * config/riscv/riscv.md (ussub<mode>3): Allow const_int for operand 2.
1137 2024-08-26 Hans-Peter Nilsson <hp@axis.com>
1139 PR middle-end/115883
1140 * combine.cc (make_more_copies): Copy attributes from the original
1141 pseudo to the new copy.
1143 2024-08-26 Arsen Arsenović <arsen@aarsen.me>
1145 * coroutine-passes.cc (execute_early_expand_coro_ifns): Emit a
1146 sorry if a statement is an alloca call.
1148 2024-08-26 David Malcolm <dmalcolm@redhat.com>
1150 * Makefile.in (OBJS-libcommon): Add diagnostic-format-text.o.
1151 * diagnostic-format-json.cc: Include "diagnostic-format.h".
1152 * diagnostic-format-sarif.cc: Likewise.
1153 * diagnostic-format-text.cc: New file, using material from
1155 * diagnostic-global-context.cc: Include
1156 "diagnostic-format.h".
1157 * diagnostic-format-text.h: New file, using material from
1159 * diagnostic-format.h: New file, using material from
1161 * diagnostic.cc: Include "diagnostic-format.h" and
1162 "diagnostic-format-text.h".
1163 (diagnostic_text_output_format::~diagnostic_text_output_format):
1164 Move to diagnostic-format-text.cc.
1165 (diagnostic_text_output_format::on_report_diagnostic): Likewise.
1166 (diagnostic_text_output_format::on_diagram): Likewise.
1167 (diagnostic_text_output_format::print_any_cwe): Likewise.
1168 (diagnostic_text_output_format::print_any_rules): Likewise.
1169 (diagnostic_text_output_format::print_option_information):
1171 * diagnostic.h (class diagnostic_output_format): Move to
1172 diagnostic-format.h.
1173 (class diagnostic_text_output_format): Move to
1174 diagnostic-format-text.h.
1175 (diagnostic_output_format_init): Move to
1176 diagnostic-format.h.
1177 (diagnostic_output_format_init_json_stderr): Likewise.
1178 (diagnostic_output_format_init_json_file): Likewise.
1179 (diagnostic_output_format_init_sarif_stderr): Likewise.
1180 (diagnostic_output_format_init_sarif_file): Likewise.
1181 (diagnostic_output_format_init_sarif_stream): Likewise.
1182 * gcc.cc: Include "diagnostic-format.h".
1183 * opts.cc: Include "diagnostic-format.h".
1185 2024-08-26 David Malcolm <dmalcolm@redhat.com>
1187 * diagnostic-format-json.cc
1188 (json_output_format::on_begin_diagnostic): Delete.
1189 (json_output_format::on_end_diagnostic): Rename to...
1190 (json_output_format::on_report_diagnostic): ...this and add call
1191 to pp_output_formatted_text.
1192 (diagnostic_output_format_init_json): Drop unnecessary calls
1193 to disable textual printing of CWEs, rules, and options.
1194 * diagnostic-format-sarif.cc (sarif_builder::end_diagnostic):
1196 (sarif_builder::on_report_diagnostic): ...this and add call to
1197 pp_output_formatted_text.
1198 (sarif_output_format::on_begin_diagnostic): Delete.
1199 (sarif_output_format::on_end_diagnostic): Rename to...
1200 (sarif_output_format::on_report_diagnostic): ...this and update
1201 call to m_builder accordingly.
1202 (diagnostic_output_format_init_sarif): Drop unnecessary calls
1203 to disable textual printing of CWEs, rules, and options.
1204 * diagnostic.cc (diagnostic_context::print_any_cwe): Convert to...
1205 (diagnostic_text_output_format::print_any_cwe): ...this.
1206 (diagnostic_context::print_any_rules): Convert to...
1207 (diagnostic_text_output_format::print_any_rules): ...this.
1208 (diagnostic_context::print_option_information): Convert to...
1209 (diagnostic_text_output_format::print_option_information):
1211 (diagnostic_context::report_diagnostic): Replace calls to the
1212 output format's on_begin_diagnostic, to pp_output_formatted_text,
1213 printing CWE, rules, option info, and the call to the format's
1214 on_end_diagnostic with a call to the format's
1215 on_report_diagnostic.
1216 (diagnostic_text_output_format::on_begin_diagnostic): Delete.
1217 (diagnostic_text_output_format::on_end_diagnostic): Delete.
1218 (diagnostic_text_output_format::on_report_diagnostic): New vfunc,
1219 which effectively does the on_begin_diagnostic, the call to
1220 pp_output_formatted_text, the calls for printing CWE, rules,
1221 option info, and the call to the diagnostic_finalizer.
1222 * diagnostic.h (diagnostic_output_format::on_begin_diagnostic):
1224 (diagnostic_output_format::on_end_diagnostic): Delete.
1225 (diagnostic_output_format::on_report_diagnostic): New.
1226 (diagnostic_text_output_format::on_begin_diagnostic): Delete.
1227 (diagnostic_text_output_format::on_end_diagnostic): Delete.
1228 (diagnostic_text_output_format::on_report_diagnostic): New.
1229 (class diagnostic_context): Add friend class
1230 diagnostic_text_output_format.
1231 (diagnostic_context::get_urlifier): New accessor.
1232 (diagnostic_context::print_any_cwe): Move decl...
1233 (diagnostic_text_output_format::print_any_cwe): ...to here.
1234 (diagnostic_context::print_any_rules): Move decl...
1235 (diagnostic_text_output_format::print_any_rules): ...to here.
1236 (diagnostic_context::print_option_information): Move decl...
1237 (diagnostic_text_output_format::print_option_information): ...to
1240 2024-08-26 David Malcolm <dmalcolm@redhat.com>
1242 * diagnostic-format-sarif.cc: Add comments noting that we don't
1243 yet capture any diagnostic_metadata::rules associated with a
1246 2024-08-26 David Malcolm <dmalcolm@redhat.com>
1248 * pretty-print.cc (selftest::test_urls): Make static.
1249 (selftest::test_urls_from_braces): New.
1250 (selftest::test_null_urls): Make static.
1251 (selftest::test_urlification): Likewise.
1252 (selftest::pretty_print_cc_tests): Call test_urls_from_braces.
1254 2024-08-26 David Malcolm <dmalcolm@redhat.com>
1256 * json.h: Fix typo in comment about missing INCLUDE_MEMORY.
1258 2024-08-26 Andi Kleen <ak@gcc.gnu.org>
1260 * tree-if-conv.cc: Remove unneeded include from last change.
1262 2024-08-26 Bernd Edlinger <bernd.edlinger@hotmail.de>
1265 * configure.ac: Add the "nop" instruction for cpu type ft32.
1266 * configure: Regenerate.
1267 * dwarf2out.cc (dwarf2out_set_ignored_loc): Use the correct
1270 2024-08-26 Richard Biener <rguenther@suse.de>
1272 PR tree-optimization/116460
1273 * tree-ssa-forwprop.cc (pass_forwprop::execute): Do not
1274 process blocks in unreachable natural loops.
1276 2024-08-26 Richard Biener <rguenther@suse.de>
1278 * tree-ssa-forwprop.cc (simplify_gimple_switch_label_vec):
1279 Delay removing edges and releasing dominator info, instead
1280 record into edges_to_remove vector.
1281 (simplify_gimple_switch): Pass through vector of to remove
1283 (pass_forwprop::execute): Likewise. Remove queued edges.
1285 2024-08-26 Xi Ruoyao <xry111@xry111.site>
1286 Richard Biener <rguenther@suse.de>
1288 PR tree-optimization/116348
1289 * tree-vect-stmts.cc (supportable_widening_operation): Use
1290 STMT_VINFO_REDUC_DEF (x) instead of
1291 STMT_VINFO_DEF_TYPE (x) == vect_reduction_def.
1293 2024-08-26 Pan Li <pan2.li@intel.com>
1295 * match.pd: Add int_fits_type_p check for .SAT_ADD imm operand.
1297 2024-08-26 Andrew Pinski <quic_apinski@quicinc.com>
1299 PR middle-end/116480
1300 * internal-fn.cc (expand_POPCOUNT): Use the correct mode
1303 2024-08-26 Haochen Jiang <haochen.jiang@intel.com>
1305 * config/i386/avx10_2-512convertintrin.h
1306 (_mm512_cvtpbf8_ph): New.
1307 (_mm512_mask_cvtpbf8_ph): Ditto.
1308 (_mm512_maskz_cvtpbf8_ph): Ditto.
1309 * config/i386/avx10_2convertintrin.h
1310 (_mm_cvtpbf8_ph): Ditto.
1311 (_mm_mask_cvtpbf8_ph): Ditto.
1312 (_mm_maskz_cvtpbf8_ph): Ditto.
1313 (_mm256_cvtpbf8_ph): Ditto.
1314 (_mm256_mask_cvtpbf8_ph): Ditto.
1315 (_mm256_maskz_cvtpbf8_ph): Ditto.
1317 2024-08-26 Zhang, Jun <jun.zhang@intel.com>
1318 Haochen Jiang <haochen.jiang@intel.com>
1319 Hongtao Liu <hongtao.liu@intel.com>
1321 * config/i386/i386-expand.cc
1322 (ix86_ssecom_setcc): Mention behavior change on flags.
1323 (ix86_expand_sse_comi): Handle AVX10.2 behavior.
1324 (ix86_expand_sse_comi_round): Ditto.
1325 (ix86_expand_round_builtin): Ditto.
1326 (ix86_expand_builtin): Change function call.
1327 * config/i386/i386.md (UNSPEC_COMX): New unspec.
1328 * config/i386/sse.md
1329 (avx10_2_v<unord>comx<ssemodesuffix><round_saeonly_name>): New.
1330 (<sse>_<unord>comi<round_saeonly_name>): Add HFmode.
1332 2024-08-26 Zhang, Jun <jun.zhang@intel.com>
1334 * config.gcc: Add avx10_2copyintrin.h.
1335 * config/i386/i386.md (avx10_2): New isa attribute.
1336 * config/i386/immintrin.h: Include avx10_2copyintrin.h.
1337 * config/i386/sse.md
1338 (sse_movss_<mode>): Add new constraints to handle AVX10.2.
1339 (vec_set<mode>_0): Ditto.
1340 (@vec_set<mode>_0): Ditto.
1341 (vec_set<mode>_0): Ditto.
1342 (avx512fp16_mov<mode>): Ditto.
1343 (*vec_set<mode>_0_1): New split.
1344 * config/i386/avx10_2copyintrin.h: New file.
1346 2024-08-26 Mo, Zewei <zewei.mo@intel.com>
1347 Hu, Lin1 <lin1.hu@intel.com>
1348 Haochen Jiang <haochen.jiang@intel.com>
1350 * config.gcc: Add avx10_2-512minmaxintrin.h and
1351 avx10_2minmaxintrin.h.
1352 * config/i386/i386-builtin-types.def:
1353 Add DEF_FUNCTION_TYPE (V8BF, V8BF, V8BF, INT, V8BF, UQI),
1354 (V16BF, V16BF, V16BF, INT, V16BF, UHI),
1355 (V32BF, V32BF, V32BF, INT, V32BF, USI),
1356 (V8HF, V8HF, V8HF, INT, V8HF, UQI),
1357 (V8DF, V8DF, V8DF, INT, V8DF, UQI, INT),
1358 (V32HF, V32HF, V32HF, INT, V32HF, USI, INT),
1359 (V16HF, V16HF, V16HF, INT, V16HF, UHI, INT),
1360 (V16SF, V16SF, V16SF, INT, V16SF, UHI, INT).
1361 * config/i386/i386-builtin.def (BDESC): Add new builtins.
1362 * config/i386/i386-expand.cc
1363 (ix86_expand_args_builtin): Handle V8BF_FTYPE_V8BF_V8BF_INT_V8BF_UQI,
1364 V16BF_FTYPE_V16BF_V16BF_INT_V16BF_UHI,
1365 V32BF_FTYPE_V32BF_V32BF_INT_V32BF_USI,
1366 V8HF_FTYPE_V8HF_V8HF_INT_V8HF_UQI,
1367 (ix86_expand_round_builtin): Handle V8DF_FTYPE_V8DF_V8DF_INT_V8DF_UQI_INT,
1368 V32HF_FTYPE_V32HF_V32HF_INT_V32HF_USI_INT,
1369 V16HF_FTYPE_V16HF_V16HF_INT_V16HF_UHI_INT.
1370 V16SF_FTYPE_V16SF_V16SF_INT_V16SF_UHI_INT.
1371 * config/i386/immintrin.h: Include avx10_2-512mixmaxintrin.h and
1372 avx10_2minmaxintrin.h.
1373 * config/i386/sse.md (VFH_AVX10_2): New.
1374 (avx10_2_vminmaxnepbf16_<mode><mask_name>): New define_insn.
1375 (avx10_2_minmaxp<mode><mask_name><round_saeonly_name>): Ditto.
1376 (avx10_2_minmaxs<mode><mask_scalar_name><round_saeonly_scalar_name>): Ditto.
1377 * config/i386/avx10_2-512minmaxintrin.h: New file.
1378 * config/i386/avx10_2minmaxintrin.h: Ditto.
1380 2024-08-26 Hu, Lin1 <lin1.hu@intel.com>
1382 * config/i386/avx10_2-512satcvtintrin.h: Add new intrin.
1383 * config/i386/avx10_2satcvtintrin.h: Ditto.
1384 * config/i386/i386-builtin.def (BDESC): Add new builtins.
1385 * config/i386/sse.md (VF1_VF2_AVX10_2): New iterator.
1386 (VF2_AVX10_2): Ditto.
1387 (VI8_AVX10_2): Ditto.
1388 (sat_cvt_sign_prefix): Add new UNSPEC.
1389 (UNSPEC_SAT_CVT_DS_SIGN_ITER): New iterator.
1390 (pd2dqssuff): Ditto.
1391 (avx10_2_vcvtt<castmode>2<sat_cvt_sign_prefix>dqs<mode><mask_name><round_saeonly_name>):
1393 (avx10_2_vcvttpd2<sat_cvt_sign_prefix>qqs<mode><mask_name><round_saeonly_name>):
1395 (avx10_2_vcvttps2<sat_cvt_sign_prefix>qqs<mode><mask_name><round_saeonly_name>):
1397 (avx10_2_vcvttsd2<sat_cvt_sign_prefix>sis<mode><round_saeonly_name>):
1399 (avx10_2_vcvttss2<sat_cvt_sign_prefix>sis<mode><round_saeonly_name>):
1402 2024-08-26 Hu, Lin1 <lin1.hu@intel.com>
1404 * config.gcc: Add avx10_2satcvtintrin.h and
1405 avx10_2-512satcvtintrin.h.
1406 * config/i386/i386-builtin-types.def:
1407 Add DEF_FUNCTION_TYPE (V8HI, V8BF, V8HI, UQI),
1408 (V16HI, V16BF, V16HI, UHI), (V32HI, V32BF, V32HI, USI),
1409 (V16SI, V16SF, V16SI, UHI, INT), (V16HI, V16BF, V16HI, UHI, INT),
1410 (V32HI, V32BF, V32HI, USI, INT).
1411 * config/i386/i386-builtin.def (BDESC): Add new builtins.
1412 * config/i386/i386-expand.cc (ix86_expand_args_builtin): Handle
1413 V32HI_FTYPE_V32BF_V32HI_USI, V16HI_FTYPE_V16BF_V16HI_UHI,
1414 V8HI_FTYPE_V8BF_V8HI_UQI.
1415 (ix86_expand_round_builtin): Handle V32HI_FTYPE_V32BF_V32HI_USI_INT,
1416 V16SI_FTYPE_V16SF_V16SI_UHI_INT, V16HI_FTYPE_V16BF_V16HI_UHI_INT.
1417 * config/i386/immintrin.h: Include avx10_2satcvtintrin.h and
1418 avx10_2-512savcvtintrin.h.
1419 * config/i386/sse.md:
1420 (UNSPEC_CVTNE_BF16_IBS_ITER): New iterator.
1421 (sat_cvt_sign_prefix): Ditto.
1422 (sat_cvt_trunc_prefix): Ditto.
1423 (UNSPEC_CVT_PH_IBS_ITER): Ditto.
1424 (UNSPEC_CVTT_PH_IBS_ITER): Ditto.
1425 (UNSPEC_CVT_PS_IBS_ITER): Ditto.
1426 (UNSPEC_CVTT_PS_IBS_ITER): Ditto.
1427 (avx10_2_cvt<sat_cvt_trunc_prefix>nebf162i<sat_cvt_sign_prefix>bs<mode><mask_name>):
1429 (avx10_2_cvtph2i<sat_cvt_sign_prefix>bs<mode><mask_name><round_name>):
1431 (avx10_2_cvttph2i<sat_cvt_sign_prefix>bs<mode><mask_name><round_saeonly_name>):
1433 (avx10_2_cvtps2i<sat_cvt_sign_prefix>bs<mode><mask_name><round_name>):
1435 (avx10_2_cvttps2i<sat_cvt_sign_prefix>bs<mode><mask_name><round_saeonly_name>):
1437 * config/i386/avx10_2-512satcvtintrin.h: New file.
1438 * config/i386/avx10_2satcvtintrin.h: Ditto.
1440 2024-08-26 konglin1 <lingling.kong@intel.com>
1441 Levy Hsu <admin@levyhsu.com>
1443 * config/i386/avx10_2-512bf16intrin.h: Add new intrinsics.
1444 * config/i386/avx10_2bf16intrin.h: Diito.
1445 * config/i386/i386-builtin-types.def : Add new DEF_FUNCTION_TYPE
1447 * config/i386/i386-builtin.def (BDESC): Add new buildin.
1448 * config/i386/i386-expand.cc (ix86_expand_args_builtin):
1450 * config/i386/sse.md (vecmemsuffix): Add vector BF mode.
1451 (avx10_2_rsqrtpbf16_<mode><mask_name>): New define_insn.
1452 (avx10_2_sqrtnepbf16_<mode><mask_name>): Ditto.
1453 (avx10_2_rcppbf16_<mode><mask_name>): Ditto.
1454 (avx10_2_getexppbf16_<mode><mask_name>): Ditto.
1455 (BF16IMMOP): New iterator.
1457 (avx10_2_<bf16immop>pbf16_<mode><mask_name>): New define_insn.
1458 (avx10_2_fpclasspbf16_<mode><mask_scalar_merge_name>): Ditto.
1459 (avx10_2_cmppbf16_<mode><mask_scalar_merge_name>): Ditto.
1460 (avx10_2_comsbf16_v8bf): Ditto.
1462 2024-08-26 konglin1 <lingling.kong@intel.com>
1463 Levy Hsu <admin@levyhsu.com>
1465 * config.gcc: Add avx10_2-512bf16intrin.h and avx10_2bf16intrin.h.
1466 * config/i386/i386-builtin-types.def : Add new
1467 DEF_FUNCTION_TYPE for V32BF_FTYPE_V32BF_V32BF,
1468 V16BF_FTYPE_V16BF_V16BF, V8BF_FTYPE_V8BF_V8BF,
1469 V8BF_FTYPE_V8BF_V8BF_UQI, V16BF_FTYPE_V16BF_V16BF_UHI,
1470 V32BF_FTYPE_V32BF_V32BF_USI, V32BF_FTYPE_V32BF_V32BF_V32BF_USI,
1471 V8BF_FTYPE_V8BF_V8BF_V8BF_UQI and V16BF_FTYPE_V16BF_V16BF_V16BF_UHI.
1472 * config/i386/i386-builtin.def (BDESC): Add new builtins.
1473 * config/i386/i386-expand.cc (ix86_expand_args_builtin):
1474 Handle new DEF_FUNCTION_TYPE.
1475 * config/i386/immintrin.h: Include avx10_2-512bf16intrin.h and
1476 avx10_2bf16intrin.h.
1477 * config/i386/sse.md
1478 (VBF_AVX10_2): New iterator.
1479 (avx10_2_scalefpbf16_<mode><mask_name>): New define_insn.
1480 (avx10_2_<code>nepbf16_<mode><mask_name>): Ditto.
1481 (avx10_2_<insn>nepbf16_<mode><mask_name>): Ditto.
1482 (avx10_2_fmaddnepbf16_<mode>_maskz): New expander.
1483 (avx10_2_fnmaddnepbf16_<mode>_maskz): Ditto.
1484 (avx10_2_fmsubnepbf16_<mode>_maskz): Ditto.
1485 (avx10_2_fnmsubnepbf16_<mode>_maskz): Ditto.
1486 (avx10_2_fmaddnepbf16_<mode><sd_maskz_name>): New define_insn.
1487 (avx10_2_fmaddnepbf16_<mode>_mask): Ditto.
1488 (avx10_2_fmaddnepbf16_<mode>_mask3): Ditto.
1489 (avx10_2_fnmaddnepbf16_<mode><sd_maskz_name>): Ditto.
1490 (avx10_2_fnmaddnepbf16_<mode>_mask): Ditto.
1491 (avx10_2_fnmaddnepbf16_<mode>_mask3): Ditto.
1492 (avx10_2_fmsubnepbf16_<mode><sd_maskz_name>): Ditto.
1493 (avx10_2_fmsubnepbf16_<mode>_mask): Ditto.
1494 (avx10_2_fmsubnepbf16_<mode>_mask3): Ditto.
1495 (avx10_2_fnmsubnepbf16_<mode><sd_maskz_name>): Ditto.
1496 (avx10_2_fnmsubnepbf16_<mode>_mask): Ditto.
1497 (avx10_2_fnmsubnepbf16_<mode>_mask3): Ditto.
1498 * config/i386/avx10_2-512bf16intrin.h: New file.
1499 * config/i386/avx10_2bf16intrin.h: Ditto.
1501 2024-08-26 Levy Hsu <admin@levyhsu.com>
1502 Kong Lingling <lingling.kong@intel.com>
1504 * config.gcc: Add avx10_2-512convertintrin.h and
1505 avx10_2convertintrin.h.
1506 * config/i386/i386-builtin-types.def: Add new DEF_POINTER_TYPE
1507 and DEF_FUNCTION_TYPE.
1508 * config/i386/i386-builtin.def (BDESC): Add new builtins.
1509 * config/i386/i386-expand.cc (ix86_expand_args_builtin):
1511 (ix86_expand_round_builtin): Ditto.
1512 * config/i386/immintrin.h: Include avx10_2-512convertintrin.h,
1513 avx10_2convertintrin.h.
1514 * config/i386/sse.md (VHF_AVX10_2): New iterator.
1515 (bf16_ph): Add 512 bit mode.
1516 (avx10_2_cvt2ps2phx_<mode><mask_name<round_name>): New define_insn.
1517 (ssebvecmode): New iterator.
1518 (UNSPEC_NECONVERTFP8_PACK): Ditto.
1519 (neconvertfp8_pack): Ditto.
1520 (vcvt<neconvertfp8_pack><mode><mask_name>): New define_insn.
1521 (ssebvecmode_2): New iterator.
1522 (UNSPEC_VCVTBIASPH2FP8_PACK): Ditto.
1523 (biasph2fp8_pack): Ditto.
1524 (vcvt<biasph2fp8_pack>v8hf): New expander.
1525 (vcvt<biasph2fp8_pack>v8hf_mask): Ditto.
1526 (*vcvt<biasph2bf8_pack>v8hf): New define_insn.
1527 (*vcvt<biasph2fp8_pack>v8hf_mask): Ditto.
1528 (VHF_AVX10_2_2): New iterator.
1529 (vcvt<biasph2fp8_pack><mode><mask_name>): New define_insn.
1530 (VHF_256_512): New iterator.
1531 (ph2fp8suff): Ditto.
1532 (UNSPEC_NECONVERTPH2FP8_PACK): Ditto.
1533 (neconvertph2fp8): Ditto.
1534 (vcvt<neconvertph2fp8>v8hf_mask): New expander.
1535 (*vcvt<neconvertph2fp8>v8hf): New define_insn.
1536 (*vcvt<neconvertph2fp8>v8hf_mask): Ditto.
1537 (vcvt<neconvertph2fp8><mode><mask_name>): Ditto.
1538 (vcvthf82ph<mode><mask_name>): Ditto.
1539 * config/i386/avx10_2-512convertintrin.h: New file.
1540 * config/i386/avx10_2convertintrin.h: Ditto.
1542 2024-08-26 Haochen Jiang <haochen.jiang@intel.com>
1543 Hongyu Wang <hongyu.wang@intel.com>
1545 * config/i386/avx10_2-512mediaintrin.h: Add new intrins.
1546 * config/i386/avx10_2mediaintrin.h: Ditto.
1547 * config/i386/i386-builtin.def: Add new builtins.
1548 * config/i386/i386-builtins.cc (def_builtin): Handle shared
1549 builtins between AVXVNNIINT16 and AVX10.2.
1550 * config/i386/i386-expand.cc (ix86_check_builtin_isa_match):
1552 * config/i386/sse.md (unspec): Add UNSPEC_VDPPHPS.
1553 (avx10_2_mpsadbw<mask_name>): New define_insn.
1554 (<mask_codefor><sse4_1_avx2>_mpsadbw<mask_name>): Ditto.
1555 (vpdp<vpdpwprodtype>_<mode>): Add AVX10_2_256.
1556 (vpdp<vpdpwprodtype>_v16si): New defin_insn.
1557 (vpdp<vpdpwprodtype>_<mode>_mask): Ditto.
1558 (*vpdp<vpdpwprodtype>_<mode>_maskz): Ditto.
1559 (vpdp<vpdpwprodtype>_<mode>_maskz): New expander.
1560 (vdpphps_<mode>): New define_insn.
1561 (vdpphps_<mode>_mask): Ditto.
1562 (*vdpphps_<mode>_maskz): Ditto.
1563 (vdpphps_<mode>_maskz): New expander.
1565 2024-08-26 Hongyu Wang <hongyu.wang@intel.com>
1566 Haochen Jiang <haochen.jiang@intel.com>
1568 * config.gcc: Add avx10_2mediaintrin.h and
1569 avx10_2-512mediaintrin.h.
1570 * config/i386/i386-builtin.def: Add new builtins.
1571 * config/i386/i386-builtins.cc (def_builtin): Handle shared
1572 builtins between AVXVNNIINT8 and AVX10.2.
1573 * config/i386/i386-expand.cc (ix86_check_builtin_isa_match):
1575 * config/i386/immintrin.h: Include avx10_2mediaintrin.h and
1576 avx10_2-512mediaintrin.h
1577 * config/i386/sse.md: (VI4_AVX10_2): New.
1578 (vpdp<vpdotprodtype>_<mode>): Add AVX10_2_256.
1579 (vpdp<vpdotprodtype>_v16si): New define_insn.
1580 (vpdp<vpdotprodtype>_<mode>_mask): Ditto.
1581 (*vpdp<vpdotprodtype>_<mode>_maskz): Ditto.
1582 (vpdp<vpdotprodtype>_<mode>_maskz): New expander.
1583 * config/i386/avx10_2-512mediaintrin.h: New file.
1584 * config/i386/avx10_2mediaintrin.h: Ditto.
1586 2024-08-26 Pan Li <pan2.li@intel.com>
1588 * config/riscv/riscv.cc (riscv_gen_unsigned_xmode_reg): Add new
1589 func impl to gen xmode rtx reg from operand rtx.
1590 (riscv_expand_ussub): Gen xmode reg for operand 1.
1591 * config/riscv/riscv.md: Allow const_int for operand 1.
1593 2024-08-25 demin.han <demin.han@starfivetech.com>
1595 * config/riscv/vector.md: Add !FLOAT_MODE_P constraint.
1597 2024-08-25 Xianmiao Qu <cooper.qu@linux.alibaba.com>
1599 * lower-subreg.cc (resolve_simple_move): Re-add calling emit_clobber
1600 immediately before moving a multi-word register by parts.
1602 2024-08-25 Andi Kleen <ak@gcc.gnu.org>
1604 PR tree-optimization/115866
1605 * tree-if-conv.cc (if_convertible_switch_p): New function.
1606 (if_convertible_stmt_p): Check for switch.
1607 (get_loop_body_in_if_conv_order): Handle switch.
1608 (predicate_bbs): Likewise.
1609 (predicate_statements): Likewise.
1610 (remove_conditions_and_labels): Likewise.
1611 (ifcvt_split_critical_edges): Likewise.
1612 (ifcvt_local_dce): Likewise.
1614 2024-08-25 Mark Harmstone <mark@harmstone.com>
1616 * dwarf2codeview.cc (write_optimized_static_local_vars): New function.
1617 (write_function): Call write_optimized_static_local_vars.
1619 2024-08-25 Mark Harmstone <mark@harmstone.com>
1621 * dwarf2codeview.cc (enum cv_sym_type): Add S_FRAMEPROC.
1622 (write_s_frameproc): New function.
1623 (write_function): Call write_s_frameproc.
1625 2024-08-25 Mark Harmstone <mark@harmstone.com>
1627 * dwarf2codeview.cc (enum cv_sym_type): Add S_DEFRANGE_REGISTER_REL.
1628 (write_defrange_register_rel): New function.
1629 (write_optimized_local_variable_loc): Add fbloc param, and call
1630 write_defrange_register_rel.
1631 (write_optimized_local_variable): Add fbloc param.
1632 (write_optimized_function_vars): Add fbloc param.
1634 2024-08-25 Mark Harmstone <mark@harmstone.com>
1636 * dwarf2codeview.cc (enum cv_sym_type): Add S_LOCAL and
1637 S_DEFRANGE_REGISTER.
1638 (write_s_local): New function.
1639 (write_defrange_register): New function.
1640 (write_optimized_local_variable_loc): New function.
1641 (write_optimized_local_variable): New function.
1642 (write_optimized_function_vars): New function.
1643 (write_function): Call write_optimized_function_vars if variable
1645 * dwarf2out.cc (typedef var_loc_view): Move to dwarf2out.h.
1646 (struct dw_loc_list_struct): Likewise.
1647 * dwarf2out.h (typedef var_loc_view): Move from dwarf2out.h.
1648 (struct dw_loc_list_struct): Likewise.
1649 * opts.cc (finish_options): Enable variable tracking for CodeView.
1651 2024-08-25 Roger Sayle <roger@nextmovesoftware.com>
1652 Uros Bizjak <ubizjak@gmail.com>
1654 * config/i386/i386-features.cc (compute_convert_gain)
1655 <case ASHIFTRT>: Update to match ix86_expand_v1ti_ashiftrt.
1657 2024-08-23 Patrick O'Neill <patrick@rivosinc.com>
1659 * config/riscv/riscv-v.cc (rvv_builder::can_duplicate_repeating_sequence_p):
1660 Use encoded_nelts when calling repeating_sequence_p.
1661 (rvv_builder::is_repeating_sequence): Ditto.
1662 (rvv_builder::repeating_sequence_use_merge_profitable_p): Ditto.
1664 2024-08-23 Manolis Tsamis <manolis.tsamis@vrull.eu>
1666 PR rtl-optimization/116372
1667 PR rtl-optimization/116405
1668 * ifcvt.cc (noce_convert_multiple_sets): Iterate backwards and track
1671 2024-08-23 Manolis Tsamis <manolis.tsamis@vrull.eu>
1673 PR middle-end/116358
1674 * ifcvt.cc (noce_convert_multiple_sets): Disallow call insns.
1676 2024-08-23 Peter Bergner <bergner@linux.ibm.com>
1679 * config/rs6000/rs6000.h (TI_OR_PTI_MODE): New define.
1680 * config/rs6000/rs6000-p8swap.cc (rs6000_analyze_swaps): Use it to
1681 handle PTImode identically to TImode.
1683 2024-08-23 Richard Biener <rguenther@suse.de>
1685 PR tree-optimization/116463
1686 * tree-complex.cc: Include tree-ssa-dce.h.
1687 (dce_worklist): New global.
1688 (update_complex_assignment): Add SSA def to the DCE worklist.
1689 (tree_lower_complex): Perform DCE.
1691 2024-08-23 Pan Li <pan2.li@intel.com>
1693 * match.pd: Add form 4 for unsigned .SAT_TRUNC matching.
1695 2024-08-23 Robin Dapp <rdapp@ventanamicro.com>
1697 PR middle-end/115495
1698 * cfgexpand.cc (expand_debug_expr): Require mode.
1699 * combine.cc (make_extraction): Ditto.
1700 * config/aarch64/aarch64.cc (aarch64_expand_cpymem): Ditto.
1701 (aarch64_expand_setmem): Ditto.
1702 * config/arc/arc.cc (arc_expand_cpymem): Ditto.
1703 * config/arm/arm.cc (arm_expand_divmod_libfunc): Ditto.
1704 * config/i386/i386.cc (ix86_get_mask_mode): Ditto.
1705 * config/rs6000/predicates.md: Ditto.
1706 * config/rs6000/rs6000.cc (vspltis_constant): Ditto.
1707 * config/s390/s390.cc (s390_expand_insv): Ditto.
1708 * config/sparc/sparc.cc (assign_int_registers): Ditto.
1709 * coverage.cc (get_gcov_type): Ditto.
1710 (get_gcov_unsigned_t): Ditto.
1711 * dse.cc (find_shift_sequence): Ditto.
1712 * expmed.cc (store_integral_bit_field): Ditto.
1713 * expr.cc (convert_mode_scalar): Ditto.
1714 (op_by_pieces_d::smallest_fixed_size_mode_for_size): Ditto.
1715 (emit_block_move_via_oriented_loop): Ditto.
1716 (copy_blkmode_to_reg): Ditto.
1717 (store_field): Ditto.
1718 * internal-fn.cc (expand_arith_overflow): Ditto.
1719 * machmode.h (HAVE_MACHINE_MODES): Ditto.
1720 (smallest_mode_for_size): Use opt_machine_mode.
1721 (smallest_int_mode_for_size): Use opt_scalar_int_mode.
1722 * optabs-query.cc (get_best_extraction_insn): Require mode.
1723 * optabs.cc (expand_twoval_binop_libfunc): Ditto.
1724 * stor-layout.cc (smallest_mode_for_size): Return
1726 (layout_type): Require mode.
1727 (initialize_sizetypes): Ditto.
1728 * tree-ssa-loop-manip.cc (canonicalize_loop_ivs): Ditto.
1730 2024-08-23 Robin Dapp <rdapp@ventanamicro.com>
1732 * config/riscv/autovec.md (abs<mode>2): Expand via max (a, -a).
1734 2024-08-23 Gerald Pfeifer <gerald@pfeifer.com>
1736 * doc/gm2.texi (License): Specifically link to GPL v3.0
1738 2024-08-22 Jeff Law <jlaw@ventanamicro.com>
1740 PR rtl-optimization/116420
1741 * ext-dce.cc (ext_dce_init): Fix loop iteration when setting up the
1742 interesting block for DF to analyze.
1744 2024-08-22 Prathamesh Kulkarni <prathameshk@nvidia.com>
1746 * lto-streamer-in.cc: (lto_read_tree_1): Set DECL_MODE (expr) to
1747 TREE_TYPE (TYPE_MODE (expr)) if TREE_TYPE (expr) is aggregate type and
1748 offloading is enabled.
1749 * stor-layout.cc (layout_type): Move computation of mode for
1751 (compute_array_mode): ... to here.
1752 * stor-layout.h (compute_array_mode): Declare.
1753 * tree-streamer-in.cc: Include stor-layout.h.
1754 (unpack_ts_common_value_fields): Call compute_array_mode if offloading
1756 * tree-streamer-out.cc (pack_ts_fixed_cst_value_fields): Stream out
1757 VOIDmode if decl has aggregate type and offloading is enabled.
1758 (pack_ts_type_common_value_fields): Stream out VOIDmode for aggregate
1759 type if offloading is enabled.
1761 2024-08-22 Raphael Moreira Zinsly <rzinsly@ventanamicro.com>
1763 * config/riscv/riscv.cc (riscv_v_adjust_scalable_frame): Add
1764 epilogue code for stack-clash and fix prologue cfi note.
1766 2024-08-22 Andrew Pinski <quic_apinski@quicinc.com>
1767 Richard Biener <rguenther@suse.de>
1769 PR middle-end/116454
1770 * fold-const.cc (fold_binary_loc): Fix `a * +-1i`
1771 by wrapping arg0 with save_expr when it is not COMPLEX_EXPR.
1773 2024-08-22 Jennifer Schmitz <jschmitz@nvidia.com>
1776 * config/aarch64/aarch64-opts.h
1777 (enum aarch64_autovec_preference_enum): New enum.
1778 * config/aarch64/aarch64.cc (aarch64_cmp_autovec_modes):
1779 Change numerical to enum values.
1780 (aarch64_autovectorize_vector_modes): Change numerical to enum
1782 (aarch64_vector_costs::record_potential_advsimd_unrolling):
1783 Change numerical to enum values.
1784 * config/aarch64/aarch64.opt: Change param type to enum.
1785 * doc/invoke.texi: Update documentation.
1787 2024-08-22 Bernd Edlinger <bernd.edlinger@hotmail.de>
1789 * dwarf2out.cc (dwarf2out_maybe_output_loclist_view_pair,
1790 output_loc_list): Correct handling of -gno-as-loc-support,
1791 use ZERO_VIEW_P to output view number as zero value.
1792 * toplev.cc (process_options): Do not automatically disable
1793 -gvariable-location-views when -gno-as-loc-support or
1794 -gno-as-locview-support is used, instead do automatically
1795 disable -gas-locview-support if -gno-as-loc-support is used.
1797 2024-08-22 Bernd Edlinger <bernd.edlinger@hotmail.de>
1800 * dwarf2out.cc (gen_inlined_subroutine_die): Handle the case
1801 of multiple subranges correctly.
1803 2024-08-22 Jennifer Schmitz <jschmitz@nvidia.com>
1805 PR tree-optimization/101390
1806 * tree-vect-patterns.cc (vect_recog_mod_var_pattern): Add new pattern.
1808 2024-08-22 Alexandre Oliva <oliva@adacore.com>
1810 * toplev.cc (dump_final_alias_vcg): New.
1811 (dump_final_node_vcg): Dump aliases along with node.
1813 2024-08-22 liuhongt <hongtao.liu@intel.com>
1815 * config/i386/i386-options.cc (ix86_option_override_internal):
1816 set ix86_{move_max,store_max} to PVW_AVX256 when TARGET_AVX
1817 instead of PVW_AVX128.
1819 2024-08-21 Jeff Law <jlaw@ventanamicro.com>
1821 PR rtl-optimization/116437
1822 * ext-dce.cc (ext_dce_try_optimize_insn): Handle SUBREG and
1823 ZERO_EXTRACT destinations.
1825 2024-08-21 Richard Sandiford <richard.sandiford@arm.com>
1828 * config/aarch64/aarch64.cc (aarch64_hard_regno_caller_save_mode):
1829 Only return SImode if we can convert to and from it.
1831 2024-08-21 Andrew Pinski <quic_apinski@quicinc.com>
1834 * config/aarch64/aarch64.md (popcountti2): New define_expand.
1836 2024-08-21 Richard Biener <rguenther@suse.de>
1838 PR tree-optimization/116406
1839 * tree-ssa-sccvn.cc (vn_reference_eq): Never equate
1840 float and int when the float mode cannot transfer bits.
1841 Do not try to anticipate which is the mode we actually load
1844 2024-08-21 Martin Jambor <mjambor@suse.cz>
1847 * tree-sra.cc (types_risk_mangled_binary_repr_p): New function.
1848 (sort_and_splice_var_accesses): Use it.
1849 (propagate_subaccesses_from_rhs): Likewise.
1851 2024-08-21 Richard Biener <rguenther@suse.de>
1853 PR tree-optimization/116380
1854 * tree-loop-distribution.cc (copy_loop_before): Handle
1855 out-of-loop defs appropriately.
1857 2024-08-21 Kewen Lin <linkw@linux.ibm.com>
1859 * config/rs6000/vsx.md (define_insn *vsx_le_perm_store_{<VSX_D:mode>,
1860 <VSX_W:mode>,v8hi,v16qi,<VSX_LE_128:mode>}): Remove constraint modifier
1863 2024-08-21 Kewen Lin <linkw@linux.ibm.com>
1865 * config/rs6000/vsx.md (*vsx_le_perm_store_{<VSX_D:mode>,<VSX_W:mode>,
1866 v8hi,v16qi,<VSX_LE_128:mode>} !reload_completed splitters): Assert
1867 can_create_pseudo_p and always generate one new pseudo for operand 1.
1869 2024-08-21 liuhongt <hongtao.liu@intel.com>
1871 * config/i386/sse.md (mov<mode>): Align predicates for
1872 operands[1] between mov<mode> and *mov<mode>_internal.
1873 * config/i386/mmx.md (mov<mode>): Ditto.
1875 2024-08-21 Andrew Pinski <quic_apinski@quicinc.com>
1877 * builtins.cc (fold_builtin_bit_query): Don't expand double
1878 `unsigned long long` typess if there is an optab entry for that
1881 2024-08-21 Andrew Pinski <quic_apinski@quicinc.com>
1884 * asan.cc (asan_instrument): Call initialize_sanitizer_builtins
1886 (hwasan_finish_file): Likewise.
1888 2024-08-20 Andrew Pinski <quic_apinski@quicinc.com>
1890 PR tree-optimization/116412
1891 * gimple-match-exports.cc (gimple_extract): Return false if op0
1892 was not a SSA name nor a min invariant for REALPART_EXPR/IMAGPART_EXPR/VCE
1895 2024-08-20 Andrew Pinski <quic_apinski@quicinc.com>
1897 PR tree-optimization/116409
1898 * tree-ssa-phiopt.cc (factor_out_conditional_operation): Move
1899 maybe_push_res_to_seq before creating the phi node and the debug dump.
1900 Return false if maybe_push_res_to_seq fails.
1902 2024-08-20 Gerald Pfeifer <gerald@pfeifer.com>
1904 * doc/install.texi (Specific) <c6x-*-*>: Normalize reference to
1907 2024-08-20 Andrew Pinski <quic_apinski@quicinc.com>
1909 PR tree-optimization/103660
1910 * match.pd (`(a ? b : 0) | (a ? 0 : c)`): New pattern.
1912 2024-08-20 Andrew Pinski <quic_apinski@quicinc.com>
1914 PR tree-optimization/103660
1915 * match.pd (`((a CMP b) ? c : 0) | ((a CMP' b) ? d : 0)`): Extend to support
1918 2024-08-20 Richard Biener <rguenther@suse.de>
1920 PR tree-optimization/116274
1921 * tree-vect-slp.cc (vect_bb_slp_scalar_cost): Cost scalar loads
1922 and stores as simple scalar stmts when they access a non-global,
1923 not address-taken variable that doesn't have BLKmode assigned.
1925 2024-08-20 Prathamesh Kulkarni <prathameshk@nvidia.com>
1927 * optc-save-gen.awk: New array var_target_opt. Use it to generate
1928 if (!lto_stream_offload_p) check in cl_optimization_stream_out,
1929 and generate a diagnostic with #error if accelerator backend uses
1930 Optimization for target-specifc options in cl_optimization_stream_in.
1932 2024-08-19 Andreas Schwab <schwab@linux-m68k.org>
1935 * config/m68k/m68k.opt (mlra): New target option.
1936 * config/m68k/m68k.cc (m68k_use_lra_p): New function.
1937 (TARGET_LRA_P): Use it.
1938 * config/m68k/m68k.opt.urls: Regenerate.
1940 2024-08-19 Andrew Carlotti <andrew.carlotti@arm.com>
1943 * config/aarch64/aarch64-builtins.cc (handle_arm_acle_h): Remove
1944 feature check at initialisation.
1945 (aarch64_general_check_builtin_call): Check ls64 intrinsics.
1946 * config/aarch64/arm_acle.h: (data512_t) Make always available.
1948 2024-08-19 Andrew Carlotti <andrew.carlotti@arm.com>
1951 * config/aarch64/aarch64-builtins.cc (aarch64_init_memtag_builtins):
1952 Define intrinsic names directly.
1953 (aarch64_general_init_builtins): Move memtag intialisation...
1954 (handle_arm_acle_h): ...to here, and remove feature check.
1955 (aarch64_general_check_builtin_call): Check memtag intrinsics.
1956 * config/aarch64/arm_acle.h (__arm_mte_create_random_tag)
1957 (__arm_mte_exclude_tag, __arm_mte_ptrdiff)
1958 (__arm_mte_increment_tag, __arm_mte_set_tag, __arm_mte_get_tag):
1961 2024-08-19 Andrew Carlotti <andrew.carlotti@arm.com>
1964 * config/aarch64/aarch64-builtins.cc (aarch64_init_tme_builtins):
1965 Define intrinsic names directly.
1966 (aarch64_general_init_builtins): Move tme initialisation...
1967 (handle_arm_acle_h): ...to here, and remove feature check.
1968 (aarch64_general_check_builtin_call): Check tme intrinsics.
1969 * config/aarch64/arm_acle.h (__tstart, __tcommit, __tcancel)
1971 (_TMFAILURE_*): Define unconditionally.
1973 2024-08-19 Andrew Carlotti <andrew.carlotti@arm.com>
1975 * config/aarch64/aarch64-sve-builtins.cc (check_builtin_call)
1976 (expand_builtin): Update calls to the below.
1977 (report_missing_extension, report_missing_registers)
1978 (check_required_extensions): Move out of aarch64_sve namespace,
1979 rename, and move into...
1980 * config/aarch64/aarch64-builtins.cc (aarch64_report_missing_extension)
1981 (aarch64_report_missing_registers)
1982 (aarch64_check_required_extensions) ...here.
1983 * config/aarch64/aarch64-protos.h (aarch64_check_required_extensions):
1986 2024-08-19 Andrew Carlotti <andrew.carlotti@arm.com>
1988 * config/aarch64/aarch64-sve-builtins.cc
1989 (check_required_registers): Remove target check and rename to...
1990 (report_missing_registers): ...this.
1991 (check_required_extensions): Refactor.
1993 2024-08-19 Kyrylo Tkachov <ktkachov@nvidia.com>
1995 * config/aarch64/tuning_models/neoversev2.h (fp_reassoc_width):
1997 (tune_flags): Add AARCH64_EXTRA_TUNE_FULLY_PIPELINED_FMA.
1999 2024-08-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
2001 * read-rtl.cc (rtx_reader::rtx_alloc_for_name): Allow all attribute
2002 types to produce code 'values'.
2003 (check_code_attribute): Rename ...
2004 (check_attribute_codes): ... to this. And change comments to refer to
2005 * doc/md.texi: Add paragraph to document that you can use int and mode
2006 attributes to produce codes.
2008 2024-08-19 Haochen Gui <guihaoc@gcc.gnu.org>
2010 * config/aarch64/aarch64-simd.md (mov<mode> for VSTRUCT_QD):
2011 Expand 16-byte vector mode const0 store by TImode.
2013 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2015 * config/i386/avx10_2roundingintrin.h: New intrins.
2016 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2018 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2020 * config/i386/avx10_2roundingintrin.h: New intrins.
2021 * config/i386/i386-builtin.def: Add new builtins.
2022 * config/i386/sse.md:
2023 (<avx512>_scalef<mode><mask_name><round_name>): Add condition check.
2025 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2027 * config/i386/avx10_2roundingintrin.h: New intrins.
2028 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2029 * config/i386/sse.md:
2030 (<mask_codefor>reducep<mode><mask_name><round_saeonly_name>):
2031 Add condition check.
2032 (<avx512>_rndscale<mode><mask_name><round_saeonly_name>): Ditto.
2034 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2036 * config/i386/avx10_2roundingintrin.h: New intrins.
2037 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2038 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2039 * config/i386/i386-expand.cc (ix86_expand_round_builtin):
2040 Handle V8SF_FTYPE_V8SF_V8SF_INT_V8SF_UQI_INT,
2041 V4DF_FTYPE_V4DF_V4DF_INT_V4DF_UQI_INT.
2043 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2045 * config/i386/avx10_2roundingintrin.h: New intrins.
2046 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2048 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2050 * config/i386/avx10_2roundingintrin.h: New intrins.
2051 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2052 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2053 * config/i386/i386-expand.cc (ix86_expand_round_builtin): Handle
2054 V8SF_FTYPE_V8SF_V8SF_UQI_INT, V4DF_FTYPE_V4DF_V4DF_UQI_INT,
2055 V16HF_FTYPE_V16HF_V16HF_UHI_INT, V16HF_FTYPE_V16HF_INT_V16HF_UHI_INT,
2056 V4DF_FTYPE_V4DF_INT_V4DF_UQI_INT, V8SF_FTYPE_V8SF_INT_V8SF_UQI_INT.
2057 * config/i386/sse.md:
2058 (<avx512>_getexp<mode><mask_name><round_saeonly_name>):
2059 Add condition check.
2060 (<avx512>_getmant<mode><mask_name><round_saeonly_name>):
2063 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2065 * config/i386/avx10_2roundingintrin.h: New intrins.
2066 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2067 * config/i386/sse.md:
2068 (<avx512>_fnmsub_<mode>_mask3<round_name>): Add condition check.
2070 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2072 * config/i386/avx10_2roundingintrin.h: New intrins.
2073 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2075 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2077 * config/i386/avx10_2roundingintrin.h: New intrins.
2078 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2079 * config/i386/sse.md:
2080 (<avx512>_fmsub_<mode>_mask<round_name>): Add condition check.
2082 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2084 * config/i386/avx10_2roundingintrin.h: New intrins.
2085 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2086 * config/i386/sse.md:
2087 (<avx512>_fmaddsub_<mode>_mask<round_name>): Add condition check.
2088 (<avx512>_fmaddsub_<mode>_mask3<round_name>): Ditto.
2090 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2092 * config/i386/avx10_2roundingintrin.h: New intrins.
2093 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2094 * config/i386/sse.md:
2095 (<avx512>_fmadd_<mode>_mask3<round_name>): Add condition check.
2097 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2099 * config/i386/avx10_2roundingintrin.h: New intrins.
2100 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2101 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2102 * config/i386/i386-expand.cc (ix86_expand_round_builtin): Handle
2103 V16HF_FTYPE_V16HF_V16HF_INT, V16HF_FTYPE_V16HF_V16HF_V16HF_INT,
2104 V16HF_FTYPE_V16HF_V16HF_V16HF_UQI_INT,
2105 V4DF_FTYPE_V4DF_V4DF_V4DI_INT_UQI_INT,
2106 V8SF_FTYPE_V8SF_V8SF_V8SI_INT_UQI_INT.
2107 * config/i386/sse.md:
2108 (<avx512>_fixupimm<mode><sd_maskz_name><round_saeonly_name>):
2109 Add condition check.
2110 (<avx512>_fixupimm<mode>_mask<round_saeonly_name>): Ditto.
2112 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2114 * config/i386/avx10_2roundingintrin.h: New intrins.
2115 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2116 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2117 * config/i386/i386-expand.cc (ix86_expand_round_builtin): Handle
2118 V16HF_FTYPE_V16HI_V16HF_UHI_INT.
2120 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2122 * config/i386/avx10_2roundingintrin.h: New intrins.
2123 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2124 * config/i386/sse.md
2125 (unspec_fix_truncv8sfv8si2<mask_name>): Extend rounding control.
2126 (<mask_codefor>fixuns_trunc<mode><sseintvecmodelower>2<mask_name>):
2128 (<mask_codefor>floatuns<sseintvecmodelower><mode>2<mask_name><round_name>):
2129 Add condition check.
2130 (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
2131 Remove round_saeonly_name.
2133 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2135 * config/i386/avx10_2roundingintrin.h: New intrins.
2136 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2137 * config/i386/sse.md (avx512fp16_fix<fixunssuffix>_trunc<mode>2<mask_name>):
2138 Extend round control for 256bit.
2139 (unspec_avx512fp16_fix<vcvtt_uns_suffix>_trunc<mode>2<mask_name>):
2141 (avx512fp16_fix<fixunssuffix>_trunc<mode>2<mask_name><round_saeonly_name>):
2142 Add condition check.
2143 * config/i386/subst.md
2144 (round_saeonly_mode_condition): Add V16HI check for 256bit.
2146 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2148 * config/i386/avx10_2roundingintrin.h: New intrins.
2149 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2150 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2151 * config/i386/i386-expand.cc (ix86_expand_round_builtin): Handle
2152 V4DF_FTYPE_V4DI_V4DF_UQI_INT, V4SF_FTYPE_V4DI_V4SF_UQI_INT,
2153 V8HF_FTYPE_V4DI_V8HF_UQI_INT.
2154 * config/i386/sse.md:
2155 (avx512fp16_vcvt<floatsuffix>qq2ph_v4di_mask_round): New expand.
2156 (*avx512fp16_vcvt<floatsuffix><sseintconvert>2ph_<mode>_mask):
2157 Extend round control and add "_1" suffix.
2158 (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
2159 Add condition check.
2160 (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
2162 (float<floatunssuffix><mode><ssePSmode2lower>2<mask_name><round_name>):
2163 Limit suffix output.
2164 (unspec_fix_truncv4dfv4si2<mask_name>): Extend round control.
2165 (unspec_fixuns_truncv4dfv4si2<mask_name>): Ditto.
2166 * config/i386/subst.md (round_qq2pssuff): New iterator.
2167 (round_saeonly_suff): Ditto.
2169 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2171 * config/i386/avx10_2roundingintrin.h: New intrins.
2172 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2173 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2174 * config/i386/i386-expand.cc (ix86_expand_round_builtin): Handle
2175 V8SI_FTYPE_V8SF_V8SI_UQI_INT, V4DI_FTYPE_V4SF_V4DI_UQI_INT.
2176 * config/i386/sse.md
2177 (<sse2_avx_avx512f>_fix_notrunc<sf2simodelower><mode><mask_name>):
2179 (<mask_codefor><avx512>_fixuns_notrunc<sf2simodelower><mode><mask_name><round_name>):
2180 Add round condition check.
2181 * config/i386/subst.md (round_constraint4): New.
2183 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2185 * config/i386/avx10_2roundingintrin.h: New intrins.
2186 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2187 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2188 * config/i386/i386-expand.cc (ix86_expand_round_builtin): Handle
2189 V16HI_FTYPE_V16HF_V16HI_UHI_INT, V4DF_FTYPE_V4SF_V4DF_UQI_INT
2190 V8HF_FTYPE_V8SF_V8HF_UQI_INT.
2191 * config/i386/sse.md
2192 (avx512fp16_vcvt<castmode>2ph_<mode><mask_name><round_name>):
2193 Add round condition check.
2194 * config/i386/subst.md (round_mode_condition): Add V16HI check for
2197 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2199 * config/i386/avx10_2roundingintrin.h: New intrins.
2200 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2201 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2202 * config/i386/i386-expand.cc (ix86_expand_round_builtin): Handle
2203 V8SF_FTYPE_V8HF_V8SF_UQI_INT, V8SI_FTYPE_V8HF_V8SI_UQI_INT,
2204 V4DF_FTYPE_V8HF_V4DF_UQI_INT, V4DI_FTYPE_V8HF_V4DI_UQI_INT.
2205 * config/i386/sse.md:
2206 (avx512fp16_float_extend_ph<mode>2<mask_name><round_saeonly_name>):
2207 Add condition check.
2208 (avx512fp16_vcvtph2<sseintconvertsignprefix><sseintconvert>_<mode>
2209 <mask_name><round_name>):
2211 (avx512fp16_float_extend_ph<mode>2<mask_name>): Extend round saeonly.
2212 (vcvtph2ps256<mask_name>): Ditto.
2213 * config/i386/subst.md
2214 (round_saeonly_applied): New condition.
2216 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2218 * config/i386/avx10_2roundingintrin.h: Add new intrins.
2219 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2220 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2221 * config/i386/i386-expand.cc (ix86_expand_round_builtin): Handle
2222 V4DI_FTYPE_V4DF_V4DI_UQI_INT, V4SI_FTYPE_V4DF_V4SI_UQI_INT.
2223 * config/i386/sse.md:
2224 (avx_cvtpd2dq256<mask_name>): Change name to
2225 avx_cvtpd2dq256<mask_name><round_name> and extend pattern to
2226 generate 256bit insns.
2227 (fixuns_notrunc<mode><si2dfmodelower>2<mask_name><round_name>):
2228 Add round_mode_condition.
2229 * config/i386/subst.md (round_pd2udqsuff): New iterator.
2231 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2233 * config/i386/avx10_2roundingintrin.h: Add new intrins.
2234 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2235 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2236 * config/i386/i386-expand.cc (ix86_expand_round_builtin): Handle
2237 V8SF_FTYPE_V8SI_V8SF_UQI_INT, V4SF_FTYPE_V4DF_V4SF_UQI_INT,
2238 V8HF_FTYPE_V8SI_V8HF_UQI_INT, V8HF_FTYPE_V4DF_V8HF_UQI_INT.
2239 * config/i386/sse.md:
2240 (avx512fp16_vcvt<floatsuffix><sseintconvert>2ph_<mode><mask_name><round_name>):
2241 Add condition check.
2242 (avx512fp16_vcvtpd2ph_v4df_mask_round): New expand.
2243 (*avx512fp16_vcvt<castmode>2ph_<mode>_mask): Change name to
2244 avx512fp16_vcvt<castmode>2ph_<mode>_mask<round_name>_1
2245 and extend pattern to generate 256bit insns.
2246 (avx_cvtpd2ps256<mask_name>): Change name to
2247 avx_cvtpd2ps256<mask_name><round_name> and extend pattern to
2248 generate 256bit insns.
2249 * config/i386/subst.md (round_applied): New condition.
2250 (round_suff): New iterator.
2251 (round_mode_condition): Add V32HI check for 512bit.
2252 (round_saeonly_mode_condition): Ditto.
2254 2024-08-19 Hu, Lin1 <lin1.hu@intel.com>
2256 * config.gcc: Add avx10_2roundingintrin.h.
2257 * config/i386/i386-builtin-types.def: Add new DEF_FUNCTION_TYPE.
2258 * config/i386/i386-builtin.def (BDESC): Add new builtins.
2259 * config/i386/i386-expand.cc (ix86_expand_round_builtin): Handle
2260 V4DF_FTYPE_V4DF_V4DF_V4DF_UQI_INT, V8SF_FTYPE_V8SF_V8SF_V8SF_UQI_INT,
2261 V16HF_FTYPE_V16HF_V16HF_V16HF_UHI_INT, UQI_FTYPE_V4DF_V4DF_INT_UQI_INT,
2262 UHI_FTYPE_V16HF_V16HF_INT_UHI_INT, UQI_FTYPE_V8SF_V8SF_INT_UQI_INT.
2263 * config/i386/immintrin.h: Include avx10_2roundingintrin.h.
2264 * config/i386/sse.md: Change subst_attr name due to renaming.
2265 * config/i386/subst.md:
2266 (<round_mode512bit_condition>): Add condition check for avx10.2
2267 rounding control 256bit intrins and renamed to ...
2268 (<round_mode_condition>): ...this.
2269 (round_saeonly_mode512bit_condition): Add condition check for
2270 avx10.2 rounding control 256 bit intris and renamed to ...
2271 (round_saeonly_mode_condition): ...this.
2272 * config/i386/avx10_2roundingintrin.h: New file.
2274 2024-08-18 Jeff Law <jlaw@ventanamicro.com>
2276 PR rtl-optimization/115876
2277 * ext-dce.cc (ext_dce_process_sets): Replace hardcoded 63/64 instances
2278 with HOST_BITS_PER_WIDE_INT based values.
2279 (carry_backpropagate): Handle modes with more bits than
2280 HOST_BITS_PER_WIDE_INT gracefully, avoiding undefined behavior.
2281 (ext_dce_process_uses): Handle subreg offsets which would result
2282 in ubsan shifts gracefully, avoiding undefined behavior.
2284 2024-08-18 Gerald Pfeifer <gerald@pfeifer.com>
2286 * doc/gm2.texi (Contributing): Tweak gm2 mailing list address.
2288 2024-08-18 Andrew Pinski <quic_apinski@quicinc.com>
2290 * gimple-match-exports.cc (gimple_match_op::operands_occurs_in_abnormal_phi):
2292 * gimple-match.h (gimple_match_op): Add operands_occurs_in_abnormal_phi.
2293 * tree-ssa-phiopt.cc (factor_out_conditional_operation): Use gimple_match_op
2294 instead of manually extracting from/creating the gimple.
2296 2024-08-18 Georg-Johann Lay <avr@gjlay.de>
2298 * config/avr/avr.md (*add<mode>3_split) [!reload_completed]:
2299 Add a scratch:QI to 16-bit additions with constant.
2301 2024-08-18 Georg-Johann Lay <avr@gjlay.de>
2304 * config/avr/avr.md (*dec-and-branchhi!=-1.l.clobber):
2305 Increase the additional jump offset to 2 words.
2307 2024-08-18 Georg-Johann Lay <avr@gjlay.de>
2310 * config/avr/avr-protos.h (avr_jump_mode): Add an int argument.
2311 * config/avr/avr.cc (avr_jump_mode): Add an int argument to increase
2312 the computed jump offset of backwards branches.
2313 * config/avr/avr.md (*dec-and-branchhi!=-1, *dec-and-branchsi!=-1):
2314 Increase the jump offset used by avr_jump_mode() as needed.
2316 2024-08-18 Andrew Pinski <quic_apinski@quicinc.com>
2318 * gimple-fold.cc (mark_lhs_in_seq_for_dce): New function.
2319 (replace_stmt_with_simplification): Call mark_lhs_in_seq_for_dce
2320 right before inserting the sequence.
2321 (fold_stmt_1): Add dce_worklist argument, update call to
2322 replace_stmt_with_simplification.
2323 (fold_stmt): Add dce_worklist argument, update call to fold_stmt_1.
2324 (fold_stmt_inplace): Update call to fold_stmt_1.
2325 * gimple-fold.h (fold_stmt): Add bitmap argument.
2326 * tree-ssa-forwprop.cc (pass_forwprop::execute): Update call to fold_stmt.
2328 2024-08-18 Pan Li <pan2.li@intel.com>
2330 * config/riscv/iterators.md (ANYI_QUAD_TRUNC): New iterator for
2332 (ANYI_OCT_TRUNC): New iterator for oct truncation.
2333 (ANYI_QUAD_TRUNCATED): New attr for truncated quad modes.
2334 (ANYI_OCT_TRUNCATED): New attr for truncated oct modes.
2335 (anyi_quad_truncated): Ditto but for lower case.
2336 (anyi_oct_truncated): Ditto but for lower case.
2337 * config/riscv/riscv.md (ustrunc<mode><anyi_quad_truncated>2):
2338 Add new pattern for quad truncation.
2339 (ustrunc<mode><anyi_oct_truncated>2): Ditto but for oct.
2341 2024-08-18 Pan Li <pan2.li@intel.com>
2344 * config/riscv/riscv.cc (riscv_gen_zero_extend_rtx): Add new
2345 func impl to zero extend rtx.
2346 (riscv_expand_usadd): Leverage above func to cleanup operands 0
2347 and remove the special handing for SImode in RV64.
2349 2024-08-17 Jeff Law <jlaw@ventanamicro.com>
2351 * ext-dce.cc (carry_backpropagate): Cast mask to HOST_WIDE_INT before
2354 2024-08-17 Kevin Kirspel <Kevin-Kirspel@idexx.com>
2356 * config/riscv/t-rtems: Add ilp32f multilib.
2358 2024-08-17 Jeff Law <jlaw@ventanamicro.com>
2360 * config/v850/v850.md (rotlsi3): Allow more cases for V850E3V5+.
2362 2024-08-17 Jin Ma <jinma@linux.alibaba.com>
2364 * config/riscv/vector.md: Allow scalar operand to be 0.
2366 2024-08-17 Jeff Law <jlaw@ventanamicro.com>
2369 * config/riscv/riscv-protos.h (riscv_const_insns): Add new argument.
2370 * config/riscv/riscv.cc (riscv_build_integer): Add new argument
2371 ALLOW_NEW_PSEUDOS. Pass it down to recursive calls and check it
2372 before using synthesis which allows new registers to be created.
2373 (riscv_split_integer_cost): Pass new argument to riscv_build_integer.
2374 (riscv_integer_cost): Add ALLOW_NEW_PSEUDOS argument, pass it down to
2375 riscv_build_integer.
2376 (riscv_legitimate_constant_p): Pass new argument to riscv_const_insns.
2377 (riscv_const_insns): New argment ALLOW_NEW_PSEUDOS. Pass it down to
2378 riscv_integer_cost and riscv_const_insns.
2379 (riscv_split_const_insns): Pass new argument to riscv_const_insns.
2380 (riscv_move_integer, riscv_rtx_costs): Similarly.
2381 * config/riscv/riscv.md (shadd with costly constant): Pass new argument
2382 to riscv_const_insns.
2383 * config/riscv/bitmanip.md (and with costly constant): Pass new argument
2384 to riscv_const_insns.
2386 2024-08-17 Jin Ma <jinma@linux.alibaba.com>
2388 * config/riscv/riscv-protos.h (riscv_vector_float_type_p): New.
2389 * config/riscv/riscv-vector-builtins.cc (function_instance::any_type_float_p):
2390 Use riscv_vector_float_type_p instead of FLOAT_MODE_P for judgment.
2391 * config/riscv/riscv.cc (riscv_vector_int_type_p): Change static to extern.
2393 2024-08-17 Pan Li <pan2.li@intel.com>
2396 * config/riscv/autovec-opt.md: Add quad truncation to
2397 align the mode requirement for vwsll.
2399 2024-08-17 Feng Wang <wangfeng@eswincomputing.com>
2401 * config/riscv/autovec.md (v<bitmanip_optab><mode>3):
2402 Add new define_expand pattern for vector rotate shift.
2404 2024-08-17 Gerald Pfeifer <gerald@pfeifer.com>
2406 * doc/gm2.texi (What is GNU Modula-2): Tweak PIM4 link.
2408 2024-08-17 Gerald Pfeifer <gerald@pfeifer.com>
2410 * doc/gm2.texi (Community): Tweak link to gm2 list archive.
2412 2024-08-17 Georg-Johann Lay <avr@gjlay.de>
2415 * config/avr/avr.cc (avr_out_movsi_mr_r_reg_disp_tiny): Fix
2416 output templates for the reg_base == reg_src and
2417 reg_src == reg_base - 2 cases.
2419 2024-08-17 曾治金 <zhijin.zeng@spacemit.com>
2422 * config/riscv/riscv.cc (riscv_dwarf_poly_indeterminate_value): Take
2423 BYTES_PER_RISCV_VECTOR for *factor instead of riscv_bytes_per_vector_chunk.
2425 2024-08-16 Mark Harmstone <mark@harmstone.com>
2427 * dwarf2codeview.cc (enum cv_sym_type): Add S_REGREL32.
2428 (write_fbreg_variable): New function.
2429 (write_unoptimized_local_variable): Add fblock parameter, and handle
2430 DW_OP_fbreg locations.
2431 (write_unoptimized_function_vars): Add fbloc parameter.
2432 (write_function): Extract frame base from DWARF.
2433 * dwarf2out.cc (convert_cfa_to_fb_loc_list): Output simplified frame
2434 base information for CodeView.
2436 2024-08-16 Mark Harmstone <mark@harmstone.com>
2438 * dwarf2codeview.cc (enum cv_sym_type): Add S_REGISTER.
2439 (enum cv_x86_register): New type.
2440 (enum cv_amd64_register): New type.
2441 (dwarf_reg_to_cv): New function.
2442 (write_s_register): New function.
2443 (write_unoptimized_local_variable): Handle parameters and DW_OP_reg*
2446 2024-08-16 Mark Harmstone <mark@harmstone.com>
2448 * dwarf2codeview.cc (enum cv_sym_type): Add S_END and S_BLOCK32.
2449 (write_local_s_ldata32): New function.
2450 (write_unoptimized_local_variable): New function.
2451 (write_s_block32): New function.
2452 (write_s_end): New function.
2453 (write_unoptimized_function_vars): New function.
2454 (write_function): Call write_unoptimized_function_vars.
2456 2024-08-16 Mark Harmstone <mark@harmstone.com>
2458 * dwarf2codeview.cc (get_type_num_enumeration_type): Initialize last_type
2460 (get_type_num_struct): Likewise.
2462 2024-08-16 Georg-Johann Lay <avr@gjlay.de>
2464 Backported from master:
2465 2024-08-16 Georg-Johann Lay <avr@gjlay.de>
2468 * config/avr/avr.md (*clrmemqi*): Use HImode for alignment operand.
2470 2024-08-16 Lingling Kong <lingling.kong@intel.com>
2472 * config/i386/sse.md (vpmadd52<vpmadd52type><mode>):
2473 Prohibit egpr for vex version.
2474 (vpdpbusd_<mode>): Ditto.
2475 (vpdpbusds_<mode>): Ditto.
2476 (vpdpwssd_<mode>): Ditto.
2477 (vpdpwssds_<mode>): Ditto.
2478 (*vcvtneps2bf16_v4sf): Ditto.
2479 (*vcvtneps2bf16_v8sf): Ditto.
2480 (vpdp<vpdotprodtype>_<mode>): Ditto.
2481 (vbcstnebf162ps_<mode>): Ditto.
2482 (vbcstnesh2ps_<mode>): Ditto.
2483 (vcvtnee<bf16_ph>2ps_<mode>): Ditto.
2484 (vcvtneo<bf16_ph>2ps_<mode>): Ditto.
2485 (vpdp<vpdpwprodtype>_<mode>): Ditto.
2487 2024-08-16 Andrew Pinski <quic_apinski@quicinc.com>
2490 * config/aarch64/aarch64.md (popcount<mode>2): Update pattern
2491 to support ALLI modes.
2493 2024-08-16 Andrew Pinski <pinskia@gmail.com>
2495 * tree-ssa-phiopt.cc (factor_out_conditional_operation): Update
2498 2024-08-15 Vineet Gupta <vineetg@rivosinc.com>
2500 * config/riscv/riscv.md: define_insn for fclass insn.
2501 define_expand for isfinite, isnormal, isinf.
2503 2024-08-15 Roger Sayle <roger@nextmovesoftware.com>
2504 Uros Bizjak <ubizjak@gmail.com>
2506 * config/i386/i386.md (*extendv2di2_highpart_stv_noavx512vl): Split
2507 to an improved implementation on !TARGET_XOP. On TARGET_XOP, use
2508 a new pseudo for the intermediate to simplify register allocation.
2510 2024-08-15 Richard Sandiford <richard.sandiford@arm.com>
2512 PR middle-end/116236
2513 * rtlanal.cc (decompose_normal_address): Try to distinguish
2514 bases and indices based on mode, before resorting to "baseness".
2516 2024-08-15 Richard Sandiford <richard.sandiford@arm.com>
2519 * recog.h (insn_propagation::apply_to_note): Declare.
2520 * recog.cc (insn_propagation::apply_to_note): New function.
2521 * late-combine.cc (insn_combination::substitute_note): Use
2522 apply_to_note instead of apply_to_rvalue.
2523 * rtl-ssa/changes.cc (rtl_ssa::changes_are_worthwhile): Improve
2524 dumping of costs for noop moves.
2526 2024-08-15 Xi Ruoyao <xry111@xry111.site>
2528 * config/loongarch/loongarch.md (extendsidi2): Add ("=r", "f")
2529 alternative and use movfr2gr.s for it. The spec clearly states
2530 movfr2gr.s sign extends the value to GRLEN.
2531 (fclass_<fmt>): Make the result SImode instead of a floating
2532 mode. The fclass results are really not FP values.
2533 (FCLASS_MASK): New define_int_iterator.
2534 (fclass_optab): New define_int_attr.
2535 (<FCLASS_MASK:fclass_optab><ANYF:mode>): New define_expand
2538 2024-08-15 liuhongt <hongtao.liu@intel.com>
2541 * config/i386/i386-expand.cc (ix86_expand_vector_move):
2542 Restrict special case TImode to 128-bit vector conversions via
2543 V2DI under ix86_pre_reload_split ().
2544 * config/i386/i386.cc (inline_secondary_memory_needed):
2545 Movement between GENERAL_REGS and SSE_REGS for TImode doesn't
2546 need secondary reload.
2547 * config/i386/i386.md (*extendsidi2_rex64): Add a
2548 define_peephole2 after it.
2550 2024-08-15 Richard Sandiford <richard.sandiford@arm.com>
2553 * config/aarch64/aarch64-sve-builtins-sve2.h (svpext): Rename to...
2554 (svpext_lane): ...this.
2555 * config/aarch64/aarch64-sve-builtins-sve2.cc (svpext_impl): Rename
2557 (svpext_lane_impl): ...this and update instantiation accordingly.
2558 * config/aarch64/aarch64-sve-builtins-sve2.def (svpext): Rename to...
2559 (svpext_lane): ...this.
2561 2024-08-15 Haochen Gui <guihaoc@gcc.gnu.org>
2563 * config/rs6000/rs6000.md (floatti<mode>2, floatunsti<mode>2,
2564 fix_trunc<mode>ti2): Add guard TARGET_FLOAT128_HW.
2565 * config/rs6000/vsx.md (xsxexpqp_<IEEE128:mode>_<V2DI_DI:mode>,
2566 xsxsigqp_<IEEE128:mode>_<VEC_TI:mode>, xsiexpqpf_<mode>,
2567 xsiexpqp_<IEEE128:mode>_<V2DI_DI:mode>, xscmpexpqp_<code>_<mode>,
2568 *xscmpexpqp, xststdcnegqp_<mode>): Replace guard TARGET_P9_VECTOR
2569 with TARGET_FLOAT128_HW.
2570 (xststdc_<mode>, *xststdc_<mode>, isinf<mode>2): Add guard
2571 TARGET_FLOAT128_HW for the IEEE128 modes.
2573 2024-08-15 Haochen Gui <guihaoc@gcc.gnu.org>
2576 * config/rs6000/vsx.md (isnormal<mode>2): New expand.
2578 2024-08-15 Haochen Gui <guihaoc@gcc.gnu.org>
2581 * config/rs6000/vsx.md (isfinite<mode>2): New expand.
2583 2024-08-15 Haochen Gui <guihaoc@gcc.gnu.org>
2586 * config/rs6000/rs6000.md (constant VSX_TEST_DATA_CLASS_NAN,
2587 VSX_TEST_DATA_CLASS_POS_INF, VSX_TEST_DATA_CLASS_NEG_INF,
2588 VSX_TEST_DATA_CLASS_POS_ZERO, VSX_TEST_DATA_CLASS_NEG_ZERO,
2589 VSX_TEST_DATA_CLASS_POS_DENORMAL, VSX_TEST_DATA_CLASS_NEG_DENORMAL):
2591 (mode_attr sdq, vsx_altivec, wa_v, x): Define.
2592 (mode_iterator IEEE_FP): Define.
2593 * config/rs6000/vsx.md (isinf<mode>2): New expand.
2594 (expand xststdcqp_<mode>, xststdc<sd>p): Combine into...
2595 (expand xststdc_<mode>): ...this.
2596 (insn *xststdcqp_<mode>, *xststdc<sd>p): Combine into...
2597 (insn *xststdc_<mode>): ...this.
2598 * config/rs6000/rs6000-builtin.cc (rs6000_expand_builtin): Rename
2599 CODE_FOR_xststdcqp_kf as CODE_FOR_xststdc_kf,
2600 CODE_FOR_xststdcqp_tf as CODE_FOR_xststdc_tf.
2601 * config/rs6000/rs6000-builtins.def: Rename xststdcdp as xststdc_df,
2602 xststdcsp as xststdc_sf, xststdcqp_kf as xststdc_kf.
2604 2024-08-15 Haochen Gui <guihaoc@gcc.gnu.org>
2606 * gimple-range-op.cc (class cfn_isfinite): New.
2607 (op_cfn_finite): New variables.
2608 (gimple_range_op_handler::maybe_builtin_call): Handle
2609 CFN_BUILT_IN_ISFINITE.
2610 * value-range.h (class frange): Declear known_isnormal and
2611 known_isdenormal_or_zero.
2612 (frange::known_isnormal): Define.
2613 (frange::known_isdenormal_or_zero): Define.
2615 2024-08-15 Haochen Gui <guihaoc@gcc.gnu.org>
2617 * gimple-range-op.cc (class cfn_isfinite): New.
2618 (op_cfn_finite): New variables.
2619 (gimple_range_op_handler::maybe_builtin_call): Handle
2620 CFN_BUILT_IN_ISFINITE.
2622 2024-08-15 Haochen Gui <guihaoc@gcc.gnu.org>
2625 * gimple-range-op.cc (class cfn_isinf): New.
2626 (op_cfn_isinf): New variables.
2627 (gimple_range_op_handler::maybe_builtin_call): Handle
2628 CASE_FLT_FN (BUILT_IN_ISINF).
2630 2024-08-14 Marek Polacek <polacek@redhat.com>
2633 * gimplify.cc (gimplify_arg): Do not strip a TARGET_EXPR whose
2634 initializer is a CONSTRUCTOR.
2636 2024-08-14 Stefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
2638 * config/s390/vecintrin.h (vec_vstbrh): Remove.
2639 (vec_vstbrf): Remove.
2640 (vec_vstbrg): Remove.
2641 (vec_vstbrq): Remove.
2642 (vec_vstbrf_flt): Remove.
2643 (vec_vstbrg_dbl): Remove.
2644 (vec_vsterb): Remove.
2645 (vec_vsterh): Remove.
2646 (vec_vsterf): Remove.
2647 (vec_vsterg): Remove.
2648 (vec_vsterf_flt): Remove.
2649 (vec_vsterg_dbl): Remove.
2651 2024-08-14 Stefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
2653 * config/s390/s390-builtin-types.def (BT_FN_UV16QI_UV2DI_UV2DI):
2655 (BT_FN_UV16QI_UV2DI_UV2DI_UV16QI): New.
2656 * config/s390/s390-builtins.def (s390_vgfmg_128): New.
2657 (s390_vgfmag_128): New.
2658 * config/s390/vecintrin.h (vec_gfmsum_128): Use s390_vgfmg_128.
2659 (vec_gfmsum_accum_128): Use s390_vgfmag_128.
2661 2024-08-14 Lingling Kong <lingling.kong@intel.com>
2664 * config/i386/i386.md (*ashlqi3_1_zext<mode><nf_name>):
2666 (*ashlhi3_1_zext<mode><nf_name>): Ditto.
2667 (*<insn>qi3_1_zext<mode><nf_name>): Ditto.
2668 (*<insn>hi3_1_zext<mode><nf_name>): Ditto.
2670 2024-08-14 Lingling Kong <lingling.kong@intel.com>
2673 * config/i386/i386.md (*andqi_1_zext<mode><nf_name>): New
2675 (*andhi_1_zext<mode><nf_name>): Ditto.
2676 (*<code>qi_1_zext<mode><nf_name>): Ditto.
2677 (*<code>hi_1_zext<mode><nf_name>): Ditto.
2678 (*negqi_1_zext<mode><nf_name>): Ditto.
2679 (*neghi_1_zext<mode><nf_name>): Ditto.
2680 (*one_cmplqi2_1_zext<mode>): Ditto.
2681 (*one_cmplhi2_1_zext<mode>): Ditto.
2683 2024-08-14 Lingling Kong <lingling.kong@intel.com>
2686 * config/i386/i386.md (*subqi_1_zext<mode><nf_name>): New
2688 (*subhi_1_zext<mode><nf_name>): Ditto.
2689 (*addqi3_carry_zext<mode>): Ditto.
2690 (*addhi3_carry_zext<mode>): Ditto.
2691 (*addqi3_carry_zext<mode>_0): Ditto.
2692 (*addhi3_carry_zext<mode>_0): Ditto.
2693 (*addqi3_carry_zext<mode>_0r): Ditto.
2694 (*addhi3_carry_zext<mode>_0r): Ditto.
2695 (*subqi3_carry_zext<mode>): Ditto.
2696 (*subhi3_carry_zext<mode>): Ditto.
2697 (*subqi3_carry_zext<mode>_0): Ditto.
2698 (*subhi3_carry_zext<mode>_0): Ditto.
2699 (*subqi3_carry_zext<mode>_0r): Ditto.
2700 (*subhi3_carry_zext<mode>_0r): Ditto.
2702 2024-08-14 Lingling Kong <lingling.kong@intel.com>
2705 * config/i386/i386.md (*addqi_1_zext<mode><nf_name>): New
2707 (*addhi_1_zext<mode><nf_name>): Ditto.
2709 2024-08-14 Xianmiao Qu <cooper.qu@linux.alibaba.com>
2711 * genoutput.cc (struct operand_data): Add member 'eq_next' to
2712 point to the next member with the same hash value in the
2714 (compare_operands): Move the comparison of the mode to the very
2715 beginning to accelerate the comparison of the two operands.
2716 (struct operand_data_hasher): New, a class that takes into account
2717 the necessary elements for comparing the equality of two operands
2719 (operand_data_hasher::hash): New.
2720 (operand_data_hasher::equal): New.
2721 (operand_datas): New, hash table of konwn pattern operands.
2722 (place_operands): Use a hash table instead of traversing the array
2723 to find the same operand.
2724 (main): Add initialization of the hash table 'operand_datas'.
2726 2024-08-14 Jeff Law <jlaw@ventanamicro.com>
2729 2024-08-12 Jeff Law <jlaw@ventanamicro.com>
2731 * rtlanal.cc (subreg_regno): Update comment.
2732 * final.cc (alter_subrg): Always use REGNO (SUBREG_REG ()) to get
2733 the base regsiter for paradoxical subregs.
2735 2024-08-14 liuhongt <hongtao.liu@intel.com>
2738 * config/i386/i386.cc (ix86_align_loops): Move this to ..
2739 * config/i386/i386-features.cc (ix86_align_loops): .. here.
2740 (class pass_align_tight_loops): New class.
2741 (make_pass_align_tight_loops): New function.
2742 * config/i386/i386-passes.def: Insert pass_align_tight_loops
2743 after pass_insert_endbr_and_patchable_area.
2744 * config/i386/i386-protos.h (make_pass_align_tight_loops): New
2747 2024-08-13 Manolis Tsamis <manolis.tsamis@vrull.eu>
2749 PR tree-optimization/116353
2750 * ifcvt.cc (bb_ok_for_noce_convert_multiple_sets): Check
2751 noce_can_force_operand.
2753 2024-08-13 Patrick O'Neill <patrick@rivosinc.com>
2755 * config/riscv/riscv-v.cc (legitimize_move): extrac -> extract.
2756 (expand_vec_cmp_float): Remove duplicate vmnor.mm.
2757 * config/riscv/riscv-vector-builtins.cc: ins -> insns.
2758 * config/riscv/riscv.cc (riscv_init_machine_status): mwrvv -> mrvv.
2759 * config/riscv/vector-iterators.md: RVVM8QImde -> RVVM8QImode
2760 * config/riscv/vector.md: Replaced non-existant vsetivl with vsetivli.
2762 2024-08-13 Pan Li <pan2.li@intel.com>
2765 * internal-fn.cc (type_strictly_matches_mode_p): Add handling
2766 for vector bool type.
2768 2024-08-13 Kewen Lin <linkw@linux.ibm.com>
2770 PR rtl-optimization/116170
2771 * lra-constraints.cc (curr_insn_transform): Don't emit move back to
2772 old operand if it's CONSTANT_P.
2774 2024-08-13 Mark Wielaard <mark@klomp.org>
2776 * config/avr/avr.opt.urls: Regenerate.
2778 2024-08-12 Peter Bergner <bergner@linux.ibm.com>
2781 * config/rs6000/rs6000.cc (rs6000_override_options_after_change): Move
2782 the disabling of shrink-wrapping from here....
2783 * config/rs6000/rs6000-logue.cc (rs6000_emit_prologue): ...to here.
2785 2024-08-12 Jeff Law <jlaw@ventanamicro.com>
2787 * rtlanal.cc (subreg_regno): Update comment.
2788 * final.cc (alter_subrg): Always use REGNO (SUBREG_REG ()) to get
2789 the base regsiter for paradoxical subregs.
2791 2024-08-12 Manolis Tsamis <manolis.tsamis@vrull.eu>
2793 * ifcvt.cc (need_cmov_or_rewire): Renamed init_noce_multiple_sets_info.
2794 (init_noce_multiple_sets_info): Initialize noce_multiple_sets_info.
2795 (noce_convert_multiple_sets_1): Use noce_multiple_sets_info and handle
2796 rewiring of multiple registers.
2797 (noce_convert_multiple_sets): Updated to use noce_multiple_sets_info.
2798 * ifcvt.h (struct noce_multiple_sets_info): Introduce new struct
2799 noce_multiple_sets_info to store info for noce_convert_multiple_sets.
2801 2024-08-12 Manolis Tsamis <manolis.tsamis@vrull.eu>
2803 * ifcvt.cc (try_emit_cmove_seq): Modify comments.
2804 (noce_convert_multiple_sets_1): Modify comments.
2805 (bb_ok_for_noce_convert_multiple_sets): Allow more operations.
2807 2024-08-12 Manolis Tsamis <manolis.tsamis@vrull.eu>
2809 * ifcvt.cc (check_for_cc_cmp_clobbers): Use modified_in_p instead.
2810 (noce_convert_multiple_sets_1): Don't use seq2 if it clobbers cc_cmp.
2811 Punt if seq clobbers cond. Refactor the code that sets read_comparison.
2813 2024-08-12 Georg-Johann Lay <avr@gjlay.de>
2816 * config/avr/avr.md (setmemhi): Set alignment to 0.
2818 2024-08-12 Joern Rennecke <joern.rennecke@riscy-ip.com>
2820 * except.cc (sjlj_emit_function_enter):
2821 Set fn_begin_outside_block again if encountering a jump instruction.
2823 2024-08-12 Richard Sandiford <richard.sandiford@arm.com>
2826 * splay-tree-utils.h (rooted_splay_tree::insert_relative)
2827 (rooted_splay_tree::lookup_le): New functions.
2828 (rooted_splay_tree::remove_root_and_splay_next): Likewise.
2829 * splay-tree-utils.tcc (rooted_splay_tree::insert_relative): New
2830 function, extracted from...
2831 (rooted_splay_tree::insert): ...here.
2832 (rooted_splay_tree::lookup_le): New function.
2833 (rooted_splay_tree::remove_root_and_splay_next): Likewise.
2834 * tree-ssa-sccvn.cc (pd_range::m_children): New member variable.
2835 (vn_walk_cb_data::vn_walk_cb_data): Initialize first_range.
2836 (vn_walk_cb_data::known_ranges): Use a default_splay_tree.
2837 (vn_walk_cb_data::~vn_walk_cb_data): Remove freeing of known_ranges.
2838 (pd_range_compare, pd_range_alloc, pd_range_dealloc): Delete.
2839 (vn_walk_cb_data::push_partial_def): Rewrite splay tree operations
2840 to use splay-tree-utils.h.
2841 * rtl-ssa/accesses.cc (function_info::add_use): Use insert_relative.
2843 2024-08-12 Kyrylo Tkachov <ktkachov@nvidia.com>
2845 * config/aarch64/aarch64-simd.md
2846 (aarch64_simd_imm_shl<mode><vczle><vczbe>): Rewrite to new
2847 syntax. Add =w,w,vs1 alternative.
2848 * config/aarch64/constraints.md (vs1): New constraint.
2850 2024-08-12 Haochen Jiang <haochen.jiang@intel.com>
2852 * common/config/i386/cpuinfo.h (get_available_features): Handle
2854 * common/config/i386/i386-common.cc
2855 (OPTION_MASK_ISA2_AVX10_2_256_SET): New.
2856 (OPTION_MASK_ISA2_AVX10_2_512_SET): Ditto.
2857 (OPTION_MASK_ISA2_AVX10_1_256_UNSET):
2858 Add OPTION_MASK_ISA2_AVX10_2_256_UNSET.
2859 (OPTION_MASK_ISA2_AVX10_1_512_UNSET):
2860 Add OPTION_MASK_ISA2_AVX10_2_512_UNSET.
2861 (OPTION_MASK_ISA2_AVX10_2_256_UNSET): New.
2862 (OPTION_MASK_ISA2_AVX10_2_512_UNSET): Ditto.
2863 (ix86_handle_option): Handle avx10.2-256 and avx10.2-512.
2864 * common/config/i386/i386-cpuinfo.h (enum processor_features):
2865 Add FEATURE_AVX10_2_256 and FEATURE_AVX10_2_512.
2866 * common/config/i386/i386-isas.h: Add ISA_NAMES_TABLE_ENTRY for
2867 avx10.2-256 and avx10.2-512.
2868 * config/i386/i386-c.cc (ix86_target_macros_internal): Define
2869 __AVX10_2_256__ and __AVX10_2_512__.
2870 * config/i386/i386-isa.def (AVX10_2): Add DEF_PTA(AVX10_2_256)
2871 and DEF_PTA(AVX10_2_512).
2872 * config/i386/i386-options.cc (isa2_opts): Add -mavx10.2-256 and
2874 (ix86_valid_target_attribute_inner_p): Handle avx10.2-256 and
2876 * config/i386/i386.opt: Add option -mavx10.2, -mavx10.2-256 and
2878 * config/i386/i386.opt.urls: Regenerated.
2879 * doc/extend.texi: Document avx10.2, avx10.2-256 and avx10.2-512.
2880 * doc/invoke.texi: Document -mavx10.2, -mavx10.2-256 and
2882 * doc/sourcebuild.texi: Document target avx10.2, avx10.2-256,
2885 2024-08-12 Roger Sayle <roger@nextmovesoftware.com>
2888 * config/i386/i386.md (*extendv2di2_highpart_stv_noavx512vl): New
2889 define_insn_and_split to handle the STV conversion of the DImode
2890 pattern *extendsi2_doubleword_highpart.
2892 2024-08-12 Lulu Cheng <chenglulu@loongson.cn>
2894 * config/loongarch/loongarch.md (insn): Added rotatert rotr pairs.
2895 * config/loongarch/simd.md (rotr<mode>3): Remove to ...
2896 (<optab><mode>3): This.
2898 2024-08-12 Lulu Cheng <chenglulu@loongson.cn>
2901 * config/loongarch/lasx.md (vcondu<LASX:mode><ILASX:mode>): Delete.
2902 (vcond<LASX:mode><LASX_2:mode>): Likewise.
2903 * config/loongarch/lsx.md (vcondu<LSX:mode><ILSX:mode>): Likewise.
2904 (vcond<LSX:mode><LSX_2:mode>): Likewise.
2906 2024-08-12 Lulu Cheng <chenglulu@loongson.cn>
2908 * config/loongarch/lasx.md (xvandn<mode>3): Rename to ...
2909 (andn<mode>3): This.
2910 (xvorn<mode>3): Rename to ...
2911 (iorn<mode>3): This.
2912 * config/loongarch/loongarch-builtins.cc
2913 (CODE_FOR_lsx_vandn_v): Defined as the modified name.
2914 (CODE_FOR_lsx_vorn_v): Likewise.
2915 (CODE_FOR_lasx_xvandn_v): Likewise.
2916 (CODE_FOR_lasx_xvorn_v): Likewise.
2917 (loongarch_expand_builtin_insn): When the builtin function to be
2918 called is __builtin_lasx_xvandn or __builtin_lsx_vandn, swap the
2920 * config/loongarch/loongarch.md (<optab>n<mode>): Rename to ...
2921 (<optab>n<mode>3): This.
2922 * config/loongarch/lsx.md (vandn<mode>3): Rename to ...
2923 (andn<mode>3): This.
2924 (vorn<mode>3): Rename to ...
2925 (iorn<mode>3): This.
2927 2024-08-11 Georg-Johann Lay <avr@gjlay.de>
2929 * config/avr/avr.opt (mlra): Set Undocumented flag.
2931 2024-08-11 Georg-Johann Lay <avr@gjlay.de>
2933 * config/avr/avr.cc (ra_in_progress): New static function.
2934 (avr_legitimate_address_p, avr_addr_space_legitimate_address_p)
2935 (extra_constraint_Q): Use it with -mlog=.
2937 2024-08-10 Andi Kleen <ak@gcc.gnu.org>
2939 * doc/cfg.texi: Fix references to dom_walker.
2941 2024-08-10 Georg-Johann Lay <avr@gjlay.de>
2944 * config/avr/avr.opt (-mlra): New target option.
2945 * config/avr/avr.cc (avr_use_lra_p): New function.
2946 (TARGET_LRA_P): Use it.
2947 (avr_hard_regno_mode_ok) [lra]: Don't disallow 4-byte modes for X.
2949 2024-08-09 Jeff Law <jlaw@ventanamicro.com>
2952 * config/riscv/bitmanip.md (Zbs combiner patterns/splitters): Mask the
2953 bit position in the split code appropriately.
2955 2024-08-09 Kyrylo Tkachov <ktkachov@nvidia.com>
2958 2024-08-08 Surya Kumari Jangala <jskumari@linux.ibm.com>
2960 PR rtl-optimization/116028
2961 * lra-constraints.cc (split_reg): Spill register before call
2963 (latest_call_insn): New variable.
2964 (inherit_in_ebb): Track the latest call insn.
2966 2024-08-09 Andrew MacLeod <amacleod@redhat.com>
2968 PR tree-optimization/114855
2969 * gimple-range-gori.cc (gori_compute::gori_compute): Adjust
2970 ranger_recompute_depth limit based on the number of BBs.
2971 (gori_compute::may_recompute_p): Use previosuly calculated value.
2972 * gimple-range-gori.h (gori_compute::m_recompute_depth): New.
2974 2024-08-09 Andrew MacLeod <amacleod@redhat.com>
2976 PR tree-optimization/114855
2977 * gimple-range-cache.cc (ranger_cache::fill_block_cache): Do not
2978 process equivalencies if the number of blocks is too high.
2980 2024-08-09 Raphael Moreira Zinsly <rzinsly@ventanamicro.com>
2982 * config/riscv/riscv.cc (riscv_compute_frame_info): Update
2984 (riscv_stack_clash_protection_alloca_probe_range): New.
2985 (TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
2986 * config/riscv/riscv.h
2987 (STACK_CLASH_MIN_BYTES_OUTGOING_ARGS): New.
2988 (STACK_DYNAMIC_OFFSET): New.
2990 2024-08-09 Raphael Moreira Zinsly <rzinsly@ventanamicro.com>
2992 * config/riscv/riscv.cc
2993 (riscv_allocate_and_probe_stack_loop): New function.
2994 (riscv_v_adjust_scalable_frame): Add stack-clash protection
2996 (riscv_allocate_and_probe_stack_space): Move the probe loop
2997 implementation to riscv_allocate_and_probe_stack_loop.
2998 * config/riscv/riscv.h: Define RISCV_STACK_CLASH_VECTOR_CFA_REGNUM.
3000 2024-08-09 Raphael Moreira Zinsly <rzinsly@ventanamicro.com>
3002 * config/riscv/riscv.cc
3003 (riscv_option_override): Enforce that interval is the same size as
3005 (riscv_allocate_and_probe_stack_space): New function.
3006 (riscv_expand_prologue): Call riscv_allocate_and_probe_stack_space
3007 to the final allocation of the stack and add stack-clash dump
3009 * config/riscv/riscv.h: Define STACK_CLASH_CALLER_GUARD and
3010 STACK_CLASH_MAX_UNROLL_PAGES.
3012 2024-08-09 Raphael Moreira Zinsly <rzinsly@ventanamicro.com>
3014 * config/riscv/riscv.cc (riscv_v_adjust_scalable_frame): Move
3015 closer to riscv_expand_prologue.
3017 2024-08-09 Raphael Moreira Zinsly <rzinsly@ventanamicro.com>
3019 * config/riscv/riscv.cc (riscv_emit_stack_tie): Pass the
3020 register to be tied to the stack pointer as argument.
3021 * config/riscv/riscv.md (stack_tie<mode>): Don't match equal
3024 2024-08-09 Jakub Jelinek <jakub@redhat.com>
3027 * config/i386/i386.cc (ix86_fold_builtin) <case IX86_BUILTIN_BEXTR32>:
3028 When folding into zero without checking whether first argument is
3029 constant, use omit_one_operand.
3030 (ix86_fold_builtin) <case IX86_BUILTIN_BZHI32>: Likewise.
3032 2024-08-09 Andrew Stubbs <ams@baylibre.com>
3034 * config/gcn/gcn.cc (gcn_asm_trampoline_template): Add .align.
3035 * config/gcn/gcn.h (TRAMPOLINE_SIZE): Increase to 40.
3037 2024-08-09 Georg-Johann Lay <avr@gjlay.de>
3039 * config/avr/avr.md (*load_<mode>_libgcc, *xload_<mode>_libgcc):
3042 2024-08-09 Kyrylo Tkachov <ktkachov@nvidia.com>
3044 * config/aarch64/constraints.md (Dm): Match CONSTM1_RTX rather
3047 2024-08-08 Tamar Christina <tamar.christina@arm.com>
3050 * config/aarch64/aarch64-simd.md (aarch64_fnegv2di2<vczle><vczbe>): New.
3051 * config/aarch64/aarch64.cc (aarch64_maybe_generate_simd_constant):
3052 Update call to gen_aarch64_fnegv2di2.
3053 * config/aarch64/iterators.md: New UNSPEC_FNEG.
3055 2024-08-08 Georg-Johann Lay <avr@gjlay.de>
3057 * config/avr/avr.cc (Mem_Insn::Mem_Insn): Don't consider MEMs
3058 that are avr_mem_memx_p or avr_load_libgcc_p.
3060 2024-08-08 Georg-Johann Lay <avr@gjlay.de>
3062 * doc/extend.texi (AVR Built-in Functions) <mask1>: Fix a typo.
3064 2024-08-08 Georg-Johann Lay <avr@gjlay.de>
3066 * config/avr/avr.cc (avr_insn_has_reg_unused_note_p): New function.
3067 (_reg_unused_after): Use it to recognize more cases.
3068 (avr_out_lpm_no_lpmx) [POST_INC]: Use reg_unused_after.
3070 2024-08-08 Andrew Stubbs <ams@baylibre.com>
3072 * config/gcn/gcn.cc (gcn_conditional_register_usage): Fix registers
3073 remaining after maximum allocation using TARGET_VGPR_GRANULARITY.
3075 2024-08-08 Christoph Müllner <christoph.muellner@vrull.eu>
3077 * config/riscv/constraints.md (th_m_noi): New constraint.
3078 * config/riscv/riscv.md: Adjust movdf_hardfloat_rv32 for
3081 2024-08-08 Christoph Müllner <christoph.muellner@vrull.eu>
3084 * config/riscv/thead.cc (th_memidx_classify_address_index):
3085 Recognize all possible XTheadMemIdx memory operand structures.
3086 (th_fmemidx_output_index): Do strict classification.
3087 * config/riscv/thead.md (*th_memidx_operand): Remove.
3088 (TARGET_XTHEADMEMIDX): Likewise.
3089 (TARGET_HARD_FLOAT && TARGET_XTHEADFMEMIDX): Likewise.
3090 (!TARGET_64BIT && TARGET_XTHEADMEMIDX): Likewise.
3091 (*th_memidx_I_a): Likewise.
3092 (*th_memidx_I_b): Likewise.
3093 (*th_memidx_I_c): Likewise.
3094 (*th_memidx_US_a): Likewise.
3095 (*th_memidx_US_b): Likewise.
3096 (*th_memidx_US_c): Likewise.
3097 (*th_memidx_UZ_a): Likewise.
3098 (*th_memidx_UZ_b): Likewise.
3099 (*th_memidx_UZ_c): Likewise.
3100 (*th_fmemidx_movsf_hardfloat): Likewise.
3101 (*th_fmemidx_movdf_hardfloat_rv64): Likewise.
3102 (*th_fmemidx_I_a): Likewise.
3103 (*th_fmemidx_I_c): Likewise.
3104 (*th_fmemidx_US_a): Likewise.
3105 (*th_fmemidx_US_c): Likewise.
3106 (*th_fmemidx_UZ_a): Likewise.
3107 (*th_fmemidx_UZ_c): Likewise.
3109 2024-08-08 Andrew Pinski <quic_apinski@quicinc.com>
3111 * tree-vect-patterns.cc (NUM_PATTERNS): Delete.
3112 (vect_pattern_recog_1): Constify and change
3113 recog_func to a reference.
3114 (vect_pattern_recog): Use range-based loop over
3115 vect_vect_recog_func_ptrs.
3117 2024-08-08 Jin Ma <jinma@linux.alibaba.com>
3119 * config/riscv/riscv.h (RISCV_DWARF_VLENB): Delete.
3121 2024-08-08 Andrew Stubbs <ams@baylibre.com>
3123 * config/gcn/gcn.cc (gcn_trampoline_init): Re-enable trampolines.
3125 2024-08-08 Jeff Law <jlaw@ventanamicro.com>
3128 * config/riscv/riscv.cc (riscv_rtx_costs): Ensure object is a
3129 comparison before looking at its arguments.
3131 2024-08-08 Manolis Tsamis <manolis.tsamis@vrull.eu>
3133 PR tree-optimization/98138
3134 * tree-vect-slp.cc: Avoid duplicates in two_operators nodes.
3136 2024-08-08 Roger Sayle <roger@nextmovesoftware.com>
3138 * config/i386/i386.cc (ix86_mode_can_transfer_bits): Use E_?Fmode
3139 enumeration constants in switch statement.
3141 2024-08-08 Surya Kumari Jangala <jskumari@linux.ibm.com>
3143 PR rtl-optimization/116028
3144 * lra-constraints.cc (split_reg): Spill register before call
3146 (latest_call_insn): New variable.
3147 (inherit_in_ebb): Track the latest call insn.
3149 2024-08-08 Jiawei <jiawei@iscas.ac.cn>
3151 * common/config/riscv/riscv-common.cc: New extension.
3152 * config/riscv/riscv.opt: New mask.
3154 2024-08-07 Iain Sandoe <iain@sandoe.co.uk>
3157 * config/darwin.h (SUBTARGET_DRIVER_SELF_SPECS): Add a spec for
3159 * config/darwin.opt: Handle weak_framework driver option.
3161 2024-08-07 Prathamesh Kulkarni <prathameshk@nvidia.com>
3165 * data-streamer-in.cc (streamer_read_poly_uint64): Remove code for
3166 streaming, and call poly_int_read_common instead.
3167 (streamer_read_poly_int64): Likewise.
3168 * data-streamer.cc (host_num_poly_int_coeffs): Conditionally define
3169 new variable if ACCEL_COMPILER is defined.
3170 * data-streamer.h (host_num_poly_int_coeffs): Declare.
3171 (poly_int_read_common): New function template.
3172 (bp_unpack_poly_value): Remove code for streaming and call
3173 poly_int_read_common instead.
3174 * lto-streamer-in.cc (lto_input_mode_table): Stream-in host
3175 NUM_POLY_INT_COEFFS into host_num_poly_int_coeffs if ACCEL_COMPILER
3177 * lto-streamer-out.cc (lto_write_mode_table): Stream out
3178 NUM_POLY_INT_COEFFS if offloading is enabled.
3179 * poly-int.h (MAX_NUM_POLY_INT_COEFFS_BITS): New macro.
3180 * tree-streamer-in.cc (lto_input_ts_poly_tree_pointers): Adjust
3181 streaming-in of poly_int.
3183 2024-08-07 Jakub Jelinek <jakub@redhat.com>
3186 * gimple-expr.cc (remove_suffix): Formatting fixes.
3187 (create_tmp_var_name): Don't call clean_symbol_name.
3188 * gimplify.cc (gimplify_init_constructor): When promoting automatic
3189 DECL_NAMELESS vars to static, don't preserve their DECL_NAME.
3191 2024-08-07 Julian Brown <julian@codesourcery.com>
3192 Tobias Burnus <tobias@baylibre.com>
3194 * builtins.def (DEF_GOMP_BUILTIN_COMPILER): Define
3195 DEF_GOMP_BUILTIN_COMPILER to handle the non-prefix version.
3196 * gimple-fold.cc (gimple_fold_builtin_omp_is_initial_device): New.
3197 (gimple_fold_builtin): Call it.
3198 * omp-builtins.def (BUILT_IN_OMP_IS_INITIAL_DEVICE): Define.
3199 * tree.cc (get_file_function_name): Support names for on-target
3200 constructor/destructor functions.
3202 2024-08-07 Carl Love <cel@linux.ibm.com>
3204 * config/rs6000/altivec.md (vs<SLDB_lr>db_<mode>): Change
3205 define_insn iterator to VEC_IC.
3206 * config/rs6000/rs6000-builtins.def (__builtin_altivec_vsldoi_v1ti,
3207 __builtin_vsx_xxsldwi_v1ti, __builtin_altivec_vsldb_v1ti,
3208 __builtin_altivec_vsrdb_v1ti): New builtin definitions.
3209 * config/rs6000/rs6000-overload.def (vec_sld, vec_sldb, vec_sldw,
3210 vec_sll, vec_slo, vec_srdb, vec_srl, vec_sro): New overloaded
3212 * doc/extend.texi (vec_sld, vec_sldb, vec_sldw, vec_sll, vec_slo,
3213 vec_srdb, vec_srl, vec_sro): Add documentation for new overloaded
3216 2024-08-07 Richard Biener <rguenther@suse.de>
3218 PR tree-optimization/116258
3219 * tree-vect-generic.cc (expand_vector_operations_1): Do not
3222 2024-08-07 Xi Ruoyao <xry111@xry111.site>
3223 Richard Biener <rguenther@suse.de>
3225 PR tree-optimization/116142
3226 * tree-vect-stmts.cc (supportable_widening_operation): Remove an
3227 redundant and incorrect vect_reduction_def check, and fix the
3228 operand of another vect_reduction_def check.
3230 2024-08-07 Richard Biener <rguenther@suse.de>
3232 PR tree-optimization/116166
3233 * tree-ssa-threadedge.h (jump_threader::thread_around_empty_blocks):
3234 Add limit parameter.
3235 (jump_threader::thread_through_normal_block): Likewise.
3236 * tree-ssa-threadedge.cc (jump_threader::thread_around_empty_blocks):
3237 Honor and decrement limit parameter.
3238 (jump_threader::thread_through_normal_block): Likewise.
3239 (jump_threader::thread_across_edge): Initialize limit from
3240 param_max_jump_thread_paths and pass it down to workers.
3242 2024-08-07 Pan Li <pan2.li@intel.com>
3245 * tree-vect-patterns.cc (vect_recog_sat_trunc_pattern): Add the
3246 type_has_mode_precision_p check for the lhs type.
3248 2024-08-07 Patrick Palka <ppalka@redhat.com>
3251 * diagnostic.cc (diagnostic_context::initialize): Set
3252 m_adjust_diagnostic_info.
3253 (diagnostic_context::report_diagnostic): Call
3254 m_adjust_diagnostic_info.
3255 * diagnostic.h (diagnostic_context::m_adjust_diagnostic_info):
3257 * doc/invoke.texi (-Wno-template-body): Document.
3258 (-fpermissive): Mention -Wtemplate-body.
3260 2024-08-06 David Malcolm <dmalcolm@redhat.com>
3263 * diagnostic-format-sarif.cc (sarif_invocation::prepare_to_flush):
3264 If the diagnostics would lead to us exiting with a failure code,
3265 then emit "executionSuccessful": False (SARIF v2.1.0 section
3267 * diagnostic.cc (diagnostic_context::execution_failed_p): New.
3268 * diagnostic.h (diagnostic_context::execution_failed_p): New decl.
3269 * toplev.cc (toplev::main): Use it for determining returned value.
3271 2024-08-06 Tamar Christina <tamar.christina@arm.com>
3273 * config/aarch64/aarch64-protos.h (struct sve_vec_cost): Add
3274 gather_load_x32_init_cost and gather_load_x64_init_cost.
3275 * config/aarch64/aarch64.cc (aarch64_vector_costs): Add
3276 m_sve_gather_scatter_init_cost.
3277 (aarch64_vector_costs::add_stmt_cost): Use them.
3278 (aarch64_vector_costs::finish_cost): Likewise.
3279 * config/aarch64/tuning_models/a64fx.h: Update.
3280 * config/aarch64/tuning_models/cortexx925.h: Update.
3281 * config/aarch64/tuning_models/generic.h: Update.
3282 * config/aarch64/tuning_models/generic_armv8_a.h: Update.
3283 * config/aarch64/tuning_models/generic_armv9_a.h: Update.
3284 * config/aarch64/tuning_models/neoverse512tvb.h: Update.
3285 * config/aarch64/tuning_models/neoversen2.h: Update.
3286 * config/aarch64/tuning_models/neoversen3.h: Update.
3287 * config/aarch64/tuning_models/neoversev1.h: Update.
3288 * config/aarch64/tuning_models/neoversev2.h: Update.
3289 * config/aarch64/tuning_models/neoversev3.h: Update.
3290 * config/aarch64/tuning_models/neoversev3ae.h: Update.
3292 2024-08-06 Gerald Pfeifer <gerald@pfeifer.com>
3294 * doc/gm2.texi (Limitations): Rephrase. Remove invalid link.
3296 2024-08-06 John David Anglin <danglin@gcc.gnu.org>
3299 * config/pa/pa.cc (hppa_legitimize_address): Add check to
3300 ensure constant is an integral multiple of shift the value.
3302 2024-08-06 Patrick O'Neill <patrick@rivosinc.com>
3304 * config/riscv/riscv-target-attr.cc (num_occurences_in_str): Rename...
3305 (num_occurrences_in_str): here.
3306 (riscv_process_target_attr): Update num_occurences_in_str callsite.
3307 * config/riscv/riscv-v.cc (emit_vec_widden_cvt_x_f): widden -> widen.
3308 (emit_vec_widen_cvt_x_f): Ditto.
3309 (emit_vec_widden_cvt_f_f): Ditto.
3310 (emit_vec_widen_cvt_f_f): Ditto.
3311 (emit_vec_rounding_to_integer): Update *widden* callsites.
3312 * config/riscv/riscv-vector-builtins.cc (expand_builtin): Update
3313 required_ext_to_isa_name callsite and fix xtheadvector typo.
3314 * config/riscv/riscv-vector-builtins.h (reqired_ext_to_isa_name): Rename...
3315 (required_ext_to_isa_name): here.
3316 * config/riscv/riscv_th_vector.h: Fix endif label.
3317 * config/riscv/vector-crypto.md: boardcast_scalar -> broadcast_scalar.
3318 * config/riscv/vector.md: Ditto.
3320 2024-08-06 Patrick O'Neill <patrick@rivosinc.com>
3322 * config/riscv/arch-canonicalize: Fix typos in comments.
3323 * config/riscv/autovec.md: Ditto.
3324 * config/riscv/riscv-avlprop.cc (avl_can_be_propagated_p): Ditto.
3325 (pass_avlprop::get_vlmax_ta_preferred_avl): Ditto.
3326 * config/riscv/riscv-modes.def (ADJUST_FLOAT_FORMAT): Ditto.
3328 * config/riscv/riscv-opts.h (TARGET_ZICOND_LIKE): Ditto.
3329 (enum rvv_vector_bits_enum): Ditto.
3330 * config/riscv/riscv-protos.h (enum insn_flags): Ditto.
3331 (enum insn_type): Ditto.
3332 * config/riscv/riscv-sr.cc (riscv_sr_match_epilogue): Ditto.
3333 * config/riscv/riscv-string.cc (expand_block_move): Ditto.
3334 * config/riscv/riscv-v.cc (rvv_builder::is_repeating_sequence): Ditto.
3335 (rvv_builder::single_step_npatterns_p): Ditto.
3336 (calculate_ratio): Ditto.
3337 (expand_const_vector): Ditto.
3338 (shuffle_merge_patterns): Ditto.
3339 (shuffle_compress_patterns): Ditto.
3340 (expand_select_vl): Ditto.
3341 * config/riscv/riscv-vector-builtins-functions.def (REQUIRED_EXTENSIONS): Ditto.
3342 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
3343 * config/riscv/riscv-vector-builtins.cc (function_builder::add_function): Ditto.
3344 (resolve_overloaded_builtin): Ditto.
3345 * config/riscv/riscv-vector-builtins.def (vbool1_t): Ditto.
3346 (vuint8m8_t): Ditto.
3347 (vuint16m8_t): Ditto.
3348 (vfloat16m8_t): Ditto.
3349 (unsigned_vector): Ditto.
3350 * config/riscv/riscv-vector-builtins.h (enum required_ext): Ditto.
3351 * config/riscv/riscv-vector-costs.cc (get_store_value): Ditto.
3352 (costs::analyze_loop_vinfo): Ditto.
3353 (costs::add_stmt_cost): Ditto.
3354 * config/riscv/riscv.cc (riscv_build_integer): Ditto.
3355 (riscv_vector_type_p): Ditto.
3356 * config/riscv/thead.cc (th_mempair_output_move): Ditto.
3357 * config/riscv/thead.md: Ditto.
3358 * config/riscv/vector-iterators.md: Ditto.
3359 * config/riscv/vector.md: Ditto.
3360 * config/riscv/zc.md: Ditto.
3362 2024-08-06 Roger Sayle <roger@nextmovesoftware.com>
3364 * config/i386/i386-expand.cc (ix86_expand_v2di_ashiftrt): New
3365 function refactored from define_expand ashrv2di3.
3366 * config/i386/i386-features.cc (general_scalar_to_vector_candidate_p)
3367 <case ASHIFTRT>: Handle like other shifts and rotates.
3368 * config/i386/i386-protos.h (ix86_expand_v2di_ashiftrt): Prototype.
3369 * config/i386/sse.md (ashrv2di3): Call ix86_expand_v2di_ashiftrt.
3370 (*ashrv2di3): New define_insn_and_split to enable creation by stv2
3371 pass, and splitting during split1 reusing ix86_expand_v2di_ashiftrt.
3373 2024-08-06 Patrick O'Neill <patrick@rivosinc.com>
3374 Jakub Jelinek <jakub@redhat.com>
3377 * config/riscv/riscv.cc (riscv_option_override): Fix url
3380 2024-08-06 Filip Kastl <fkastl@suse.cz>
3382 * gimple-ssa-sccopy.cc (class scc_copy_prop): New class.
3383 (replace_scc_by_value): Put into...
3384 (scc_copy_prop::replace_scc_by_value): ...scc_copy_prop.
3385 (sccopy_visit_op): Put into...
3386 (scc_copy_prop::visit_op): ...scc_copy_prop.
3387 (sccopy_propagate): Put into...
3388 (scc_copy_prop::propagate): ...scc_copy_prop.
3389 (init_sccopy): Replace by...
3390 (scc_copy_prop::scc_copy_prop): ...the construtor.
3391 (finalize_sccopy): Replace by...
3392 (scc_copy_prop::~scc_copy_prop): ...the destructor.
3393 (pass_sccopy::execute): Use scc_copy_prop.
3395 2024-08-06 Richard Biener <rguenther@suse.de>
3397 PR tree-optimization/116241
3398 * tree-vect-loop.cc (vect_create_epilog_for_reduction): Handle
3399 non-COND_EXPR nodes in SLP reduction chain following.
3401 2024-08-06 Jakub Jelinek <jakub@redhat.com>
3403 PR tree-optimization/116224
3404 * wide-int.cc (wi::mul_internal): If prec isn't multiple of
3405 HOST_BITS_PER_WIDE_INT, for need_overflow checking only look at
3406 the least significant prec bits starting with r[half_blocks_needed].
3408 2024-08-06 Richard Biener <rguenther@suse.de>
3410 PR middle-end/111821
3411 * expmed.cc (store_integral_bit_field): Terminate the
3412 word-wise copy loop when we get out of the destination
3413 and do a forward copy. Skip the word if it would be
3414 outside of the destination in case of a backward copy.
3416 2024-08-06 Haochen Gui <guihaoc@gcc.gnu.org>
3418 * config/rs6000/predicates.md (any_operand): Add const_vector.
3420 2024-08-06 Feng Xue <fxue@os.amperecomputing.com>
3422 PR tree-optimization/115228
3423 * tree-vect-data-refs.cc (vect_get_smallest_scalar_type): Add
3424 missed opcodes that involve widening operation.
3426 2024-08-06 Feng Xue <fxue@os.amperecomputing.com>
3428 PR tree-optimization/115707
3429 * tree-vect-patterns.cc (vect_look_through_possible_promotion): Allow
3430 unsigned-to-signed promotion.
3432 2024-08-06 Andrew Pinski <quic_apinski@quicinc.com>
3435 * config/sh/sh.cc (sh_recog_treg_set_expr): Don't call make_insn_raw,
3436 make the insn with a fake uid.
3438 2024-08-05 Patrick O'Neill <patrick@rivosinc.com>
3441 * config/riscv/riscv.cc (riscv_option_override): Add deprecation
3444 2024-08-05 Mark Harmstone <mark@harmstone.com>
3446 * dwarf2codeview.cc (get_type_num_const_type): Handle missing
3447 DW_AT_type attribute.
3448 (get_type_num_volatile_type): Likewise.
3450 2024-08-05 Jose E. Marchesi <jose.marchesi@oracle.com>
3452 * config/bpf/atomic.md ("atomic_add<AMO:mode>"): Remove insn.
3453 ("atomic_and<AMO:mode>"): Likewise
3454 ("atomic_or<AMO:mode>"): Likewise.
3455 ("atomic_xor<AMO:mode>"): Likewise.
3457 2024-08-05 Jennifer Schmitz <jschmitz@nvidia.com>
3459 * config/aarch64/aarch64.md (*and<mode>_compare0): Change attribute.
3461 2024-08-05 Filip Kastl <fkastl@suse.cz>
3463 * gimple-ssa-sccopy.cc: Move a misplaced comment.
3465 2024-08-05 Kyrylo Tkachov <ktkachov@nvidia.com>
3467 PR tree-optimization/116139
3468 * tree-ssa-reassoc.cc (get_reassociation_width): Move width_mult
3469 <= width comparison to if condition rather than assert.
3471 2024-08-05 Richard Sandiford <richard.sandiford@arm.com>
3474 2024-08-02 Richard Sandiford <richard.sandiford@arm.com>
3476 PR rtl-optimization/116145
3477 * rtlanal.cc (may_trap_p_1): Trust MEM_NOTRAP_P even for code
3478 movement if MEM_READONLY_P is also true.
3480 2024-08-05 Alex Coplan <alex.coplan@arm.com>
3482 * gdbhooks.py: Add attempted call to "on-gcc-hooks-load" once
3483 we've finished loading the hooks.
3485 2024-08-05 Alex Coplan <alex.coplan@arm.com>
3487 * gdbhooks.py (GCCDotCmd): New.
3488 (gcc_dot_cmd): New. Use it ...
3489 (DotFn.invoke): ... here.
3491 2024-08-05 Andrew Pinski <quic_apinski@quicinc.com>
3493 PR rtl-optimization/116179
3494 * ira.cc (split_live_ranges_for_shrink_wrap): For the uses loop,
3495 only look at non-debug insns.
3497 2024-08-04 Jeff Law <jlaw@ventanamicro.com>
3499 PR rtl-optimization/116199
3500 * reload.cc (operands_match_p): Verify subreg is expressable before
3501 trying to simplify and match it to another operand.
3503 2024-08-02 Marek Polacek <polacek@redhat.com>
3505 * doc/invoke.texi: Document that -Wdangling-reference is
3508 2024-08-02 Andrew Pinski <quic_apinski@quicinc.com>
3510 PR middle-end/116058
3511 * genemit.cc (struct clobber_pat): Change pattern to be rtvec.
3513 (gen_insn): Look through an explicit parallel if there was one.
3514 Update store to new clobber_pat.
3515 (output_add_clobbers): Update call to gen_exp for the changed
3518 2024-08-02 Patrick O'Neill <patrick@rivosinc.com>
3520 * config/riscv/sync-rvwmo.md: Add conditional length attributes.
3521 * config/riscv/sync-ztso.md: Ditto.
3522 * config/riscv/sync.md: Fix incorrect insn length attributes and
3523 reformat existing conditional checks.
3525 2024-08-02 Jennifer Schmitz <jschmitz@nvidia.com>
3527 * config/aarch64/aarch64.cc (aarch_macro_fusion_pair_p): Implement
3529 * config/aarch64/aarch64-fusion-pairs.def (cmp+csel): New entry.
3530 (cmp+cset): Likewise.
3531 * config/aarch64/tuning_models/neoversev2.h: Enable logic in
3534 2024-08-02 Richard Sandiford <richard.sandiford@arm.com>
3536 PR rtl-optimization/116145
3537 * rtlanal.cc (may_trap_p_1): Trust MEM_NOTRAP_P even for code
3538 movement if MEM_READONLY_P is also true.
3540 2024-08-02 Andrew Pinski <quic_apinski@quicinc.com>
3542 PR tree-optimization/116156
3543 * tree-ssa-forwprop.cc (pass_forwprop::execute): Don't add
3544 uses if the statement was a debug statement.
3546 2024-08-02 Lingling Kong <lingling.kong@intel.com>
3548 * config/i386/constraints.md: Fixed the comment/naming for je/jM/jO.
3549 * config/i386/predicates.md (apx_ndd_memory_operand): Renamed and
3551 (apx_evex_memory_operand): New name.
3552 (apx_ndd_add_memory_operand): Ditto.
3553 (apx_evex_add_memory_operand): Ditto.
3555 2024-08-02 Lingling Kong <lingling.kong@intel.com>
3557 * config/i386/i386.md (nf_mem_constraint): Fixed the constraint
3558 for the define_subst_attr.
3559 (nf_mem_constraint): Added new define_subst_attr.
3560 (*add<mode>_1<nf_name>): Fixed the constraint.
3562 2024-08-02 Yang Yujie <yangyujie@loongson.cn>
3564 * config/loongarch/genopts/gen-evolution.awk: Do not use
3565 "length()" to compute the size of an array.
3567 2024-08-02 Pengxuan Zheng <quic_pzheng@quicinc.com>
3570 * config/aarch64/aarch64-simd.md (popcount<mode>2): Add TARGET_SVE
3572 * config/aarch64/aarch64-sve.md (@aarch64_pred_<optab><mode>): Use new
3574 * config/aarch64/iterators.md (SVE_VDQ_I): New mode iterator.
3575 (VPRED): Add V8QI, V16QI, V4HI, V8HI and V2SI.
3577 2024-08-01 Robin Dapp <rdapp@ventanamicro.com>
3580 * config/riscv/vector.md: Fix mode_idx attribute of scalar
3581 widen add/sub variants.
3583 2024-08-01 Patrick O'Neill <patrick@rivosinc.com>
3586 * config/riscv/riscv.cc (riscv_option_override): Add error.
3588 2024-08-01 Tamar Christina <tamar.christina@arm.com>
3590 * config/aarch64/aarch64-cores.def (cortex-x925): New.
3591 * config/aarch64/aarch64-tune.md: Regenerate.
3592 * config/aarch64/tuning_models/cortexx925.h: New file.
3593 * config/aarch64/aarch64.cc: Use it.
3594 * doc/invoke.texi: Document it.
3596 2024-08-01 Tamar Christina <tamar.christina@arm.com>
3598 * config/aarch64/tuning_models/neoversen2.h: Update costs.
3600 2024-08-01 Tamar Christina <tamar.christina@arm.com>
3602 * config/aarch64/tuning_models/generic_armv9_a.h: Update costs.
3604 2024-08-01 Tamar Christina <tamar.christina@arm.com>
3606 * config/aarch64/aarch64-cores.def (neoverse-n3, cortex-a725): New.
3607 * config/aarch64/aarch64-tune.md: Regenerate.
3608 * config/aarch64/tuning_models/neoversen3.h: New file.
3609 * config/aarch64/aarch64.cc: Use it.
3610 * doc/invoke.texi: Document it.
3612 2024-08-01 Tamar Christina <tamar.christina@arm.com>
3614 * config/aarch64/aarch64-cores.def (neoverse-v3ae): New.
3615 * config/aarch64/aarch64-tune.md: Regenerate.
3616 * config/aarch64/tuning_models/neoversev3ae.h: New file.
3617 * config/aarch64/aarch64.cc: Use it.
3618 * doc/invoke.texi: Document it.
3620 2024-08-01 Tamar Christina <tamar.christina@arm.com>
3622 * config/aarch64/aarch64-cores.def (cortex-x4): Update.
3624 * config/aarch64/aarch64-tune.md: Regenerate.
3625 * config/aarch64/tuning_models/neoversev3.h: New file.
3626 * config/aarch64/aarch64.cc: Use it.
3627 * doc/invoke.texi: Document it.
3629 2024-08-01 Tamar Christina <tamar.christina@arm.com>
3631 * config/aarch64/aarch64-cores.def (cortex-x3): Use Neoverse-V2 costs.
3632 * config/aarch64/tuning_models/neoversev2.h: Update costs.
3634 2024-08-01 Andrew Pinski <quic_apinski@quicinc.com>
3636 PR tree-optimization/116120
3637 * match.pd (`(a ? x : y) eq/ne (b ? x : y)`): Add test for `x != y`
3639 (`(a ? x : y) eq/ne (b ? y : x)`): Add test for `x == y` in result.
3641 2024-08-01 liuhongt <hongtao.liu@intel.com>
3644 * config/i386/constraints.md (Wc): New constraint for integer
3646 * config/i386/i386.md (ashl<mode>3_doubleword): Refine
3649 2024-08-01 Richard Biener <rguenther@suse.de>
3651 PR tree-optimization/114659
3652 * tree-ssa-sccvn.cc (visit_reference_op_load): Do not
3653 prevent punning from modes with padding here, but ...
3654 (vn_reference_eq): ... ensure this here, also honoring
3655 types with modes that cannot act as bit container.
3657 2024-08-01 Richard Biener <rguenther@suse.de>
3659 * config/i386/i386.cc (TARGET_MODE_CAN_TRANSFER_BITS): Define.
3660 (ix86_mode_can_transfer_bits): New function.
3662 2024-08-01 Richard Biener <rguenther@suse.de>
3664 * target.def (mode_can_transfer_bits): New target hook.
3665 * target.h (mode_can_transfer_bits): New function wrapping the
3666 hook and providing default behavior.
3667 * doc/tm.texi.in: Update.
3668 * doc/tm.texi: Re-generate.
3670 2024-08-01 Georg-Johann Lay <avr@gjlay.de>
3672 * config/avr/avr.md (cbranch<mode>4_insn): Split to a test of the
3673 high part against 0 if possible.
3675 2024-08-01 Georg-Johann Lay <avr@gjlay.de>
3677 * config/avr/constraints.md (YMM): New constraint.
3678 * config/avr/avr.md (cmp<mode>3, *cmp<mode>3)
3679 (cbranch<mode>4_insn): Allow YMM where M is allowed.
3681 2024-08-01 Jakub Jelinek <jakub@redhat.com>
3684 * config/i386/sse.md
3685 (*<extract_type>_vinsert<shuffletype><extract_suf>_0): Swap the
3686 first two VEC_MERGE operands, renumber match_operands and test
3687 for 0xF or 0x3 rather than 0xFFF0 or 0xFC immediate.
3689 2024-08-01 Tobias Burnus <tburnus@baylibre.com>
3690 Richard Biener <rguenther@suse.de
3692 PR middle-end/115637
3693 * gimplify.cc (gimplify_body): Fix macro name in the comment.
3694 * omp-offload.cc (find_link_var_op): Rename to ...
3695 (process_link_var_op): ... this. Replace value expr.
3696 (pass_omp_target_link::execute): Update walk_gimple_stmt call.
3698 2024-08-01 Lingling Kong <lingling.kong@intel.com>
3699 Hu, Lin1 <lin1.hu@intel.com>
3702 * config/i386/i386.md (*add<mode>_4): Remove ndd support.
3705 2024-08-01 Mark Harmstone <mark@harmstone.com>
3707 * dwarf2codeview.cc (get_type_num_struct): Fix NULL pointer dereference.
3709 2024-08-01 David Malcolm <dmalcolm@redhat.com>
3711 * diagnostic-path.cc
3712 (thread_event_printer::print_swimlane_for_event_range): Gracefully
3713 handle logical_location::get_name_for_path_output returning null.
3715 2024-08-01 David Malcolm <dmalcolm@redhat.com>
3717 * diagnostic-format-sarif.cc
3718 (sarif_location_manager::worklist_item::unlabelled_secondary_location):
3720 (sarif_location_manager::m_unlabelled_secondary_locations): New
3722 (sarif_location_manager::process_worklist_item): Handle unlabelled
3723 secondary locations.
3724 (sarif_builder::make_location_object): Generalize code to handle
3725 ranges within a rich_location so as well as using annotations for
3726 those with labels, we now add related locations for those without
3729 2024-08-01 David Malcolm <dmalcolm@redhat.com>
3731 * diagnostic-format-sarif.cc (sarif_builder::sarif_builder): Assert
3732 that m_line_maps is nonnull.
3733 (diagnostic_output_format_init_sarif_stderr): Add "line_maps"
3734 param and pass to format ctor.
3735 (diagnostic_output_format_init_sarif_file): Likewise.
3736 (diagnostic_output_format_init_sarif_stream): Likewise.
3737 * diagnostic.cc (diagnostic_output_format_init): Pass "line_table"
3738 as line_maps param to the above.
3739 * diagnostic.h (diagnostic_output_format_init_sarif_stderr): Add
3741 (diagnostic_output_format_init_sarif_file): Likewise.
3742 (diagnostic_output_format_init_sarif_stream): Likewise.
3744 2024-08-01 David Malcolm <dmalcolm@redhat.com>
3746 * diagnostic-format-sarif.cc: Tweak ASCII art in comment
3747 to show edges for both directions in the digraph.
3749 2024-07-31 Andrew Pinski <quic_apinski@quicinc.com>
3751 PR middle-end/116134
3752 * match.pd (`(a ? x : y) eq/ne (b ? x : y)`): Check that
3753 a and b types match.
3754 (`(a ? x : y) eq/ne (b ? y : x)`): Likewise.
3756 2024-07-31 Jeff Law <jlaw@ventanamicro.com>
3758 * ext-dce.cc (carry_backpropagate): Change more guards of [U]INTVAL to
3759 test CONST_INT_P rather than CONSTANT_P, fixing rtl-checking failures.
3761 2024-07-31 Dimitar Dimitrov <dimitar@dinux.eu>
3763 * common/config/pru/pru-common.cc
3764 (TARGET_OPTION_OPTIMIZATION_TABLE): New definition.
3765 * config/pru/pru.cc (TARGET_MIN_ANCHOR_OFFSET): Set minimal
3767 (TARGET_MAX_ANCHOR_OFFSET): Set maximum anchor offset.
3769 2024-07-31 Jeff Law <jlaw@ventanamicro.com>
3771 PR rtl-optimization/116136
3772 * simplify-rtx.cc (simplify_context::simplify_subreg): Check
3773 that we're working with the lowpart offset rather than byte 0.
3775 2024-07-31 Claudio Bantaloukas <claudio.bantaloukas@arm.com>
3777 * config.gcc (extra_headers): Install arm_private_fp8.h.
3778 * config/aarch64/arm_neon.h: Include arm_private_fp8.h.
3779 * config/aarch64/arm_sve.h: Likewise.
3780 * config/aarch64/arm_private_fp8.h: New file
3781 (fpm_t): New type representing fpmr values.
3782 (enum __ARM_FPM_FORMAT): New enum representing valid fp8 formats.
3783 (enum __ARM_FPM_OVERFLOW): New enum representing how some fp8
3785 (__arm_fpm_init): New.
3786 (__arm_set_fpm_src1_format): Likewise.
3787 (__arm_set_fpm_src2_format): Likewise.
3788 (__arm_set_fpm_dst_format): Likewise.
3789 (__arm_set_fpm_overflow_cvt): Likewise.
3790 (__arm_set_fpm_overflow_mul): Likewise.
3791 (__arm_set_fpm_lscale): Likewise.
3792 (__arm_set_fpm_lscale2): Likewise.
3793 (__arm_set_fpm_nscale): Likewise.
3795 2024-07-31 Claudio Bantaloukas <claudio.bantaloukas@arm.com>
3797 * config/aarch64/aarch64.cc (aarch64_hard_regno_nregs): Add
3798 support for MOVEABLE_SYSREGS class.
3799 (aarch64_hard_regno_mode_ok): Allow reads and writes to fpmr.
3800 (aarch64_regno_regclass): Support MOVEABLE_SYSREGS class.
3801 (aarch64_class_max_nregs): Likewise.
3802 * config/aarch64/aarch64.h (FIXED_REGISTERS): add fpmr.
3803 (CALL_REALLY_USED_REGISTERS): Likewise.
3804 (REGISTER_NAMES): Likewise.
3805 (enum reg_class): Add MOVEABLE_SYSREGS class.
3806 (REG_CLASS_NAMES): Likewise.
3807 (REG_CLASS_CONTENTS): Update class bitmaps to deal with fpmr,
3808 the new MOVEABLE_REGS class and renumbering of registers.
3809 * config/aarch64/aarch64.md: (FPM_REGNUM): added new register
3810 number, reusing old value.
3811 (FFR_REGNUM): Renumber.
3812 (FFRT_REGNUM): Likewise.
3813 (LOWERING_REGNUM): Likewise.
3814 (TPIDR2_BLOCK_REGNUM): Likewise.
3815 (SME_STATE_REGNUM): Likewise.
3816 (TPIDR2_SETUP_REGNUM): Likewise.
3817 (ZA_FREE_REGNUM): Likewise.
3818 (ZA_SAVED_REGNUM): Likewise.
3819 (ZA_REGNUM): Likewise.
3820 (ZT0_REGNUM): Likewise.
3821 (*mov<mode>_aarch64): Add support for moveable sysregs.
3822 (*movsi_aarch64): Likewise.
3823 (*movdi_aarch64): Likewise.
3824 * config/aarch64/constraints.md (MOVEABLE_SYSREGS): New constraint.
3826 2024-07-31 Claudio Bantaloukas <claudio.bantaloukas@arm.com>
3828 * config/aarch64/aarch64-option-extensions.def (fp8): New.
3829 * config/aarch64/aarch64.h (TARGET_FP8): Likewise.
3830 * doc/invoke.texi (AArch64 Options): Document new -march flags
3833 2024-07-31 Xi Ruoyao <xry111@xry111.site>
3835 * config/loongarch/loongarch.md (UNSPEC_REVB_2H, UNSPEC_REVB_4H,
3836 UNSPEC_REVH_D): Remove UNSPECs.
3837 (revb_4h, revh_d): Remove define_insn.
3838 (revb_2h): Define as (rotatert:SI (bswap:SI x) 16) instead of
3840 (revb_2h_extend, revb_2w, *bswapsi2, bswapdi2): New define_insn.
3841 (bswapsi2): Change to define_expand. Only expand to revb.2h +
3842 rotri.w if !TARGET_64BIT.
3843 (bswapdi2): Change to define_insn of which the output is just a
3846 2024-07-31 Xi Ruoyao <xry111@xry111.site>
3848 * config/loongarch/predicates.md (ins_zero_bitmask_operand):
3849 Cover more cases that bstrins can benefit.
3850 (high_bitmask_operand): Remove.
3851 * config/loongarch/constraints.md (Yy): Remove.
3852 * config/loongarch/loongarch.md (and<mode>3_align): Remove.
3854 2024-07-31 Richard Biener <rguenther@suse.de>
3856 PR middle-end/101478
3857 * gimplify.cc (gimplify_addr_expr): Check we still have an
3858 ADDR_EXPR before calling recompute_tree_invariant_for_addr_expr.
3860 2024-07-31 Hongyu Wang <hongyu.wang@intel.com>
3863 * config/i386/i386.opt (munroll-only-small-loops): Mark as
3864 Optimization instead of Save.
3866 2024-07-31 Richard Sandiford <richard.sandiford@arm.com>
3868 PR rtl-optimization/115881
3869 * recog.cc: Include rtl-iter.h.
3870 (insn_propagation::apply_to_rvalue_1): Check that the result
3871 of simplify_subreg does not include nested subregs.
3873 2024-07-31 Kewen Lin <linkw@linux.ibm.com>
3876 * config/rs6000/rs6000.md (@extenddf<FLOAT128:mode>2): Don't check
3877 TARGET_LONG_DOUBLE_128 for FLOAT128_IEEE_P modes.
3878 (extendsf<FLOAT128:mode>2): Likewise.
3879 (trunc<FLOAT128:mode>df2): Likewise.
3880 (trunc<FLOAT128:mode>sf2): Likewise.
3881 (floatsi<FLOAT128:mode>2): Likewise.
3882 (fix_trunc<FLOAT128:mode>si2): Likewise.
3884 2024-07-31 Kewen Lin <linkw@linux.ibm.com>
3886 * config/rs6000/altivec.md (p9_vadu<mode>3): Rename to ...
3887 (uabd<mode>3): ... this. Update RTL pattern with umin and umax rather
3889 (vadu<mode>3): Remove.
3890 (UNSPEC_VADU): Remove.
3891 (usadv16qi): Replace gen_p9_vaduv16qi3 with gen_uabdv16qi3.
3892 (usadv8hi): Replace gen_p9_vaduv8hi3 with gen_uabdv8hi3.
3893 * config/rs6000/rs6000-builtins.def (__builtin_altivec_vadub): Replace
3894 expander with uabdv16qi3.
3895 (__builtin_altivec_vaduh): Adjust expander with uabdv8hi3.
3896 (__builtin_altivec_vaduw): Adjust expander with uabdv4si3.
3898 2024-07-31 Xi Ruoyao <xry111@xry111.site>
3900 * config/loongarch/loongarch.md (optab): Add (rotatert "rotr").
3901 (<optab:any_shift><mode>3, <optab:any_div><mode>3,
3902 sub<mode>3, rotr<mode>3, mul<mode>3): Add a "*" to the insn name
3903 so we can redefine the names with define_expand.
3904 (*<optab:any_shift>si3_extend): Remove "*" so we can use them
3906 (*subsi3_extended, *mulsi3_extended): Likewise, also remove the
3907 trailing "ed" for consistency.
3908 (*<optab:any_div>si3_extended): Add mode for sign_extend to
3909 prevent an ICE using it in expanders.
3910 (shift_w, arith_w): New define_code_iterator.
3911 (<optab:any_w><mode>3): New define_expand. Expand with
3912 <optab:any_w>si3_extend for SImode if TARGET_64BIT.
3913 (<optab:arith_w><mode>3): Likewise.
3914 (mul<mode>3): Expand to mulsi3_extended for SImode if
3915 TARGET_64BIT and ISA_HAS_DIV32.
3916 (<optab:any_div><mode>3): Expand to <optab:any_div>si3_extended
3917 for SImode if TARGET_64BIT.
3918 (rotl<mode>3): Expand to rotrsi3_extend for SImode if
3920 (bytepick_w_<bytepick_imm>): Add mode for lshiftrt and ashift.
3921 (bitsize, bytepick_imm, bytepick_w_ashift_amount): New
3923 (bytepick_w_<bytepick_imm>_extend): Adjust for the RTL change
3924 caused by 32-bit shift expanding. Now bytepick_imm only covers
3925 2 and 3, separate one remaining case to ...
3926 (bytepick_w_1_extend): ... here, new define_insn.
3928 2024-07-30 Edwin Lu <ewlu@rivosinc.com>
3930 * common/config/riscv/riscv-common.cc (riscv_subset_list::to_string):
3931 Skip b in march string
3932 * config.in: Regenerate.
3933 * configure: Regenerate.
3934 * configure.ac: Add B assembler check
3936 2024-07-30 Filip Kastl <fkastl@suse.cz>
3938 * tree-switch-conversion.cc (can_log2): New static function to
3939 check if gen_log2 can be used on current target.
3940 (gen_log2): New static function to generate efficient GIMPLE
3941 code for taking an exact base 2 log.
3942 (gen_pow2p): New static function to generate efficient GIMPLE
3943 code for checking if a value is a power of 2.
3944 (switch_conversion::switch_conversion): Track if the
3945 transformation happened.
3946 (switch_conversion::is_exp_index_transform_viable): New function
3947 to decide whether the transformation should be applied.
3948 (switch_conversion::exp_index_transform): New function to
3949 execute the transformation.
3950 (switch_conversion::gen_inbound_check): Don't remove the default
3951 BB if the transformation happened.
3952 (switch_conversion::expand): Execute the transform if it is
3953 viable. Skip the "sufficiently small case range" test if the
3954 transformation is going to be executed.
3955 * tree-switch-conversion.h: Add is_exp_index_transform_viable
3956 and exp_index_transform.
3958 2024-07-30 Gianluca Guida <gianluca@rivosinc.com>
3959 Patrick O'Neill <patrick@rivosinc.com>
3961 * common/config/riscv/riscv-common.cc: Add zacas extension.
3962 * config/riscv/arch-canonicalize: Make zacas imply zaamo.
3963 * config/riscv/riscv.opt: Add zacas.
3964 * config/riscv/sync.md (zacas_atomic_cas_value<mode>): New pattern.
3965 (atomic_compare_and_swap<mode>): Use new pattern for compare-and-swap ops.
3966 (zalrsc_atomic_cas_value_strong<mode>): Rename atomic_cas_value_strong.
3967 * doc/sourcebuild.texi: Add Zacas documentation.
3969 2024-07-30 Patrick O'Neill <patrick@rivosinc.com>
3971 * common/config/riscv/riscv-common.cc
3972 (riscv_subset_list::to_string): Remove zabha configure check
3973 handling and clarify zaamo/zalrsc comment.
3974 * config.in: Regenerate.
3975 * configure: Regenerate.
3976 * configure.ac: Remove zabha configure check.
3978 2024-07-30 Jennifer Schmitz <jschmitz@nvidia.com>
3980 * config/aarch64/aarch64-sve-builtins-base.cc (svdiv_impl::fold):
3981 Implement strength reduction.
3983 2024-07-30 Georg-Johann Lay <avr@gjlay.de>
3985 * doc/extend.texi (AVR Function Attributes): Propose to use
3986 attribute signal(n) via AVR-LibC's ISR_N from avr/interrupt.h
3988 2024-07-30 Pan Li <pan2.li@intel.com>
3990 * config/riscv/riscv.cc (riscv_expand_ussub): Promote to Xmode
3993 2024-07-30 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
3995 * config/xtensa/xtensa.cc (xtensa_insn_cost):
3996 Add a case statement for TYPE_FARITH.
3998 2024-07-30 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
4000 * config/xtensa/xtensa.md (movsf_internal):
4001 Reorder alternative that corresponds to L32R machine instruction,
4002 and prefix alternatives that correspond to LSI/SSI instructions
4003 with the constraint character '^' so that they are disparaged by
4006 2024-07-30 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
4008 * config/xtensa/xtensa-protos.h (xtensa_expand_call):
4009 Remove the third argument.
4010 * config/xtensa/xtensa.cc (xtensa_expand_call):
4011 Remove the third argument and the code that uses it.
4012 * config/xtensa/xtensa.md (call, call_value, sibcall, sibcall_value):
4013 Remove each Boolean constant specified in the third argument of
4015 (sibcall_epilogue): Add emitting '(use A0_REG)' after calling
4016 xtensa_expand_epilogue.
4018 2024-07-30 liuhongt <hongtao.liu@intel.com>
4021 * config/i386/constraints.md (Bk): Refine to
4022 define_special_memory_constraint.
4024 2024-07-30 Haochen Jiang <haochen.jiang@intel.com>
4026 * config/i386/prfchiintrin.h
4027 (_m_prefetchit0): Add macro for non-optimized option.
4028 (_m_prefetchit1): Ditto.
4030 2024-07-30 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
4032 * config/xtensa/predicates.md
4033 (fix_scaling_operand, float_scaling_operand): New predicates.
4034 * config/xtensa/xtensa.md
4035 (any_fix/m_fix/s_fix, any_float/m_float/s_float):
4036 New code iterators and their attributes.
4037 (fix<s_fix>_truncsfsi2): Change from "fix_truncsfsi2".
4038 (*fix<s_fix>_truncsfsi2_2x, *fix<s_fix>_truncsfsi2_scaled):
4039 New insn definitions.
4040 (float<s_float>sisf2): Change from "floatsisf2".
4041 (*float<s_float>sisf2_scaled): New insn definition.
4043 2024-07-30 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
4045 * config/xtensa/xtensa.cc
4046 (gen_int_relational, gen_float_relational): Replace tempvar-based
4047 value-swapping codes with std::swap.
4048 * config/xtensa/xtensa.md (movdi_internal, movdf_internal):
4051 2024-07-29 Jeff Law <jlaw@ventanamicro.com>
4054 * ext-dce.cc (carry_backpropagate): Fix test guarding UINTVAL
4055 extraction of shift count.
4057 2024-07-29 Jonathan Wakely <jwakely@redhat.com>
4059 * doc/invoke.texi (Diagnostic Message Formatting Options):
4060 Replace hyphen with a new sentence. Replace "the former" with
4063 2024-07-29 Max Filippov <jcmvbkbc@gmail.com>
4065 * config/xtensa/xtensa.cc (xtensa_option_override_after_change):
4067 (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define as
4068 xtensa_option_override_after_change.
4069 (xtensa_option_override): Call
4070 xtensa_option_override_after_change.
4072 2024-07-29 Georg-Johann Lay <avr@gjlay.de>
4074 * config/avr/avr.cc (avr_set_current_function): Fix typo in
4077 2024-07-29 Carl Love <cel@linux.ibm.com>
4079 * config/rs6000/vector.md: Add comment for the VEC_IC
4080 define_mode_iterator.
4082 2024-07-29 Pan Li <pan2.li@intel.com>
4084 * tree-ssa-math-opts.cc (math_opts_dom_walker::after_dom_children):
4085 Try .SAT_SUB for PLUS_EXPR case.
4087 2024-07-29 Jan Hubicka <hubicka@ucw.cz>
4090 * ipa-modref.cc (analyze_function): Do not ICE when flags regress.
4092 2024-07-29 Feng Xue <fxue@os.amperecomputing.com>
4094 * tree-vect-patterns.cc (vect_recog_bitfield_ref_pattern): Only call
4095 single_imm_use if statement is not generated from pattern recognition.
4097 2024-07-29 Haochen Jiang <haochen.jiang@intel.com>
4099 * config/i386/avx512dqintrin.h
4100 (_mm_mask_fpclass_ss_mask): Correct operand order.
4101 (_mm_mask_fpclass_sd_mask): Ditto.
4102 (_mm256_maskz_reduce_round_ss): Use __builtin_ia32_reducess_mask_round
4103 instead of __builtin_ia32_reducesd_mask_round.
4104 (_mm_reduce_round_sd): Use -1 as mask since it is non-mask.
4105 (_mm_reduce_round_ss): Ditto.
4106 * config/i386/avx512vlbwintrin.h
4107 (_mm256_mask_alignr_epi8): Correct operand usage.
4108 (_mm_mask_alignr_epi8): Ditto.
4109 * config/i386/avx512vlintrin.h (_mm_mask_alignr_epi64): Ditto.
4111 2024-07-28 Jonathan Wakely <jwakely@redhat.com>
4113 * exec-tool.in: Exit with an error if $original is empty.
4115 2024-07-28 Georg-Johann Lay <avr@gjlay.de>
4118 * config/avr/avr.h (machine_function) <is_noblock>: New field.
4119 * config/avr/avr-c.cc (avr_cpu_cpp_builtins) <__HAVE_SIGNAL_N__>: New
4121 * config/avr/avr.cc (avr_declare_function_name): New function.
4122 (avr_attribute_table) <noblock>: New function attribute>.
4123 <signal, interrupt>: Allow any number of args.
4124 (avr_insert_attributes): Check validity of "signal" and "interrupt"
4126 (avr_foreach_function_attribute, avr_interrupt_signal_function)
4127 (avr_isr_number, avr_asm_isr_alias, avr_handle_isr_attribute)
4128 (avr_noblock_function_p): New static functions.
4129 (avr_interrupt_function): New from avr_interrupt_function_p.
4131 (avr_signal_function): New from avr_signal_function_p.
4133 (avr_set_current_function): Only diagnose non-__vector ISR names
4134 when "signal" or "interrupt" attribute has no args. Set
4135 cfun->machine->is_noblock. Warn about "noblock" in non-ISR functions.
4136 (struct avr_fun_cookie): New.
4137 (avr_expand_prologue, avr_asm_function_end_prologue): Handle "noblock".
4138 * config/avr/elf.h (ASM_DECLARE_FUNCTION_NAME): New define.
4139 * config/avr/avr-protos.h (avr_declare_function_name): New proto.
4140 * doc/extend.texi (AVR Function Attributes): Document
4141 signal(num) and interrupt(num).
4142 * doc/invoke.texi (AVR Built-in Macros) <__HAVE_SIGNAL_N__>: Document.
4144 2024-07-27 Roger Sayle <roger@nextmovesoftware.com>
4145 Andrew Pinski <quic_apinski@quicinc.com>
4147 * match.pd (ctz (-X) => ctz (X)): New simplification.
4148 (ctz (abs (X)) => ctz (X)): Likewise.
4150 2024-07-27 Pan Li <pan2.li@intel.com>
4152 * match.pd: Add case 9 and case 10 for .SAT_SUB when one
4155 2024-07-27 David Malcolm <dmalcolm@redhat.com>
4157 PR middle-end/107941
4158 * diagnostic-format-sarif.cc: Define INCLUDE_LIST and INCLUDE_MAP.
4159 (enum class location_relationship_kind): New.
4160 (diagnostic_artifact_role::scanned_file): New value.
4161 (class sarif_location_manager): New.
4162 (class sarif_result): Derive from sarif_location_manager rather
4163 than directly from sarif_object.
4164 (sarif_result::add_related_location): Convert to vfunc
4166 (sarif_location::m_relationships_map): New field.
4167 (class sarif_location_relationship): New.
4168 (class sarif_ice_notification): Derive from sarif_location_manager
4169 rather than directly from sarif_object.
4170 (sarif_builder::take_current_result): New.
4171 (sarif_builder::m_line_maps): New field.
4172 (sarif_builder::m_cur_group_result): Convert to std::unique_ptr.
4173 (sarif_artifact::add_role): Skip scanned_file.
4174 (get_artifact_role_string): Handle scanned_file.
4175 (sarif_location_manager::add_relationship_to_worklist): New.
4176 (sarif_location_manager::process_worklist): New.
4177 (sarif_location_manager::process_worklist_item): New.
4178 (sarif_result::on_nested_diagnostic): Pass *this to
4179 make_location_object.
4180 (sarif_location::lazily_add_id): New.
4181 (sarif_location::get_id): New.
4182 (get_string_for_location_relationship_kind): New.
4183 (sarif_location::lazily_add_relationship): New.
4184 (sarif_location::lazily_add_relationship_object): New.
4185 (sarif_location::lazily_add_relationships_array): New.
4186 (sarif_ice_notification::sarif_ice_notification): Fix overlong line.
4187 Pass *this to make_locations_arr.
4188 (sarif_ice_notification::add_related_location): New.
4189 (sarif_location_relationship::sarif_location_relationship): New.
4190 (sarif_location_relationship::get_target_id): New.
4191 (sarif_location_relationship::lazily_add_kind): New.
4192 (sarif_builder::sarif_builder): Add "line_maps" param and use it
4193 to initialize m_line_maps.
4194 (sarif_builder::end_diagnostic): Update for m_cur_group_result
4195 becoming a std::unique_ptr. Don't append to m_results_array yet.
4196 (sarif_builder::end_group): Append m_cur_group_result to
4197 m_results_array here, rather than in end_diagnostic.
4198 (sarif_builder::make_result_object): Pass result_obj to
4199 make_locations_arr and to make_code_flow_object.
4200 (sarif_builder::make_locations_arr): Add "loc_mgr" param and pass
4201 it to make_location_object.
4202 (sarif_builder::make_location_object): For two overloads, add
4203 "loc_mgr" param and call add_any_include_chain on the location.
4204 (sarif_builder::add_any_include_chain): New.
4205 (sarif_builder::make_location_object): New overload.
4206 (sarif_builder::make_code_flow_object): Add "result" param and
4207 pass it to make_thread_flow_location_object.
4208 (sarif_builder::make_thread_flow_location_object): Add "result"
4209 param and pass it to make_location_object.
4210 (sarif_builder::get_or_create_artifact): Handle scanned_file.
4211 (sarif_output_format::~sarif_output_format): Assert that there
4212 isn't a pending result.
4213 (sarif_output_format::sarif_output_format): Add "line_maps" param
4214 and pass it to m_builder's ctor.
4215 (sarif_stream_output_format::sarif_stream_output_format): Add
4216 "line_maps" param and pass it to base class ctor.
4217 (sarif_file_output_format::sarif_file_output_format): Likewise.
4218 (diagnostic_output_format_init_sarif_stderr): Pass "line_table"
4220 (diagnostic_output_format_init_sarif_file): Likewise.
4221 (diagnostic_output_format_init_sarif_stream): Likewise.
4222 (test_sarif_diagnostic_context::test_sarif_diagnostic_context):
4224 (buffered_output_format::buffered_output_format): Likewise.
4225 (selftest::test_make_location_object): Likewise.
4226 (selftest::test_make_location_object): Create a sarif_result for
4227 use when calling make_location_object.
4228 * diagnostic.cc (diagnostic_context::finish): End any active
4230 (diagnostic_context::report_diagnostic): Assert that we're within
4232 * diagnostic.h (diagnostic_report_diagnostic): Add
4233 begin_group/end_group pair around call to
4234 diagnostic_context::report_diagnostic.
4235 * selftest-diagnostic.cc (test_diagnostic_context::report): Add
4236 begin_group/end_group pair around diagnostic_impl call.
4238 2024-07-26 Jeff Law <jlaw@ventanamicro.com>
4241 * config/riscv/bitmanip.md (minmax extension avoidance splitter):
4242 Rewrite as a simpler define_split. Adjust the opcode appropriately.
4243 Avoid emitting sign extension if it's clearly not needed.
4244 * config/riscv/iterators.md (minmax_optab): Rename to uminmax_optab
4245 and map everything to unsigned variants.
4247 2024-07-26 Siddhesh Poyarekar <siddhesh@gotplt.org>
4249 * gimple-ssa-sprintf.cc (format_string): Fix type in range check
4250 for UNLIKELY for wide chars.
4252 2024-07-26 Andrew Pinski <quic_apinski@quicinc.com>
4254 * config/aarch64/aarch64-sve-builtins-base.cc (svbic_impl::expand): Update
4255 to use andn optab instead of using code_for_aarch64_bic.
4256 * config/aarch64/aarch64-sve.md (@aarch64_bic<mode>): Rename to ...
4257 (andn<mode>3): This.
4259 2024-07-26 Andrew Pinski <quic_apinski@quicinc.com>
4261 * config/aarch64/aarch64.md (*<NLOGICAL:optab>_one_cmpl<mode>3): Rename to ...
4262 (<NLOGICAL:optab>n<mode>3): This.
4263 (*<NLOGICAL:optab>_one_cmplsidi3_ze): Rename to ...
4264 (*<NLOGICAL:optab>nsidi3_ze): This.
4266 2024-07-26 Andrew Pinski <quic_apinski@quicinc.com>
4268 * config/aarch64/aarch64-simd.md
4269 (bic<mode>3<vczle><vczbe>): Rename to ...
4270 (andn<mode>3<vczle><vczbe>): This. Also swap operands.
4271 (orn<mode>3<vczle><vczbe>): Rename to ...
4272 (iorn<mode>3<vczle><vczbe>): This. Also swap operands.
4273 (vec_cmp<mode><v_int_equiv>): Update orn call to iorn
4274 and swap the last two arguments.
4276 2024-07-26 Andrew Pinski <quic_apinski@quicinc.com>
4279 * config/aarch64/aarch64.opt (mearly-ra=): Mark as Optimization rather
4282 2024-07-26 Andrew Pinski <quic_apinski@quicinc.com>
4284 PR tree-optimization/116101
4285 * gimple-isel.cc (maybe_duplicate_comparison): Don't
4286 do anything for -O0 or -fno-tree-ter.
4288 2024-07-26 Andrew Pinski <quic_apinski@quicinc.com>
4290 * gimple-isel.cc (duplicate_comparison): Rename to ...
4291 (maybe_duplicate_comparison): This. Add check for use here
4292 rather than in its caller.
4293 (pass_gimple_isel::execute): Don't check how many uses the
4294 comparison had and call maybe_duplicate_comparison instead of
4295 duplicate_comparison.
4297 2024-07-26 Andrew Pinski <quic_apinski@quicinc.com>
4299 * gimple-isel.cc (pass_gimple_isel::execute): Factor out
4300 duplicate comparisons out to ...
4301 (duplicate_comparison): New function.
4303 2024-07-26 Andi Kleen <ak@gcc.gnu.org>
4306 * tree-tailcall.cc (find_tail_calls): Change tail call
4309 2024-07-26 Robin Dapp <rdapp@ventanamicro.com>
4311 * config/riscv/riscv.cc (riscv_override_options_internal):
4312 Reword error string without apostrophe.
4314 2024-07-26 Tamar Christina <tamar.christina@arm.com>
4317 * tree-vect-patterns.cc (vect_recog_cond_store_pattern): Check vector mode.
4319 2024-07-26 Haochen Jiang <haochen.jiang@intel.com>
4321 * config/i386/i386-expand.cc (ix86_expand_builtin): Change
4322 from XImode to BLKmode.
4323 * config/i386/i386.md (ldtilecfg): Change XI to BLK.
4326 2024-07-26 Nathaniel Shead <nathanieloshead@gmail.com>
4329 * tree.h (put_warning_spec_at): Declare new function.
4330 (has_warning_spec): Likewise.
4331 (get_warning_spec): Likewise.
4332 (put_warning_spec): Likewise.
4333 * diagnostic-spec.h (nowarn_spec_t::from_bits): New function.
4334 * diagnostic-spec.cc (put_warning_spec_at): New function.
4335 * warning-control.cc (has_warning_spec): New function.
4336 (get_warning_spec): New function.
4337 (put_warning_spec): New function.
4339 2024-07-25 Carl Love <cel@linux.ibm.com>
4341 * config/rs6000/rs6000-builtin.cc (get_element_number,
4342 altivec_expand_vec_set_builtin): Remove functions.
4343 (rs6000_expand_builtin): Remove the if statement to call
4344 altivec_expand_vec_set_builtin.
4345 * config/rs6000/rs6000-builtins.def (__builtin_vsx_set_1ti,
4346 __builtin_vsx_set_2df, __builtin_vsx_set_2di): Remove the
4347 built-in definitions.
4348 * config/rs6000/rs6000-gen-builtins.cc (struct attrinfo):
4349 Remove the isset variable from the structure.
4350 (parse_bif_attrs): Remove the uses of the isset variable.
4352 2024-07-25 Carl Love <cel@linux.ibm.com>
4354 * config/rs6000/rs6000-builtins.def (__builtin_vec_set_v1ti,
4355 __builtin_vec_set_v2df, __builtin_vec_set_v2di): Remove built-in
4357 * config/rs6000/rs6000-c.cc (resolve_vec_insert): Remove the
4358 handling for constant vec_insert position with
4359 VECTOR_UNIT_VSX_P V1TImode, V2DFmode and V2DImode modes.
4361 2024-07-25 Carl Love <cel@linux.ibm.com>
4363 * config/rs6000/rs6000-builtins.def (__builtin_vsx_xvcmpeqsp,
4364 __builtin_vsx_xvcmpgesp, __builtin_vsx_xvcmpgtsp): Remove
4367 2024-07-25 Jeff Law <jlaw@ventanamicro.com>
4369 PR rtl-optimization/116039
4370 * ext-dce.cc (ext_dce_process_uses): Add some comments about concerns
4371 with current code. Mark additional bit groups as live when we have
4372 an extension of a suitably promoted subreg.
4374 2024-07-25 Christoph Müllner <christoph.muellner@vrull.eu>
4377 * config/riscv/thead.cc (th_memidx_classify_address_modify):
4380 2024-07-25 Richard Biener <rguenther@suse.de>
4382 PR tree-optimization/116083
4383 * tree-vect-slp.cc (vect_build_slp_tree): Do not allocate
4384 a discovery fail node when we reached the discovery limit.
4385 (vect_build_slp_instance): Terminate early when the
4386 discovery limit is reached.
4388 2024-07-25 Richard Sandiford <richard.sandiford@arm.com>
4390 * doc/rtl.texi: Document the need to define INCLUDE_ARRAY before
4391 including rtl-ssa.h.
4392 * rtl-ssa.h: Likewise (in comment).
4393 * config/aarch64/aarch64-cc-fusion.cc: Add INCLUDE_ARRAY.
4394 * config/aarch64/aarch64-early-ra.cc: Likewise.
4395 * config/riscv/riscv-avlprop.cc: Likewise.
4396 * config/riscv/riscv-vsetvl.cc: Likewise.
4397 * fwprop.cc: Likewise.
4398 * late-combine.cc: Likewise.
4399 * pair-fusion.cc: Likewise.
4400 * rtl-ssa/accesses.cc: Likewise.
4401 * rtl-ssa/blocks.cc: Likewise.
4402 * rtl-ssa/changes.cc: Likewise.
4403 * rtl-ssa/functions.cc: Likewise.
4404 * rtl-ssa/insns.cc: Likewise.
4405 * rtl-ssa/movement.cc: Likewise.
4407 2024-07-25 Sam James <sam@gentoo.org>
4409 PR middle-end/114855
4410 * doc/invoke.texi (Optimize options): Mention machine-generated
4413 2024-07-25 Richard Biener <rguenther@suse.de>
4415 PR tree-optimization/116081
4416 * tree-vect-loop.cc (get_initial_defs_for_reduction):
4417 Use operand_equal_p for comparing the element with the
4420 2024-07-25 Richard Biener <rguenther@suse.de>
4422 PR tree-optimization/116079
4423 * tree-ssa-loop-im.cc (hoist_memory_references): Clear
4424 VDEF of elided clobbers.
4426 2024-07-25 Richard Biener <rguenther@suse.de>
4428 PR tree-optimization/116081
4429 * tree-vect-stmts.cc (vect_get_vector_types_for_stmt):
4430 Properly compare types.
4432 2024-07-25 Robin Dapp <rdapp@ventanamicro.com>
4435 * config/riscv/riscv.cc (riscv_override_options_internal): Error
4436 with TARGET_VECTOR && !TARGET_MUL.
4438 2024-07-25 Juzhe-Zhong <juzhe.zhong@rivai.ai>
4440 * config/riscv/riscv.cc (riscv_legitimize_move): Fix poly_int dest generation.
4442 2024-07-25 Richard Sandiford <richard.sandiford@arm.com>
4444 PR rtl-optimization/116044
4445 * rtl-ssa/functions.h (function_info::split_clobber_group): Return
4446 an array of two clobber_groups.
4447 * rtl-ssa/accesses.cc (function_info::split_clobber_group): Return
4448 the new clobber groups. Don't modify the splay tree here.
4449 (function_info::add_def): Update call accordingly. Generalize
4450 the splay tree insertion code so that the new definition can be
4451 inserted as a child of any existing node, not just the root.
4452 Fix the insertion used after calling split_clobber_group.
4454 2024-07-25 Jennifer Schmitz <jschmitz@nvidia.com>
4456 * config/aarch64/aarch64-sve-builtins.cc
4457 (gimple_folder::redirect_call): Update return type.
4458 * config/aarch64/aarch64-sve-builtins.h: Likewise.
4459 * config/aarch64/aarch64-sve-builtins-sve2.cc (svqshl_impl::fold):
4460 Remove cast to gcall.
4461 (svrshl_impl::fold): Likewise.
4463 2024-07-25 Richard Biener <rguenther@suse.de>
4465 * tree-ssa-structalias.cc (constraint_equal): Take const
4466 reference to constraints.
4467 (constraint_vec_find): Similar.
4468 (solve_graph): Keep constraint vector sorted and verify
4469 sorting with checking.
4471 2024-07-25 Lingling Kong <lingling.kong@intel.com>
4474 * config/i386/x86-tune-costs.h (struct processor_costs):
4475 Adjust rtx_cost of imulq and imulw for COST_N_INSNS (4)
4476 to COST_N_INSNS (3).
4478 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4480 * diagnostic-format-sarif.cc (sarif_builder::make_locations_arr):
4481 Don't add entirely empty location objects, such as for
4483 (test_sarif_diagnostic_context::test_sarif_diagnostic_context):
4484 Add param "main_input_filename".
4485 (selftest::test_simple_log): Provide above param. Verify that
4486 "locations" is empty.
4487 (selftest::test_simple_log_2): New.
4488 (selftest::diagnostic_format_sarif_cc_tests): Call it.
4490 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4492 * diagnostic-format-sarif.cc (sarif_builder::flush_to_object):
4493 New, using code moved from...
4494 (sarif_builder::end_group): ...here.
4495 (class selftest::test_sarif_diagnostic_context): New.
4496 (selftest::test_simple_log): New.
4497 (selftest::diagnostic_format_sarif_cc_tests): Call it.
4498 * json.h (json::object::is_empty): New.
4499 * selftest-diagnostic.cc (test_diagnostic_context::report): New.
4500 * selftest-diagnostic.h (test_diagnostic_context::report): New
4502 * selftest-json.cc (selftest::assert_json_string_eq): New.
4503 (selftest::expect_json_object_with_string_property): New.
4504 (selftest::assert_json_string_property_eq): New.
4505 * selftest-json.h (selftest::assert_json_string_eq): New decl.
4506 (ASSERT_JSON_STRING_EQ): New macro.
4507 (selftest::expect_json_object_with_string_property): New decl.
4508 (EXPECT_JSON_OBJECT_WITH_STRING_PROPERTY): New macro.
4510 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4512 * diagnostic-format-sarif.cc
4513 (sarif_builder::make_location_object): Add "annotations" property if
4514 there are any labelled ranges (§3.28.6).
4515 (selftest::test_make_location_object): Verify annotations are added
4517 * json.h (json::array::size): New.
4518 (json::array::operator[]): New.
4520 (selftest::expect_json_object_with_array_property): New.
4522 (selftest::expect_json_object_with_array_property): New decl.
4523 (EXPECT_JSON_OBJECT_WITH_ARRAY_PROPERTY): New macro.
4525 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4527 * diagnostic-format-sarif.cc
4528 (make_date_time_string_for_current_time): New.
4529 (sarif_invocation::sarif_invocation): Set "startTimeUtc"
4530 property (§3.20.7).
4531 (sarif_invocation::prepare_to_flush): Set "endTimeUtc"
4532 property (§3.20.8).
4534 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4536 * diagnostic-format-sarif.cc (sarif_invocation::sarif_invocation):
4537 Add "original_argv" param and use it to populate "arguments"
4538 property (§3.20.2).
4539 (sarif_builder::sarif_builder): Pass argv to m_invocation_obj's
4541 * diagnostic.cc (diagnostic_context::initialize): Initialize
4543 (diagnostic_context::finish): Clean up m_original_argv.
4544 (diagnostic_context::set_original_argv): New.
4545 * diagnostic.h: Include "unique-argv.h".
4546 (diagnostic_context::set_original_argv): New decl.
4547 (diagnostic_context::get_original_argv): New decl.
4548 (diagnostic_context::m_original_argv): New field.
4549 * toplev.cc: Include "unique-argv.h".
4550 (general_init): Add "original_argv" param and move it to global_dc.
4551 (toplev::main): Stash a copy of the original argv before expansion,
4552 and pass it to general_init for use by SARIF output.
4553 * unique-argv.h: New file.
4555 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4557 * diagnostic-format-sarif.cc
4558 (sarif_builder::make_artifact_location_object): Make public.
4559 (sarif_invocation::sarif_invocation): Add param "builder".
4560 Use it to potentially populate the "workingDirectory" property
4561 with the result of pwd (§3.20.19).
4562 (sarif_builder::sarif_builder): Pass *this to m_invocation_obj's
4565 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4567 * text-range-label.h: New file, taking class text_range_label from
4568 gcc-rich-location.h.
4570 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4572 * Makefile.in (OBJS-libcommon): Add selftest-json.o.
4573 * diagnostic-format-sarif.cc: Include "selftest.h",
4574 "selftest-diagnostic.h", "selftest-diagnostic-show-locus.h",
4575 "selftest-json.h", and "text-range-label.h".
4576 (class content_renderer): New.
4577 (sarif_builder::m_rules_arr): Convert to std::unique_ptr.
4578 (sarif_builder::make_location_object): Add class
4579 escape_nonascii_renderer. If rich_loc.escape_on_output_p (),
4580 pass a nonnull escape_nonascii_renderer to
4581 maybe_make_physical_location_object as its snippet_renderer, and
4582 add a property bag property "gcc/escapeNonAscii" to the SARIF
4583 location object. For other overloads of make_location_object,
4584 pass nullptr for the snippet_renderer.
4585 (sarif_builder::maybe_make_region_object_for_context): Add
4586 "snippet_renderer" param and pass it to
4587 maybe_make_artifact_content_object.
4588 (sarif_builder::make_tool_object): Drop "const".
4589 (sarif_builder::make_driver_tool_component_object): Likewise.
4590 Use typesafe unique_ptr variant of object::set for setting "rules"
4591 property on driver_obj.
4592 (sarif_builder::maybe_make_artifact_content_object): Add param "r"
4593 and use it to potentially set the "rendered" property (§3.3.4).
4594 (selftest::test_make_location_object): New.
4595 (selftest::diagnostic_format_sarif_cc_tests): New.
4596 * diagnostic-show-locus.cc: Include "text-range-label.h" and
4597 "selftest-diagnostic-show-locus.h".
4598 (selftests::diagnostic_show_locus_fixture::diagnostic_show_locus_fixture):
4600 (selftests::test_layout_x_offset_display_utf8): Use
4601 diagnostic_show_locus_fixture to simplify and consolidate setup
4603 (selftests::test_diagnostic_show_locus_one_liner): Likewise.
4604 (selftests::test_one_liner_colorized_utf8): Likewise.
4605 (selftests::test_diagnostic_show_locus_one_liner_utf8): Likewise.
4606 * gcc-rich-location.h (class text_range_label): Move to new file
4608 * selftest-diagnostic-show-locus.h: New file, based on material in
4609 diagnostic-show-locus.cc.
4610 * selftest-json.cc: New file.
4611 * selftest-json.h: New file.
4612 * selftest-run-tests.cc (selftest::run_tests): Call
4613 selftest::diagnostic_format_sarif_cc_tests.
4614 * selftest.h (selftest::diagnostic_format_sarif_cc_tests): New decl.
4616 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4618 * diagnostic-format-json.cc: Include "make-unique.h".
4619 (json_output_format::m_toplevel_array): Convert to
4621 (json_output_format::json_output_format): Update accordingly.
4622 (json_output_format::~json_output_format): Remove manual
4624 (json_from_expanded_location): Convert return type to
4626 (json_from_location_range): Likewise. Use nullptr rather than
4628 (json_from_fixit_hint): Convert return type to std::unique_ptr.
4629 (json_from_metadata): Likewise.
4630 (make_json_for_path): Likewise.
4631 (json_output_format::on_end_diagnostic): Use std::unique_ptr
4633 (json_file_output_format::~json_file_output_format): Use nullptr.
4634 (selftest::test_unknown_location): Update to use std::unique_ptr.
4635 (selftest::test_bad_endpoints): Likewise. Replace NULL with
4638 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4640 * diagnostic-format-sarif.cc: Include "make-unique.h". Convert
4641 raw pointers to std::unique_ptr throughout to indicate ownership,
4642 adding comments in the few places where pointers are borrowed.
4643 Use typesafe unique_ptr variants of json::object::set and
4644 json::array::append throughout to make types of properties more
4645 explicit, whilst using "auto" to reduce typing.
4646 Use "nullptr" rather than "NULL" throughout.
4647 * diagnostic-format-sarif.h (make_sarif_logical_location_object):
4648 Use std::unique_ptr for return type.
4650 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4652 * diagnostic-format-json.cc: Define INCLUDE_MEMORY.
4653 * diagnostic-format-sarif.cc: Likewise.
4654 * dumpfile.cc: Likewise.
4655 * gcov.cc: Likewise.
4656 * json.cc: Likewise. Include "make-unique.h".
4657 (selftest::test_formatting): Exercise overloads of
4658 array::append and object::set that use unique_ptr.
4659 * json.h: Require INCLUDE_MEMORY to have been defined.
4660 (json::object::set): Add a template to add a family of overloads
4661 taking a std::unique_ptr<JsonType>
4662 (json::array::append): Likewise.
4663 * optinfo-emit-json.cc: Define INCLUDE_MEMORY.
4664 * optinfo.cc: Likewise.
4665 * timevar.cc: Likewise.
4666 * toplev.cc: Likewise.
4667 * tree-diagnostic-client-data-hooks.cc: Likewise.
4669 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4671 * diagnostic-format-json.cc (json_from_expanded_location): Make
4672 "static". Pass param "context" by reference, as it cannot be null.
4673 (json_from_location_range): Likewise for param "context".
4674 (json_from_fixit_hint): Likewise.
4675 (make_json_for_path): Likewise.
4676 (json_output_format::on_end_diagnostic): Update for above changes.
4677 (diagnostic_output_format_init_json::diagnostic_output_format_init_json):
4678 Pass param "context" by reference, as it cannot be null.
4679 (diagnostic_output_format_init_json_stderr): Likewise.
4680 (diagnostic_output_format_init_json_file): Likewise.
4681 (selftest::test_unknown_location): Update for above changes.
4682 (selftest::test_bad_endpoints): Likewise.
4683 * diagnostic-format-sarif.cc (sarif_builder::m_context): Convert
4684 from pointer to reference.
4685 (sarif_invocation::add_notification_for_ice): Convert both params
4686 from pointers to references.
4687 (sarif_invocation::prepare_to_flush): Likewise for "context".
4688 (sarif_result::on_nested_diagnostic): Likewise for "context" and
4690 (sarif_result::on_diagram): Likewise.
4691 (sarif_ice_notification::sarif_ice_notification): Likewise.
4692 (sarif_builder::sarif_builder): Likewise for "context".
4693 (sarif_builder::end_diagnostic): Likewise.
4694 (sarif_builder::emit_diagram): Likewise.
4695 (sarif_builder::make_result_object): Likewise.
4696 (make_reporting_descriptor_object_for_warning): Likewise.
4697 (sarif_builder::make_locations_arr): Update for change to m_context.
4698 (sarif_builder::get_sarif_column): Likewise.
4699 (sarif_builder::make_message_object_for_diagram): Convert "context"
4700 from pointer to reference.
4701 (sarif_builder::make_tool_object): Likewise for "m_context".
4702 (sarif_builder::make_driver_tool_component_object): Likewise.
4703 (sarif_builder::get_or_create_artifact): Likewise.
4704 (sarif_builder::maybe_make_artifact_content_object): Likewise.
4705 (sarif_builder::get_source_lines): Likewise.
4706 (sarif_output_format::on_end_diagnostic): Update for above changes.
4707 (sarif_output_format::on_diagram): Likewise.
4708 (sarif_output_format::sarif_output_format): Likewise.
4709 (diagnostic_output_format_init_sarif): Convert param "context"
4710 from pointer to reference.
4711 (diagnostic_output_format_init_sarif_stderr): Likewise.
4712 (diagnostic_output_format_init_sarif_file): Likewise.
4713 (diagnostic_output_format_init_sarif_stream): Likewise.
4714 * diagnostic.cc (diagnostic_output_format_init): Likewise.
4715 * diagnostic.h (diagnostic_output_format_init): Likewise.
4716 (diagnostic_output_format_init_json_stderr): Likewise.
4717 (diagnostic_output_format_init_json_file): Likewise.
4718 (diagnostic_output_format_init_sarif_stderr): Likewise.
4719 (diagnostic_output_format_init_sarif_file): Likewise.
4720 (diagnostic_output_format_init_sarif_stream): Likewise.
4721 (json_from_expanded_location): Delete decl.
4722 * gcc.cc (driver_handle_option): Update for change to
4723 diagnostic_output_format_init.
4724 * opts.cc (common_handle_option): Likewise.
4726 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4728 * diagnostic-format-sarif.cc: Introduce subclasses of sarif_object
4729 for all aspects of the spec that we're using. Replace almost all
4730 usage of json::object with uses of these subclasses, the only
4731 remaining use of json::object being for originalUriBaseIds, as per
4732 SARIF 2.1.0 §3.14.14. This stronger typing makes it considerably
4733 easier to maintain validity against the schema.
4734 * diagnostic-format-sarif.h (class sarif_logical_location): New.
4735 (make_sarif_logical_location_object): Convert return type from
4736 json::object * to sarif_logical_location *.
4738 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4740 * gcov.cc (output_intermediate_json_line): Use
4741 json::object::set_integer to avoid naked "new".
4743 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4745 * diagnostic-format-sarif.cc (sarif_artifact::populate_roles):
4746 Avoid naked "new" by using json::array::append_string.
4747 (sarif_builder::maybe_make_kinds_array): Likewise.
4748 * json.cc (json::array::append_string): New.
4749 (selftest::test_writing_arrays): Use it.
4750 * json.h (json::array::append_string): New decl.
4751 * optinfo-emit-json.cc (optrecord_json_writer::pass_to_json):
4752 Avoid naked "new" by using json::array::append_string.
4753 (optrecord_json_writer::optinfo_to_json): Likewise.
4755 2024-07-24 David Malcolm <dmalcolm@redhat.com>
4757 * json.cc (value::dump): New overload, taking no params.
4758 * json.h (value::dump): New decl.
4760 2024-07-24 Jeff Law <jlaw@ventanamicro.com>
4762 PR rtl-optimization/116037
4763 * ext-dce.cc (ext_dce_process_sets): Note if we ever skip a dest
4764 and return that info explicitly.
4765 (ext_dce_process_uses): If a set was skipped, then consider all bits
4766 in every input as live. Do not try to optimize away an extension if
4767 we skipped processing a destination in the same insn. Restore code
4768 to make shift/rotate count fully live.
4769 (ext_dce_process_bb): Handle API changes for ext_dce_process_sets.
4771 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4773 * common/config/aarch64/aarch64-common.cc
4774 (aarch64_set_asm_isa_flags): Store a second uint64_t value.
4775 * config/aarch64/aarch64-opts.h
4776 (aarch64_feature_flags): Switch typedef to bbitmap<2>.
4777 * config/aarch64/aarch64.cc
4778 (aarch64_set_current_function): Extract isa mode from val[0].
4779 * config/aarch64/aarch64.h
4780 (aarch64_get_asm_isa_flags): Load a second uint64_t value.
4781 (aarch64_get_isa_flags): Ditto.
4782 (aarch64_asm_isa_flags): Ditto.
4783 (aarch64_isa_flags): Ditto.
4784 (HANDLE): Use bbitmap<2>::from_index to initialise flags.
4785 (AARCH64_FL_ISA_MODES): Do arithmetic on integer type.
4786 (AARCH64_ISA_MODE): Extract value from bbitmap<2> array.
4787 * config/aarch64/aarch64.opt
4788 (aarch64_asm_isa_flags_1): New variable.
4789 (aarch64_isa_flags_1): Ditto.
4791 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4793 * bbitmap.h: New file.
4795 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4797 * config/aarch64/aarch64-feature-deps.h
4798 (get_flags_off): Construct aarch64_feature_flags (0) explicitly.
4800 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4802 * config/aarch64/aarch64-c.cc
4803 (aarch64_define_unconditional_macros): Use TARGET_V8R macro.
4804 (aarch64_update_cpp_builtins): Use TARGET_* macros.
4805 * config/aarch64/aarch64.h (AARCH64_HAVE_ISA): New macro.
4806 (AARCH64_ISA_SM_OFF, AARCH64_ISA_SM_ON, AARCH64_ISA_ZA_ON)
4807 (AARCH64_ISA_V8A, AARCH64_ISA_V8_1A, AARCH64_ISA_CRC)
4808 (AARCH64_ISA_FP, AARCH64_ISA_SIMD, AARCH64_ISA_LSE)
4809 (AARCH64_ISA_RDMA, AARCH64_ISA_V8_2A, AARCH64_ISA_F16)
4810 (AARCH64_ISA_SVE, AARCH64_ISA_SVE2, AARCH64_ISA_SVE2_AES)
4811 (AARCH64_ISA_SVE2_BITPERM, AARCH64_ISA_SVE2_SHA3)
4812 (AARCH64_ISA_SVE2_SM4, AARCH64_ISA_SME, AARCH64_ISA_SME_I16I64)
4813 (AARCH64_ISA_SME_F64F64, AARCH64_ISA_SME2, AARCH64_ISA_V8_3A)
4814 (AARCH64_ISA_DOTPROD, AARCH64_ISA_AES, AARCH64_ISA_SHA2)
4815 (AARCH64_ISA_V8_4A, AARCH64_ISA_SM4, AARCH64_ISA_SHA3)
4816 (AARCH64_ISA_F16FML, AARCH64_ISA_RCPC, AARCH64_ISA_RCPC8_4)
4817 (AARCH64_ISA_RNG, AARCH64_ISA_V8_5A, AARCH64_ISA_TME)
4818 (AARCH64_ISA_MEMTAG, AARCH64_ISA_V8_6A, AARCH64_ISA_I8MM)
4819 (AARCH64_ISA_F32MM, AARCH64_ISA_F64MM, AARCH64_ISA_BF16)
4820 (AARCH64_ISA_SB, AARCH64_ISA_RCPC3, AARCH64_ISA_V8R)
4821 (AARCH64_ISA_PAUTH, AARCH64_ISA_V8_7A, AARCH64_ISA_V8_8A)
4822 (AARCH64_ISA_V8_9A, AARCH64_ISA_V9A, AARCH64_ISA_V9_1A)
4823 (AARCH64_ISA_V9_2A, AARCH64_ISA_V9_3A, AARCH64_ISA_V9_4A)
4824 (AARCH64_ISA_MOPS, AARCH64_ISA_LS64, AARCH64_ISA_CSSC)
4825 (AARCH64_ISA_D128, AARCH64_ISA_THE, AARCH64_ISA_GCS): Remove.
4826 (TARGET_BASE_SIMD, TARGET_SIMD, TARGET_FLOAT)
4827 (TARGET_NON_STREAMING, TARGET_STREAMING, TARGET_ZA, TARGET_SHA2)
4828 (TARGET_SHA3, TARGET_AES, TARGET_SM4, TARGET_F16FML)
4829 (TARGET_CRC32, TARGET_LSE, TARGET_FP_F16INST)
4830 (TARGET_SIMD_F16INST, TARGET_DOTPROD, TARGET_SVE, TARGET_SVE2)
4831 (TARGET_SVE2_AES, TARGET_SVE2_BITPERM, TARGET_SVE2_SHA3)
4832 (TARGET_SVE2_SM4, TARGET_SME, TARGET_SME_I16I64)
4833 (TARGET_SME_F64F64, TARGET_SME2, TARGET_ARMV8_3, TARGET_JSCVT)
4834 (TARGET_FRINT, TARGET_TME, TARGET_RNG, TARGET_MEMTAG)
4835 (TARGET_I8MM, TARGET_SVE_I8MM, TARGET_SVE_F32MM)
4836 (TARGET_SVE_F64MM, TARGET_BF16_FP, TARGET_BF16_SIMD)
4837 (TARGET_SVE_BF16, TARGET_PAUTH, TARGET_BTI, TARGET_MOPS)
4838 (TARGET_LS64, TARGET_CSSC, TARGET_SB, TARGET_RCPC, TARGET_RCPC2)
4839 (TARGET_RCPC3, TARGET_SIMD_RDMA, TARGET_ARMV9_4, TARGET_D128)
4840 (TARGET_THE, TARGET_GCS): Redefine using AARCH64_HAVE_ISA.
4841 (TARGET_V8R, TARGET_V9A): New.
4842 * config/aarch64/aarch64.md (arch_enabled): Use TARGET_RCPC2.
4843 * config/aarch64/iterators.md (GPI_I16): Use TARGET_FP_F16INST.
4845 * config/aarch64/predicates.md
4846 (aarch64_rcpc_memory_operand): Use TARGET_RCPC2.
4848 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4850 * config/aarch64/aarch64.cc
4851 (aarch64_valid_sysreg_name_p): Add bool cast.
4853 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4855 * common/config/aarch64/aarch64-common.cc
4856 (aarch64_set_asm_isa_flags): Reorder, and add suffix to names.
4857 * config/aarch64/aarch64.h
4858 (aarch64_get_asm_isa_flags): Add "_0" suffix.
4859 (aarch64_get_isa_flags): Ditto.
4860 (aarch64_asm_isa_flags): Redefine using renamed uint64_t value.
4861 (aarch64_isa_flags): Ditto.
4862 * config/aarch64/aarch64.opt:
4863 (aarch64_asm_isa_flags): Rename to...
4864 (aarch64_asm_isa_flags_0): ...this, and change to uint64_t.
4865 (aarch64_isa_flags): Rename to...
4866 (aarch64_isa_flags_0): ...this, and change to uint64_t.
4868 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4870 * common/config/aarch64/aarch64-common.cc
4871 (aarch64_handle_option): Use new macro.
4872 * config/aarch64/aarch64.cc
4873 (aarch64_override_options_internal): Ditto.
4874 (aarch64_option_print): Ditto.
4875 (aarch64_set_current_function): Ditto.
4876 (aarch64_can_inline_p): Ditto.
4877 (aarch64_declare_function_name): Ditto.
4878 (aarch64_start_file): Ditto.
4879 * config/aarch64/aarch64.h (aarch64_get_asm_isa_flags): New
4880 (aarch64_get_isa_flags): New.
4881 (aarch64_asm_isa_flags): Use new macro.
4882 (aarch64_isa_flags): Ditto.
4884 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4886 * config/aarch64/aarch64-opts.h: Add aarch64_isa_mode typedef.
4887 * config/aarch64/aarch64-protos.h
4888 (aarch64_gen_callee_cookie): Use aarch64_isa_mode parameter.
4889 (aarch64_sme_vq_immediate): Ditto.
4890 * config/aarch64/aarch64.cc
4891 (aarch64_fntype_pstate_sm): Use aarch64_isa_mode values.
4892 (aarch64_fntype_pstate_za): Ditto.
4893 (aarch64_fndecl_pstate_sm): Ditto.
4894 (aarch64_fndecl_pstate_za): Ditto.
4895 (aarch64_fndecl_isa_mode): Ditto.
4896 (aarch64_cfun_incoming_pstate_sm): Ditto.
4897 (aarch64_cfun_enables_pstate_sm): Ditto.
4898 (aarch64_call_switches_pstate_sm): Ditto.
4899 (aarch64_gen_callee_cookie): Ditto.
4900 (aarch64_callee_isa_mode): Ditto.
4901 (aarch64_insn_callee_abi): Ditto.
4902 (aarch64_sme_vq_immediate): Ditto.
4903 (aarch64_add_offset_temporaries): Ditto.
4904 (aarch64_add_offset): Ditto.
4905 (aarch64_add_sp): Ditto.
4906 (aarch64_sub_sp): Ditto.
4907 (aarch64_guard_switch_pstate_sm): Ditto.
4908 (aarch64_switch_pstate_sm): Ditto.
4909 (aarch64_init_cumulative_args): Ditto.
4910 (aarch64_allocate_and_probe_stack_space): Ditto.
4911 (aarch64_expand_prologue): Ditto.
4912 (aarch64_expand_epilogue): Ditto.
4913 (aarch64_start_call_args): Ditto.
4914 (aarch64_expand_call): Ditto.
4915 (aarch64_end_call_args): Ditto.
4916 (aarch64_set_current_function): Ditto, with added conversions.
4917 (aarch64_handle_attr_arch): Avoid macro with changed type.
4918 (aarch64_handle_attr_cpu): Ditto.
4919 (aarch64_handle_attr_isa_flags): Ditto.
4920 (aarch64_switch_pstate_sm_for_landing_pad):
4921 Use arch64_isa_mode values.
4922 (aarch64_switch_pstate_sm_for_jump): Ditto.
4923 (pass_switch_pstate_sm::gate): Ditto.
4924 * config/aarch64/aarch64.h
4925 (AARCH64_ISA_MODE_{SM_ON|SM_OFF|ZA_ON}): New macros.
4926 (AARCH64_FL_SM_STATE): Mark as possibly unused.
4927 (AARCH64_ISA_MODE_SM_STATE): New aarch64_isa_mode mask.
4928 (AARCH64_DEFAULT_ISA_MODE): New aarch64_isa_mode value.
4929 (AARCH64_FL_DEFAULT_ISA_MODE): Define using above value.
4930 (AARCH64_ISA_MODE): Change type to aarch64_isa_mode.
4931 (arm_pcs): Use aarch64_isa_mode value.
4933 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4935 * config/aarch64/aarch64.cc
4936 (aarch64_override_options): Remove temporary variable.
4938 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4940 * config/aarch64/aarch64.h (DEF_AARCH64_ISA_MODE): Move to...
4941 * config/aarch64/aarch64-opts.h (DEF_AARCH64_ISA_MODE): ...here.
4943 2024-07-24 Andrew Carlotti <andrew.carlotti@arm.com>
4945 * config/aarch64/aarch64.cc
4946 (aarch64_tune_flags): Remove unused global variable.
4947 (aarch64_override_options_internal): Remove dead assignment.
4949 2024-07-24 Andrew Pinski <quic_apinski@quicinc.com>
4951 * config/rs6000/rs6000-builtins.def: s/iorc/iorn/. s/andc/andn/
4953 * config/rs6000/rs6000-string.cc (expand_cmp_vec_sequence): Update
4955 * config/rs6000/rs6000.md (andc<mode>3): Rename to ...
4956 (andn<mode>3): This.
4957 (iorc<mode>3): Rename to ...
4958 (iorn<mode>3): This.
4959 * doc/md.texi: Update documentation for the rename.
4960 * internal-fn.def (BIT_ANDC): Rename to ...
4962 (BIT_IORC): Rename to ...
4964 * optabs.def (andc_optab): Rename to ...
4966 (iorc_optab): Rename to ...
4968 * gimple-isel.cc (gimple_expand_vec_cond_expr): Update for the
4969 renamed internal functions, ANDC/IORC to ANDN/IORN.
4971 2024-07-24 Gaius Mulley <gaiusmod2@gmail.com>
4973 * doc/install.texi (GM2-prerequisite): Add GNU flex.
4975 2024-07-24 Richard Biener <rguenther@suse.de>
4977 PR tree-optimization/116057
4978 * tree-ssa-ccp.cc (likely_value): Also walk CTORs in stmt
4979 operands to look for constants.
4981 2024-07-24 Kyrylo Tkachov <ktkachov@nvidia.com>
4984 2024-07-24 Jennifer Schmitz <jschmitz@nvidia.com>
4986 * config/aarch64/aarch64.cc (aarch_macro_fusion_pair_p): Implement
4988 * config/aarch64/aarch64-fusion-pairs.def (cmp+csel): New entry.
4989 (cmp+cset): Likewise.
4990 * config/aarch64/tuning_models/neoversev2.h: Enable logic in
4993 2024-07-24 Jennifer Schmitz <jschmitz@nvidia.com>
4995 * config/aarch64/aarch64.cc (aarch_macro_fusion_pair_p): Implement
4997 * config/aarch64/aarch64-fusion-pairs.def (cmp+csel): New entry.
4998 (cmp+cset): Likewise.
4999 * config/aarch64/tuning_models/neoversev2.h: Enable logic in
5002 2024-07-24 Christoph Müllner <christoph.muellner@vrull.eu>
5005 * config/riscv/bitmanip.md: Disable zero_extendsidi2_bitmanip
5008 2024-07-24 Lingling Kong <lingling.kong@intel.com>
5011 * config/i386/driver-i386.cc (host_detect_local_cpu): Enable
5012 APX_F only for 64-bit codegen.
5013 * config/i386/i386-options.cc (DEF_PTA): Skip PTA_APX_F if
5016 2024-07-24 Pan Li <pan2.li@intel.com>
5019 * internal-fn.cc (type_strictly_matches_mode_p): Add new func
5020 impl to check type strictly matches mode or not.
5021 (type_pair_strictly_matches_mode_p): Ditto but for tree type
5023 (direct_internal_fn_supported_p): Add above check for the tree
5026 2024-07-23 Mark Harmstone <mark@harmstone.com>
5028 * dwarf2codeview.cc (get_type_num_reference_type): Handle rvalue refs.
5029 (get_type_num_array_type): Add DW_TAG_rvalue_reference_type to switch.
5030 (get_type_num): Handle DW_TAG_rvalue_reference_type DIEs.
5031 * dwarf2codeview.h (CV_PTR_MODE_RVREF): Define.
5033 2024-07-23 Mark Harmstone <mark@harmstone.com>
5035 * dwarf2codeview.cc (get_type_num_reference_type): New function.
5036 (get_type_num_array_type): Add DW_TAG_reference_type to switch.
5037 (get_type_num): Handle DW_TAG_reference_type DIEs.
5038 * dwarf2codeview.h (CV_PTR_MODE_LVREF): Define.
5040 2024-07-23 Vineet Gupta <vineetg@rivosinc.com>
5042 * config/riscv/bitmanip.md: Fix splitter.
5044 2024-07-23 Marek Polacek <polacek@redhat.com>
5046 * doc/extend.texi: Add missing @option.
5048 2024-07-23 Andi Kleen <ak@linux.intel.com>
5051 * doc/extend.texi: Document [[musttail]]
5053 2024-07-23 Tobias Burnus <tburnus@baylibre.com>
5055 * doc/install.texi (amdgcn-x-amdhsa): Suggest newer git version
5058 2024-07-23 Jiufu Guo <guojiufu@linux.ibm.com>
5061 * config/rs6000/rs6000.cc (print_operand_address): Emit message for
5062 unsupported operand.
5064 2024-07-23 Richard Biener <rguenther@suse.de>
5066 PR tree-optimization/116002
5067 * tree-ssa-structalias.cc (topo_visit): Also consider
5068 SCALAR = SCALAR complex constraints as edges.
5070 2024-07-23 Jakub Jelinek <jakub@redhat.com>
5071 Andrew Pinski <quic_apinski@quicinc.com>
5073 PR tree-optimization/116034
5074 * tree-ssa.cc (maybe_rewrite_mem_ref_base): Only use IMAGPART_EXPR
5075 if MEM_REF offset is equal to element type size.
5077 2024-07-23 Richard Biener <rguenther@suse.de>
5079 PR rtl-optimization/116002
5080 * cselib.cc (cselib_hash_rtx): Use inchash to get proper mixing.
5081 Consistently avoid a zero return value when hashing successfully.
5082 Consistently treat a zero hash value from recursing as fatal.
5083 Use hashval_t where appropriate.
5084 (cselib_hash_plus_const_int): Likewise.
5085 (new_cselib_val): Use hashval_t.
5086 (cselib_lookup_1): Likewise.
5088 2024-07-23 liuhongt <hongtao.liu@intel.com>
5090 * config/i386/i386.cc (ix86_hardreg_mov_ok): Relax mov subreg
5091 to hard register after split1.
5093 2024-07-23 Kewen Lin <linkw@linux.ibm.com>
5096 * config/rs6000/rs6000.cc (rs6000_inner_target_options): Update option
5097 set information for rs6000_opt_vars.
5099 2024-07-23 Kewen Lin <linkw@linux.ibm.com>
5102 * config/rs6000/rs6000.cc (rs6000_inner_target_options): Avoid to
5103 enable altivec or disable avoid-indexed-addresses automatically
5104 when they get specified explicitly.
5106 2024-07-23 Kewen Lin <linkw@linux.ibm.com>
5109 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Emit error
5110 messages when explicit VSX encounters explicit soft-float, no-altivec
5111 or avoid-indexed-addresses.
5113 2024-07-23 Haochen Jiang <haochen.jiang@intel.com>
5115 * config/i386/i386.md (prefetchi): Change to %a.
5117 2024-07-23 Jeff Law <jlaw@ventanamicro.com>
5119 PR rtl-optimization/115877
5120 * ext-dce.cc (ext_dce_process_sets): Reasonably handle input/output
5122 (ext_dce_rd_transfer_n): Drop bogus assertion.
5124 2024-07-23 Pan Li <pan2.li@intel.com>
5126 * config/riscv/iterators.md (ANYI_DOUBLE_TRUNC): Add new iterator
5127 for int double truncation.
5128 (ANYI_DOUBLE_TRUNCATED): Add new attr for int double truncation.
5129 (anyi_double_truncated): Ditto but for lowercase.
5130 * config/riscv/riscv-protos.h (riscv_expand_ustrunc): Add new
5131 func decl for expanding ustrunc
5132 * config/riscv/riscv.cc (riscv_expand_ustrunc): Add new func
5133 impl to expand ustrunc.
5134 * config/riscv/riscv.md (ustrunc<mode><anyi_double_truncated>2): Impl
5135 the new pattern ustrunc<m><n>2 for int.
5137 2024-07-22 Jan Hubicka <hubicka@ucw.cz>
5140 * ipa-modref.cc (modref_summary::useful_p): Fix handling of ECF_NOVOPS.
5141 (modref_access_analysis::process_fnspec): Likevise.
5142 (modref_access_analysis::analyze_call): Likevise.
5143 (propagate_unknown_call): Likevise.
5144 (modref_propagate_in_scc): Likevise.
5145 (modref_propagate_flags_in_scc): Likewise.
5146 (ipa_merge_modref_summary_after_inlining): Likewise.
5148 2024-07-22 Jan Hubicka <hubicka@ucw.cz>
5151 * ipa-modref.cc (analyze_parms): Do not preserve EAF_NO_DIRECT_READ and
5152 EAF_NO_INDIRECT_READ from past flags.
5154 2024-07-22 Michael Meissner <meissner@linux.ibm.com>
5156 * config.gcc (powerpc*-*-*): Add support for power11.
5157 * config/rs6000/aix71.h (ASM_CPU_SPEC): Add support for -mcpu=power11.
5158 * config/rs6000/aix72.h (ASM_CPU_SPEC): Likewise.
5159 * config/rs6000/aix73.h (ASM_CPU_SPEC): Likewise.
5160 * config/rs6000/driver-rs6000.cc (asm_names): Likewise.
5161 * config/rs6000/ppc-auxv.h (PPC_PLATFORM_POWER11): New define.
5162 * config/rs6000/rs6000-builtin.cc (cpu_is_info): Add power11.
5163 * config/rs6000/rs6000-c.cc (rs6000_target_modify_macros): Define
5164 _ARCH_PWR11 if -mcpu=power11.
5165 * config/rs6000/rs6000-cpus.def (POWER11_MASKS_SERVER): New define.
5166 (POWERPC_MASKS): Add power11.
5167 (power11 cpu): Add power11 definition.
5168 * config/rs6000/rs6000-opts.h (PROCESSOR_POWER11): Add power11 processor.
5169 * config/rs6000/rs6000-string.cc (expand_compare_loop): Likewise.
5170 * config/rs6000/rs6000-tables.opt: Regenerate.
5171 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Add power11
5173 (rs6000_machine_from_flags): Likewise.
5174 (rs6000_reassociation_width): Likewise.
5175 (rs6000_adjust_cost): Likewise.
5176 (rs6000_issue_rate): Likewise.
5177 (rs6000_sched_reorder): Likewise.
5178 (rs6000_sched_reorder2): Likewise.
5179 (rs6000_register_move_cost): Likewise.
5180 (rs6000_opt_masks): Likewise.
5181 * config/rs6000/rs6000.h (ASM_CPU_SPEC): Likewise.
5182 * config/rs6000/rs6000.md (cpu attribute): Add power11.
5183 * config/rs6000/rs6000.opt (-mpower11): Add internal power11 flag.
5184 * doc/invoke.texi (RS/6000 and PowerPC Options): Document -mcpu=power11.
5185 * config/rs6000/power10.md (all reservations): Add power11 support.
5187 2024-07-22 Jeff Law <jlaw@ventanamicro.com>
5189 PR rtl-optimization/115877
5190 * ext-dce.cc (ext_dce_process_sets): More correctly handle SUBREG
5193 2024-07-22 Jan Hubicka <hubicka@ucw.cz>
5196 * ipa-modref.cc (modref_eaf_analysis::analyze_ssa_name): Fix checking of
5197 EAF flags when analysing values dereferenced as function parameters.
5199 2024-07-22 Jan Hubicka <hubicka@ucw.cz>
5202 * ipa-prop.cc (unadjusted_ptr_and_unit_offset): Fix accounting of offsets in ADDR_EXPR.
5204 2024-07-22 Jan Hubicka <hubicka@ucw.cz>
5207 * ipa-icf-gimple.cc (func_checker::compare_loops): compare loop
5210 2024-07-22 Richard Sandiford <richard.sandiford@arm.com>
5212 PR rtl-optimization/116009
5213 * rtl-ssa/accesses.cc (function_info::add_def): Set the root
5214 local variable after removing the old clobber group.
5216 2024-07-22 Richard Sandiford <richard.sandiford@arm.com>
5218 * rtl-ssa/accesses.h (rtl_ssa::pp_def_splay_tree): Declare.
5219 (dump, debug): Add overloads for def_splay_tree.
5220 * rtl-ssa/accesses.cc (rtl_ssa::pp_def_splay_tree): New function.
5221 (dump, debug): Add overloads for def_splay_tree.
5223 2024-07-22 Richard Sandiford <richard.sandiford@arm.com>
5226 * config/aarch64/aarch64.cc (aarch64_simd_mem_operand_p): Require
5227 the operand to be a legitimate memory_operand.
5229 2024-07-22 Jeff Law <jlaw@ventanamicro.com>
5231 PR rtl-optimization/115877
5232 * ext-dce.cc (group_limit): New function.
5233 (mark_reg_live): Likewise.
5234 (ext_dce_process_sets): Use new functions.
5235 (ext_dce_process_uses): Likewise.
5236 (ext_dce_init): Likewise.
5238 2024-07-22 Richard Biener <rguenther@suse.de>
5240 * fold-const.cc (operand_compare::hash_operand): Fix hash
5243 2024-07-22 Richard Biener <rguenther@suse.de>
5245 * inchash.h (inchash::end): Make const.
5246 (inchash::merge): Take const reference hash argument.
5247 (inchash::add_commutative): Likewise.
5249 2024-07-22 Tamar Christina <tamar.christina@arm.com>
5251 PR tree-optimization/115531
5252 * config/aarch64/aarch64.cc
5253 (aarch64_conditional_operation_is_expensive): New.
5254 (TARGET_VECTORIZE_CONDITIONAL_OPERATION_IS_EXPENSIVE): New.
5256 2024-07-22 Tamar Christina <tamar.christina@arm.com>
5258 PR tree-optimization/115531
5259 * tree-vect-patterns.cc (vect_cond_store_pattern_same_ref): New.
5260 (vect_recog_cond_store_pattern): New.
5261 (vect_vect_recog_func_ptrs): Use it.
5262 * target.def (conditional_operation_is_expensive): New.
5263 * doc/tm.texi: Regenerate.
5264 * doc/tm.texi.in: Document it.
5265 * targhooks.cc (default_conditional_operation_is_expensive): New.
5266 * targhooks.h (default_conditional_operation_is_expensive): New.
5268 2024-07-21 Jeff Law <jlaw@ventanamicro.com>
5270 PR rtl-optimization/115877
5271 * ext-dce.cc (safe_for_live_propagation): Handle RTX_CONST_OBJ.
5273 2024-07-21 Jeff Law <jlaw@ventanamicro.com>
5275 PR rtl-optimization/115877
5276 * ext-dce.cc (ext_dce_process_uses): Restore the value of DST_MASK
5279 2024-07-21 Sam James <sam@gentoo.org>
5281 * Makefile.in (NOCOMMON_FLAG): Delete.
5282 (GCC_WARN_CFLAGS): Drop NOCOMMON_FLAG.
5283 (GCC_WARN_CXXFLAGS): Drop NOCOMMON_FLAG.
5284 * configure.ac: Ditto.
5285 * configure: Regenerate.
5287 2024-07-21 Oleg Endo <olegendo@gcc.gnu.org>
5289 * config/sh/sh.md (mov_neg_si_t): Allow insn and split after
5290 register allocation.
5291 (*treg_noop_move): New insn.
5293 2024-07-20 Andi Kleen <ak@gcc.gnu.org>
5296 2024-07-20 Andi Kleen <ak@linux.intel.com>
5299 * doc/extend.texi: Document [[musttail]]
5301 2024-07-20 Mark Harmstone <mark@harmstone.com>
5303 * dwarf2codeview.cc (enum cv_sym_type): Add new values.
5304 (struct codeview_symbol): Add function to union.
5305 (struct codeview_custom_type): Add lf_func_id to union.
5306 (write_function): New function.
5307 (write_codeview_symbols): Call write_function.
5308 (write_lf_func_id): New function.
5309 (write_custom_types): Call write_lf_func_id.
5310 (add_function): New function.
5311 (codeview_debug_early_finish): Call add_function.
5313 2024-07-20 André Maroneze <andre.maroneze@cea.fr>
5315 * doc/invoke.texi (Spec Files): Remove documentation of obsolete
5316 spec strings "predefines" and "signed_char".
5318 2024-07-20 Siddhesh Poyarekar <siddhesh@gotplt.org>
5320 * opt-suggestions.cc
5321 (option_proposer::build_option_suggestions): Pull OPTB
5322 definition out of the innermost loop.
5324 2024-07-20 Andi Kleen <ak@linux.intel.com>
5327 * doc/extend.texi: Document [[musttail]]
5329 2024-07-20 Lulu Cheng <chenglulu@loongson.cn>
5331 * config/loongarch/loongarch-protos.h
5332 (loongarch_split_128bit_move): Delete.
5333 (loongarch_split_128bit_move_p): Delete.
5334 (loongarch_split_256bit_move): Delete.
5335 (loongarch_split_256bit_move_p): Delete.
5336 (loongarch_split_vector_move): Add a function declaration.
5337 * config/loongarch/loongarch.cc
5338 (loongarch_vector_costs::finish_cost): Adjust the code
5340 (loongarch_split_vector_move_p): Merge
5341 loongarch_split_128bit_move_p and loongarch_split_256bit_move_p.
5342 (loongarch_split_move_p): Merge code.
5343 (loongarch_split_move): Likewise.
5344 (loongarch_split_128bit_move_p): Delete.
5345 (loongarch_split_256bit_move_p): Delete.
5346 (loongarch_split_128bit_move): Delete.
5347 (loongarch_split_vector_move): Merge loongarch_split_128bit_move
5348 and loongarch_split_256bit_move.
5349 (loongarch_split_256bit_move): Delete.
5350 (loongarch_global_init): Remove the extra semicolon at the
5351 end of the function.
5352 * config/loongarch/loongarch.md (*movdf_softfloat): Added a new
5353 condition TARGET_64BIT.
5355 2024-07-19 Andrew MacLeod <amacleod@redhat.com>
5357 PR tree-optimization/116003
5358 * value-relation.cc (equiv_oracle::register_initial_def): Check
5359 if SSA_NAME is in the IL before registering.
5361 2024-07-19 Thomas Schwinge <tschwinge@baylibre.com>
5363 * passes.def: Rewrite usage comment at the top.
5365 2024-07-19 Richard Sandiford <richard.sandiford@arm.com>
5367 PR middle-end/115406
5368 * fold-const.cc (native_encode_vector_part): For vector booleans,
5369 check whether an element is nonzero and, if so, set all of the
5370 correspending bits in the target image.
5371 * simplify-rtx.cc (native_encode_rtx): Likewise.
5373 2024-07-19 Georg-Johann Lay <avr@gjlay.de>
5375 * config/avr/builtins.def (MASK1): New DEF_BUILTIN.
5376 * config/avr/avr.cc (avr_rtx_costs_1): Handle rtx costs for
5377 expressions like __builtin_avr_mask1.
5378 (avr_init_builtins) <uintQI_ftype_uintQI_uintQI>: New tree type.
5379 (avr_expand_builtin) [AVR_BUILTIN_MASK1]: Diagnose unexpected forms.
5380 (avr_fold_builtin) [AVR_BUILTIN_MASK1]: Handle case.
5381 * config/avr/avr.md (gen_mask1): New expand helper.
5382 (mask1_0x01_split, mask1_0x80_split, mask1_0xfe_split): New
5384 (*mask1_0x01, *mask1_0x80, *mask1_0xfe): New insns.
5385 * doc/extend.texi (AVR Built-in Functions) <__builtin_avr_mask1>:
5386 Document new built-in function.
5388 2024-07-19 Cupertino Miranda <cupertino.miranda@oracle.com>
5390 * config/bpf/atomic.md (atomic_compare_and_swap,
5391 atomic_exchange): Add operand modifier %M to the first
5393 * config/bpf/bpf.cc (no_parentheses_mem_operand): Create
5395 (bpf_print_operand): Set no_parentheses_mem_operand variable if
5397 (bpf_print_operand_address): Conditionally output parentheses.
5399 2024-07-19 Pan Li <pan2.li@intel.com>
5402 * match.pd: Add single_use check for .SAT_TRUNC form 2.
5404 2024-07-18 René Rebe <rene@exactcode.de>
5405 Peter Bergner <bergner@linux.ibm.com>
5408 * config/rs6000/rs6000.cc (rs6000_machine_from_flags): Do not consider
5409 OPTION_MASK_ALTIVEC.
5410 (emit_asm_machine): For Altivec compiles, emit a ".machine altivec".
5412 2024-07-18 Marek Polacek <polacek@redhat.com>
5413 Jakub Jelinek <jakub@redhat.com>
5416 * tree-eh.cc (get_eh_else): Check that the result of
5417 gimple_seq_first_stmt is non-null.
5419 2024-07-18 LIU Hao <lh_mouse@126.com>
5421 PR rtl-optimization/115049
5422 * varasm.cc (decl_binds_to_current_def_p): Add a check for COMDAT
5423 declarations too, like weak ones.
5425 2024-07-18 Richard Biener <rguenther@suse.de>
5427 PR middle-end/115641
5428 * fold-const.cc (decode_field_reference): If the inner
5429 reference isn't something we can take the address of, fail.
5431 2024-07-18 Pan Li <pan2.li@intel.com>
5433 * doc/md.texi: Add Standard-Names ustrunc and sstrunc.
5435 2024-07-18 Rubin Gerritsen <rubin.gerritsen@gmail.com>
5437 * gimple-fold.cc (dump_transformation): Moved definition.
5438 (replace_call_with_call_and_fold): Calls dump_transformation.
5439 (gimple_fold_builtin_stxcpy_chk): Removes call to
5440 dump_transformation, now in replace_call_with_call_and_fold.
5441 (gimple_fold_builtin_stxncpy_chk): Removes call to
5442 dump_transformation, now in replace_call_with_call_and_fold.
5444 2024-07-18 Richard Biener <rguenther@suse.de>
5446 PR tree-optimization/104515
5447 * tree-ssa-loop-im.cc (execute_sm_exit): Add clobbers_to_prune
5448 parameter and handle re-materializing of clobbers.
5449 (sm_seq_valid_bb): end-of-storage/object clobbers are OK inside
5450 an ordered sequence of stores.
5451 (sm_seq_push_down): Refuse to push down clobbers.
5452 (hoist_memory_references): Prune clobbers from the loop body
5453 we re-materialized on an exit.
5455 2024-07-18 Roger Sayle <roger@nextmovesoftware.com>
5457 * match.pd ((FTYPE) N CMP CST): Only worry about exceptions with
5458 flag_trapping_math, and about signaling NaNs with HONOR_SNANS.
5460 2024-07-18 Kyrylo Tkachov <ktkachov@nvidia.com>
5462 * doc/invoke.texi (AArch64 Options): Document rewriting of
5463 -march=native to -mcpu=native.
5465 2024-07-18 liuhongt <hongtao.liu@intel.com>
5468 * config/i386/predicates.md (const0_or_m1_operand): New
5470 * config/i386/sse.md (*<avx512>_store<mode>_mask_1): New
5471 pre_reload define_insn_and_split.
5472 (V): Add V32BF,V16BF,V8BF.
5473 (V4SF_V8BF): Rename to ..
5474 (V24F_128): .. this.
5475 (*vec_concat<mode>): Adjust with V24F_128.
5476 (*vec_concat<mode>_0): Ditto.
5478 2024-07-18 Andi Kleen <ak@linux.intel.com>
5481 * calls.cc (initialize_argument_information): Mark messages
5483 (can_implement_as_sibling_call_p): Dito.
5484 (expand_call): Dito.
5486 2024-07-18 Andi Kleen <ak@linux.intel.com>
5489 * tree-tailcall.cc (maybe_error_musttail): New function.
5490 (suitable_for_tail_opt_p): Report error reason.
5491 (suitable_for_tail_call_opt_p): Report error reason.
5492 (find_tail_calls): Accept basic blocks with abnormal edges.
5493 Delay reporting of errors until the call is discovered.
5494 Move top level suitability checks to here.
5495 (tree_optimize_tail_calls_1): Remove top level checks.
5497 2024-07-18 Andi Kleen <ak@linux.intel.com>
5500 * function.h (struct function): Add has_musttail.
5501 * lto-streamer-in.cc (input_struct_function_base): Stream
5503 * lto-streamer-out.cc (output_struct_function_base): Dito.
5504 * passes.def (pass_musttail): Add.
5505 * tree-cfg.cc (notice_special_calls): Record has_musttail.
5506 (clear_special_calls): Clear has_musttail.
5507 * tree-pass.h (make_pass_musttail): Add.
5508 * tree-tailcall.cc (find_tail_calls): Handle only_musttail
5510 (tree_optimize_tail_calls_1): Pass on only_musttail.
5511 (execute_tail_calls): Pass only_musttail as false.
5512 (class pass_musttail): Add.
5513 (make_pass_musttail): Add.
5515 2024-07-18 Andi Kleen <ak@linux.intel.com>
5518 * function.cc (thread_prologue_and_epilogue_insns): Check
5519 cfun->tail_call_marked for sibcalls too.
5520 (rest_of_handle_thread_prologue_and_epilogue): Dito.
5522 2024-07-18 Andi Kleen <ak@linux.intel.com>
5525 * calls.cc (maybe_complain_about_tail_call): Clear must tail
5527 (expand_call): Give error messages for all musttail failures.
5529 2024-07-17 Richard Sandiford <richard.sandiford@arm.com>
5531 PR rtl-optimization/115929
5532 * rtl-ssa/movement.h (canonicalize_move_range): Check for null prev
5533 and next insns and create an invalid move range for them.
5535 2024-07-17 Richard Sandiford <richard.sandiford@arm.com>
5537 PR rtl-optimization/115928
5538 * rtl-ssa/accesses.h (clobber_group): Add a new constructor that
5539 takes the first, last and root clobbers.
5540 * rtl-ssa/internals.inl (clobber_group::clobber_group): Define it.
5541 * rtl-ssa/accesses.cc (function_info::split_clobber_group): Use it.
5542 Allocate a new group for both sides and invalidate the previous group.
5543 (function_info::add_def): After calling split_clobber_group,
5544 remove the old group from the splay tree.
5546 2024-07-17 Richard Sandiford <richard.sandiford@arm.com>
5548 * genattrtab.cc (attr_desc::cxx_type): New field.
5549 (write_attr_get, write_attr_value): Use it.
5550 (gen_attr, find_attr, make_internal_attr): Initialize it,
5553 2024-07-17 Eikansh Gupta <quic_eikagupt@quicinc.com>
5555 PR tree-optimization/111150
5556 * match.pd (`(a ? x : y) eq/ne (b ? x : y)`): New pattern.
5557 (`(a ? x : y) eq/ne (b ? y : x)`): New pattern.
5559 2024-07-17 Andrew Pinski <quic_apinski@quicinc.com>
5561 * dbgcnt.def (ext_dce): New debug counter.
5562 * ext-dce.cc (ext_dce_try_optimize_insn): Reject the insn
5563 if the debug counter says so.
5564 (ext_dce): Rename to ...
5565 (ext_dce_execute): This.
5566 (pass_ext_dce::execute): Update for the name of ext_dce.
5568 2024-07-17 Uros Bizjak <ubizjak@gmail.com>
5571 * config/alpha/alpha.md (movdi_er_high_g): Add cannot_copy attribute.
5572 (movdi_er_tlsgd): Ditto.
5573 (movdi_er_tlsldm): Ditto.
5574 (call_value_osf_<tls>): Ditto.
5576 2024-07-17 Georg-Johann Lay <avr@gjlay.de>
5579 * config/avr/predicates.md (const_0mod256_operand): New predicate.
5580 * config/avr/constraints.md (Cp8): New constraint.
5581 * config/avr/avr.md (*aligned_add_symbol): New insn.
5582 * config/avr/avr.cc (avr_out_plus_symbol) [HImode]:
5583 When op2 is a multiple of 256, there is no need to add / subtract
5585 (avr_rtx_costs_1) [PLUS && HImode]: Return expected costs for
5586 new insn *aligned_add_symbol as it applies.
5588 2024-07-17 Jakub Jelinek <jakub@redhat.com>
5590 PR middle-end/115887
5591 * gimple-lower-bitint.cc (gimple_lower_bitint): Use gsi_insert_on_edge
5592 instead of gsi_insert_on_edge_immediate and set edge_insertions to
5595 2024-07-17 Jakub Jelinek <jakub@redhat.com>
5597 * varasm.cc (default_elf_asm_output_ascii): Use ASM_OUTPUT_SKIP instead
5598 of 2 or more default_elf_asm_output_limited_string (f, "") calls and
5599 adjust base64 heuristics correspondingly.
5601 2024-07-17 Tamar Christina <tamar.christina@arm.com>
5603 PR tree-optimization/115936
5604 * tree-scalar-evolution.cc (simple_iv_with_niters): Use sizetype for
5607 2024-07-17 Feng Xue <fxue@os.amperecomputing.com>
5609 PR tree-optimization/114440
5610 * tree-vectorizer.h (struct _stmt_vec_info): Add a new field
5612 * tree-vect-loop.cc (vect_transform_reduction): Generate lane-reducing
5613 statements in an optimized order.
5615 2024-07-17 Feng Xue <fxue@os.amperecomputing.com>
5617 PR tree-optimization/114440
5618 * tree-vectorizer.h (vectorizable_lane_reducing): New function
5620 * tree-vect-stmts.cc (vect_analyze_stmt): Call new function
5621 vectorizable_lane_reducing to analyze lane-reducing operation.
5622 * tree-vect-loop.cc (vect_model_reduction_cost): Remove cost computation
5623 code related to emulated_mixed_dot_prod.
5624 (vectorizable_lane_reducing): New function.
5625 (vectorizable_reduction): Allow multiple lane-reducing operations in
5626 loop reduction. Move some original lane-reducing related code to
5627 vectorizable_lane_reducing.
5628 (vect_transform_reduction): Adjust comments with updated example.
5630 2024-07-17 Feng Xue <fxue@os.amperecomputing.com>
5632 * tree-vect-loop.cc (vect_reduction_update_partial_vector_usage):
5633 Calculate effective vector stmts number with generic
5634 vect_get_num_copies.
5635 (vect_transform_reduction): Insert copies for lane-reducing so as to
5636 fix over-estimated vector stmts number.
5637 (vect_transform_cycle_phi): Calculate vector PHI number only based on
5639 * tree-vect-slp.cc (vect_slp_analyze_node_operations_1): Remove
5640 adjustment on vector stmts number specific to slp reduction.
5642 2024-07-17 Feng Xue <fxue@os.amperecomputing.com>
5644 * tree-vectorizer.h (vect_get_num_copies): New overload function.
5645 * tree-vect-slp.cc (vect_slp_analyze_node_operations_1): Calculate
5646 number of vector stmts for slp node with vect_get_num_copies.
5647 (vect_slp_analyze_node_operations): Calculate number of vector elements
5648 for constant/external slp node with vect_get_num_copies.
5650 2024-07-17 Richard Biener <rguenther@suse.de>
5652 PR tree-optimization/115959
5653 * tree-vect-loop.cc (vect_create_epilog_for_reduction):
5654 Get at the REDUC_IDX child in a safer way for COND_EXPR
5657 2024-07-17 Jakub Jelinek <jakub@redhat.com>
5660 * varasm.cc (default_elf_asm_output_ascii): Cast t - s to unsigned
5661 to avoid -Wsign-compare warnings.
5663 2024-07-17 Jakub Jelinek <jakub@redhat.com>
5665 PR middle-end/115527
5666 * gimple-fold.cc (clear_padding_flush): Introduce endsize
5667 variable and use it instead of wordsize when comparing it against
5669 (clear_padding_type): Increment off by sz.
5671 2024-07-17 Haochen Gui <guihaoc@gcc.gnu.org>
5673 * config/rs6000/rs6000.md (mov<mode>cc, *mov<mode>cc_p10,
5674 *mov<mode>cc_invert_p10, *fpmask<mode>, *xxsel<mode>,
5675 @ieee_128bit_vsx_abs<mode>2, *ieee_128bit_vsx_nabs<mode>2,
5676 add<mode>3, sub<mode>3, mul<mode>3, div<mode>3, sqrt<mode>2,
5677 copysign<mode>3, copysign<mode>3_hard, copysign<mode>3_soft,
5678 @neg<mode>2_hw, @abs<mode>2_hw, *nabs<mode>2_hw, fma<mode>4_hw,
5679 *fms<mode>4_hw, *nfma<mode>4_hw, *nfms<mode>4_hw,
5680 extend<SFDF:mode><IEEE128:mode>2_hw, trunc<mode>df2_hw,
5681 trunc<mode>sf2_hw, fix<uns>_<IEEE128:mode><SDI:mode>2_hw,
5682 fix<uns>_trunc<IEEE128:mode><QHI:mode>2,
5683 *fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem,
5684 float_<mode>di2_hw, float_<mode>si2_hw,
5685 float<QHI:mode><IEEE128:mode>2, floatuns_<mode>di2_hw,
5686 floatuns_<mode>si2_hw, floatuns<QHI:mode><IEEE128:mode>2,
5687 floor<mode>2, ceil<mode>2, btrunc<mode>2, round<mode>2,
5688 add<mode>3_odd, sub<mode>3_odd, mul<mode>3_odd, div<mode>3_odd,
5689 sqrt<mode>2_odd, fma<mode>4_odd, *fms<mode>4_odd, *nfma<mode>4_odd,
5690 *nfms<mode>4_odd, trunc<mode>df2_odd, *cmp<mode>_hw for IEEE128):
5691 Remove guard FLOAT128_IEEE_P.
5692 (@extenddf<mode>2_fprs, @extenddf<mode>2_vsx,
5693 trunc<mode>df2_internal1, trunc<mode>df2_internal2,
5694 fix_trunc_helper<mode>, neg<mode>2, *cmp<mode>_internal1,
5695 *cmp<IBM128:mode>_internal2 for IBM128): Remove guard FLOAT128_IBM_P.
5697 2024-07-17 Kewen Lin <linkw@linux.ibm.com>
5699 * config/rs6000/rs6000.cc (init_float128_ieee): Use trunc_optab rather
5700 than sext_optab for converting FLOAT128_IBM_P mode to FLOAT128_IEEE_P
5701 mode, and use sext_optab rather than trunc_optab for converting
5702 FLOAT128_IEEE_P mode to FLOAT128_IBM_P mode.
5703 (rs6000_expand_float128_convert): Likewise.
5705 2024-07-17 Kewen Lin <linkw@linux.ibm.com>
5708 * tree.cc (build_common_tree_nodes): Drop the workaround for rs6000
5709 KFmode precision adjustment.
5711 2024-07-17 Kewen Lin <linkw@linux.ibm.com>
5714 * value-range.h (range_compatible_p): Remove the workaround on
5715 different type precision between _Float128 and long double.
5717 2024-07-17 Kewen Lin <linkw@linux.ibm.com>
5720 * config/rs6000/rs6000-modes.def (IFmode, KFmode, TFmode): Define
5721 with FLOAT_MODE instead of FRACTIONAL_FLOAT_MODE, don't use special
5722 precisions any more.
5723 (rs6000-modes.h): Remove include.
5724 * config/rs6000/rs6000-modes.h: Remove.
5725 * config/rs6000/rs6000.h (rs6000-modes.h): Remove include.
5726 * config/rs6000/t-rs6000: Remove rs6000-modes.h include.
5727 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Replace
5728 all uses of FLOAT_PRECISION_TFmode with 128.
5729 (rs6000_c_mode_for_floating_type): Likewise.
5730 * config/rs6000/rs6000.md (define_expand extendiftf2): Remove.
5731 (define_expand extendifkf2): Remove.
5732 (define_expand extendtfkf2): Remove.
5733 (define_expand trunckftf2): Remove.
5734 (define_expand trunctfif2): Remove.
5735 (define_expand extendtfif2): Add new assertion.
5736 (define_expand expandkftf2): New.
5737 (define_expand trunciftf2): Add new assertion.
5738 (define_expand trunctfkf2): New.
5739 (define_expand truncifkf2): Change with gcc_unreachable.
5740 (define_expand expandkfif2): New.
5741 (define_insn_and_split extendkftf2): Rename to ...
5742 (define_insn_and_split *extendkftf2): ... this.
5743 (define_insn_and_split trunctfkf2): Rename to ...
5744 (define_insn_and_split *extendtfkf2): ... this.
5746 2024-07-17 Kewen Lin <linkw@linux.ibm.com>
5749 * expr.cc (convert_mode_scalar): Allow same precision conversion
5750 between scalar floating point modes if whose underlying format is
5751 ibm_extended_format or ieee_quad_format, and refactor assertion
5752 with new lambda function acceptable_same_precision_modes. Use
5753 trunc_optab rather than sext_optab for ibm128 to ieee128 conversion.
5754 * optabs-libfuncs.cc (gen_trunc_conv_libfunc): Use trunc_optab rather
5755 than sext_optab for ibm128 to ieee128 conversion.
5757 2024-07-17 Peter Bergner <bergner@linux.ibm.com>
5760 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Disallow
5761 CPUs and ABIs that do no support the ROP protection insns.
5762 * config/rs6000/rs6000-logue.cc (rs6000_stack_info): Remove now
5764 (rs6000_emit_prologue): Likewise.
5765 Remove unneeded gcc_assert.
5766 (rs6000_emit_epilogue): Likewise.
5767 * config/rs6000/rs6000.md: Likewise.
5769 2024-07-17 Peter Bergner <bergner@linux.ibm.com>
5772 * config/rs6000/rs6000-logue.cc (rs6000_stack_info): Use TARGET_POWER8.
5773 (rs6000_emit_prologue): Likewise.
5774 * config/rs6000/rs6000.md (hashchk): Likewise.
5778 2024-07-16 Andrew MacLeod <amacleod@redhat.com>
5780 PR tree-optimization/115951
5781 * range-op-ptr.cc (operator_equal::fold_range): Return a boolean
5782 range with the requested type.
5783 (operator_not_equal::fold_range): Likewise.
5784 (operator_lt::fold_range): Likewise.
5785 (operator_le::fold_range): Likewise.
5786 (operator_gt::fold_range): Likewise.
5787 (operator_ge::fold_range): Likewise.
5789 2024-07-16 Iain Sandoe <iain@sandoe.co.uk>
5794 * gimplify.cc (struct gimplify_ctx): Add a flag to show we are
5795 expending a handler.
5796 (gimplify_expr): When we are expanding a handler, and the body
5797 transforms might have re-written DECL_RESULT into a gimple var,
5798 ensure that hander references to DECL_RESULT are also re-written
5799 to refer to the gimple var. When we are processing an EH_ELSE
5800 expression, then add it if either of the cleanup slots is in
5803 2024-07-16 Richard Sandiford <richard.sandiford@arm.com>
5805 PR rtl-optimization/115929
5806 * rtl-ssa/insns.cc (function_info::remove_insn): Remove an
5807 order_node from the instruction as well as from the splay tree.
5809 2024-07-16 Richard Sandiford <richard.sandiford@arm.com>
5811 PR rtl-optimization/115901
5812 * recog.cc (insn_propagation::apply_to_rvalue_1): Restrict
5813 paradoxical mode punning to cases where "to" is constant.
5815 2024-07-16 Richard Sandiford <richard.sandiford@arm.com>
5817 PR rtl-optimization/115891
5818 * rtl-ssa/changes.cc (find_clobbered_access): New function.
5819 (recog_level2): Use it to check for overlap between input
5820 registers and hard-coded clobbers. Conditionally reset
5821 recog_data.insn after changing the insn code.
5823 2024-07-16 Georg-Johann Lay <avr@gjlay.de>
5825 * config/avr/avr.cc (avr_out_minus): Assimilate into...
5826 (avr_out_plus_ext): ...this new function.
5827 (avr_adjust_insn_length) [ADJUST_LEN_PLUS_EXT]: Handle case.
5828 (avr_rtx_costs_1) [PLUS, MINUS]: Adjust RTX costs.
5829 * config/avr/avr.md (adjust_len) <plus_ext>: Add new attribute value.
5830 (*addpsi3_zero_extend.hi_split): Assimilate...
5831 (*addpsi3_zero_extend.qi_split): Assimilate...
5832 (*addsi3_zero_extend_split): Assimilate...
5833 (*addsi3_zero_extend.hi_split): Assimilate...
5834 (*addpsi3_sign_extend.hi_split): Assimilate...
5835 (*addhi3.sign_extend1_split): Assimilate...
5836 (*add<PSISI:mode>3.<code>.<QIPSI:mode>_split): ...into this
5838 (*addpsi3_zero_extend.hi): Assimilate...
5839 (*addpsi3_zero_extend.qi): Assimilate...
5840 (*addsi3_zero_extend): Assimilate...
5841 (*addsi3_zero_extend.hi): Assimilate...
5842 (*addpsi3_sign_extend.hi): Assimilate...
5843 (*addhi3.sign_extend1): Assimilate...
5844 (*add<PSISI:mode>3.<code>.<QIPSI:mode>): ...into this new insn.
5845 (*subpsi3_sign_extend.hi_split): Assimilate...
5846 (*subhi3.sign_extend2_split): Assimilate...
5847 (*sub<HISI:mode>3.zero_extend.<QIPSI:mode>_split): Assimilate...
5848 (*sub<HISI:mode>3.<code><QIPSI:mode>_split): ...into this new
5850 (*subpsi3_sign_extend.hi): Assimilate...
5851 (*subhi3.sign_extend2): Assimilate...
5852 (*sub<HISI:mode>3.zero_extend.<QIPSI:mode>): Assimilate...
5853 (*sub<HISI:mode>3.<code>.<QIPSI:mode>): ...into this new insn.
5854 (*sub<HISI:mode>3.zero_extend.<QIPSI:mode>): Use avr_out_plus_ext
5856 * config/avr/avr-protos.h (avr_out_minus): Remove.
5857 (avr_out_plus_ext): New proto.
5859 2024-07-16 Richard Biener <rguenther@suse.de>
5861 PR tree-optimization/115841
5862 * tree-vect-loop.cc (vect_transform_cycle_phi): Correctly
5863 place the partial vector reduction for the accumulator
5864 re-use when the main loop cannot be skipped but the
5867 2024-07-16 Georg-Johann Lay <avr@gjlay.de>
5869 * config/avr/avr-protos.h (avr_emit_xior_with_shift): New proto.
5870 * config/avr/avr.cc (avr_emit_xior_with_shift): New function.
5871 * config/avr/avr.md (any_lshift): New code iterator.
5872 (*<xior:code><mode>.<any_lshift:code>): New insn-and-split.
5873 (<code><HISI:mode><QIPSI:mode>.0): Replaces...
5874 (*<code_stdname><mode>qi.byte0): ...this one.
5875 (*<xior:code><HISI:mode><QIPSI:mode>.<any_lshift:code>): Replaces...
5876 (*<code_stdname><mode>qi.byte1-3): ...this one.
5878 2024-07-16 Stefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
5880 * config/s390/3931.md (vlbr, vstbr): Remove.
5881 * config/s390/s390.md (xdee): Add FPRX2 mapping.
5882 * config/s390/vector.md (bhfgq): Add TF mapping.
5884 2024-07-16 Richard Biener <rguenther@suse.de>
5886 * config/i386/x86-tune-costs.h (znver5_cost): Update unaligned
5887 load and store cost from the aligned costs.
5889 2024-07-16 Stefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
5892 * config/s390/vector.md (V_HW2): Remove.
5893 (vcond<V_HW:mode><V_HW2:mode>): Remove.
5894 (vcondu<V_HW:mode><V_HW2:mode>): Remove.
5896 2024-07-16 Stefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
5898 * config/s390/vector.md: Enable vcond_mask for 128-bit ops.
5900 2024-07-16 Stefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
5902 * config/s390/vector.md (V_HW): Enable V1TI unconditionally and
5904 (vec_cmpu<VIT_HW:mode><VIT_HW:mode>): Add 128-bit integer
5906 (*vec_cmpeq<mode><mode>_nocc_emu): Emulate operation.
5907 (*vec_cmpgt<mode><mode>_nocc_emu): Emulate operation.
5908 (*vec_cmpgtu<mode><mode>_nocc_emu): Emulate operation.
5910 2024-07-16 Richard Biener <rguenther@suse.de>
5912 PR tree-optimization/115843
5913 * tree-vect-loop-manip.cc
5914 (vect_set_loop_condition_partial_vectors_avx512): Properly
5915 bias the shift of the initial mask for alignment peeling.
5917 2024-07-16 Richard Biener <rguenther@suse.de>
5919 PR tree-optimization/115843
5920 * config/i386/x86-tune-costs.h (znver4_cost): Update unaligned
5921 load and store cost from the aligned costs.
5923 2024-07-16 Roger Sayle <roger@nextmovesoftware.com>
5924 Richard Biener <rguenther@suse.de>
5926 PR tree-optimization/114661
5927 * match.pd ((X*C1)|(X*C2) to X*(C1+C2)): Allow optional useless
5928 type conversions around multiplications, such as those inserted
5929 by this transformation.
5931 2024-07-16 Hu, Lin1 <lin1.hu@intel.com>
5934 * config/i386/sse.md
5935 (PMOV_SRC_MODE_3_AVX2): Add TARGET_AVX2 for V4DI and V8SI.
5936 (PMOV_SRC_MODE_4): Add TARGET_AVX2 for V4DI.
5937 (trunc<mode><pmov_dst_3_lower>2): Change constraint from TARGET_AVX2 to
5939 (trunc<mode><pmov_dst_4_lower>2): Ditto.
5940 (truncv2div2si2): Change constraint from TARGET_AVX2 to TARGET_SSE.
5942 2024-07-16 Jeff Law <jlaw@ventanamicro.com>
5944 * ext-dce.cc (ext_dce_process_uses): Simplify control flow and fix
5945 liveness computation for shift/rotate counts.
5947 2024-07-15 Jeff Law <jlaw@ventanamicro.com>
5949 * ext-dce.cc (carry_backpropagate): Make return type unsigned as well.
5950 Cast to signed for right shift to preserve sign bit.
5952 2024-07-15 Christoph Müllner <christoph.muellner@vrull.eu>
5955 2024-07-15 Christoph Müllner <christoph.muellner@vrull.eu>
5957 * config/riscv/riscv-target-attr.cc (riscv_target_attr_parser::parse_arch):
5958 Replace new + std::unique_ptr by alloca().
5959 (riscv_process_one_target_attr): Likewise.
5960 (riscv_process_target_attr): Likewise.
5962 2024-07-15 Christoph Müllner <christoph.muellner@vrull.eu>
5964 * common/config/riscv/riscv-common.cc (riscv_subset_list::add):
5965 Allow adding enabled extension if m_allow_adding_dup is set.
5966 * config/riscv/riscv-subset.h: Add m_allow_adding_dup and setter.
5967 * config/riscv/riscv-target-attr.cc (riscv_target_attr_parser::parse_arch):
5968 Allow adding enabled extensions.
5970 2024-07-15 Christoph Müllner <christoph.muellner@vrull.eu>
5974 * common/config/riscv/riscv-common.cc (struct riscv_func_target_info):
5976 (struct riscv_func_target_hasher): Likewise.
5977 (riscv_func_decl_hash): Likewise.
5978 (riscv_func_target_hasher::hash): Likewise.
5979 (riscv_func_target_hasher::equal): Likewise.
5980 (riscv_current_subset_list): Likewise.
5981 (riscv_cmdline_subset_list): Remove obsolete space.
5982 (riscv_func_target_table_lazy_init): Remove.
5983 (riscv_func_target_get): Likewise.
5984 (riscv_func_target_put): Likewise.
5985 (riscv_func_target_remove_and_destory): Likewise.
5986 (riscv_arch_str): Generate from cmdline_subset_list.
5987 (riscv_set_arch_by_subset_list): Don't set current_subset_list.
5988 (riscv_parse_arch_string): Remove current_subset_list.
5989 * config/riscv/riscv-c.cc (riscv_cpu_cpp_builtins):
5990 Get subset list via riscv_cmdline_subset_list().
5991 * config/riscv/riscv-subset.h (riscv_current_subset_list):
5993 (riscv_func_target_get): Likewise.
5994 (riscv_func_target_put): Likewise.
5995 (riscv_func_target_remove_and_destory): Likewise.
5996 * config/riscv/riscv-target-attr.cc (riscv_target_attr_parser::parse_arch):
5997 Build base arch string from existing target options, if any.
5998 (riscv_target_attr_parser::update_settings): Store new arch
5999 string in target options.
6000 (riscv_process_one_target_attr): Whitespace fix.
6001 (riscv_process_target_attr): Drop opts argument.
6002 (riscv_option_valid_attribute_p): Properly save, change and restore
6004 * config/riscv/riscv.cc (get_arch_str): New function.
6005 (riscv_declare_function_name): Get arch string for option-arch
6006 directive from function's target options.
6007 * config/riscv/riscv.opt: Add riscv_arch_string variable to
6010 2024-07-15 Christoph Müllner <christoph.muellner@vrull.eu>
6012 * config/riscv/riscv-target-attr.cc (riscv_target_attr_parser::parse_arch):
6013 Replace new + std::unique_ptr by alloca().
6014 (riscv_process_one_target_attr): Likewise.
6015 (riscv_process_target_attr): Likewise.
6017 2024-07-15 Alexandre Oliva <oliva@adacore.com>
6020 * config/i386/i386-options.cc (ix86_option_override_internal):
6021 Move flag_omit_frame_pointer final overrider...
6022 (ix86_recompute_optlev_based_flags): ... here.
6024 2024-07-15 Georg-Johann Lay <avr@gjlay.de>
6026 * config/avr/avr.md: Simplify mode usage.
6027 (GET_MODE_SIZE (<MODE>mode)): Use <SIZE> instead.
6028 (GET_MODE_BITSIZE (<MODE>mode) - 1): Use <MSB> instead.
6029 (GET_MODE_MASK (QImode)): Use 0xff instead.
6030 * config/avr/avr-fixed.md: Same.
6032 2024-07-15 Jakub Jelinek <jakub@redhat.com>
6034 * configure.ac (HAVE_GAS_BASE64): New check.
6035 * config/elfos.h (BASE64_ASM_OP): Define if HAVE_GAS_BASE64 is
6037 * varasm.cc (assemble_string): Bump maximum from 2000 to 16384 if
6038 BASE64_ASM_OP is defined.
6039 (default_elf_asm_output_limited_string): Emit opening '"' together
6041 (default_elf_asm_output_ascii): Use BASE64_ASM_OP if defined and
6042 beneficial. Remove UB when last_null is NULL.
6043 * configure: Regenerate.
6044 * config.in: Regenerate.
6046 2024-07-15 liuhongt <hongtao.liu@intel.com>
6049 * tree-ssa-ccp.cc (convert_atomic_bit_not): Remove use_stmt after use_nop_stmt is removed.
6050 (optimize_atomic_bit_test_and): Ditto.
6052 2024-07-15 Hongyu Wang <hongyu.wang@intel.com>
6054 * config/i386/i386.md (has_nf): New define_attr, add to all
6055 nf related patterns.
6056 * config/i386/i386-features.cc (apx_nf_convert): New function
6057 to convert Non-NF insns to their NF counterparts.
6058 (class pass_apx_nf_convert): New pass class.
6059 (make_pass_apx_nf_convert): New.
6060 * config/i386/i386-passes.def: Add pass_apx_nf_convert after
6062 * config/i386/i386-protos.h (make_pass_apx_nf_convert): Declare.
6064 2024-07-15 Monk Chiang <monk.chiang@sifive.com>
6066 * config/riscv/riscv.cc (riscv_print_operand): Add 'L' letter
6067 to print zihintntl instructions string.
6068 * config/riscv/riscv.md (prefetch): Add zihintntl instructions.
6070 2024-07-15 Feng Wang <wangfeng@eswincomputing.com>
6072 * config/riscv/generic-vector-ooo.md: Add def_insn_reservation for vector BFloat16.
6073 * config/riscv/riscv.md: Add new insn name for vector BFloat16.
6074 * config/riscv/vector-iterators.md: Add some iterators for vector BFloat16.
6075 * config/riscv/vector.md: Add some attribute for vector BFloat16.
6076 * config/riscv/vector-bfloat16.md: New file. Add insn pattern vector BFloat16.
6078 2024-07-15 Feng Wang <wangfeng@eswincomputing.com>
6080 * config/riscv/riscv-vector-builtins-bases.cc (class vfncvtbf16_f):
6081 Add 'Zvfbfmin' intrinsic in bases.
6082 (class vfwcvtbf16_f): Ditto.
6083 (class vfwmaccbf16): Add 'Zvfbfwma' intrinsic in bases.
6084 (BASE): Add BASE macro for 'Zvfbfmin' and 'Zvfbfwma'.
6085 * config/riscv/riscv-vector-builtins-bases.h: Add declaration for 'Zvfbfmin' and 'Zvfbfwma'.
6086 * config/riscv/riscv-vector-builtins-functions.def (REQUIRED_EXTENSIONS):
6087 Add builtins def for 'Zvfbfmin' and 'Zvfbfwma'.
6088 (vfncvtbf16_f): Ditto.
6089 (vfncvtbf16_f_frm): Ditto.
6090 (vfwcvtbf16_f): Ditto.
6091 (vfwmaccbf16): Ditto.
6092 (vfwmaccbf16_frm): Ditto.
6093 * config/riscv/riscv-vector-builtins-shapes.cc (supports_vectype_p):
6094 Add vector intrinsic build judgment for BFloat16.
6096 (BASE_NAME_MAX_LEN): Adjust max length.
6097 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_F32_OPS):
6098 Add new operand type for BFloat16.
6099 (vfloat32mf2_t): Ditto.
6100 (vfloat32m1_t): Ditto.
6101 (vfloat32m2_t): Ditto.
6102 (vfloat32m4_t): Ditto.
6103 (vfloat32m8_t): Ditto.
6104 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_F32_OPS): Ditto.
6105 (validate_instance_type_required_extensions):
6106 Add required_ext checking for 'Zvfbfmin' and 'Zvfbfwma'.
6107 * config/riscv/riscv-vector-builtins.h (enum required_ext):
6108 Add required_ext declaration for 'Zvfbfmin' and 'Zvfbfwma'.
6109 (reqired_ext_to_isa_name): Ditto.
6110 (required_extensions_specified): Ditto.
6111 (struct function_group_info): Add match case for 'Zvfbfmin' and 'Zvfbfwma'.
6112 * config/riscv/riscv.cc (riscv_validate_vector_type):
6113 Add required_ext checking for 'Zvfbfmin' and 'Zvfbfwma'.
6115 2024-07-15 Hongyu Wang <hongyu.wang@intel.com>
6118 * config/i386/predicates.md (vcvtne2ps2bf_parallel): Remove.
6119 * config/i386/sse.md (hi_cvt_bf): Remove.
6120 (HI_CVT_BF): Likewise.
6121 (vpermt2_sepcial_bf16_shuffle_<mode>):Likewise.
6123 2024-07-15 Feng Wang <wangfeng@eswincomputing.com>
6125 * config/riscv/genrvv-type-indexer.cc (bfloat16_type):
6126 Generate bf16 vector_type and scalar_type in DEF_RVV_TYPE_INDEX.
6127 (bfloat16_wide_type): Ditto.
6128 (same_ratio_eew_bf16_type): Ditto.
6130 * config/riscv/riscv-modes.def (ADJUST_BYTESIZE):
6131 Add vector type for BFloat16.
6132 (RVV_WHOLE_MODES): Add vector type for BFloat16.
6133 (RVV_FRACT_MODE): Ditto.
6134 (RVV_NF4_MODES): Ditto.
6135 (RVV_NF8_MODES): Ditto.
6136 (RVV_NF2_MODES): Ditto.
6137 * config/riscv/riscv-vector-builtins-types.def (vbfloat16mf4_t):
6138 Add builtin vector type for BFloat16.
6139 (vbfloat16mf2_t): Add builtin vector type for BFloat16.
6140 (vbfloat16m1_t): Ditto.
6141 (vbfloat16m2_t): Ditto.
6142 (vbfloat16m4_t): Ditto.
6143 (vbfloat16m8_t): Ditto.
6144 (vbfloat16mf4x2_t): Ditto.
6145 (vbfloat16mf4x3_t): Ditto.
6146 (vbfloat16mf4x4_t): Ditto.
6147 (vbfloat16mf4x5_t): Ditto.
6148 (vbfloat16mf4x6_t): Ditto.
6149 (vbfloat16mf4x7_t): Ditto.
6150 (vbfloat16mf4x8_t): Ditto.
6151 (vbfloat16mf2x2_t): Ditto.
6152 (vbfloat16mf2x3_t): Ditto.
6153 (vbfloat16mf2x4_t): Ditto.
6154 (vbfloat16mf2x5_t): Ditto.
6155 (vbfloat16mf2x6_t): Ditto.
6156 (vbfloat16mf2x7_t): Ditto.
6157 (vbfloat16mf2x8_t): Ditto.
6158 (vbfloat16m1x2_t): Ditto.
6159 (vbfloat16m1x3_t): Ditto.
6160 (vbfloat16m1x4_t): Ditto.
6161 (vbfloat16m1x5_t): Ditto.
6162 (vbfloat16m1x6_t): Ditto.
6163 (vbfloat16m1x7_t): Ditto.
6164 (vbfloat16m1x8_t): Ditto.
6165 (vbfloat16m2x2_t): Ditto.
6166 (vbfloat16m2x3_t): Ditto.
6167 (vbfloat16m2x4_t): Ditto.
6168 (vbfloat16m4x2_t): Ditto.
6169 * config/riscv/riscv-vector-builtins.cc (check_required_extensions):
6170 Add required_ext checking for BFloat16.
6171 * config/riscv/riscv-vector-builtins.def (vbfloat16mf4_t):
6172 Add vector_type for BFloat16 in builtins.def.
6173 (vbfloat16mf4x2_t): Ditto.
6174 (vbfloat16mf4x3_t): Ditto.
6175 (vbfloat16mf4x4_t): Ditto.
6176 (vbfloat16mf4x5_t): Ditto.
6177 (vbfloat16mf4x6_t): Ditto.
6178 (vbfloat16mf4x7_t): Ditto.
6179 (vbfloat16mf4x8_t): Ditto.
6180 (vbfloat16mf2_t): Ditto.
6181 (vbfloat16mf2x2_t): Ditto.
6182 (vbfloat16mf2x3_t): Ditto.
6183 (vbfloat16mf2x4_t): Ditto.
6184 (vbfloat16mf2x5_t): Ditto.
6185 (vbfloat16mf2x6_t): Ditto.
6186 (vbfloat16mf2x7_t): Ditto.
6187 (vbfloat16mf2x8_t): Ditto.
6188 (vbfloat16m1_t): Ditto.
6189 (vbfloat16m1x2_t): Ditto.
6190 (vbfloat16m1x3_t): Ditto.
6191 (vbfloat16m1x4_t): Ditto.
6192 (vbfloat16m1x5_t): Ditto.
6193 (vbfloat16m1x6_t): Ditto.
6194 (vbfloat16m1x7_t): Ditto.
6195 (vbfloat16m1x8_t): Ditto.
6196 (vbfloat16m2_t): Ditto.
6197 (vbfloat16m2x2_t): Ditto.
6198 (vbfloat16m2x3_t): Ditto.
6199 (vbfloat16m2x4_t): Ditto.
6200 (vbfloat16m4_t): Ditto.
6201 (vbfloat16m4x2_t): Ditto.
6202 (vbfloat16m8_t): Ditto.
6203 (double_trunc_bfloat_scalar): Add scalar_type def for BFloat16.
6204 (double_trunc_bfloat_vector): Add vector_type def for BFloat16.
6205 * config/riscv/riscv-vector-builtins.h (RVV_REQUIRE_ELEN_BF_16):
6206 Add required defination of BFloat16 ext.
6207 * config/riscv/riscv-vector-switch.def (ENTRY):
6208 Add vector_type information for BFloat16.
6209 (TUPLE_ENTRY): Add tuple vector_type information for BFloat16.
6211 2024-07-14 Roger Sayle <roger@nextmovesoftware.com>
6213 * config/i386/i386-expand.cc (ix86_expand_fp_absneg_operator):
6214 Use E_?Fmode enumeration constants in switch statement.
6215 (ix86_expand_copysign): Likewise.
6216 (ix86_expand_xorsign): Likewise.
6218 2024-07-14 Alejandro Colomar <alx@kernel.org>
6221 * doc/invoke.texi: Document the new
6222 -Wunterminated-string-initialization.
6224 2024-07-14 Hans-Peter Nilsson <hp@axis.com>
6226 * config/cris/cris.cc (cris_option_override_after_change): Fix up
6227 comment regarding disabling late_combine.
6229 2024-07-14 Hans-Peter Nilsson <hp@axis.com>
6231 * config/cris/cris.cc (cris_option_override_after_change): New
6232 function. Disable late-combine by default.
6233 (cris_option_override): Call the new function.
6235 2024-07-13 Mark Harmstone <mark@harmstone.com>
6237 * dwarf2codeview.cc (write_lf_modifier): Expand upon comment.
6239 2024-07-13 Mark Harmstone <mark@harmstone.com>
6241 * dwarf2codeview.cc (write_data_symbol): Add alignment directive.
6243 2024-07-13 Mark Harmstone <mark@harmstone.com>
6245 * dwarf2codeview.cc (enum cv_leaf_type): Add padding constants.
6246 (write_cv_padding): Use names for padding constants.
6248 2024-07-13 Mark Harmstone <mark@harmstone.com>
6250 * dwarf2codeview.cc (S_LDATA32, S_GDATA32, S_COMPILE3): Undefine.
6251 (enum cv_sym_type): Define.
6252 (struct codeview_symbol): Use enum cv_sym_type.
6253 (write_codeview_symbols): Add default to switch.
6255 2024-07-13 Mark Harmstone <mark@harmstone.com>
6257 * dwarf2codeview.cc (enum cv_leaf_type): Define.
6258 (struct codeview_subtype): Use enum cv_leaf_type.
6259 (struct codeview_custom_type): Use enum cv_leaf_type.
6260 (write_lf_fieldlist): Add default to switch.
6261 (write_custom_types): Add default to switch.
6262 * dwarf2codeview.h (LF_MODIFIER, LF_POINTER): Undefine.
6263 (LF_PROCEDURE, LF_ARGLIST, LF_FIELDLIST, LF_BITFIELD): Likewise.
6264 (LF_INDEX, LF_ENUMERATE, LF_ARRAY, LF_CLASS): Likewise.
6265 (LF_STRUCTURE, LF_UNION, LF_ENUM, LF_MEMBER, LF_CHAR): Likewise.
6266 (LF_SHORT, LF_USHORT, LF_LONG, LF_ULONG, LF_QUADWORD): Likewise.
6267 (LF_UQUADWORD): Likewise.
6269 2024-07-13 David Malcolm <dmalcolm@redhat.com>
6271 * common.opt (fdiagnostics-show-highlight-colors): New option.
6272 * common.opt.urls: Regenerate.
6273 * coretypes.h (pp_markup::element): New forward decl.
6274 (pp_element): New typedef.
6275 * diagnostic-color.cc (gcc_color_defaults): Add "highlight-a"
6277 * diagnostic-format-json.cc (diagnostic_output_format_init_json):
6278 Disable highlight colors.
6279 * diagnostic-format-sarif.cc (diagnostic_output_format_init_sarif):
6281 * diagnostic-highlight-colors.h: New file.
6282 * diagnostic-path.cc (struct event_range): Pass nullptr for
6283 highlight color of m_rich_loc.
6284 * diagnostic-show-locus.cc (colorizer::set_range): Handle ranges
6285 with m_highlight_color.
6286 (colorizer::STATE_NAMED_COLOR): New.
6287 (colorizer::m_richloc): New field.
6288 (colorizer::colorizer): Add richloc param for initializing
6290 (colorizer::set_named_color): New.
6291 (colorizer::begin_state): Add case STATE_NAMED_COLOR.
6292 (layout::layout): Pass richloc to m_colorizer's ctor.
6293 (selftest::test_one_liner_labels): Pass nullptr for new param of
6294 gcc_rich_location ctor for labels.
6295 (selftest::test_one_liner_labels_utf8): Likewise.
6296 * diagnostic.h (diagnostic_context::set_show_highlight_colors):
6298 * doc/invoke.texi: Add option -fdiagnostics-show-highlight-colors
6299 and highlight-a and highlight-b color caps.
6301 (Use color consistently when highlighting mismatches): New
6303 * gcc-rich-location.cc (gcc_rich_location::add_expr): Add
6304 "highlight_color" param.
6305 (gcc_rich_location::maybe_add_expr): Likewise.
6306 * gcc-rich-location.h (gcc_rich_location::gcc_rich_location):
6307 Split out into a pair of ctors, where if a range_label is supplied
6308 the caller must also supply a highlight color.
6309 (gcc_rich_location::add_expr): Add "highlight_color" param.
6310 (gcc_rich_location::maybe_add_expr): Likewise.
6311 * gcc.cc (driver_handle_option): Handle
6312 OPT_fdiagnostics_show_highlight_colors.
6313 * lto-wrapper.cc (merge_and_complain): Likewise.
6314 (append_compiler_options): Likewise.
6315 (append_diag_options): Likewise.
6316 (run_gcc): Likewise.
6317 * opts-common.cc (decode_cmdline_options_to_array): Add comment
6318 about -fno-diagnostics-show-highlight-colors.
6319 * opts-global.cc (init_options_once): Preserve
6320 pp_show_highlight_colors in case the global_dc's printer is
6322 * opts.cc (common_handle_option): Handle
6323 OPT_fdiagnostics_show_highlight_colors.
6324 (gen_command_line_string): Likewise.
6325 * pretty-print-markup.h: New file.
6326 * pretty-print.cc: Include "pretty-print-markup.h" and
6327 "diagnostic-highlight-colors.h".
6328 (pretty_printer::format): Handle %e.
6329 (pretty_printer::pretty_printer): Handle new field
6330 m_show_highlight_colors.
6332 (pp_markup::context::begin_quote): New.
6333 (pp_markup::context::end_quote): New.
6334 (pp_markup::context::begin_color): New.
6335 (pp_markup::context::end_color): New.
6336 (highlight_colors::expected): New.
6337 (highlight_colors::actual): New.
6338 (highlight_colors::lhs): New.
6339 (highlight_colors::rhs): New.
6340 (class selftest::test_element): New.
6341 (selftest::test_pp_format): Add tests of %e.
6342 (selftest::test_urlification): Likewise.
6343 * pretty-print.h (pp_markup::context): New forward decl.
6344 (class chunk_info): Add friend class pp_markup::context.
6345 (class pretty_printer): Add friend pp_show_highlight_colors.
6346 (pretty_printer::m_show_highlight_colors): New field.
6347 (pp_show_highlight_colors): New inline function.
6348 (pp_string_n): New decl.
6349 * substring-locations.cc: Include "diagnostic-highlight-colors.h".
6350 (format_string_diagnostic_t::highlight_color_format_string): New.
6351 (format_string_diagnostic_t::highlight_color_param): New.
6352 (format_string_diagnostic_t::emit_warning_n_va): Use highlight
6354 * substring-locations.h
6355 (format_string_diagnostic_t::highlight_color_format_string): New.
6356 (format_string_diagnostic_t::highlight_color_param): New.
6357 * toplev.cc (general_init): Initialize global_dc's
6358 show_highlight_colors.
6359 * tree-pretty-print-markup.h: New file.
6361 2024-07-13 Richard Biener <rguenther@suse.de>
6363 PR tree-optimization/115868
6364 * tree-vect-stmts.cc (vectorizable_simd_clone_call): Correctly
6365 compute the number of mask copies required for vect_record_loop_mask.
6367 2024-07-12 Gerald Pfeifer <gerald@pfeifer.com>
6369 * doc/gm2.texi (Community): Update lists.nongnu.org and
6370 lists.gnu.org links.
6372 2024-07-12 Jeff Law <jlaw@ventanamicro.com>
6374 PR rtl-optimization/115876
6375 * ext-dce.cc (carry_backpropagate): Make mask and mmask unsigned.
6377 2024-07-12 Marek Polacek <polacek@redhat.com>
6379 * doc/invoke.texi: Remove @opindex and @itemx for -fconcepts-ts.
6381 2024-07-12 Daniel Bertalan <dani@danielbertalan.dev>
6383 * value-pointer-equiv.cc: Change NULL to nullptr.
6385 2024-07-12 Richard Sandiford <richard.sandiford@arm.com>
6387 PR rtl-optimization/115785
6388 * rtl-ssa/insns.h (insn_info::prev_insn_or_last_debug_insn)
6389 (insn_info::next_nondebug_or_debug_insn): Remove typedefs.
6390 (insn_info::m_prev_insn_or_last_debug_insn): Rename to...
6391 (insn_info::m_prev_sametype_or_last_debug_insn): ...this.
6392 * rtl-ssa/internals.inl (insn_info::insn_info): Update after
6394 (insn_info::copy_prev_from): Likewise.
6395 (insn_info::set_prev_sametype_insn): Likewise.
6396 (insn_info::set_last_debug_insn): Likewise.
6397 (insn_info::clear_insn_links): Likewise.
6398 (insn_info::has_insn_links): Likewise.
6399 * rtl-ssa/member-fns.inl (insn_info::prev_nondebug_insn): Likewise.
6400 (insn_info::prev_any_insn): Fix moves from non-debug to debug insns.
6402 2024-07-12 Jeff Law <jlaw@ventanamicro.com>
6404 * config/riscv/riscv-string.cc (emit_memcmp_scalar_load_and_compare):
6405 Set RESULT directly rather than using a temporary.
6406 (emit_memcmp_scalar_result_calculation): Similarly.
6407 (riscv_expand_block_compare_scalar): Use CONST0_RTX rather than
6409 * config/riscv/riscv.md (cmpmemsi): Pass an X mode temporary to the
6410 expansion routines. If necessary extract low part of the word to store
6411 in final result location.
6413 2024-07-12 Stefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
6415 * config/s390/2964.md: Remove extended mnemonics for vgm.
6416 * config/s390/3906.md: Remove extended mnemonics for vgm.
6417 * config/s390/3931.md: Remove extended mnemonics for vgm.
6418 * config/s390/8561.md: Remove extended mnemonics for vgm.
6419 * config/s390/constraints.md (jKK): Remove constraint.
6420 (jzz): Add constraint.
6421 * config/s390/s390-protos.h (s390_contiguous_bitmask_vector_p):
6423 (s390_constant_via_vgm_p): Add prototype.
6424 (s390_constant_via_vrepi_p): Add prototype.
6425 * config/s390/s390.cc (s390_contiguous_bitmask_vector_p): New
6427 (s390_constant_via_vgm_vrepi_helper): New function.
6428 (s390_constant_via_vgm_p): New function.
6429 (s390_constant_via_vgbm_p): For the sake of symmetry rename
6430 s390_bytemask_vector_p into s390_constant_via_vgbm_p.
6431 (s390_bytemask_vector_p): Deal with non-integer and partial
6433 (s390_constant_via_vrepi_p): New function.
6434 (s390_legitimate_constant_p): Allow partial vectors.
6435 (legitimate_reload_constant_p): Fix indentation.
6436 (legitimate_reload_vector_constant_p): Restrict to constraints
6437 j00, jm1, jxx, jyy, jzz only, i.e., allow partial vectors.
6438 (s390_expand_vec_init): Also make use of vrepi if possible.
6439 (print_operand): Add q,p,r for vgm,vrepi,vgbm, respectively.
6440 Remove e,s,t for constant vectors.
6441 * config/s390/s390.md (movti): Add variants utilizing
6443 * config/s390/vector.md (mov<mode><tf_vr>): Adapt variants
6444 for vgbm,vgm,vrepi for the new scheme.
6445 (mov<mode>): Adapt variants for vgbm,vgm for the new
6446 scheme and add vrepi variant for modes V_8,V_16,V_32,V_64.
6448 2024-07-12 Stefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
6450 * config/s390/vector.md (mov<mode>): Fix output template for
6453 2024-07-12 Roger Sayle <roger@nextmovesoftware.com>
6454 Hongtao Liu <hongtao.liu@intel.com>
6456 * config/i386/i386-expand.cc (ix86_broadcast_from_constant):
6457 Use CONST_VECTOR_P instead of comparison against GET_CODE.
6458 (ix86_gen_bcst_mem): Likewise.
6459 (ix86_ternlog_leaf_p): Likewise.
6460 (ix86_ternlog_operand_p): ix86_ternlog_leaf_p is always true for
6461 vector_all_ones_operand.
6462 (ix86_expand_ternlog_bin_op): Use CONST_VECTOR_P instead of
6463 equality comparison against GET_CODE. Replace call to force_reg
6464 with gen_reg_rtx and emit_move_insn (for VEC_DUPLICATE broadcast).
6465 Check for !register_operand instead of memory_operand.
6466 Support CONST_VECTORs by calling force_const_mem.
6467 (ix86_expand_ternlog): Fix indentation whitespace.
6468 Allow ix86_ternlog_leaf_p as ix86_expand_ternlog_andnot's second
6469 operand. Use CONST_VECTOR_P instead of equality against GET_CODE.
6470 Use gen_reg_rtx and emit_move_insn for ~a, ~b and ~c cases.
6472 2024-07-12 Stefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
6474 * config/s390/s390.md (*icjump_64): Allow raw CC comparisons,
6475 i.e., any constant integer between 0 and 15 for CC comparisons.
6477 2024-07-12 Richard Sandiford <richard.sandiford@arm.com>
6479 * config/aarch64/aarch64.cc (aarch64_process_one_target_attr)
6480 (aarch64_process_target_attr): Avoid alloca.
6482 2024-07-12 Alexandre Oliva <oliva@adacore.com>
6485 * config/alpha/alpha.cc (alpha_expand_block_move): Adjust
6486 MEMs to match inferred alignment.
6488 2024-07-12 YunQiang Su <yunqiang@isrc.iscas.ac.cn>
6491 * config/riscv/riscv.cc(riscv_preferred_else_value): Mark
6492 tmp_var as NO_WARNING.
6494 2024-07-12 xuli <xuli1@eswincomputing.com>
6497 * config/riscv/riscv.cc (riscv_slow_unaligned_access): Disable vector misalign.
6499 2024-07-12 Kito Cheng <kito.cheng@sifive.com>
6501 * common/config/riscv/riscv-common.cc (riscv_implied_info): Add xsfvcp.
6502 (riscv_ext_version_table): Add xsfvcp, xsfcease.
6503 (riscv_ext_flag_table): Ditto.
6504 * config/riscv/riscv.opt (riscv_sifive_subext): New.
6508 2024-07-12 Kewen Lin <linkw@linux.ibm.com>
6511 * config/rs6000/rs6000-protos.h (rs6000_emit_vector_cond_expr): Remove.
6512 * config/rs6000/rs6000.cc (rs6000_emit_vector_cond_expr): Add static
6513 qualifier as it is only called by rs6000_emit_swsqrt now.
6514 * config/rs6000/vector.md (vcond<VEC_F:mode><VEC_F:mode>): Remove.
6515 (vcond<VEC_I:mode><VEC_I:mode>): Remove.
6516 (vcondv4sfv4si): Likewise.
6517 (vcondv4siv4sf): Likewise.
6518 (vcondv2dfv2di): Likewise.
6519 (vcondv2div2df): Likewise.
6520 (vcondu<VEC_I:mode><VEC_I:mode>): Likewise.
6521 (vconduv4sfv4si): Likewise.
6522 (vconduv2dfv2di): Likewise.
6524 2024-07-12 Richard Biener <rguenther@suse.de>
6526 PR tree-optimization/115867
6527 * tree-vect-stmts.cc (vectorizable_simd_clone_call): Properly
6528 guess the number of mask elements for integer mode masks.
6530 2024-07-12 Jeff Law <jlaw@ventanamicro.com>
6532 * config/m68k/m68k.md (extendsidi2): Add missing early clobbers.
6534 2024-07-12 Lulu Cheng <chenglulu@loongson.cn>
6536 * config/loongarch/loongarch.cc
6537 (loongarch_split_move): Delete.
6538 (loongarch_hard_regno_mode_ok_uncached): Likewise.
6539 * config/loongarch/loongarch.md
6540 (move_doubleword_fpr<mode>): Likewise.
6541 (load_low<mode>): Likewise.
6542 (load_high<mode>): Likewise.
6543 (store_word<mode>): Likewise.
6544 (movgr2frh<mode>): Likewise.
6545 (movfrh2gr<mode>): Likewise.
6547 2024-07-12 Lulu Cheng <chenglulu@loongson.cn>
6550 * config/loongarch/loongarch.cc
6551 (loongarch_hard_regno_mode_ok_uncached): Replace
6552 UNITS_PER_FPVALUE with UNITS_PER_HWFPVALUE.
6553 * config/loongarch/loongarch.h (UNITS_PER_FPVALUE): Delete.
6555 2024-07-11 Jeff Law <jlaw@ventanamicro.com>
6557 * config/riscv/riscv-string.cc
6558 (emit_strcmp_scalar_compare_byte): Set RESULT directly rather
6559 than using a new temporary.
6560 (emit_strcmp_scalar_result_calculation_nonul): Likewise.
6561 (emit_strcmp_scalar_result_calculation): Likewise.
6562 (riscv_expand_strcmp_scalar): Use CONST0_RTX rather than
6563 generating a new node.
6564 (expand_strcmp): Copy directly from SUB to RESULT.
6565 * config/riscv/riscv.md (cmpstrnsi, cmpstrsi): Pass an X
6566 mode temporary to the expansion routines. If necessary
6567 extract low part of the word to store in final result location.
6569 2024-07-11 Andrew Pinski <quic_apinski@quicinc.com>
6571 * value-range.h (class int_range): Mark as final.
6572 (class prange): Likewise.
6573 (class frange): Likewise.
6575 2024-07-11 Andre Vieira <andre.simoesdiasvieira@arm.com>
6578 * config/arm/mve.md (mve_vec_setv2di_internal): Fix printing of input
6579 scalar register pair when lane = 1.
6581 2024-07-11 Richard Sandiford <richard.sandiford@arm.com>
6583 PR rtl-optimization/115782
6584 * recog.cc (validate_change_1): Suppress early exit for no-op
6585 changes that are part of a group.
6587 2024-07-11 Eric Botcazou <ebotcazou@adacore.com>
6589 * gimplify.cc (gimplify_scalar_mode_aggregate_compare): Add support
6590 for ordering comparisons.
6591 (gimplify_expr) <default>: Call gimplify_scalar_mode_aggregate_compare
6592 only for integral scalar modes.
6594 2024-07-11 Georg-Johann Lay <avr@gjlay.de>
6596 * config/avr/avr-protos.h (avr_out_minus): New prototype.
6597 * config/avr/avr.cc (avr_out_minus): New function.
6598 * config/avr/avr.md (*sub<HISI:mode>3.zero_extend.<QIPSI:mode>)
6599 (*sub<HISI:mode>3.zero_extend.<QIPSI:mode>_split): New insns.
6600 (*subpsi3_zero_extend.qi_split): Remove isns_and_split.
6601 (*subpsi3_zero_extend.hi_split): Remove insn_and_split.
6602 (*subhi3_zero_extend1_split): Remove insn_and_split.
6603 (*subsi3_zero_extend_split): Remove insn_and_split.
6604 (*subsi3_zero_extend.hi_split): Remove insn_and_split.
6605 (*subpsi3_zero_extend.qi): Remove insn.
6606 (*subpsi3_zero_extend.hi): Remove insn.
6607 (*subhi3_zero_extend1): Remove insn.
6608 (*subsi3_zero_extend): Remove insn.
6609 (*subsi3_zero_extend.hi): Remove insn.
6611 2024-07-11 Jørgen Kvalsvik <j@lambda.is>
6613 * doc/gcov.texi: Add --include, --exclude, --match-on-demangled
6615 * gcov.cc (struct fnfilter): New.
6616 (print_usage): Add --include, --exclude, -M,
6617 --match-on-demangled.
6618 (process_args): Likewise.
6619 (release_structures): Release filters.
6620 (read_graph_file): Only add function_infos matching filters.
6621 (output_lines): Likewise.
6623 2024-07-11 Jørgen Kvalsvik <j@lambda.is>
6625 * gcov.cc (process_all_functions): Ensure fn.end_line is
6626 included source[fn].lines.
6628 2024-07-11 Fei Gao <gaofei@eswincomputing.com>
6630 * common/config/riscv/riscv-common.cc:
6631 c implies zca, and conditionally zcf & zcd.
6633 2024-07-10 Pan Li <pan2.li@intel.com>
6635 * tree-vect-patterns.cc (vect_recog_sat_sub_pattern_transform):
6636 Add new func impl to perform the truncation distribution.
6637 (vect_recog_sat_sub_pattern): Perform above optimize before
6638 generate .SAT_SUB call.
6640 2024-07-10 Uros Bizjak <ubizjak@gmail.com>
6642 * config/i386/i386.md (ustruncdi<mode>2): Swap compare operands.
6643 (ustruncsi<mode>2): Ditto.
6644 (ustrunchiqi2): Ditto.
6646 2024-07-10 Marek Polacek <polacek@redhat.com>
6648 * doc/invoke.texi: Mention that -fconcepts-ts was removed.
6650 2024-07-10 Edwin Lu <ewlu@rivosinc.com>
6652 * common/config/riscv/riscv-common.cc: Add imply rules for B extension
6653 * config/riscv/arch-canonicalize: Ditto
6655 2024-07-10 Richard Sandiford <richard.sandiford@arm.com>
6657 * internal-fn.cc (create_call_lhs_operand, assign_call_lhs): New
6658 functions, split out from...
6659 (expand_fn_using_insn): ...here.
6660 (expand_load_lanes_optab_fn): Use them.
6661 (expand_GOMP_SIMT_ENTER_ALLOC): Likewise.
6662 (expand_GOMP_SIMT_LAST_LANE): Likewise.
6663 (expand_GOMP_SIMT_ORDERED_PRED): Likewise.
6664 (expand_GOMP_SIMT_VOTE_ANY): Likewise.
6665 (expand_GOMP_SIMT_XCHG_BFLY): Likewise.
6666 (expand_GOMP_SIMT_XCHG_IDX): Likewise.
6667 (expand_partial_load_optab_fn): Likewise.
6668 (expand_vec_cond_optab_fn): Likewise.
6669 (expand_vec_cond_mask_optab_fn): Likewise.
6670 (expand_RAWMEMCHR): Likewise.
6671 (expand_gather_load_optab_fn): Likewise.
6672 (expand_while_optab_fn): Likewise.
6673 (expand_SPACESHIP): Likewise.
6675 2024-07-10 Richard Sandiford <richard.sandiford@arm.com>
6677 * recog.cc (insn_propagation::apply_to_rvalue_1): Handle simple
6678 cases of hardreg propagation in which the register is set and
6679 used in different modes.
6681 2024-07-10 Richard Sandiford <richard.sandiford@arm.com>
6683 PR rtl-optimization/115785
6684 * rtl-ssa/functions.h (function_info::replace_nondebug_insn): Declare.
6685 * rtl-ssa/insns.h (insn_info::order_node::set_uid): New function.
6686 (insn_info::remove_note): Declare.
6687 * rtl-ssa/insns.cc (insn_info::remove_note): New function.
6688 (function_info::replace_nondebug_insn): Likewise.
6689 * rtl-ssa/changes.cc (function_info::change_insns): Use
6690 replace_nondebug_insn instead of remove_insn + add_insn.
6692 2024-07-10 Uros Bizjak <ubizjak@gmail.com>
6694 PR middle-end/115836
6695 * expmed.cc (emit_store_flag_1): Move calculation of
6696 scode just before its only usage site.
6698 2024-07-10 Richard Earnshaw <rearnsha@arm.com>
6700 * config/arm/arm-protos.h (arm_dllexport_name_p): Remove prototype.
6701 (arm_dllimport_name_p): Likewise.
6702 (arm_pe_unique_section): Likewise.
6703 (arm_pe_encode_section_info): Likewise.
6704 (arm_dllexport_p): Likewise.
6705 (arm_dllimport_p): Likewise.
6706 (arm_mark_dllexport): Likewise.
6707 (arm_mark_dllimport): Likewise.
6708 (arm_change_mode_p): Likewise.
6709 * config/arm/arm.cc (arm_gnu_attributes): Remove attributes for ARM_PE.
6710 (TARGET_ENCODE_SECTION_INFO): Remove setting for ARM_PE.
6711 (is_called_in_ARM_mode): Remove ARM_PE conditional code.
6712 (thumb1_output_interwork): Remove obsolete ARM_PE code.
6713 (arm_encode_section_info): Remove surrounding #ifndef.
6715 2024-07-10 Prathamesh Kulkarni <prathameshk@nvidia.com>
6718 * lto-streamer.h: Remove streamer_debugging definition.
6719 * lto-streamer-out.cc (stream_write_tree_ref): Remove use of streamer_debugging.
6720 (lto_output_tree): Likewise.
6721 * tree-streamer-in.cc (streamer_read_tree_bitfields): Likewise.
6722 (streamer_get_pickled_tree): Likewise.
6723 * tree-streamer-out.cc (pack_ts_base_value_fields): Likewise.
6725 2024-07-10 Pan Li <pan2.li@intel.com>
6727 * match.pd: Add form 2 for .SAT_TRUNC.
6728 * tree-ssa-math-opts.cc (math_opts_dom_walker::after_dom_children):
6729 Add new case NOP_EXPR, and try to match SAT_TRUNC.
6731 2024-07-10 Andrew Pinski <quic_apinski@quicinc.com>
6733 PR tree-optimization/115721
6734 * tree-complex.cc (expand_complex_comparison): Remove
6735 support for GIMPLE_RETURN.
6737 2024-07-10 Fei Gao <gaofei@eswincomputing.com>
6740 * config/riscv/riscv.cc (riscv_zcmp_can_use_popretz): Removed.
6741 (riscv_gen_multi_pop_insn): Remove generation of cm.popretz.
6743 2024-07-09 Carl Love <cel@linux.ibm.com>
6745 * config/rs6000/rs6000-builtin.cc (altivec_expand_vec_init_builtin):
6746 Remove the function.
6747 (rs6000_expand_builtin): Remove the if bif_is_int check to call
6748 the altivec_expand_vec_init_builtin function.
6749 * config/rs6000/rs6000-builtins.def: Remove the attribute string
6751 (__builtin_vec_init_v16qi,
6752 __builtin_vec_init_v4sf, __builtin_vec_init_v4si,
6753 __builtin_vec_init_v8hi, __builtin_vec_init_v1ti,
6754 __builtin_vec_init_v2df, __builtin_vec_init_v2di,
6755 __builtin_vec_set_v16qi, __builtin_vec_set_v4sf,
6756 __builtin_vec_set_v4si, __builtin_vec_set_v8hi): Remove
6757 built-in definitions.
6758 * config/rs6000/rs6000-gen-builtins.cc: Remove comment for init
6760 (struct attrinfo): Remove isinit entry.
6761 (parse_bif_attrs): Remove the if statement to check for attribute
6763 (ifdef DEBUG): Remove print for init attribute string.
6764 (write_decls): Remove print for define bif_init_bit and
6765 define for bif_is_init.
6766 (write_bif_static_init): Remove if bifp->attrs.isinit statement.
6768 2024-07-09 Carl Love <cel@linux.ibm.com>
6770 * config/rs6000/rs6000-builtins.def (__builtin_vsx_xvcmpeqsp_p):
6771 Remove built-in definition.
6773 2024-07-09 Carl Love <cel@linux.ibm.com>
6775 * config/rs6000/rs6000-overload.def (vec_xxpermdi): Add new
6776 overloaded built-in instances of vector signed and unsigned
6778 * doc/extend.texi: Add documentation for built-in instances of
6779 vector signed and unsigned int128.
6781 2024-07-09 Carl Love <cel@linux.ibm.com>
6783 * config/rs6000/rs6000-builtins.def (__builtin_vsx_xvnegdp,
6784 __builtin_vsx_xvnegsp): Remove built-in definitions.
6786 2024-07-09 Carl Love <cel@linux.ibm.com>
6788 * config/rs6000/rs6000-builtins.def (__builtin_vsx_vperm_16qi_uns,
6789 __builtin_vsx_vperm_1ti, __builtin_vsx_vperm_1ti_uns,
6790 __builtin_vsx_vperm_2df, __builtin_vsx_vperm_2di,
6791 __builtin_vsx_vperm_2di_uns, __builtin_vsx_vperm_4sf,
6792 __builtin_vsx_vperm_4si, __builtin_vsx_vperm_4si_uns): Remove
6793 built-in definitions and comments.
6795 2024-07-09 Carl Love <cel@linux.ibm.com>
6797 * config/rs6000/rs6000-builtins.def (__builtin_vsx_xxsel_16qi,
6798 __builtin_vsx_xxsel_16qi_uns, __builtin_vsx_xxsel_2df,
6799 __builtin_vsx_xxsel_2di, __builtin_vsx_xxsel_2di_uns,
6800 __builtin_vsx_xxsel_4sf, __builtin_vsx_xxsel_4si,
6801 __builtin_vsx_xxsel_4si_uns, __builtin_vsx_xxsel_8hi,
6802 __builtin_vsx_xxsel_8hi_uns): Remove built-in definitions.
6804 2024-07-09 Carl Love <cel@linux.ibm.com>
6806 * config/rs6000/rs6000-builtins.def (__builtin_vsx_xxsel_1ti,
6807 __builtin_vsx_xxsel_1ti_uns): Remove built-in definitions.
6808 * config/rs6000/rs6000-overload.def (vec_sel): Add new
6809 overloaded vector signed, unsigned and bool 128-bit definitions.
6810 * doc/extend.texi (vec_sel): Add documentation for new instances
6811 with signed, unsigned and bool 129-bit bool arguments.
6813 2024-07-09 Carl Love <cel@linux.ibm.com>
6815 * config/rs6000/rs6000-builtins.def (__builtin_vsx_xxmrghw,
6816 __builtin_vsx_xxmrghw_4si, __builtin_vsx_xxmrglw,
6817 __builtin_vsx_xxmrglw_4si, __builtin_vsx_xxsel_16qi): Remove
6818 built-in definition.
6819 * config/rs6000/rs6000-builtin.cc (rs6000_gimple_fold_builtin):
6820 remove case entries RS6000_BIF_XXMRGLW_4SI,
6821 RS6000_BIF_XXMRGLW_4SF, RS6000_BIF_XXMRGHW_4SI,
6822 RS6000_BIF_XXMRGHW_4SF.
6823 * config/rs6000/vsx.md (vsx_xxmrghw_<mode>, vsx_xxmrglw_<mode>):
6824 Remove unused define_expands.
6826 2024-07-09 Carl Love <cel@linux.ibm.com>
6828 * config/rs6000/rs6000-builtins.def (__builtin_vsx_xvcvspdp,
6829 __builtin_vsx_xvcvdpsp, __builtin_vsx_xvcvsxwdp,
6830 __builtin_vsx_xvcvuxddp_uns): Remove.
6832 2024-07-09 Carl Love <cel@linux.ibm.com>
6834 * config/rs6000/rs6000-builtins.def (__builtin_vsx_xvcvspsxds,
6835 __builtin_vsx_xvcvspuxds): Rename to __builtin_vsignede_v4sf,
6836 __builtin_vunsignede_v4sf respectively.
6837 (XVCVSPSXDS, XVCVSPUXDS): Rename to VEC_VSIGNEDE_V4SF,
6838 VEC_VUNSIGNEDE_V4SF respectively.
6839 (__builtin_vsignedo_v4sf, __builtin_vunsignedo_v4sf): New
6840 built-in definitions.
6841 * config/rs6000/rs6000-overload.def (vec_signede, vec_signedo,
6842 vec_unsignede, vec_unsignedo): Add new overloaded specifications.
6843 * config/rs6000/vsx.md (vsignede_v4sf, vsignedo_v4sf,
6844 vunsignede_v4sf, vunsignedo_v4sf): New define_expands.
6845 * doc/extend.texi (vec_signedo, vec_signede, vec_unsignedo,
6846 vec_unsignede): Add documentation for new overloaded built-ins to
6847 convert vector float to vector {un,}signed long long.
6849 2024-07-09 Carl Love <cel@linux.ibm.com>
6851 * config/rs6000/rs6000-builtins.def (__builtin_vsx_vunsigned_v2df,
6852 __builtin_vsx_vunsigned_v4sf, __builtin_vsx_vunsignede_v2df,
6853 __builtin_vsx_vunsignedo_v2df): Change the result type to unsigned.
6855 2024-07-09 Carl Love <cel@linux.ibm.com>
6857 * config/rs6000/rs6000-builtins.def (__builtin_vsx_xvcvspsxws,
6858 __builtin_vsx_xvcvdpuxds_uns, __builtin_vsx_xvcvspuxws,
6859 __builtin_vsx_xvcvdpsxws, __builtin_vsx_xvcvdpuxws): Remove
6860 built-in definitions.
6862 2024-07-09 Carl Love <cel@linux.ibm.com>
6864 * config/rs6000/rs6000-builtin.cc (RS6000_BIF_CMPLE_16QI,
6865 RS6000_BIF_CMPLE_U16QI, RS6000_BIF_CMPLE_8HI,
6866 RS6000_BIF_CMPLE_U8HI, RS6000_BIF_CMPLE_4SI, RS6000_BIF_CMPLE_U4SI,
6867 RS6000_BIF_CMPLE_2DI, RS6000_BIF_CMPLE_U2DI, RS6000_BIF_CMPLE_1TI,
6868 RS6000_BIF_CMPLE_U1TI): Remove case statements.
6869 * config/rs6000/rs6000-builtins.def (__builtin_vsx_cmple_16qi,
6870 __builtin_vsx_cmple_2di, __builtin_vsx_cmple_4si,
6871 __builtin_vsx_cmple_8hi, __builtin_vsx_cmple_u16qi,
6872 __builtin_vsx_cmple_u2di, __builtin_vsx_cmple_u4si,
6873 __builtin_vsx_cmple_u8hi): Remove buit-in definitions.
6875 2024-07-09 Uros Bizjak <ubizjak@gmail.com>
6877 * config/i386/i386.md (@cmp<mode>_1): Use SWI mode iterator.
6878 (ustruncdi<mode>2): New expander.
6879 (ustruncsi<mode>2): Ditto.
6880 (ustrunchiqi2): Ditto.
6882 2024-07-09 David Malcolm <dmalcolm@redhat.com>
6884 * diagnostic-path.cc: Replace "const diagnostic_path *" with
6885 "const diagnostic_path &" throughout, and "diagnostic_context *"
6886 with "diagnostic context &".
6887 * diagnostic.cc (diagnostic_context::show_any_path): Pass
6888 reference in call to print_path.
6889 * diagnostic.h (diagnostic_context::print_path): Convert param
6892 2024-07-09 Richard Earnshaw <rearnsha@arm.com>
6894 * config/arm/arm.cc (fp_consts_initited): Delete variable.
6895 (value_fp0): Likewise.
6896 (init_fp_table): Delete function.
6897 (fp_const_from_val): Likewise.
6898 (arm_const_double_rtx): Rework to avoid converting to REAL_VALUE_TYPE.
6899 (arm_print_operand, case 'N'): Make use of this case an error.
6901 2024-07-09 Christoph Müllner <christoph.muellner@vrull.eu>
6903 * config/riscv/riscv-target-attr.cc (riscv_process_target_attr):
6904 Fix comments and variable names.
6906 2024-07-09 Christoph Müllner <christoph.muellner@vrull.eu>
6908 * common/config/riscv/riscv-common.cc (riscv_set_arch_by_subset_list):
6910 (riscv_parse_arch_string): Replace duplicated code by a call to
6911 riscv_set_arch_by_subset_list.
6913 2024-07-09 Haochen Jiang <haochen.jiang@intel.com>
6915 * common/config/i386/cpuinfo.h (get_available_features): Correct
6916 AVX10 CPUID emulation to specify ecx value.
6918 2024-07-09 liuhongt <hongtao.liu@intel.com>
6921 * config/i386/emmintrin.h (__float_u): Rename to ..
6922 (__x86_float_u): .. this.
6923 (_mm_load_sd): Ditto.
6924 (_mm_store_sd): Ditto.
6925 (_mm_loadh_pd): Ditto.
6926 (_mm_loadl_pd): Ditto.
6927 * config/i386/xmmintrin.h (__double_u): Rename to ..
6928 (__x86_double_u): .. this.
6929 (_mm_load_ss): Ditto.
6930 (_mm_store_ss): Ditto.
6932 2024-07-08 Jeff Law <jlaw@ventanamicro.com>
6934 * Makefile.in (OBJS): Add ext-dce.o
6935 * common.opt (ext-dce): Document new option.
6936 * df-scan.cc (df_get_ext_block_use_set): Delete prototype and
6938 * df.h (df_get_exit_block_use_set): Prototype.
6939 * ext-dce.cc: New file/pass.
6940 * opts.cc (default_options_table): Handle ext-dce at -O2 or higher.
6941 * passes.def: Add ext-dce before combine.
6942 * tree-pass.h (make_pass_ext_dce): Prototype.
6944 2024-07-08 Uros Bizjak <ubizjak@gmail.com>
6946 * config/i386/i386.md (x86_mov<mode>cc_0_m1_neg splitter to SImode):
6948 (NEG and NOT splitter to SImode): Remove optimize_insn_for_size_p
6949 predicate from insn condition.
6951 2024-07-08 Patrick O'Neill <patrick@rivosinc.com>
6953 * doc/invoke.texi: Remove trailing whitespace.
6955 2024-07-08 Levy Hsu <admin@levyhsu.com>
6957 * config/i386/i386-expand.cc (ix86_expand_fp_absneg_operator): Add VBF modes.
6958 (ix86_expand_copysign): Ditto.
6959 (ix86_expand_xorsign): Ditto.
6960 * config/i386/i386.cc (ix86_build_const_vector): Ditto.
6961 (ix86_build_signbit_mask): Ditto.
6962 * config/i386/sse.md: Ditto.
6964 2024-07-08 Jeevitha Palanisamy <jeevitha@linux.ibm.com>
6967 * config/rs6000/vsx.md (split pattern for V1TI to DI move): New define.
6969 2024-07-08 Pan Li <pan2.li@intel.com>
6971 * config/riscv/autovec.md (ustrunc<mode><v_double_trunc>2): Add
6972 new pattern for double truncation.
6973 (ustrunc<mode><v_quad_trunc>2): Ditto but for quad truncation.
6974 (ustrunc<mode><v_oct_trunc>2): Ditto but for oct truncation.
6975 * config/riscv/riscv-protos.h (expand_vec_double_ustrunc): Add
6976 new func decl to expand double vec ustrunc.
6977 (expand_vec_quad_ustrunc): Ditto but for quad.
6978 (expand_vec_oct_ustrunc): Ditto but for oct.
6979 * config/riscv/riscv-v.cc (expand_vec_double_ustrunc): Add new
6980 func impl to expand vector double ustrunc.
6981 (expand_vec_quad_ustrunc): Ditto but for quad.
6982 (expand_vec_oct_ustrunc): Ditto but for oct.
6984 2024-07-08 Fei Gao <gaofei@eswincomputing.com>
6986 * common/config/riscv/riscv-common.cc (riscv_subset_list::riscv_subset_list):
6987 init m_subset_num to 0.
6988 (riscv_subset_list::add): increase m_subset_num once a subset added.
6989 (riscv_subset_list::finalize): call handle_implied_ext repeatly
6990 until no change in m_subset_num.
6991 * config/riscv/riscv-subset.h: add m_subset_num member.
6993 2024-07-08 Kewen Lin <linkw@linux.ibm.com>
6995 PR tree-optimization/115659
6996 * config/rs6000/rs6000-builtins.def: Update some bif expanders by
6997 replacing orc<mode>3 with iorc<mode>3.
6998 * config/rs6000/rs6000-string.cc (expand_cmp_vec_sequence): Update gen
6999 function by replacing orc<mode>3 with iorc<mode>3.
7000 * config/rs6000/rs6000.md (orc<mode>3): Rename to ...
7001 (iorc<mode>3): ... this.
7003 2024-07-08 Kewen Lin <linkw@linux.ibm.com>
7005 PR tree-optimization/115659
7006 * doc/md.texi: Document andcm3 and iorcm3.
7007 * gimple-isel.cc (gimple_expand_vec_cond_expr): Add more foldings for
7008 patterns x CMP y ? 0 : z and x CMP y ? z : -1.
7009 * internal-fn.def (BIT_ANDC): New internal function.
7010 (BIT_IORC): Likewise.
7011 * optabs.def (andc, iorc): New optab.
7013 2024-07-08 Kewen Lin <linkw@linux.ibm.com>
7016 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Consider
7017 explicit VSX when masking off ALTIVEC.
7019 2024-07-08 H.J. Lu <hjl.tools@gmail.com>
7021 * config/i386/i386.cc (ix86_print_operand): Always generate
7022 branch hint for conditional branches.
7023 * config/i386/i386.h (TARGET_BRANCH_PREDICTION_HINTS): Split
7025 (TARGET_BRANCH_PREDICTION_HINTS_TAKEN): .. this, and ..
7026 (TARGET_BRANCH_PREDICTION_HINTS_NOT_TAKEN): .. this.
7027 * config/i386/x86-tune.def (X86_TUNE_BRANCH_PREDICTION_HINTS):
7029 (X86_TUNE_BRANCH_PREDICTION_HINTS_TAKEN): .. this, and ..
7030 (X86_TUNE_BRANCH_PREDICTION_HINTS_NOT_TAKEN): .. this.
7032 2024-07-07 Gerald Pfeifer <gerald@pfeifer.com>
7034 * doc/bugreport.texi (Bug Criteria): Remove dubious example.
7036 2024-07-06 Jeff Law <jlaw@ventanamicro.com>
7038 * config/riscv/bitmanip.md (bset splitters): Turn into define_and_splits.
7039 Don't depend on combine splitting the "andn with constant" form.
7040 (bset, binv, bclr with masked bit position): New patterns.
7042 2024-07-06 Jeff Law <jlaw@ventanamicro.com>
7044 * config/sh/sh.md (adddi3): Only allow matching when we can
7045 still create new pseudos.
7046 (subdi3, *rotcl, *rotcr, *rotcr_neg_t, negdi2): Likewise.
7047 (abs<mode>2, negabs<mode>2, negdi_cond): Likewise.
7048 (*swapbisi2_and_shl8, *swapbhisi2, *movsi_index_disp_load): Likewise.
7049 (*movhi_index_disp_load, *mov<mode>index_disp_store): Likewise.
7050 (*mov_t_msb_neg, *negt_msb, clipu_one): Likewise.
7052 2024-07-06 Georg-Johann Lay <avr@gjlay.de>
7054 * config/avr/avr.md: Also split with avr_split_tiny_move()
7056 * config/avr/avr.cc (avr_split_tiny_move): Don't change memory
7057 references with base regs that can do PLUS addressing.
7058 (avr_out_lpm_no_lpmx) [POST_INC]: Don't output final ADIW when the
7059 address register is unused after.
7061 2024-07-06 Eric Botcazou <ebotcazou@adacore.com>
7064 * config/riscv/riscv.cc (riscv_valid_lo_sum_p): Add missing test on
7065 tree_fits_uhwi_p before calling tree_to_uhwi.
7067 2024-07-06 Roger Sayle <roger@nextmovesoftware.com>
7070 * config/i386/i386-expand.cc (ix86_expand_ternlog): Avoid use of
7071 force_reg to "reload" non-register operands, as these may contain
7072 vec_duplicate (broadcast) operands that aren't supported by
7073 force_reg. Use (safer) gen_reg_rtx and emit_move instead.
7075 2024-07-05 Iain Sandoe <iain@sandoe.co.uk>
7077 * config/i386/i386.cc (ix86_cannot_copy_insn_p): New.
7078 (TARGET_CANNOT_COPY_INSN_P): New.
7080 2024-07-05 Wilco Dijkstra <wilco.dijkstra@arm.com>
7083 * config/arm/arm.cc (arm_legitimate_index_p): Move LDRD case before
7085 (thumb2_legitimate_index_p): Update comments.
7086 (output_move_neon): Use DFmode for vldr/vstr and non-checking
7089 2024-07-05 Robin Dapp <rdapp@ventanamicro.com>
7091 * config/riscv/autovec.md: Add TU policy.
7092 * config/riscv/riscv-protos.h (enum insn_type): Define
7093 SCALAR_MOVE_MERGED_OP_TU.
7095 2024-07-05 Georg-Johann Lay <avr@gjlay.de>
7098 * config/avr/avr-dimode.md: Use "nop_general_operand" instead
7099 of "general_operand" as predicate for all input operands.
7101 2024-07-05 Tamar Christina <tamar.christina@arm.com>
7103 * config/aarch64/aarch64.cc (struct expand_vec_perm_d): Add zero_op0_p
7105 (aarch64_evpc_tbl): Implement register value remapping.
7106 (aarch64_vectorize_vec_perm_const): Detect if operand is a zero dup
7107 before it's forced to a reg.
7109 2024-07-05 Tamar Christina <tamar.christina@arm.com>
7111 * config/aarch64/aarch64-simd.md
7112 (aarch64_simd_vec_unpack<su>_lo_<mode>): Remove.
7113 (vec_unpack<su>_lo_<mode): Simplify.
7114 * config/aarch64/aarch64.cc (aarch64_gen_shareable_zero): Update
7117 2024-07-05 Alex Coplan <alex.coplan@arm.com>
7119 * dominance.cc (dot_dominance_tree): New.
7121 2024-07-05 Hu, Lin1 <lin1.hu@intel.com>
7123 * config/i386/sse.md (ssedoublemode): Remove mappings to twice
7124 the number of same-sized elements. Add mappings to the same
7125 number of double-sized elements.
7126 (define_split for vec_concat_minus_plus): Change mode_attr from
7127 ssedoublemode to ssedoublevecmode.
7128 (define_split for vec_concat_plus_minus): Ditto.
7129 (<mask_codefor>avx512dq_shuf_<shuffletype>64x2_1<mask_name>):
7131 (avx512f_shuf_<shuffletype>64x2_1<mask_name>): Ditto.
7132 (avx512vl_shuf_<shuffletype>32x4_1<mask_name>): Ditto.
7133 (avx512f_shuf_<shuffletype>32x4_1<mask_name>): Ditto.
7135 2024-07-05 YunQiang Su <syq@gcc.gnu.org>
7137 * config/mips/mips-protos.h: New function mips_msa_shf_i8.
7138 * config/mips/mips-msa.md(MSA_WHB_W): Not used anymore;
7139 (msa_shf_<msafmt_f>): Use mips_msa_shf_i8.
7140 * config/mips/mips.cc(mips_const_vector_shuffle_set_p):
7141 Support more cases try to use alien mode instruction;
7142 (mips_msa_shf_i8): New function to get the correct MSA SHF
7143 instruction and IMM.
7145 2024-07-05 Richard Biener <rguenther@suse.de>
7147 * tree-vect-slp.cc (vect_build_slp_instance): Special case
7148 three input permute with the same number of lanes in store
7151 2024-07-04 Siarhei Volkau <lis8215@gmail.com>
7153 * config/arm/arm.cc (thumb_load_double_from_address): Emit ldmia
7154 when address reg rewritten by load.
7155 * config/arm/thumb1.md (peephole2 to rewrite DI/DF load): New.
7156 (peephole2 to rewrite DI/DF store): New.
7157 * config/arm/iterators.md (DIDF): New.
7159 2024-07-04 Alfie Richards <alfie.richards@arm.com>
7162 * config/aarch64/aarch64-simd.md: Remove bigendian operand swap.
7164 2024-07-04 Richard Biener <rguenther@suse.de>
7166 PR middle-end/115426
7167 * gimplify.cc (gimplify_asm_expr): Handle "rm" output
7168 constraint gimplified to a register (operation).
7170 2024-07-04 Roger Sayle <roger@nextmovesoftware.com>
7172 * config/i386/i386.md (bswaphisi2_lowpart peephole2): New
7173 peephole2 variant to eliminate register shuffling.
7175 2024-07-04 Jeff Law <jlaw@ventanamicro.com>
7177 * config/rx/rx.cc (rx_expand_prologue): Mark the copy from FP to SP
7179 (rx_expand_epilogue): Mark the stack pointer adjustment as frame
7182 2024-07-04 Hongyu Wang <hongyu.wang@intel.com>
7184 * config/i386/i386.cc (ix86_expand_prologue): Set apx_ppx_used
7185 flag in m.fs with TARGET_APX_PPX && !crtl->calls_eh_return.
7186 (ix86_emit_save_regs): Emit ppx is available only when
7187 TARGET_APX_PPX && !crtl->calls_eh_return.
7188 (ix86_expand_epilogue): Don't restore reg using mov when
7189 apx_ppx_used flag is true.
7190 * config/i386/i386.h (struct machine_frame_state):
7191 Add apx_ppx_used flag.
7193 2024-07-04 Hu, Lin1 <lin1.hu@intel.com>
7195 PR tree-optimization/115753
7196 * tree-vect-stmts.cc (supportable_indirect_convert_operation): Add
7197 TYPE_CODE check before SSA_NAME_RANGE_INFO.
7199 2024-07-03 Jeff Law <jlaw@ventanamicro.com>
7201 * reorg.cc (relax_delay_slots): Do not optimize a conditional
7202 jump around an unconditional jump/return in the presence of
7203 a text section switch.
7205 2024-07-03 John David Anglin <danglin@gcc.gnu.org>
7208 2023-10-05 John David Anglin <danglin@gcc.gnu.org>
7210 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Delete.
7212 2024-07-03 Palmer Dabbelt <palmer@rivosinc.com>
7214 * doc/invoke.texi: Describe -march behavior for dependent extensions on
7217 2024-07-03 Gianluca Guida <gianluca@rivosinc.com>
7218 Patrick O'Neill <patrick@rivosinc.com>
7220 * common/config/riscv/riscv-common.cc
7221 (riscv_subset_list::to_string): Skip zabha when not supported by
7223 * config.in: Regenerate.
7224 * config/riscv/arch-canonicalize: Make zabha imply zaamo.
7225 * config/riscv/iterators.md (amobh): Add iterator for amo
7227 * config/riscv/riscv.opt: Add zabha.
7228 * config/riscv/sync.md (atomic_<atomic_optab><mode>): Add
7229 subword atomic op pattern.
7230 (zabha_atomic_fetch_<atomic_optab><mode>): Add subword
7231 atomic_fetch op pattern.
7232 (lrsc_atomic_fetch_<atomic_optab><mode>): Prefer zabha over lrsc
7233 for subword atomic ops.
7234 (zabha_atomic_exchange<mode>): Add subword atomic exchange
7236 (lrsc_atomic_exchange<mode>): Prefer zabha over lrsc for subword
7237 atomic exchange ops.
7238 * configure: Regenerate.
7239 * configure.ac: Add zabha assembler check.
7240 * doc/sourcebuild.texi: Add zabha documentation.
7242 2024-07-03 Pan Li <pan2.li@intel.com>
7245 * config/riscv/vector.md (*pred_broadcast<mode>): Split into
7246 zvfh and zvfhmin part.
7247 (*pred_broadcast<mode>_zvfh): New define_insn for zvfh part.
7248 (*pred_broadcast<mode>_zvfhmin): Ditto but for zvfhmin.
7250 2024-07-03 Pan Li <pan2.li@intel.com>
7252 * match.pd: Allow any otype is less than itype truncation.
7254 2024-07-03 Pan Li <pan2.li@intel.com>
7256 * tree-vect-patterns.cc (gimple_unsigned_integer_sat_trunc): Add
7257 new decl generated by match.
7258 (vect_recog_sat_trunc_pattern): Add new func impl to recog the
7261 2024-07-03 Richard Biener <rguenther@suse.de>
7263 * tree-vect-slp.cc (vectorizable_slp_permutation_1): Remove
7266 2024-07-03 Jennifer Schmitz <jschmitz@nvidia.com>
7268 * match.pd: Fold x/sqrt(x) to sqrt(x).
7270 2024-07-03 Alexandre Oliva <oliva@adacore.com>
7272 * dwarf2out.cc (modified_type_die): Follow name's debug type.
7274 2024-07-03 Alexandre Oliva <oliva@adacore.com>
7277 * config/i386/i386-options.cc
7278 (ix86_override_options_after_change_1): Add opts and opts_set
7279 parms, operate on them, after factoring out of...
7280 (ix86_override_options_after_change): ... this. Restore calls
7281 of ix86_default_align and ix86_recompute_optlev_based_flags.
7282 (ix86_option_override_internal): Call the factored-out bits.
7284 2024-07-03 Kyrylo Tkachov <ktkachov@nvidia.com>
7287 * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins):
7288 Define __ARM_FEATURE_SVE_BF16 for TARGET_SVE_BF16.
7290 2024-07-03 Kyrylo Tkachov <ktkachov@nvidia.com>
7293 * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins):
7294 Define __ARM_FEATURE_BF16 for TARGET_BF16_FP.
7296 2024-07-03 Richard Biener <rguenther@suse.de>
7298 * tree-vect-slp.cc (bst_traits::hash): Handle NULL elements
7299 in SLP_TREE_SCALAR_STMTS.
7300 (vect_print_slp_tree): Likewise.
7301 (vect_mark_slp_stmts): Likewise.
7302 (vect_mark_slp_stmts_relevant): Likewise.
7303 (vect_find_last_scalar_stmt_in_slp): Likewise.
7304 (vect_bb_slp_mark_live_stmts): Likewise.
7305 (vect_slp_prune_covered_roots): Likewise.
7306 (vect_bb_partition_graph_r): Likewise.
7307 (vect_remove_slp_scalar_calls): Likewise.
7308 (vect_slp_gather_vectorized_scalar_stmts): Likewise.
7309 (vect_bb_slp_scalar_cost): Likewise.
7310 (vect_contains_pattern_stmt_p): Likewise.
7311 (vect_slp_convert_to_external): Likewise.
7312 (vect_find_first_scalar_stmt_in_slp): Likewise.
7313 (vect_optimize_slp_pass::remove_redundant_permutations): Likewise.
7314 (vect_slp_analyze_node_operations_1): Likewise.
7315 (vect_schedule_slp_node): Likewise.
7316 * tree-vect-stmts.cc (can_vectorize_live_stmts): Likewise.
7317 (vectorizable_shift): Likewise.
7318 * tree-vect-data-refs.cc (vect_slp_analyze_load_dependences):
7319 Handle NULL elements in SLP_TREE_SCALAR_STMTS.
7321 2024-07-03 Georg-Johann Lay <avr@gjlay.de>
7324 * config/avr/avr.cc (avr_out_movqi_r_mr_reg_disp_tiny): Properly
7325 restore the base register when it is partially clobbered.
7327 2024-07-03 Tamar Christina <tamar.christina@arm.com>
7329 PR tree-optimization/114932
7330 * tree-ssa-loop-ivopts.cc (constant_multiple_of): Use
7331 aff_combination_constant_multiple_p instead.
7333 2024-07-03 Tamar Christina <tamar.christina@arm.com>
7335 PR tree-optimization/114932
7336 * tree-affine.cc (wide_int_constant_multiple_p): Support 0 and 0 being
7339 2024-07-03 Richard Sandiford <richard.sandiford@arm.com>
7341 * df.h (DF_LR_DCE): New df_problem_id.
7342 (df_lr_dce): New macro.
7343 * df-core.cc (rest_of_handle_df_finish): Check for a null free_fun.
7344 * df-problems.cc (df_lr_finalize): Split out fast DCE handling to...
7345 (df_lr_dce_finalize): ...this new function.
7346 (problem_LR_DCE): New df_problem.
7347 (df_lr_add_problem): Register LR_DCE rather than LR itself.
7348 * dce.cc (fast_dce): Clear df_lr_dce->solutions_dirty.
7350 2024-07-02 Pengxuan Zheng <quic_pzheng@quicinc.com>
7353 * config/aarch64/aarch64-simd.md (aarch64_<su>addlp<mode>): Rename to...
7354 (@aarch64_<su>addlp<mode>): ... This.
7355 (popcount<mode>2): New define_expand.
7357 2024-07-02 Andrew Pinski <quic_apinski@quicinc.com>
7359 * passes.def (expand_pow): Renamed from expand_powcabs.
7360 * timevar.def (TV_TREE_POWCABS): Remove.
7362 * tree-pass.h (make_pass_expand_powcabs): Rename to ...
7363 (make_pass_expand_pow): This.
7364 * tree-ssa-math-opts.cc (class pass_expand_powcabs): Rename to ...
7365 (class pass_expand_pow): This.
7366 (pass_expand_powcabs::execute): Rename to ...
7367 (pass_expand_pow::execute): This.
7368 (make_pass_expand_powcabs): Rename to ...
7369 (make_pass_expand_pow): This.
7371 2024-07-02 Andrew Pinski <quic_apinski@quicinc.com>
7373 * tree-complex.cc (gimple_expand_builtin_cabs): Add
7374 `cabs(a+ai)`, `cabs(x+0i)` and `cabs(0+xi)` optimizations.
7376 2024-07-02 Andrew Pinski <quic_apinski@quicinc.com>
7378 PR tree-optimization/115710
7379 * tree-complex.cc (init_dont_simulate_again): Handle CABS.
7380 (gimple_expand_builtin_cabs): New function, moved mostly
7381 from tree-ssa-math-opts.cc.
7382 (expand_complex_operations_1): Call gimple_expand_builtin_cabs.
7383 * tree-ssa-math-opts.cc (gimple_expand_builtin_cabs): Remove.
7384 (build_and_insert_binop): Remove.
7385 (pass_data_expand_powcabs): Update comment.
7386 (pass_expand_powcabs::execute): Don't handle CABS.
7388 2024-07-02 Andrew Pinski <quic_apinski@quicinc.com>
7390 * tree-complex.cc (expand_complex_addition): If both
7391 operands have the same real and imag parts, only
7392 add the addition once.
7394 2024-07-02 David Faust <david.faust@oracle.com>
7396 * common.opt.urls: Regenerate.
7398 2024-07-02 David Faust <david.faust@oracle.com>
7399 Cupertino Miranda <cupertino.miranda@oracle.com>
7401 * btfout.cc (btf_mark_type_used): New.
7402 * ctfc.h (btf_mark_type_used): Declare it here.
7403 * config/bpf/bpf.cc (bpf_option_override): Enable -gprune-btf
7404 by default if -gbtf is enabled.
7405 * config/bpf/core-builtins.cc (extra_fn): New typedef.
7406 (compute_field_expr): Add callback parameter, and call it if supplied.
7407 Fix computation for MEM_REF.
7408 (mark_component_type_as_used): New.
7409 (bpf_mark_types_as_used): Likewise.
7410 (bpf_expand_core_builtin): Call here.
7411 * doc/invoke.texi (Debugging Options): Note that -gprune-btf is
7412 enabled by default for BPF target when generating BTF.
7414 2024-07-02 David Faust <david.faust@oracle.com>
7416 * btfout.cc (btf_used_types): New hash set.
7417 (struct btf_fixup): New.
7418 (fixups, forwards): New vecs.
7419 (btf_output): Calculate num_types depending on debug_prune_btf.
7420 (btf_early_finsih): New initialization for debug_prune_btf.
7421 (btf_add_used_type): New function.
7422 (btf_used_type_list_cb): Likewise.
7423 (btf_collect_pruned_types): Likewise.
7424 (btf_add_vars): Handle special case for variables in ".maps" section
7425 when generating BTF for BPF CO-RE target.
7426 (btf_late_finish): Use btf_collect_pruned_types when debug_prune_btf
7427 is in effect. Move some initialization to btf_early_finish.
7428 (btf_finalize): Additional deallocation for debug_prune_btf.
7429 * common.opt (gprune-btf): New flag.
7430 * ctfc.cc (init_ctf_strtable): Make non-static.
7431 * ctfc.h (init_ctf_strtable, ctfc_delete_strtab): Make extern.
7432 * doc/invoke.texi (Debugging Options): Document -gprune-btf.
7434 2024-07-02 David Faust <david.faust@oracle.com>
7436 * btfout.cc (struct btf_datasec_entry): New.
7437 (struct btf_datasec): Add `id' member. Change `entries' to use
7438 new struct btf_datasec_entry.
7439 (func_map): New hash_map.
7440 (max_translated_id): New.
7441 (btf_var_ids, btf_id_map, holes, voids, num_vars_added)
7442 (num_types_added, num_types_created): Delete.
7443 (btf_absolute_var_id, btf_relative_var_id, btf_absolute_func_id)
7444 (btf_relative_func_id, btf_absolute_datasec_id, init_btf_id_map)
7445 (get_btf_id, set_btf_id, btf_emit_id_p): Delete.
7446 (btf_removed_type_p): Delete.
7447 (btf_dtd_kind, btf_emit_type_p): New helpers.
7448 (btf_fwd_to_enum_p, btf_calc_num_vbytes): Use them.
7449 (btf_collect_datasec): Delete.
7450 (btf_dtd_postprocess_cb, btf_dvd_emit_preprocess_cb)
7451 (btf_dtd_emit_preprocess_cb, btf_emit_preprocess): Delete.
7452 (btf_dmd_representable_bitfield_p): Adapt to type reference changes
7453 and delete now-unused ctfc argument.
7454 (btf_asm_datasec_type_ref): Delete.
7455 (btf_asm_type_ref): Adapt to type reference changes, simplify.
7456 (btf_asm_type): Likewise. Mark struct/union types with bitfield
7458 (btf_asm_array): Adapt to data structure changes.
7459 (btf_asm_varent): Likewise.
7460 (btf_asm_sou_member): Likewise. Ensure non-bitfield members are
7461 correctly re-encoded if struct or union contains any bitfield.
7462 (btf_asm_func_arg, btf_asm_func_type, btf_asm_datasec_entry)
7463 (btf_asm_datasec_type): Adapt to data structure changes.
7464 (output_btf_header): Adapt to other changes, simplify type
7465 length calculation, add info to assembler comments.
7466 (output_btf_vars): Adapt to other changes.
7467 (output_btf_strs): Fix overlong lines.
7468 (output_asm_btf_sou_fields, output_asm_btf_enum_list)
7469 (output_asm_btf_func_args_list, output_asm_btf_vlen_bytes)
7470 (output_asm_btf_type, output_btf_types, output_btf_func_types)
7471 (output_btf_datasec_types): Adapt to other changes.
7472 (btf_init_postprocess): Delete.
7473 (btf_output): Change to only perform output.
7474 (btf_add_const_void, btf_add_func_records): New.
7475 (btf_early_finish): Use them here. New.
7476 (btf_datasec_push_entry): Adapt to data structure changes.
7477 (btf_datasec_add_func, btf_datasec_add_var): New.
7478 (btf_add_func_datasec_entries): New.
7479 (btf_emit_variable_p): New helper.
7480 (btf_add_vars): Use it here. New.
7481 (btf_type_list_cb, btf_collect_translated_types): New.
7482 (btf_assign_func_ids, btf_late_assign_var_ids)
7483 (btf_assign_datasec_ids): New.
7484 (btf_finish): Remove unused argument. Call new btf_late*
7485 functions and btf_output.
7486 (btf_finalize): Adapt to data structure changes.
7487 * ctfc.h (struct ctf_dtdef): Convert existing boolean flags to
7488 BOOL_BITFIELD and reorder.
7489 (struct ctf_dvdef): Add dvd_id member.
7490 (btf_finish): Remove argument from prototype.
7491 (get_btf_id): Delete prototype.
7492 (funcs_traverse_callback, traverse_btf_func_types): Add an
7493 explanatory comment.
7494 * dwarf2ctf.cc (ctf_debug_finish): Remove unused argument.
7495 * dwarf2ctf.h: Analogous change.
7496 * dwarf2out.cc: Likewise.
7498 2024-07-02 David Faust <david.faust@oracle.com>
7500 * btfout.cc (BTF_VOID_TYPEID, BTF_INIT_TYPEID): Move defines to
7502 (btf_dvd_emit_preprocess_cb, btf_emit_preprocess)
7503 (btf_dmd_representable_bitfield_p, btf_asm_array, btf_asm_varent)
7504 (btf_asm_sou_member, btf_asm_func_arg, btf_init_postprocess):
7505 Adapt to structural changes in ctf_* structs.
7506 * ctfc.h (struct ctf_dtdef): Add forward declaration.
7507 (ctf_dtdef_t, ctf_dtdef_ref): Move typedefs earlier.
7508 (struct ctf_arinfo, struct ctf_funcinfo, struct ctf_sliceinfo)
7509 (struct ctf_itype, struct ctf_dmdef, struct ctf_func_arg)
7510 (struct ctf_dvdef): Use pointers instead of type IDs for
7511 references to other types and use typedefs where appropriate.
7512 (struct ctf_dtdef): Add ref_type member.
7513 (ctf_type_exists): Use pointer instead of type ID.
7514 (ctf_add_reftype, ctf_add_enum, ctf_add_slice, ctf_add_float)
7515 (ctf_add_integer, ctf_add_unknown, ctf_add_pointer)
7516 (ctf_add_array, ctf_add_forward, ctf_add_typedef)
7517 (ctf_add_function, ctf_add_sou, ctf_add_enumerator)
7518 (ctf_add_variable): Likewise. Return pointer instead of ID.
7519 (ctf_lookup_tree_type): Return pointer to type instead of ID.
7520 * ctfc.cc: Analogous changes.
7521 * ctfout.cc (ctf_asm_type, ctf_asm_slice, ctf_asm_varent)
7522 (ctf_asm_sou_lmember, ctf_asm_sou_member, ctf_asm_func_arg)
7523 (output_ctf_objt_info): Adapt to changes.
7524 * dwarf2ctf.cc (gen_ctf_type, gen_ctf_void_type)
7525 (gen_ctf_unknown_type, gen_ctf_base_type, gen_ctf_pointer_type)
7526 (gen_ctf_subrange_type, gen_ctf_array_type, gen_ctf_typedef)
7527 (gen_ctf_modifier_type, gen_ctf_sou_type, gen_ctf_function_type)
7528 (gen_ctf_enumeration_type, gen_ctf_variable, gen_ctf_function)
7529 (gen_ctf_type, ctf_do_die): Likewise.
7530 * config/bpf/btfext-out.cc (struct btf_ext_core_reloc): Use
7531 pointer instead of type ID.
7532 (bpf_core_reloc_add, bpf_core_get_sou_member_index)
7533 (output_btfext_core_sections): Adapt to above changes.
7534 * config/bpf/core-builtins.cc (process_type): Likewise.
7536 2024-07-02 David Faust <david.faust@oracle.com>
7538 * btfout.cc (btf_init_postprocess): Rename to...
7539 (btf_early_finish): ...this.
7540 (btf_output): Rename to...
7541 (btf_finish): ...this.
7542 * ctfc.h: Analogous changes.
7543 * dwarf2ctf.cc (ctf_debug_early_finish): Conditionally call
7544 btf_early_finish, or ctf_finalize as appropriate. Emit BTF
7545 here for LTO builds.
7546 (ctf_debug_finish): Always call btf_finish here if generating
7547 BTF info in non-LTO builds.
7548 (ctf_debug_finalize, ctf_debug_init_postprocess): Delete.
7549 * dwarf2out.cc (dwarf2out_early_finish): Remove call to
7550 ctf_debug_init_postprocess.
7552 2024-07-02 Wilco Dijkstra <wilco.dijkstra@arm.com>
7555 * config/arm/arm.md (unaligned_loadsi): Use 'Uw' constraint and
7556 'mem_and_no_t1_wback_op'.
7557 (unaligned_loadhiu): Likewise.
7558 (unaligned_storesi): Likewise.
7559 (unaligned_storehi): Likewise.
7560 * config/arm/predicates.md (mem_and_no_t1_wback_op): Add new predicate.
7561 * config/arm/sync.md (arm_atomic_load<mode>): Use 'Uw' constraint.
7562 (arm_atomic_store<mode>): Likewise.
7564 2024-07-02 Matthew Malcomson <matthew.malcomson@arm.com>
7566 * doc/tm.texi: Regenerated.
7567 * target.def (function_attribute_inlinable_p,
7568 unspec_may_trap_p): Update documentation.
7570 2024-07-02 Richard Biener <rguenther@suse.de>
7572 PR tree-optimization/115741
7573 * tree-vect-stmts.cc (get_group_load_store_type): Also
7574 handle VMAT_CONTIGUOUS_REVERSE when determining overrun.
7576 2024-07-02 Andrew Stubbs <ams@baylibre.com>
7578 * config/gcn/gcn-opts.h (TARGET_GLOBAL_ADDRSPACE): New.
7579 (TARGET_AVGPRS): New.
7580 (TARGET_AVGPR_MEMOPS): New.
7581 (TARGET_AVGPR_COMBINED): New.
7582 (TARGET_FLAT_OFFSETS): New.
7583 (TARGET_11BIT_GLOBAL_OFFSET): New.
7584 (TARGET_CDNA2_MEM_COSTS): New.
7585 (TARGET_WAVE64_COMPAT): New.
7586 (TARGET_DPP_FULL): New.
7587 (TARGET_DPP16): New.
7589 (TARGET_AVGPR_CDNA1_NOPS): New.
7590 (TARGET_VGPR_GRANULARITY): New.
7591 (TARGET_ARCHITECTED_FLAT_SCRATCH): New.
7592 (TARGET_EXPLICIT_CARRY): New.
7593 (TARGET_MULTIPLY_IMMEDIATE): New.
7595 (TARGET_WBINVL1_CACHE): New.
7596 (TARGET_GLn_CACHE): New.
7597 * config/gcn/gcn-valu.md (throughout): Change TARGET_GCN*,
7598 TARGET_CDNA* and TARGET_RDNA* to use TARGET_<feature> instead.
7599 * config/gcn/gcn.cc (throughout): Likewise.
7600 * config/gcn/gcn.md (throughout): Likewise.
7602 2024-07-02 Lingling Kong <lingling.kong@intel.com>
7604 * config/i386/i386.md (*imulhi<mode>zu): Added APX
7606 (*imulhi<mode>zu<nf_name>): New define_insn.
7607 (*mulsi3_1_zext<nf_name>): Ditto.
7608 (*mul<mode><dwi>3_1<nf_name>): Ditto.
7609 (*<u>mulqihi3_1<nf_name>): Ditto.
7610 (*mul<mode>3_1<nf_name>): Added APX NDD support.
7611 (*mulv<mode>4): Ditto.
7614 2024-07-02 Kewen Lin <linkw@linux.ibm.com>
7617 * config/sparc/vxworks.h (SPARC_LONG_DOUBLE_TYPE_SIZE): New define.
7619 2024-07-02 Lulu Cheng <chenglulu@loongson.cn>
7621 * config/loongarch/loongarch.cc (loongarch_insn_cost):
7623 (TARGET_INSN_COST): New macro.
7625 2024-07-02 Kewen Lin <linkw@linux.ibm.com>
7627 PR tree-optimization/115659
7628 * gimple-isel.cc (gimple_expand_vec_cond_expr): Add more foldings for
7629 patterns x CMP y ? -1 : z and x CMP y ? z : 0.
7631 2024-07-01 Richard Biener <rguenther@suse.de>
7633 * tree-ssa-forwprop.cc (fwprop_set_lattice_val): Preserve
7635 * tree-ssa-propagate.cc
7636 (substitute_and_fold_dom_walker::before_dom_children): Likewise.
7638 2024-07-01 Roger Sayle <roger@nextmovesoftware.com>
7640 * config/i386/i386.md (peephole2): Transform two consecutive
7641 additions into a 3-component lea if !TARGET_AVOID_LEA_FOR_ADDR.
7643 2024-07-01 Georg-Johann Lay <avr@gjlay.de>
7647 * config/avr/avr.md (mov<mode>) [avr_mem_memx_p]: Expand in such a
7648 way that the destination does not overlap with any hard register
7649 clobbered / used by xload8qi_A resp. xload<mode>_A.
7650 * config/avr/avr.cc (avr_out_xload): Avoid early-clobber
7651 situation for Z by executing just one load when the output register
7654 2024-07-01 Richard Biener <rguenther@suse.de>
7656 PR tree-optimization/115723
7657 * tree-vect-loop.cc (check_reduction_path): For a .COND_ADD
7658 verify the else value also refers to the reduction chain op.
7660 2024-07-01 Richard Biener <rguenther@suse.de>
7662 PR tree-optimization/115694
7663 * tree-ssa-forwprop.cc (pass_forwprop::execute): Check the
7664 store is complex before rewriting it.
7666 2024-07-01 liuhongt <hongtao.liu@intel.com>
7669 * config/i386/mmx.md (vcond<mode>v2sf): Removed.
7670 (vcond<MMXMODE124:mode><MMXMODEI:mode>): Ditto.
7671 (vcond<mode><mode>): Ditto.
7672 (vcondu<MMXMODE124:mode><MMXMODEI:mode>): Ditto.
7673 (vcondu<mode><mode>): Ditto.
7674 * config/i386/sse.md (vcond<V_512:mode><VF_512:mode>): Ditto.
7675 (vcond<V_256:mode><VF_256:mode>): Ditto.
7676 (vcond<V_128:mode><VF_128:mode>): Ditto.
7677 (vcond<VI2HFBF_AVX512VL:mode><VHF_AVX512VL:mode>): Ditto.
7678 (vcond<V_512:mode><VI_AVX512BW:mode>): Ditto.
7679 (vcond<V_256:mode><VI_256:mode>): Ditto.
7680 (vcond<V_128:mode><VI124_128:mode>): Ditto.
7681 (vcond<VI8F_128:mode>v2di): Ditto.
7682 (vcondu<V_512:mode><VI_AVX512BW:mode>): Ditto.
7683 (vcondu<V_256:mode><VI_256:mode>): Ditto.
7684 (vcondu<V_128:mode><VI124_128:mode>): Ditto.
7685 (vcondu<VI8F_128:mode>v2di): Ditto.
7686 (vcondeq<VI8F_128:mode>v2di): Ditto.
7688 2024-07-01 liuhongt <hongtao.liu@intel.com>
7691 * config/i386/sse.md ("*ashr<mode>3_1"): New
7692 define_insn_and_split.
7693 (*avx512_ashr<mode>3_1): Ditto.
7694 (*avx2_lshr<mode>3_1): Ditto.
7695 (*avx2_lshr<mode>3_2): Ditto and add 2 combine splitter after
7697 * config/i386/mmx.md (mmxscalarsize): New mode attribute.
7698 (*mmw_ashr<mode>3_1): New define_insn_and_split.
7699 ("mmx_<insn><mode>3): Add a combine spiltter after it.
7700 (*mmx_ashrv2hi3_1): New define_insn_and_plit, also add a
7701 combine splitter after it.
7703 2024-07-01 liuhongt <hongtao.liu@intel.com>
7706 * config/i386/sse.md
7707 (*<sse>_movmsk<ssemodesuffix><avxsizesuffix>_lt_avx512): New
7708 define_insn_and_split.
7709 (*<sse>_movmsk<ssemodesuffix><avxsizesuffix>_<u>ext_lt_avx512):
7711 (*<sse2_avx2>_pmovmskb_lt_avx512): Ditto.
7712 (*<sse2_avx2>_pmovmskb_zext_lt_avx512): Ditto.
7713 (*sse2_pmovmskb_ext_lt_avx512): Ditto.
7714 (*pmovsk_kmask_v16qi_avx512): Ditto.
7715 (*pmovsk_mask_v32qi_avx512): Ditto.
7716 (*pmovsk_mask_cmp_<mode>_avx512): Ditto.
7717 (*pmovsk_ptest_<mode>_avx512): Ditto.
7719 2024-07-01 liuhongt <hongtao.liu@intel.com>
7722 * config/i386/sse.md (*minmax<mode>3_1): New pre_reload
7723 define_insn_and_split.
7724 (*minmax<mode>3_2): Ditto.
7726 2024-07-01 liuhongt <hongtao.liu@intel.com>
7729 * config/i386/sse.md
7730 (*<avx512>_cvtmask2<ssemodesuffix><mode>_not): New pre_reload
7732 (*<avx512>_cvtmask2<ssemodesuffix><mode>_not): Ditto.
7733 (*avx2_pcmp<mode>3_6): Ditto.
7734 (*avx2_pcmp<mode>3_7): Ditto.
7736 2024-07-01 liuhongt <hongtao.liu@intel.com>
7739 * config/i386/sse.md
7740 (*<sse4_1>_blendv<ssemodesuffix><avxsizesuffix>_gt): New
7741 define_insn_and_split.
7742 (*<sse4_1>_blendv<ssefltmodesuffix><avxsizesuffix>_gtint):
7744 (*<sse4_1>_blendv<ssefltmodesuffix><avxsizesuffix>_not_gtint):
7746 (*<sse4_1_avx2>_pblendvb_gt): Ditto.
7747 (*<sse4_1_avx2>_pblendvb_gt_subreg_not): Ditto.
7749 2024-07-01 liuhongt <hongtao.liu@intel.com>
7751 * config/i386/i386-features.cc (ix86_rpad_gate): New function.
7752 * config/i386/i386-options.cc (ix86_override_options_after_change):
7753 Don't disable flate_combine.
7754 * config/i386/i386-passes.def: Move pass_stv2 and pass_rpad
7755 after pre_reload pas_late_combine.
7756 * config/i386/i386-protos.h (ix86_rpad_gate): New declare.
7757 * config/i386/i386.cc (ix86_insn_cost): New function.
7758 (TARGET_INSN_COST): Define.
7760 2024-07-01 liuhongt <hongtao.liu@intel.com>
7763 * config/i386/i386.md (<*insnsi3_zext): Add alternative ?k,
7764 enable it only for lshiftrt and under avx512bw.
7765 * config/i386/sse.md (*klshrsi3_1_zext): New define_insn, and
7766 add corresponding define_split after it.
7768 2024-06-30 John David Anglin <danglin@gcc.gnu.org>
7771 * config/pa/pa.md: Remove incorrect xmpyu patterns.
7773 2024-06-30 Richard Biener <rguenther@suse.de>
7775 PR tree-optimization/115701
7776 * tree-ssanames.cc (maybe_duplicate_ssa_info_at_copy):
7777 Only copy info from within the same BB.
7779 2024-06-30 Richard Biener <rguenther@suse.de>
7781 PR tree-optimization/115701
7782 * tree-ssanames.h (maybe_duplicate_ssa_info_at_copy): Declare.
7783 * tree-ssanames.cc (maybe_duplicate_ssa_info_at_copy): New
7784 function, split out from ...
7785 * tree-ssa-copy.cc (fini_copy_prop): ... here.
7786 * tree-ssa-sccvn.cc (eliminate_dom_walker::eliminate_stmt): ...
7789 2024-06-30 Richard Biener <rguenther@suse.de>
7791 * tree-vect-slp.cc (vect_build_slp_tree_1): Compare
7792 STMT_VINFO_REDUC_IDX.
7793 (vect_build_slp_tree_2): Prevent operand swapping for
7794 all stmts participating in a reduction.
7796 2024-06-30 Feng Xue <fxue@os.amperecomputing.com>
7798 * tree-vect-loop.cc (vectorizable_reduction): Determine input vectype
7799 during traversal of reduction statements.
7801 2024-06-30 Feng Xue <fxue@os.amperecomputing.com>
7803 * tree-vect-stmts.cc (vectorizable_shift): Allow shift-by-induction
7804 for single-lane slp node.
7806 2024-06-29 Maciej W. Rozycki <macro@orcam.me.uk>
7808 PR rtl-optimization/115565
7809 * cse.cc (record_jump_cond): Use INT_MIN rather than -1 for
7810 `comparison_qty' if !REG_P.
7812 2024-06-29 Sergei Lewis <slewis@rivosinc.com>
7814 * config/riscv/riscv.md (movmem<mode>): New expander.
7816 2024-06-29 Pan Li <pan2.li@intel.com>
7818 * match.pd: Add imm form for .SAT_ADD matching.
7819 * tree-ssa-math-opts.cc (math_opts_dom_walker::after_dom_children):
7820 Add .SAT_ADD matching under PLUS_EXPR.
7822 2024-06-29 Jeff Law <jlaw@ventanamicro.com>
7824 * config/mcore/mcore.md (zero_extendqihi2): Clobber CC in expander
7826 (zero_extendqisi2): Likewise.
7828 2024-06-28 Andrew MacLeod <amacleod@redhat.com>
7830 * gimple-range-cache.cc (ssa_lazy_cache::ssa_lazy_cache): Relocate here.
7831 Check for provided obstack.
7832 (ssa_lazy_cache::~ssa_lazy_cache): Relocate here. Free bitmap or obstack.
7833 * gimple-range-cache.h (ssa_lazy_cache::ssa_lazy_cache): Move.
7834 (ssa_lazy_cache::~ssa_lazy_cache): Move.
7835 (ssa_lazy_cache::m_ob): New.
7836 * gimple-range.cc (dom_ranger::dom_ranger): Iniitialize obstack.
7837 (dom_ranger::~dom_ranger): Release obstack.
7838 (dom_ranger::pre_bb): Create ssa_lazy_cache using obstack.
7839 * gimple-range.h (m_bitmaps): New.
7841 2024-06-28 Uros Bizjak <ubizjak@gmail.com>
7843 * config/i386/i386-expand.cc (ix86_expand_move): Remove extra
7844 assignment to tmp variable, reuse tmp variable instead of
7845 declaring new temporary variable and remove tmp variable shadowing.
7847 2024-06-28 Jørgen Kvalsvik <j@lambda.is>
7849 * tree-profile.cc (find_conditions): Use auto_vec without
7852 2024-06-28 Richard Biener <rguenther@suse.de>
7854 PR tree-optimization/115652
7855 * tree-vect-slp.cc (vect_schedule_slp_node): Handle the case
7856 where the outer loop header block is empty.
7858 2024-06-28 Evgeny Karpov <Evgeny.Karpov@microsoft.com>
7863 * config/aarch64/cygming.h
7864 (PE_COFF_EXTERN_DECL_SHOULD_BE_LEGITIMIZED): Rename to
7865 PE_COFF_LEGITIMIZE_EXTERN_DECL.
7866 (PE_COFF_LEGITIMIZE_EXTERN_DECL): Likewise.
7867 * config/i386/cygming.h (GOT_ALIAS_SET): Remove the diffinition to
7868 reuse it from i386.h.
7869 (PE_COFF_EXTERN_DECL_SHOULD_BE_LEGITIMIZED): Rename to
7870 PE_COFF_LEGITIMIZE_EXTERN_DECL.
7871 (PE_COFF_LEGITIMIZE_EXTERN_DECL): Likewise.
7872 * config/i386/i386-expand.cc (ix86_expand_move): Return
7874 * config/i386/i386-expand.h (ix86_GOT_alias_set): Likewise.
7875 * config/i386/i386.cc (ix86_GOT_alias_set): Likewise.
7876 * config/i386/i386.h (GOT_ALIAS_SET): Likewise.
7877 * config/mingw/winnt-dll.cc (get_dllimport_decl): Use
7879 (legitimize_pe_coff_symbol): Rename to
7880 PE_COFF_LEGITIMIZE_EXTERN_DECL.
7881 * config/mingw/winnt-dll.h (ix86_GOT_alias_set): Declare
7884 2024-06-28 Aldy Hernandez <aldyh@redhat.com>
7886 * range-op-ptr.cc (class hybrid_and_operator): Remove.
7887 (class hybrid_or_operator): Same.
7888 (class hybrid_min_operator): Same.
7889 (class hybrid_max_operator): Same.
7891 2024-06-28 Richard Biener <rguenther@suse.de>
7893 PR tree-optimization/115640
7894 * tree-vect-stmts.cc (vectorizable_load): With an inner
7895 loop SLP access to not apply a gap adjustment.
7897 2024-06-28 Andrew Stubbs <ams@baylibre.com>
7900 * config/gcn/gcn.cc (gcn_vectorize_vec_perm_const): Modify RDNA checks.
7902 2024-06-28 Roger Sayle <roger@nextmovesoftware.com>
7904 * config/i386/i386.md (*concat<mode><dwi>3_3): Change zero_extend
7905 to any_extend in first operand to left shift by mode precision.
7906 (*concat<mode><dwi>3_4): Likewise.
7907 (*concat<mode><dwi>3_6): Likewise.
7909 2024-06-28 Roger Sayle <roger@nextmovesoftware.com>
7911 * config/i386/i386-expand.cc (ix86_ternlog_idx) <case VEC_DUPLICATE>:
7912 Add a "goto do_mem_operand" as this need not match memory_operand.
7913 <case CONST_VECTOR>: Only args[2] may be volatile memory operand.
7914 Allow MEM/VEC_DUPLICATE/CONST_VECTOR as args[0] and args[1].
7916 2024-06-27 Richard Sandiford <richard.sandiford@arm.com>
7918 PR rtl-optimization/115677
7919 * late-combine.cc (pass_late_combine::gate): New function.
7921 2024-06-27 Stefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
7924 * config/s390/s390.cc (s390_decompose_addrstyle_without_index):
7925 Check for ADDR_REGS in s390_decompose_addrstyle_without_index.
7927 2024-06-27 Richard Biener <rguenther@suse.de>
7929 PR tree-optimization/115669
7930 * tree-vect-slp.cc (vect_build_slp_tree_2): Do not reassociate
7931 chains that participate in a reduction.
7933 2024-06-27 Aldy Hernandez <aldyh@redhat.com>
7935 * gimple-range-cache.cc (update_list::update_list): Add m_bitmaps.
7936 (update_list::~update_list): Initialize m_bitmaps.
7937 * gimple-range-cache.h (ssa_lazy_cache): Add m_bitmaps.
7938 * gimple-range.cc (enable_ranger): Remove global bitmap
7940 (disable_ranger): Remove global bitmap release.
7942 2024-06-27 Hu, Lin1 <lin1.hu@intel.com>
7944 * config/i386/sse.md
7945 (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name>
7946 <round_name>): Refactor the pattern.
7947 (unspec_fix<vcvtt_uns_suffix>_trunc<mode><sselongvecmodelower>2
7948 <mask_name><round_saeonly_name>): Ditto.
7949 (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name>
7950 <round_saeonly_name>): Ditto.
7951 * config/i386/subst.md (round_modev8sf_condition): Remove.
7952 (round_saeonly_modev8sf_condition): Ditto.
7954 2024-06-27 Hu, Lin1 <lin1.hu@intel.com>
7957 * config/i386/i386-expand.cc (ix86_expand_trunc_with_avx2_noavx512f):
7958 New function for generate a series of suitable insn.
7959 * config/i386/i386-protos.h (ix86_expand_trunc_with_avx2_noavx512f):
7960 Define new function.
7961 * config/i386/sse.md: Extend trunc<mode><mode>2 for x86-64-v3.
7962 (ssebytemode) Add V8HI.
7963 (PMOV_DST_MODE_2_AVX2): New mode iterator.
7964 (PMOV_SRC_MODE_3_AVX2): Ditto.
7965 * config/i386/mmx.md
7966 (trunc<mode><mmxhalfmodelower>2): Ditto.
7967 (avx512vl_trunc<mode><mmxhalfmodelower>2): Ditto.
7968 (truncv2si<mode>2): Ditto.
7969 (avx512vl_truncv2si<mode>2): Ditto.
7970 (mmxbytemode): New mode attr.
7972 2024-06-27 Hu, Lin1 <lin1.hu@intel.com>
7975 * config/i386/mmx.md
7976 (VI2_32_64): New mode iterator.
7977 (mmxhalfmode): New mode atter.
7978 (mmxhalfmodelower): Ditto.
7979 (truncv2hiv2qi2): Extend mode v4hi and change name from
7980 truncv2hiv2qi to trunc<mode><mmxhalfmodelower>2.
7982 2024-06-27 Hu, Lin1 <lin1.hu@intel.com>
7985 * tree-vect-generic.cc
7986 (expand_vector_conversion): Support convert for int -> int,
7987 float -> float and int <-> float.
7988 * tree-vect-stmts.cc (vectorizable_conversion): Wrap the
7989 indirect convert part.
7990 (supportable_indirect_convert_operation): New function.
7991 * tree-vectorizer.h (supportable_indirect_convert_operation):
7992 Define the new function.
7994 2024-06-27 Xi Ruoyao <xry111@xry111.site>
7996 * config/loongarch/loongarch.cc (loongarch_print_operand_reloc):
7997 Dedup and sort the comment describing modifiers.
7999 2024-06-27 Xi Ruoyao <xry111@xry111.site>
8001 * config/loongarch/loongarch.cc:
8002 (loongarch_use_bstrins_for_ior_with_mask): Split the main logic
8004 (loongarch_use_bstrins_for_ior_with_mask_1): ... here.
8005 (loongarch_rtx_costs): Special case for IOR those can be
8006 implemented with bstrins.
8008 2024-06-27 liuhongt <hongtao.liu@intel.com>
8011 * config/i386/i386.cc (ix86_rtx_costs): Make cost of MEM (reg +
8012 disp) just a little bit more than MEM (reg).
8014 2024-06-27 Pan Li <pan2.li@intel.com>
8016 * internal-fn.def (SAT_TRUNC): Add new signed IFN sat_trunc as
8018 * match.pd: Add new matching pattern for unsigned int sat_trunc.
8019 * optabs.def (OPTAB_CL): Add unsigned and signed optab.
8020 * tree-ssa-math-opts.cc (gimple_unsigend_integer_sat_trunc): Add
8021 new decl for the matching pattern generated func.
8022 (match_unsigned_saturation_trunc): Add new func impl to match
8024 (math_opts_dom_walker::after_dom_children): Add .SAT_TRUNC match
8025 function under BIT_IOR_EXPR case.
8027 2024-06-27 Pan Li <pan2.li@intel.com>
8029 * match.pd: Add convert description for minus and capture.
8030 * tree-vect-patterns.cc (vect_recog_build_binary_gimple_call): Add
8031 new logic to handle in_type is incompatibile with out_type, as
8032 well as rename from.
8033 (vect_recog_build_binary_gimple_stmt): Rename to.
8034 (vect_recog_sat_add_pattern): Leverage above renamed func.
8035 (vect_recog_sat_sub_pattern): Ditto.
8037 2024-06-27 Richard Biener <rguenther@suse.de>
8039 PR tree-optimization/115652
8040 * tree-vect-slp.cc (vect_schedule_slp_node): Only insert
8041 at the start of the block if that strictly dominates
8042 the discovered dependent stmt.
8044 2024-06-27 Richard Biener <rguenther@suse.de>
8046 PR tree-optimization/115493
8047 * tree-vect-loop.cc (vect_create_epilog_for_reduction): Use
8048 first scalar result.
8050 2024-06-26 Richard Biener <rguenther@suse.de>
8052 PR tree-optimization/115629
8053 * tree-ssa-tail-merge.cc (gimple_equal_p): Handle
8054 memory references better.
8055 (deps_ok_for_redirect): Handle the case not both blocks
8056 are considered a valid prevailing block.
8058 2024-06-26 Richard Biener <rguenther@suse.de>
8060 PR tree-optimization/115652
8061 * tree-vect-slp.cc (vect_schedule_slp_node): Advance the
8062 iterator based on last_stmt only for vector defs.
8064 2024-06-26 Jørgen Kvalsvik <j@lambda.is>
8066 * gcov-io.h (GCOV_ARC_TRUE): New.
8067 (GCOV_ARC_FALSE): New.
8068 * gcov.cc (struct arc_info): Add true_value, false_value.
8069 (read_graph_file): Read true_value, false_value.
8070 * profile.cc (branch_prob): Write GCOV_ARC_TRUE, GCOV_ARC_FALSE.
8072 2024-06-26 Jørgen Kvalsvik <j@lambda.is>
8074 * gcov.cc (print_usage): Reference masking MC/DC.
8076 2024-06-26 Jørgen Kvalsvik <j@lambda.is>
8078 * doc/gcov.texi: Add MC/DC section.
8080 2024-06-26 Jørgen Kvalsvik <j@lambda.is>
8082 * tree-profile.cc (find_conditions): Use auto_vec.
8084 2024-06-26 Andre Vieira <andre.simoesdiasvieira@arm.com>
8086 * config/arm/arm.cc (arm_predict_doloop_p): Reject loops with function
8087 calls that are not builtins.
8089 2024-06-26 Kyrylo Tkachov <ktkachov@nvidia.com>
8091 * config/aarch64/aarch64-cores.def (grace): New entry.
8092 * config/aarch64/aarch64-tune.md: Regenerate.
8093 * doc/invoke.texi (AArch64 Options): Document the above.
8095 2024-06-26 Evgeny Karpov <Evgeny.Karpov@microsoft.com>
8097 * config/i386/i386.cc (legitimize_dllimport_symbol): Remove unused
8099 (legitimize_pe_coff_extern_decl): Likewise.
8101 2024-06-26 Kewen Lin <linkw@linux.ibm.com>
8102 Xionghu Luo <xionghuluo@tencent.com>
8106 * config/rs6000/altivec.md (altivec_vmrghh_direct): Rename to ...
8107 (altivec_vmrghh_direct_be): ... this. Add condition BYTES_BIG_ENDIAN.
8108 (altivec_vmrghh_direct_le): New define_insn.
8109 (altivec_vmrglh_direct): Rename to ...
8110 (altivec_vmrglh_direct_be): ... this. Add condition BYTES_BIG_ENDIAN.
8111 (altivec_vmrglh_direct_le): New define_insn.
8112 (altivec_vmrghh): Adjust by calling gen_altivec_vmrghh_direct_be
8113 for BE and gen_altivec_vmrglh_direct_le for LE.
8114 (altivec_vmrglh): Adjust by calling gen_altivec_vmrglh_direct_be
8115 for BE and gen_altivec_vmrghh_direct_le for LE.
8116 (vec_widen_umult_hi_v16qi): Adjust the call to
8117 gen_altivec_vmrghh_direct by gen_altivec_vmrghh for BE
8118 and by gen_altivec_vmrglh for LE.
8119 (vec_widen_smult_hi_v16qi): Likewise.
8120 (vec_widen_umult_lo_v16qi): Adjust the call to
8121 gen_altivec_vmrglh_direct by gen_altivec_vmrglh for BE
8122 and by gen_altivec_vmrghh for LE.
8123 (vec_widen_smult_lo_v16qi): Likewise.
8124 * config/rs6000/rs6000.cc (altivec_expand_vec_perm_const): Replace
8125 CODE_FOR_altivec_vmrghh_direct by
8126 CODE_FOR_altivec_vmrghh_direct_be for BE and
8127 CODE_FOR_altivec_vmrghh_direct_le for LE. And replace
8128 CODE_FOR_altivec_vmrglh_direct by
8129 CODE_FOR_altivec_vmrglh_direct_be for BE and
8130 CODE_FOR_altivec_vmrglh_direct_le for LE.
8132 2024-06-26 Kewen Lin <linkw@linux.ibm.com>
8133 Xionghu Luo <xionghuluo@tencent.com>
8137 * config/rs6000/altivec.md (altivec_vmrghb_direct): Rename to ...
8138 (altivec_vmrghb_direct_be): ... this. Add condition BYTES_BIG_ENDIAN.
8139 (altivec_vmrghb_direct_le): New define_insn.
8140 (altivec_vmrglb_direct): Rename to ...
8141 (altivec_vmrglb_direct_be): ... this. Add condition BYTES_BIG_ENDIAN.
8142 (altivec_vmrglb_direct_le): New define_insn.
8143 (altivec_vmrghb): Adjust by calling gen_altivec_vmrghb_direct_be
8144 for BE and gen_altivec_vmrglb_direct_le for LE.
8145 (altivec_vmrglb): Adjust by calling gen_altivec_vmrglb_direct_be
8146 for BE and gen_altivec_vmrghb_direct_le for LE.
8147 * config/rs6000/rs6000.cc (altivec_expand_vec_perm_const): Replace
8148 CODE_FOR_altivec_vmrghb_direct by
8149 CODE_FOR_altivec_vmrghb_direct_be for BE and
8150 CODE_FOR_altivec_vmrghb_direct_le for LE. And replace
8151 CODE_FOR_altivec_vmrglb_direct by
8152 CODE_FOR_altivec_vmrglb_direct_be for BE and
8153 CODE_FOR_altivec_vmrglb_direct_le for LE.
8155 2024-06-26 Richard Biener <rguenther@suse.de>
8157 PR tree-optimization/115646
8158 * tree-call-cdce.cc (check_pow): Check for bit_sz values
8159 as allowed by transform.
8161 2024-06-26 Haochen Gui <guihaoc@gcc.gnu.org>
8163 * builtins.cc (interclass_mathfn_icode): Set optab to isnormal_optab
8164 for isnormal builtin.
8165 * optabs.def (isnormal_optab): New.
8166 * doc/md.texi (isnormal): Document.
8168 2024-06-26 Haochen Gui <guihaoc@gcc.gnu.org>
8170 * builtins.cc (interclass_mathfn_icode): Set optab to isfinite_optab
8171 for isfinite builtin.
8172 * optabs.def (isfinite_optab): New.
8173 * doc/md.texi (isfinite): Document.
8175 2024-06-26 liuhongt <hongtao.liu@intel.com>
8178 * match.pd: Simplify a < 0 ? -1 : 0 to (signed) >> 31 and a <
8179 0 ? 1 : 0 to (unsigned) a >> 31 for vector integer type.
8181 2024-06-26 Mark Harmstone <mark@harmstone.com>
8183 * dwarf2codeview.cc (struct codeview_custom_type): Add lf_procedure
8184 and lf_arglist to union.
8185 (write_lf_procedure, write_lf_arglist): New functions.
8186 (write_custom_types): Call write_lf_procedure and write_lf_arglist.
8187 (get_type_num_subroutine_type): New function.
8188 (get_type_num): Handle DW_TAG_subroutine_type DIEs.
8189 * dwarf2codeview.h (LF_PROCEDURE, LF_ARGLIST): Define.
8191 2024-06-26 Mark Harmstone <mark@harmstone.com>
8193 * dwarf2codeview.cc (struct codeview_custom_type): Add lf_bitfield to
8195 (write_lf_bitfield): New function.
8196 (write_custom_types): Call write_lf_bitfield.
8197 (create_bitfield): New function.
8198 (get_type_num_struct): Handle bitfields.
8199 * dwarf2codeview.h (LF_BITFIELD): Define.
8201 2024-06-26 David Malcolm <dmalcolm@redhat.com>
8203 * Makefile.in (OBJS-libcommon): Add diagnostic-global-context.o.
8204 * diagnostic-global-context.cc: New file, taken from material in
8206 * diagnostic.cc (global_diagnostic_context): Move to
8207 diagnostic-global-context.cc.
8208 (global_dc): Likewise.
8209 (verbatim): Likewise.
8210 (emit_diagnostic): Likewise.
8211 (emit_diagnostic_valist): Likewise.
8212 (emit_diagnostic_valist_meta): Likewise.
8214 (inform_n): Likewise.
8215 (warning): Likewise.
8216 (warning_at): Likewise.
8217 (warning_meta): Likewise.
8218 (warning_n): Likewise.
8219 (pedwarn): Likewise.
8220 (permerror): Likewise.
8221 (permerror_opt): Likewise.
8223 (error_n): Likewise.
8224 (error_at): Likewise.
8225 (error_meta): Likewise.
8227 (sorry_at): Likewise.
8228 (seen_error): Likewise.
8229 (fatal_error): Likewise.
8230 (internal_error): Likewise.
8231 (internal_error_no_backtrace): Likewise.
8232 (fnotice): Likewise.
8233 (auto_diagnostic_group::auto_diagnostic_group): Likewise.
8234 (auto_diagnostic_group::~auto_diagnostic_group): Likewise.
8236 2024-06-26 David Malcolm <dmalcolm@redhat.com>
8238 * diagnostic-path.cc (class path_label): Add m_path field,
8239 and use it to replace all uses of global_dc.
8240 (event_range::event_range): Add "ctxt" param and use it to
8241 construct m_path_label.
8242 (event_range::maybe_add_event): Add "ctxt" param and pass it to
8243 gcc_rich_location::add_location_if_nearby.
8244 (path_summary::path_summary): Add "ctxt" param and pass it to
8245 event_range::maybe_add_event.
8246 (diagnostic_context::print_path): Pass *this to path_summary ctor.
8247 (selftest::test_empty_path): Use "dc" when constructing
8248 path_summary rather than implicitly using global_dc.
8249 (selftest::test_intraprocedural_path): Likewise.
8250 (selftest::test_interprocedural_path_1): Likewise.
8251 (selftest::test_interprocedural_path_2): Likewise.
8252 (selftest::test_recursion): Likewise.
8253 (selftest::test_control_flow_1): Likewise.
8254 (selftest::test_control_flow_2): Likewise.
8255 (selftest::test_control_flow_3): Likewise.
8256 (selftest::assert_cfg_edge_path_streq): Likewise.
8257 (selftest::test_control_flow_5): Likewise.
8258 (selftest::test_control_flow_6): Likewise.
8259 (selftest::diagnostic_path_cc_tests): Eliminate use of global_dc.
8260 * diagnostic-show-locus.cc
8261 (gcc_rich_location::add_location_if_nearby): Add "ctxt" param and
8262 use it instead of implicitly using global_dc.
8263 (selftest::test_add_location_if_nearby): Use
8264 test_diagnostic_context rather than implicitly using global_dc.
8265 * diagnostic.cc (pedantic_warning_kind): Delete macro.
8266 (permissive_error_kind): Delete macro.
8267 (permissive_error_option): Delete macro.
8268 (diagnostic_context::diagnostic_enabled): Remove use of
8269 permissive_error_option.
8270 (diagnostic_context::report_diagnostic): Remove use of
8271 pedantic_warning_kind.
8272 (diagnostic_impl): Convert to...
8273 (diagnostic_context::diagnostic_impl): ...this.
8274 (diagnostic_n_impl): Convert to...
8275 (diagnostic_context::diagnostic_n_impl): ...this.
8276 (emit_diagnostic): Explicitly use global_dc for method call.
8277 (emit_diagnostic_valist): Likewise.
8278 (emit_diagnostic_valist_meta): Likewise.
8280 (inform_n): Likewise.
8281 (warning): Likewise.
8282 (warning_at): Likewise.
8283 (warning_meta): Likewise.
8284 (warning_n): Likewise.
8285 (pedwarn): Likewise.
8286 (permerror): Likewise.
8287 (permerror_opt): Likewise.
8289 (error_n): Likewise.
8290 (error_at): Likewise.
8291 (error_meta): Likewise.
8293 (sorry_at): Likewise.
8294 (fatal_error): Likewise.
8295 (internal_error): Likewise.
8296 (internal_error_no_backtrace): Likewise.
8297 * diagnostic.h (diagnostic_context::diagnostic_impl): New decl.
8298 (diagnostic_context::diagnostic_n_impl): New decl.
8299 * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
8302 2024-06-26 David Malcolm <dmalcolm@redhat.com>
8305 * doc/install.texi (Python3 modules): Update SARIF validation
8306 requirement to use check-jsonschema rather than jsonschema.
8308 2024-06-25 Mark Harmstone <mark@harmstone.com>
8310 * dwarf2codeview.cc (struct codeview_custom_type): Add lf_array to
8312 (write_lf_array): New function.
8313 (write_custom_types): Call write_lf_array.
8314 (get_type_num_array_type): New function.
8315 (get_type_num): Handle DW_TAG_array_type DIEs.
8316 * dwarf2codeview.h (LF_ARRAY): Define.
8318 2024-06-25 Mark Harmstone <mark@harmstone.com>
8320 * dwarf2codeview.cc (write_lf_union): New function.
8321 (write_custom_types): Call write_lf_union.
8322 (add_struct_forward_def): Handle DW_TAG_union_type DIEs.
8323 (get_type_num_struct): Handle unions.
8324 (get_type_num): Handle DW_TAG_union_type DIEs.
8325 * dwarf2codeview.h (LF_UNION): Define.
8327 2024-06-25 Sergei Lewis <slewis@rivosinc.com>
8329 * config/riscv/riscv-protos.h (riscv_vector::expand_vec_cmpmem): New
8330 function declaration.
8331 * config/riscv/riscv-string.cc (riscv_vector::expand_vec_cmpmem): New
8333 * config/riscv/riscv.md (cmpmemsi): Try riscv_vector::expand_vec_cmpmem
8334 for constant lengths.
8336 2024-06-25 Andrew MacLeod <amacleod@redhat.com>
8338 * doc/invoke.texi (vrp-block-limit): Document.
8339 * params.opt (param=vrp-block-limit): New.
8340 * tree-vrp.cc (fvrp_folder::execute): Invoke fast_vrp if block
8341 count exceeds limit.
8343 2024-06-25 Surya Kumari Jangala <jskumari@linux.ibm.com>
8345 PR rtl-optimization/111673
8346 * ira-color.cc (assign_hard_reg): Scale save/restore costs of
8347 callee save registers with block frequency.
8349 2024-06-25 Jeff Law <jlaw@ventanamicro.com>
8351 * config/fr30/constraints.md (Q): Remove unused constraint.
8352 * config/fr30/predicates.md (call_operand): Remove unused predicate.
8353 * config/fr30/fr30.md (call, vall_value): Turn into expanders and
8354 force the call address into a register.
8355 (*call, *call_value): Adjust to only allow indirect calls. Adjust
8356 output template accordingly.
8358 2024-06-25 Richard Sandiford <richard.sandiford@arm.com>
8360 * late-combine.cc (insn_combination::substitute_nondebug_use):
8361 Reject second and subsequent uses if targetm.cannot_copy_insn_p
8364 2024-06-25 Richard Biener <rguenther@suse.de>
8366 * gimple-range-gori.cc (gori_compute::may_recompute_p):
8367 Call is_export_p with NULL bb.
8369 2024-06-25 Xi Ruoyao <xry111@xry111.site>
8371 * doc/rtl.texi (jump_table_data): Fix typos.
8373 2024-06-25 Richard Sandiford <richard.sandiford@arm.com>
8375 * dbgcnt.def (late_combine): New debug counter.
8376 * late-combine.cc (insn_combination::run): Use it.
8378 2024-06-25 Eric Botcazou <ebotcazou@adacore.com>
8381 * config/sparc/linux64.h (CC1_SPEC): Pass -m32 for -mv8plus.
8383 2024-06-25 Thomas Schwinge <tschwinge@baylibre.com>
8388 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Move
8389 default-disable of late-combine passes from here...
8390 (rs6000_override_options_after_change): ... to here.
8392 2024-06-25 Richard Sandiford <richard.sandiford@arm.com>
8394 * expmed.cc (store_bit_field_using_insv): Revert earlier change
8395 to use force_subreg instead of simplify_gen_subreg.
8397 2024-06-25 YunQiang Su <syq@gcc.gnu.org>
8399 * config/mips/mips.cc(mips_expand_vec_cond_expr): Add extra
8400 argument to info that opernads[3] is cmp_res already.
8401 * config/mips/mips-protos.h(mips_expand_vec_cond_expr): Ditto.
8402 * config/mips/mips-msa.md(vcond_mask): Define new expand.
8403 (vcondu): Use mips_expand_vec_cond_expr with 4th argument.
8406 2024-06-25 YunQiang Su <syq@gcc.gnu.org>
8408 * config/mips/mips.md(conditional_trap_reg): Output $0 instead
8409 of 0 if !ISA_HAS_COND_TRAPI.
8411 2024-06-25 Evgeny Karpov <Evgeny.Karpov@microsoft.com>
8413 * config.gcc: Add winnt-dll.o, which contains the DLL
8414 import/export implementation.
8415 * config/aarch64/aarch64.cc (aarch64_load_symref_appropriately):
8416 Add dllimport implementation.
8417 (aarch64_expand_call): Likewise.
8418 (aarch64_legitimize_address): Likewise.
8419 * config/aarch64/cygming.h (SYMBOL_FLAG_DLLIMPORT): Modify MinGW
8420 environment to support DLL import/export.
8421 (SYMBOL_FLAG_DLLEXPORT): Likewise.
8422 (SYMBOL_REF_DLLIMPORT_P): Likewise.
8423 (SYMBOL_FLAG_STUBVAR): Likewise.
8424 (SYMBOL_REF_STUBVAR_P): Likewise.
8425 (TARGET_VALID_DLLIMPORT_ATTRIBUTE_P): Likewise.
8426 (TARGET_ASM_FILE_END): Likewise.
8427 (SUB_TARGET_RECORD_STUB): Likewise.
8428 (GOT_ALIAS_SET): Likewise.
8429 (PE_COFF_EXTERN_DECL_SHOULD_BE_LEGITIMIZED): Likewise.
8430 (HAVE_64BIT_POINTERS): Likewise.
8432 2024-06-25 Evgeny Karpov <Evgeny.Karpov@microsoft.com>
8434 * config/i386/cygming.h
8435 (PE_COFF_EXTERN_DECL_SHOULD_BE_LEGITIMIZED): Declare whether an
8436 external declaration should be legitimized.
8437 (HAVE_64BIT_POINTERS): Define whether the target supports 64-bit
8439 * config/mingw/mingw32.h (defined): Use the correct
8440 DllMainCRTStartup entry function.
8441 * config/mingw/winnt-dll.cc (defined): Exclude ix86-related code.
8443 2024-06-25 Evgeny Karpov <Evgeny.Karpov@microsoft.com>
8445 * config/aarch64/aarch64.cc: Extend the aarch64 attributes list.
8446 * config/aarch64/cygming.h (SUBTARGET_ATTRIBUTE_TABLE): Define the
8447 selectany attribute.
8449 2024-06-25 Evgeny Karpov <Evgeny.Karpov@microsoft.com>
8451 * config/i386/cygming.h (mingw_pe_record_stub): Rename functions
8452 in mingw folder which will be reused for aarch64.
8453 (TARGET_ASM_FILE_END): Update to new target-independent name.
8454 (SUBTARGET_ATTRIBUTE_TABLE): Likewise.
8455 (TARGET_VALID_DLLIMPORT_ATTRIBUTE_P): Likewise.
8456 (SUB_TARGET_RECORD_STUB): Likewise.
8457 * config/i386/i386-protos.h (ix86_handle_selectany_attribute):
8459 (mingw_handle_selectany_attribute): Likewise.
8460 (i386_pe_valid_dllimport_attribute_p): Likewise.
8461 (mingw_pe_valid_dllimport_attribute_p): Likewise.
8462 (i386_pe_file_end): Likewise.
8463 (mingw_pe_file_end): Likewise.
8464 (i386_pe_record_stub): Likewise.
8465 (mingw_pe_record_stub): Likewise.
8466 * config/mingw/winnt.cc (ix86_handle_selectany_attribute):
8468 (mingw_handle_selectany_attribute): Likewise.
8469 (i386_pe_valid_dllimport_attribute_p): Likewise.
8470 (mingw_pe_valid_dllimport_attribute_p): Likewise.
8471 (i386_pe_record_stub): Likewise.
8472 (mingw_pe_record_stub): Likewise.
8473 (i386_pe_file_end): Likewise.
8474 (mingw_pe_file_end): Likewise.
8475 * config/mingw/winnt.h (mingw_handle_selectany_attribute): Declate
8476 functionality that will be reused by multiple targets.
8477 (mingw_pe_file_end): Likewise.
8478 (mingw_pe_record_stub): Likewise.
8479 (mingw_pe_valid_dllimport_attribute_p): Likewise.
8481 2024-06-25 Evgeny Karpov <Evgeny.Karpov@microsoft.com>
8483 * config.gcc: Add winnt-dll.o, which contains the DLL
8484 import/export implementation.
8485 * config/i386/cygming.h (SUB_TARGET_RECORD_STUB): Remove the
8486 old implementation. Rename the required function to MinGW.
8487 Use MinGW implementation for COFF and nothing otherwise.
8488 (GOT_ALIAS_SET): Likewise.
8489 * config/i386/i386-expand.cc (ix86_expand_move): Likewise.
8490 * config/i386/i386-expand.h (ix86_GOT_alias_set): Likewise.
8491 (legitimize_pe_coff_symbol): Likewise.
8492 * config/i386/i386-protos.h (i386_pe_record_stub): Likewise.
8493 * config/i386/i386.cc (is_imported_p): Likewise.
8494 (legitimate_pic_address_disp_p): Likewise.
8495 (ix86_GOT_alias_set): Likewise.
8496 (legitimize_pic_address): Likewise.
8497 (legitimize_tls_address): Likewise.
8498 (struct dllimport_hasher): Likewise.
8500 (get_dllimport_decl): Likewise.
8501 (legitimize_pe_coff_extern_decl): Likewise.
8502 (legitimize_dllimport_symbol): Likewise.
8503 (legitimize_pe_coff_symbol): Likewise.
8504 (ix86_legitimize_address): Likewise.
8505 * config/i386/i386.h (GOT_ALIAS_SET): Likewise.
8506 * config/mingw/winnt.cc (i386_pe_record_stub): Likewise.
8507 (mingw_pe_record_stub): Likewise.
8508 * config/mingw/winnt.h (mingw_pe_record_stub): Likewise.
8509 * config/mingw/t-cygming: Add the winnt-dll.o compilation.
8510 * config/mingw/winnt-dll.cc: New file.
8511 * config/mingw/winnt-dll.h: New file.
8513 2024-06-25 Evgeny Karpov <Evgeny.Karpov@microsoft.com>
8515 * config.gcc: Move mingw_* declations to mingw.
8516 * config/aarch64/aarch64-protos.h
8517 (mingw_pe_maybe_record_exported_symbol): Likewise.
8518 (mingw_pe_section_type_flags): Likewise.
8519 (mingw_pe_unique_section): Likewise.
8520 (mingw_pe_encode_section_info): Likewise.
8521 * config/aarch64/cygming.h
8522 (mingw_pe_asm_named_section): Likewise.
8523 (mingw_pe_declare_function_type): Likewise.
8524 * config/i386/i386-protos.h
8525 (mingw_pe_unique_section): Likewise.
8526 (mingw_pe_declare_function_type): Likewise.
8527 (mingw_pe_maybe_record_exported_symbol): Likewise.
8528 (mingw_pe_encode_section_info): Likewise.
8529 (mingw_pe_section_type_flags): Likewise.
8530 (mingw_pe_asm_named_section): Likewise.
8531 * config/mingw/winnt.h: New file.
8533 2024-06-25 Mark Harmstone <mark@harmstone.com>
8535 * dwarf2codeview.cc (struct codeview_type): Add is_fwd_ref member.
8536 (struct codeview_subtype): Add lf_member to union.
8537 (struct codeview_custom_type): Add lf_structure to union.
8538 (struct codeview_deferred_type): New structure.
8539 (deferred_types, last_deferred_type): New variables.
8540 (get_type_num): Add new args to prototype.
8541 (write_lf_fieldlist): Handle LF_MEMBER subtypes.
8542 (write_lf_structure): New function.
8543 (write_custom_types): Call write_lf_structure.
8544 (get_type_num_pointer_type): Add in_struct argument.
8545 (get_type_num_const_type): Likewise.
8546 (get_type_num_volatile_type): Likewise.
8547 (add_enum_forward_def): Fix get_type_num call.
8548 (get_type_num_enumeration_type): Add in-struct argument.
8549 (add_deferred_type, flush_deferred_types): New functions.
8550 (add_struct_forward_def, get_type_num_struct): Likewise.
8551 (get_type_num): Handle self-referential structs.
8552 (add_variable): Fix get_type_num call.
8553 (codeview_debug_early_finish): Call flush_deferred_types.
8554 * dwarf2codeview.h (LF_CLASS, LF_STRUCTURE, LF_MEMBER): Define.
8556 2024-06-25 Kewen Lin <linkw@linux.ibm.com>
8558 * coretypes.h (enum tree_index): Forward declaration.
8559 * defaults.h (FLOAT_TYPE_SIZE): Remove.
8560 (DOUBLE_TYPE_SIZE): Likewise.
8561 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8562 * doc/rtl.texi: Update document by replacing {FLOAT,DOUBLE}_TYPE_SIZE
8563 with C type {float,double}.
8564 * doc/tm.texi.in: Document new hook mode_for_floating_type, remove
8565 document entries for {FLOAT,DOUBLE,LONG_DOUBLE}_TYPE_SIZE and
8566 update document for WIDEST_HARDWARE_FP_SIZE.
8567 * doc/tm.texi: Regenerate.
8568 * emit-rtl.cc (init_emit_once): Replace DOUBLE_TYPE_SIZE by
8569 calling targetm.c.mode_for_floating_type with TI_DOUBLE_TYPE.
8570 * real.h (REAL_VALUE_TO_TARGET_LONG_DOUBLE): Use TYPE_PRECISION of
8571 long_double_type_node to replace LONG_DOUBLE_TYPE_SIZE.
8572 * system.h (FLOAT_TYPE_SIZE): Poison.
8573 (DOUBLE_TYPE_SIZE): Likewise.
8574 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8575 * target.def (mode_for_floating_type): New hook.
8576 * targhooks.cc (default_mode_for_floating_type): New function.
8577 (default_scalar_mode_supported_p): Update macros
8578 {FLOAT,DOUBLE,LONG_DOUBLE}_TYPE_SIZE by calling
8579 targetm.c.mode_for_floating_type with
8580 TI_{FLOAT,DOUBLE,LONG_DOUBLE}_TYPE.
8581 * targhooks.h (default_mode_for_floating_type): New declaration.
8582 * tree-core.h (enum tree_index): Specify underlying type unsigned
8583 to sync with forward declaration in coretypes.h.
8584 (NUM_FLOATN_TYPES): Explicitly convert to int.
8585 (NUM_FLOATNX_TYPES): Likewise.
8586 (NUM_FLOATN_NX_TYPES): Likewise.
8587 * tree.cc (build_common_tree_nodes): Update macros
8588 {FLOAT,DOUBLE,LONG_DOUBLE}_TYPE_SIZE by calling
8589 targetm.c.mode_for_floating_type with
8590 TI_{FLOAT,DOUBLE,LONG_DOUBLE}_TYPE and set type mode accordingly.
8591 * config/arc/arc.h (FLOAT_TYPE_SIZE): Remove.
8592 (DOUBLE_TYPE_SIZE): Likewise.
8593 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8594 * config/bpf/bpf.h (FLOAT_TYPE_SIZE): Remove.
8595 (DOUBLE_TYPE_SIZE): Likewise.
8596 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8597 * config/epiphany/epiphany.h (FLOAT_TYPE_SIZE): Remove.
8598 (DOUBLE_TYPE_SIZE): Likewise.
8599 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8600 * config/fr30/fr30.h (FLOAT_TYPE_SIZE): Remove.
8601 (DOUBLE_TYPE_SIZE): Likewise.
8602 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8603 * config/frv/frv.h (FLOAT_TYPE_SIZE): Remove.
8604 (DOUBLE_TYPE_SIZE): Likewise.
8605 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8606 * config/ft32/ft32.h (FLOAT_TYPE_SIZE): Remove.
8607 (DOUBLE_TYPE_SIZE): Likewise.
8608 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8609 * config/gcn/gcn.h (FLOAT_TYPE_SIZE): Remove.
8610 (DOUBLE_TYPE_SIZE): Likewise.
8611 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8612 * config/iq2000/iq2000.h (FLOAT_TYPE_SIZE): Remove.
8613 (DOUBLE_TYPE_SIZE): Likewise.
8614 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8615 * config/lm32/lm32.h (FLOAT_TYPE_SIZE): Remove.
8616 (DOUBLE_TYPE_SIZE): Likewise.
8617 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8618 * config/m32c/m32c.h (FLOAT_TYPE_SIZE): Remove.
8619 (DOUBLE_TYPE_SIZE): Likewise.
8620 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8621 * config/m32r/m32r.h (FLOAT_TYPE_SIZE): Remove.
8622 (DOUBLE_TYPE_SIZE): Likewise.
8623 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8624 * config/microblaze/microblaze.h (FLOAT_TYPE_SIZE): Remove.
8625 (DOUBLE_TYPE_SIZE): Likewise.
8626 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8627 * config/mmix/mmix.h (FLOAT_TYPE_SIZE): Remove.
8628 (DOUBLE_TYPE_SIZE): Likewise.
8629 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8630 * config/moxie/moxie.h (FLOAT_TYPE_SIZE): Remove.
8631 (DOUBLE_TYPE_SIZE): Likewise.
8632 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8633 * config/msp430/msp430.h (FLOAT_TYPE_SIZE): Remove.
8634 (DOUBLE_TYPE_SIZE): Likewise.
8635 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8636 * config/nds32/nds32.h (FLOAT_TYPE_SIZE): Remove.
8637 (DOUBLE_TYPE_SIZE): Likewise.
8638 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8639 * config/nios2/nios2.h (FLOAT_TYPE_SIZE): Remove.
8640 (DOUBLE_TYPE_SIZE): Likewise.
8641 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8642 * config/nvptx/nvptx.h (FLOAT_TYPE_SIZE): Remove.
8643 (DOUBLE_TYPE_SIZE): Likewise.
8644 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8645 * config/or1k/or1k.h (FLOAT_TYPE_SIZE): Remove.
8646 (DOUBLE_TYPE_SIZE): Likewise.
8647 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8648 * config/pdp11/pdp11.h (FLOAT_TYPE_SIZE): Remove.
8649 (DOUBLE_TYPE_SIZE): Likewise.
8650 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8651 * config/pru/pru.h (FLOAT_TYPE_SIZE): Remove.
8652 (DOUBLE_TYPE_SIZE): Likewise.
8653 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8654 * config/stormy16/stormy16.h (FLOAT_TYPE_SIZE): Remove.
8655 (DOUBLE_TYPE_SIZE): Likewise.
8656 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8657 * config/visium/visium.h (FLOAT_TYPE_SIZE): Remove.
8658 (DOUBLE_TYPE_SIZE): Likewise.
8659 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8660 * config/xtensa/xtensa.h (FLOAT_TYPE_SIZE): Remove.
8661 (DOUBLE_TYPE_SIZE): Likewise.
8662 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8663 * config/rs6000/rs6000.cc (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8664 (rs6000_c_mode_for_floating_type): New function.
8665 * config/rs6000/rs6000.h (FLOAT_TYPE_SIZE): Remove.
8666 (DOUBLE_TYPE_SIZE): Likewise.
8667 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8668 * config/aarch64/aarch64.cc (aarch64_c_mode_for_floating_type):
8670 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8671 * config/aarch64/aarch64.h (FLOAT_TYPE_SIZE): Remove.
8672 (DOUBLE_TYPE_SIZE): Likewise.
8673 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8674 * config/alpha/alpha.cc (alpha_c_mode_for_floating_type): New
8676 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8677 * config/alpha/alpha.h (FLOAT_TYPE_SIZE): Remove.
8678 (DOUBLE_TYPE_SIZE): Likewise.
8679 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8680 * config/avr/avr.cc (avr_c_mode_for_floating_type): New
8682 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8683 * config/avr/avr.h (FLOAT_TYPE_SIZE): Remove.
8684 (DOUBLE_TYPE_SIZE): Likewise.
8685 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8686 * config/i386/i386.cc (ix86_c_mode_for_floating_type): New
8688 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8689 * config/i386/i386.h (FLOAT_TYPE_SIZE): Remove.
8690 (DOUBLE_TYPE_SIZE): Likewise.
8691 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8692 * config/ia64/ia64.cc (ia64_c_mode_for_floating_type): New
8694 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8695 * config/ia64/ia64.h (FLOAT_TYPE_SIZE): Remove.
8696 (DOUBLE_TYPE_SIZE): Likewise.
8697 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8698 * config/riscv/riscv.cc (riscv_c_mode_for_floating_type): New function.
8699 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8700 * config/riscv/riscv.h (FLOAT_TYPE_SIZE): Remove.
8701 (DOUBLE_TYPE_SIZE): Likewise.
8702 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8703 * config/rl78/rl78.cc (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8704 (rl78_c_mode_for_floating_type): New function.
8705 * config/rl78/rl78.h (FLOAT_TYPE_SIZE): Remove.
8706 (DOUBLE_TYPE_SIZE): Likewise.
8707 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8708 * config/rx/rx.cc (rx_c_mode_for_floating_type): New function.
8709 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8710 * config/rx/rx.h (FLOAT_TYPE_SIZE): Remove.
8711 (DOUBLE_TYPE_SIZE): Likewise.
8712 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8713 * config/s390/s390.cc (s390_c_mode_for_floating_type): New function.
8714 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8715 * config/s390/s390.h (FLOAT_TYPE_SIZE): Remove.
8716 (DOUBLE_TYPE_SIZE): Likewise.
8717 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8718 * config/sh/sh.cc (sh_c_mode_for_floating_type): New function.
8719 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8720 * config/sh/sh.h (LONG_DOUBLE_TYPE_SIZE): Remove.
8721 * config/h8300/h8300.cc (h8300_c_mode_for_floating_type): New
8723 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8724 * config/h8300/h8300.h (FLOAT_TYPE_SIZE): Remove.
8725 (DOUBLE_TYPE_SIZE): Remove.
8726 (LONG_DOUBLE_TYPE_SIZE): Remove.
8727 (DOUBLE_TYPE_MODE): New macro.
8728 * config/h8300/linux.h (DOUBLE_TYPE_SIZE): Remove.
8729 (DOUBLE_TYPE_MODE): New macro.
8730 * config/loongarch/loongarch.cc (loongarch_c_mode_for_floating_type):
8732 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8733 * config/loongarch/loongarch.h (FLOAT_TYPE_SIZE): Remove.
8734 (DOUBLE_TYPE_SIZE): Remove.
8735 (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8736 (LA_LONG_DOUBLE_TYPE_SIZE): ... this.
8737 (UNITS_PER_FPVALUE): Replace LONG_DOUBLE_TYPE_SIZE with
8738 LA_LONG_DOUBLE_TYPE_SIZE.
8739 (MAX_FIXED_MODE_SIZE): Likewise.
8740 (STRUCTURE_SIZE_BOUNDARY): Likewise.
8741 (BIGGEST_ALIGNMENT): Likewise.
8742 * config/m68k/m68k.cc (m68k_c_mode_for_floating_type): New function.
8743 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8744 * config/m68k/m68k.h (LONG_DOUBLE_TYPE_SIZE): Remove.
8745 (LONG_DOUBLE_TYPE_MODE): New macro.
8746 * config/m68k/netbsd-elf.h (LONG_DOUBLE_TYPE_SIZE): Remove.
8747 (LONG_DOUBLE_TYPE_MODE): New macro.
8748 * config/mips/mips.cc (mips_c_mode_for_floating_type): New function.
8749 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8750 * config/mips/mips.h (UNITS_PER_FPVALUE): Replace LONG_DOUBLE_TYPE_SIZE
8751 with MIPS_LONG_DOUBLE_TYPE_SIZE.
8752 (MAX_FIXED_MODE_SIZE): Likewise.
8753 (STRUCTURE_SIZE_BOUNDARY): Likewise.
8754 (BIGGEST_ALIGNMENT): Likewise.
8755 (FLOAT_TYPE_SIZE): Remove.
8756 (DOUBLE_TYPE_SIZE): Remove.
8757 (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8758 (MIPS_LONG_DOUBLE_TYPE_SIZE): ... this.
8759 * config/mips/n32-elf.h (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8760 (MIPS_LONG_DOUBLE_TYPE_SIZE): ... this.
8761 * config/pa/pa.cc (pa_c_mode_for_floating_type): New function.
8762 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8763 (pa_scalar_mode_supported_p): Rename FLOAT_TYPE_SIZE to
8764 PA_FLOAT_TYPE_SIZE, rename DOUBLE_TYPE_SIZE to PA_DOUBLE_TYPE_SIZE
8765 and rename LONG_DOUBLE_TYPE_SIZE to PA_LONG_DOUBLE_TYPE_SIZE.
8766 * config/pa/pa.h (PA_FLOAT_TYPE_SIZE): New macro.
8767 (PA_DOUBLE_TYPE_SIZE): Likewise.
8768 (PA_LONG_DOUBLE_TYPE_SIZE): Likewise.
8769 * config/pa/pa-64.h (FLOAT_TYPE_SIZE): Rename to ...
8770 (PA_FLOAT_TYPE_SIZE): ... this.
8771 (DOUBLE_TYPE_SIZE): Rename to ...
8772 (PA_DOUBLE_TYPE_SIZE): ... this.
8773 (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8774 (PA_LONG_DOUBLE_TYPE_SIZE): ... this.
8775 * config/pa/pa-hpux.h (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8776 (PA_LONG_DOUBLE_TYPE_SIZE): ... this.
8777 * config/sparc/sparc.cc (sparc_c_mode_for_floating_type): New function.
8778 (TARGET_C_MODE_FOR_FLOATING_TYPE): New macro.
8779 (FLOAT_TYPE_SIZE): Remove.
8780 (DOUBLE_TYPE_SIZE): Likewise.
8781 (LONG_DOUBLE_TYPE_SIZE): Likewise.
8782 (sparc_type_code): Replace FLOAT_TYPE_SIZE with TYPE_PRECISION of
8784 * config/sparc/sparc.h (FLOAT_TYPE_SIZE): Remove.
8785 (DOUBLE_TYPE_SIZE): Remove.
8786 * config/sparc/freebsd.h (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8787 (SPARC_LONG_DOUBLE_TYPE_SIZE): ... this.
8788 * config/sparc/linux.h (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8789 (SPARC_LONG_DOUBLE_TYPE_SIZE): ... this.
8790 * config/sparc/linux64.h (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8791 (SPARC_LONG_DOUBLE_TYPE_SIZE): ... this.
8792 * config/sparc/netbsd-elf.h (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8793 (SPARC_LONG_DOUBLE_TYPE_SIZE): ... this.
8794 * config/sparc/openbsd64.h (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8795 (SPARC_LONG_DOUBLE_TYPE_SIZE): ... this.
8796 * config/sparc/sol2.h (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8797 (SPARC_LONG_DOUBLE_TYPE_SIZE): ... this.
8798 * config/sparc/sp-elf.h (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8799 (SPARC_LONG_DOUBLE_TYPE_SIZE): ... this.
8800 * config/sparc/sp64-elf.h (LONG_DOUBLE_TYPE_SIZE): Rename to ...
8801 (SPARC_LONG_DOUBLE_TYPE_SIZE): ... this.
8802 * config/bfin/bfin.h (FLOAT_TYPE_SIZE): Rename to ...
8803 (BFIN_FLOAT_TYPE_SIZE): ... this.
8804 (DOUBLE_TYPE_SIZE): Rename to ...
8805 (BFIN_DOUBLE_TYPE_SIZE): ... this.
8806 (LONG_DOUBLE_TYPE_SIZE): Remove.
8807 (UNITS_PER_FLOAT): Replace FLOAT_TYPE_SIZE with BFIN_FLOAT_TYPE_SIZE.
8808 (UNITS_PER_DOUBLE): Replace DOUBLE_TYPE_SIZE with
8809 BFIN_DOUBLE_TYPE_SIZE.
8811 2024-06-25 Kewen Lin <linkw@linux.ibm.com>
8813 * config/vms/vms.cc (vms_patch_builtins): Use TYPE_PRECISION of
8814 long_double_type_node to replace LONG_DOUBLE_TYPE_SIZE.
8816 2024-06-25 Andrew MacLeod <amacleod@redhat.com>
8818 * tree-vrp.cc (execute_fast_vrp): Do not use transitive relations.
8819 * value-query.cc (range_query::create_relation_oracle): Add
8820 parameter to enable transitive relations.
8821 * value-query.h (range_query::create_relation_oracle): Likewise.
8822 * value-relation.h (dom_oracle::dom_oracle): Likewise.
8823 * value-relation.cc (dom_oracle::dom_oracle): Likewise.
8824 (dom_oracle::register_transitives): Check transitive flag.
8826 2024-06-24 Sergei Lewis <slewis@rivosinc.com>
8828 * config/riscv/riscv-protos.h (riscv_vector::expand_vec_setmem): New
8829 function declaration.
8830 * config/riscv/riscv-string.cc (riscv_vector::expand_vec_setmem): New
8831 function: this generates an inline vectorised memory set, if and only if
8832 we know the entire operation can be performed in a single vector store.
8833 * config/riscv/riscv.md (setmem<mode>): Try riscv_vector::expand_vec_setmem
8834 for constant lengths. Do not require operand 2 to be a constant.
8836 2024-06-24 Patrick O'Neill <patrick@rivosinc.com>
8838 * doc/sourcebuild.texi (dg-remove-option): Add documentation.
8839 (dg-add-option): Add documentation for riscv_{a,zaamo,zalrsc,ztso}
8841 2024-06-24 Roger Sayle <roger@nextmovesoftware.com>
8842 Richard Biener <rguenther@suse.de>
8844 PR tree-optimization/113673
8845 * gimple-ssa-store-merging.cc (find_bswap_or_nop_load): Make static.
8846 (find_bswap_or_nop_1): Avoid transformations (load merging) when
8847 stmt_can_throw_internal indicates that a statement can trap.
8849 2024-06-24 Richard Biener <rguenther@suse.de>
8851 PR tree-optimization/115602
8852 * tree-vect-slp.cc (vect_cse_slp_nodes): Delay populating the
8853 bst-map to avoid cycles.
8855 2024-06-24 Richard Biener <rguenther@suse.de>
8857 PR tree-optimization/115528
8858 * tree-vect-data-refs.cc (vect_compute_data_ref_alignment):
8859 Make sure to look at both the inner and outer loop step
8862 2024-06-24 Pali Rohár <pali@kernel.org>
8864 * config/i386/mingw-w64.h (CPP_SPEC): Add missing -mcrtdll=
8865 cases: msvcr40*, msvcrtd*.
8866 * config/mingw/mingw32.h (CPP_SPEC): Add missing -mcrtdll=
8867 cases: msvcr40*, msvcrtd*.
8868 * doc/invoke.texi: Add missing -mcrtdll= cases: msvcr40*,
8869 msvcrtd*, msvcr71*. Express wildcards with *. Document _UCRT.
8871 2024-06-24 Richard Sandiford <richard.sandiford@arm.com>
8873 * common.opt.urls: Regenerate.
8875 2024-06-24 Richard Sandiford <richard.sandiford@arm.com>
8877 PR rtl-optimization/106594
8878 PR rtl-optimization/114515
8879 PR rtl-optimization/114575
8880 PR rtl-optimization/114996
8881 PR rtl-optimization/115104
8882 * Makefile.in (OBJS): Add late-combine.o.
8883 * common.opt (flate-combine-instructions): New option.
8884 * doc/invoke.texi: Document it.
8885 * opts.cc (default_options_table): Enable it by default at -O2
8887 * tree-pass.h (make_pass_late_combine): Declare.
8888 * late-combine.cc: New file.
8889 * passes.def: Add two instances of late_combine.
8890 * doc/passes.texi: Document the new passes.
8891 * config/i386/i386-options.cc (ix86_override_options_after_change):
8892 Disable late-combine by default.
8893 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Likewise.
8894 * config/xtensa/xtensa.cc (xtensa_option_override): Likewise.
8896 2024-06-24 Richard Sandiford <richard.sandiford@arm.com>
8898 * rtl-ssa.h: Include predicates.h.
8899 * rtl-ssa/predicates.h: New file.
8900 * rtl-ssa/access-utils.h (prev_call_clobbers_ignoring): Rename to...
8901 (prev_call_clobbers): ...this and treat the ignore parameter as an
8902 object with the same interface as ignore_nothing.
8903 (next_call_clobbers_ignoring): Rename to...
8904 (next_call_clobbers): ...this and treat the ignore parameter as an
8905 object with the same interface as ignore_nothing.
8906 (first_nondebug_insn_use_ignoring): Rename to...
8907 (first_nondebug_insn_use): ...this and treat the ignore parameter as
8908 an object with the same interface as ignore_nothing.
8909 (last_nondebug_insn_use_ignoring): Rename to...
8910 (last_nondebug_insn_use): ...this and treat the ignore parameter as
8911 an object with the same interface as ignore_nothing.
8912 (last_access_ignoring): Rename to...
8913 (last_access): ...this and treat the ignore parameter as an object
8914 with the same interface as ignore_nothing. Conditionally skip
8916 (prev_access_ignoring): Rename to...
8917 (prev_access): ...this and treat the ignore parameter as an object
8918 with the same interface as ignore_nothing.
8919 (first_def_ignoring): Replace with...
8920 (first_access): ...this new function.
8921 (next_access_ignoring): Rename to...
8922 (next_access): ...this and treat the ignore parameter as an object
8923 with the same interface as ignore_nothing. Conditionally skip
8925 * rtl-ssa/change-utils.h (insn_is_changing): Delete.
8926 (restrict_movement_ignoring): Rename to...
8927 (restrict_movement): ...this and treat the ignore parameter as an
8928 object with the same interface as ignore_nothing.
8929 (recog_ignoring): Rename to...
8930 (recog): ...this and treat the ignore parameter as an object with
8931 the same interface as ignore_nothing.
8932 * rtl-ssa/changes.h (insn_is_changing_closure): Delete.
8933 * rtl-ssa/functions.h (function_info::add_regno_clobber): Treat
8934 the ignore parameter as an object with the same interface as
8936 * rtl-ssa/insn-utils.h (insn_is): Delete.
8937 * rtl-ssa/insns.h (insn_is_closure): Delete.
8938 * rtl-ssa/member-fns.inl
8939 (insn_is_changing_closure::insn_is_changing_closure): Delete.
8940 (insn_is_changing_closure::operator()): Likewise.
8941 (function_info::add_regno_clobber): Treat the ignore parameter
8942 as an object with the same interface as ignore_nothing.
8943 (ignore_changing_insns::ignore_changing_insns): New function.
8944 (ignore_changing_insns::should_ignore_insn): Likewise.
8945 * rtl-ssa/movement.h (restrict_movement_for_dead_range): Treat
8946 the ignore parameter as an object with the same interface as
8948 (restrict_movement_for_defs_ignoring): Rename to...
8949 (restrict_movement_for_defs): ...this and treat the ignore parameter
8950 as an object with the same interface as ignore_nothing.
8951 (restrict_movement_for_uses_ignoring): Rename to...
8952 (restrict_movement_for_uses): ...this and treat the ignore parameter
8953 as an object with the same interface as ignore_nothing. Conditionally
8955 * doc/rtl.texi: Update for above name changes. Use
8956 ignore_changing_insns instead of insn_is_changing.
8957 * config/aarch64/aarch64-cc-fusion.cc (cc_fusion::parallelize_insns):
8959 * pair-fusion.cc (no_ignore): Delete.
8960 (latest_hazard_before, first_hazard_after): Update for above name
8961 changes. Use ignore_nothing instead of no_ignore.
8962 (pair_fusion_bb_info::fuse_pair): Update for above name changes.
8963 Use ignore_changing_insns instead of insn_is_changing.
8964 (pair_fusion::try_promote_writeback): Likewise.
8966 2024-06-24 Richard Biener <rguenther@suse.de>
8968 PR tree-optimization/115599
8969 * tree-ssa-reassoc.cc (compare_repeat_factors): Use explicit
8970 compares to avoid truncations.
8972 2024-06-24 Haochen Gui <guihaoc@gcc.gnu.org>
8975 * config/rs6000/vsx.md (vsx_stxvd2x4_le_const_<mode>): New.
8977 2024-06-24 Haochen Gui <guihaoc@gcc.gnu.org>
8979 * fwprop.cc (try_fwprop_subst_pattern): Invoke change_is_worthwhile
8980 to judge if a replacement is worthwhile. Remove single_set check
8981 and add is_debug_insn check.
8982 * recog.cc (swap_change): Invalidate recog_data when the cached INSN
8984 * rtl-ssa/changes.cc (rtl_ssa::changes_are_worthwhile): Check if the
8985 insn cost of new rtl is unknown and fail the replacement.
8987 2024-06-24 Mark Harmstone <mark@harmstone.com>
8989 * dwarf2codeview.cc (MAX_FIELDLIST_SIZE): Define.
8990 (struct codeview_integer): New structure.
8991 (struct codeview_subtype): Likewise
8992 (struct codeview_custom_type): Add lf_fieldlist and lf_enum to union.
8993 (write_cv_integer, cv_integer_len): New functions.
8994 (write_lf_fieldlist, write_lf_enum): Likewise.
8995 (write_custom_types): Call write_lf_fieldlist and write_lf_enum.
8996 (add_enum_forward_def): New function.
8997 (get_type_num_enumeration_type): Likewise.
8998 (get_type_num): Handle DW_TAG_enumeration_type DIEs.
8999 * dwarf2codeview.h (LF_FIELDLIST, LF_INDEX, LF_ENUMERATE): Define.
9000 (LF_ENUM, LF_CHAR, LF_SHORT, LF_USHORT, LF_LONG): Likewise.
9001 (LF_ULONG, LF_QUADWORD, LF_UQUADWORD): Likewise.
9002 (CV_ACCESS_PRIVATE, CV_ACCESS_PROTECTED): Likewise.
9003 (CV_ACCESS_PUBLIC, CV_PROP_FWDREF): Likewise.
9005 2024-06-24 Mark Harmstone <mark@harmstone.com>
9008 (struct codeview_custom_type): Add lf_modifier to union.
9009 (write_cv_padding, write_lf_modifier): New functions.
9010 (write_custom_types): Call write_lf_modifier.
9011 (get_type_num_const_type): New function.
9012 (get_type_num_volatile_type): Likewise.
9013 (get_type_num): Handle DW_TAG_const_type and DW_TAG_volatile_type DIEs.
9014 * dwarf2codeview.h (MOD_const, MOD_volatile): Define.
9015 (LF_MODIFIER): Likewise.
9017 2024-06-24 Mark Harmstone <mark@harmstone.com>
9019 * dwarf2codeview.cc (FIRST_TYPE): Define.
9020 (struct codeview_custom_type): New structure.
9021 (custom_types, last_custom_type): New variables.
9022 (get_type_num): Prototype.
9023 (write_lf_pointer, write_custom_types): New functions.
9024 (codeview_debug_finish): Call write_custom_types.
9025 (add_custom_type, get_type_num_pointer_type): New functions.
9026 (get_type_num): Handle DW_TAG_pointer_type DIEs.
9027 * dwarf2codeview.h (T_VOID): Define.
9028 (CV_POINTER_32, CV_POINTER_64): Likewise.
9029 (T_32PVOID, T_64PVOID): Likewise.
9030 (CV_PTR_NEAR32, CV_PTR64, LF_POINTER): Likewise.
9032 2024-06-24 Mark Harmstone <mark@harmstone.com>
9034 * dwarf2codeview.cc (get_type_num): Handle typedefs.
9036 2024-06-24 Mark Harmstone <mark@harmstone.com>
9038 * dwarf2codeview.cc (struct codeview_type): New structure.
9039 (struct die_hasher): Likewise.
9040 (types_htab): New variable.
9041 (codeview_debug_finish): Free types_htab if allocated.
9042 (get_type_num_base_type, get_type_num): New function.
9043 (add_variable): Call get_type_num.
9044 * dwarf2codeview.h (T_CHAR, T_SHORT, T_LONG, T_QUAD): Define.
9045 (T_UCHAR, T_USHORT, T_ULONG, T_UQUAD, T_BOOL08): Likewise.
9046 (T_REAL32, T_REAL64, T_REAL80, T_REAL128, T_RCHAR): Likewise.
9047 (T_WCHAR, T_INT4, T_UINT4, T_CHAR16, T_CHAR32, T_CHAR8): Likewise.
9049 2024-06-23 Mark Harmstone <mark@harmstone.com>
9051 * dwarf2codeview.cc (S_LDATA32, S_GDATA32): Define.
9052 (struct codeview_symbol): New structure.
9053 (sym, last_sym): New variables.
9054 (write_data_symbol): New function.
9055 (write_codeview_symbols): Call write_data_symbol.
9056 (add_variable, codeview_debug_early_finish): New functions.
9057 * dwarf2codeview.h (codeview_debug_early_finish): Prototype.
9059 (dwarf2out_early_finish): Call codeview_debug_early_finish.
9061 2024-06-23 Artemiy Volkov <Artemiy.Volkov@synopsys.com>
9063 * config/riscv/riscv.cc (riscv_expand_conditional_move): Add a
9066 2024-06-23 Jeff Law <jlaw@ventanamicro.com>
9069 * config/riscv/riscv.cc (riscv_macro_fusion_pair_p): Verify object
9070 is a CONST_INT before looking at INTVAL.
9072 2024-06-23 Richard Biener <rguenther@suse.de>
9074 PR tree-optimization/115597
9075 * tree-vect-slp.cc (vect_cse_slp_nodes): Allow to CSE
9078 2024-06-23 Richard Biener <rguenther@suse.de>
9080 PR tree-optimization/115579
9081 * tree-ssa-loop-im.cc (execute_sm): Return the auxiliary data
9083 (hoist_memory_references): Record the flag var that's eventually
9084 created and re-use it when all stores are in the same BB.
9086 2024-06-23 Collin Funk <collin.funk1@gmail.com>
9089 * config/i386/avx512fp16intrin.h (_mm512_conj_pch): Make the
9090 constant unsigned before shifting.
9091 * config/i386/avx512fp16vlintrin.h (_mm256_conj_pch): Likewise.
9092 (_mm_conj_pch): Likewise.
9094 2024-06-23 demin.han <demin.han@starfivetech.com>
9096 * config/riscv/predicates.md (comparison_except_eqge_operator): Only
9098 (comparison_except_ge_operator): Ditto.
9099 * config/riscv/riscv-string.cc (expand_rawmemchr): Use cmp pattern.
9100 (expand_strcmp): Ditto.
9101 * config/riscv/riscv-vector-builtins-bases.cc: Remove eqne cond.
9102 * config/riscv/vector.md (@pred_eqne<mode>_scalar): Remove eqne
9104 (*pred_eqne<mode>_scalar_merge_tie_mask): Ditto.
9105 (*pred_eqne<mode>_scalar): Ditto.
9106 (*pred_eqne<mode>_scalar_narrow): Ditto.
9107 (*pred_eqne<mode>_extended_scalar_merge_tie_mask): Ditto.
9108 (*pred_eqne<mode>_extended_scalar): Ditto.
9109 (*pred_eqne<mode>_extended_scalar_narrow): Ditto.
9111 2024-06-21 David Malcolm <dmalcolm@redhat.com>
9113 * diagnostic-format-json.cc
9114 (json_output_format::on_end_diagnostic): Use
9115 get_diagnostic_kind_text rather than embedding a duplicate copy of
9117 * diagnostic-format-sarif.cc
9118 (make_rule_id_for_diagnostic_kind): Likewise.
9119 * diagnostic.cc (get_diagnostic_kind_text): New.
9120 * diagnostic.h (get_diagnostic_kind_text): New decl.
9122 2024-06-21 David Malcolm <dmalcolm@redhat.com>
9124 * diagnostic-path.cc (diagnostic_event::meaning::dump_to_pp): Move
9125 here from diagnostic.cc.
9126 (diagnostic_event::meaning::maybe_get_verb_str): Likewise.
9127 (diagnostic_event::meaning::maybe_get_noun_str): Likewise.
9128 (diagnostic_event::meaning::maybe_get_property_str): Likewise.
9129 (diagnostic_path::get_first_event_in_a_function): Likewise.
9130 (diagnostic_path::interprocedural_p): Likewise.
9131 (debug): Likewise for diagnostic_path * overload.
9132 * diagnostic.cc (diagnostic_event::meaning::dump_to_pp): Move from
9133 here to diagnostic-path.cc.
9134 (diagnostic_event::meaning::maybe_get_verb_str): Likewise.
9135 (diagnostic_event::meaning::maybe_get_noun_str): Likewise.
9136 (diagnostic_event::meaning::maybe_get_property_str): Likewise.
9137 (diagnostic_path::get_first_event_in_a_function): Likewise.
9138 (diagnostic_path::interprocedural_p): Likewise.
9139 (debug): Likewise for diagnostic_path * overload.
9141 2024-06-21 Jeff Law <jlaw@ventanamicro.com>
9143 * config/stormy16/stormy16.md (swpn_zext): New pattern.
9145 2024-06-21 Richard Sandiford <richard.sandiford@arm.com>
9147 * config/stormy16/predicates.md (xs_hi_nonmemory_operand): Handle
9148 symbol_ref and label_ref.
9150 2024-06-21 Richard Sandiford <richard.sandiford@arm.com>
9152 * config/iq2000/iq2000.cc (iq2000_print_operand): Make %p handle 1<<31.
9153 * config/iq2000/iq2000.md: Remove "I" constraints on
9154 power_of_2_operands.
9156 2024-06-21 Richard Sandiford <richard.sandiford@arm.com>
9158 * rtl-ssa/changes.cc (rtl_ssa::changes_are_worthwhile): Don't
9160 * rtl-ssa/insns.cc (insn_info::calculate_cost): Likewise.
9162 2024-06-21 Andrew MacLeod <amacleod@redhat.com>
9164 * gimple-range.cc (gimple_ranger::register_inferred_ranges): Do not
9165 dump global range info after set_range_info.
9166 (gimple_ranger::register_transitive_inferred_ranges): Likewise.
9167 (dom_ranger::range_of_stmt): Likewise.
9168 * tree-ssanames.cc (set_range_info): If global range info
9169 changes, maybe print new range to dump_file.
9170 * tree-vrp.cc (remove_unreachable::handle_early): Do not
9171 dump global range info after set_range_info.
9172 (remove_unreachable::remove): Likewise.
9173 (remove_unreachable::remove_and_update_globals): Likewise.
9174 (pass_assumptions::execute): Likewise.
9176 2024-06-21 Andrew MacLeod <amacleod@redhat.com>
9178 * gimple-range.cc (dom_ranger::dom_ranger): Create a block
9180 (dom_ranger::~dom_ranger): Dispose of the block vector.
9181 (dom_ranger::edge_range): Delete.
9182 (dom_ranger::range_on_edge): Combine range in src BB with any
9183 range gori_nme_on_edge returns.
9184 (dom_ranger::range_in_bb): Combine global range with any active
9185 contextual range for an ssa-name.
9186 (dom_ranger::range_of_stmt): Fix non-ssa LHS case, use
9187 fur_depend for folding so relations can be registered.
9188 (dom_ranger::maybe_push_edge): Delete.
9189 (dom_ranger::pre_bb): Create incoming contextual range vector.
9190 (dom_ranger::post_bb): Free contextual range vector.
9191 * gimple-range.h (dom_ranger::edge_range): Delete.
9192 (dom_ranger::m_e0): Delete.
9193 (dom_ranger::m_e1): Delete.
9194 (dom_ranger::m_bb): New.
9195 (dom_ranger::m_pop_list): Delete.
9196 * tree-vrp.cc (execute_fast_vrp): Enable relation oracle.
9198 2024-06-21 Andrew MacLeod <amacleod@redhat.com>
9200 * tree-vrp.cc (remove_unreachable::remove): Export global range
9201 if builtin_unreachable dominates all uses.
9202 (remove_unreachable::remove_and_update_globals): Do not reset SCEV.
9203 (execute_ranger_vrp): Reset SCEV here instead.
9204 (fvrp_folder::fvrp_folder): Take final pass flag
9205 and create a remove_unreachable object when specified.
9206 (fvrp_folder::pre_fold_stmt): Register GIMPLE_CONDs with
9207 the remove_unreachcable object.
9208 (fvrp_folder::m_unreachable): New.
9209 (execute_fast_vrp): Process remove_unreachable object.
9210 (pass_vrp::execute): Add final_p flag to execute_fast_vrp.
9212 2024-06-21 David Malcolm <dmalcolm@redhat.com>
9215 * doc/install.texi: Mention optional usage of "jsonschema" tool.
9217 2024-06-21 David Malcolm <dmalcolm@redhat.com>
9220 * diagnostic-format-sarif.cc
9221 (sarif_builder::make_location_object): Pass any column override
9222 from rich_loc to maybe_make_physical_location_object.
9223 (sarif_builder::maybe_make_physical_location_object): Add
9224 "column_override" param and pass it to maybe_make_region_object.
9225 (sarif_builder::maybe_make_region_object): Add "column_override"
9226 param and use it when the location has 0 for a column. Don't
9227 add "startLine", "startColumn", "endLine", or "endColumn" if
9228 the values aren't positive.
9229 (sarif_builder::maybe_make_region_object_for_context): Don't
9230 add "startLine" or "endLine" if the values aren't positive.
9232 2024-06-21 Richard Sandiford <richard.sandiford@arm.com>
9234 * config/sh/sh.md (*minus_plus_one): Add constraints.
9236 2024-06-21 Andrew Pinski <quic_apinski@quicinc.com>
9238 PR tree-optimization/68855
9239 * tree-complex.cc (init_dont_simulate_again): Handle PAREN_EXPR
9241 (complex_propagate::visit_stmt): Likewise.
9242 (expand_complex_move): Don't handle PAREN_EXPR.
9243 (expand_complex_paren): New function.
9244 (expand_complex_operations_1): Handle PAREN_EXPR like
9245 NEGATE_EXPR. And call expand_complex_paren for PAREN_EXPR.
9247 2024-06-21 Richard Biener <rguenther@suse.de>
9249 * doc/passes.texi: Remove references to no longer existing
9252 2024-06-21 YunQiang Su <syq@gcc.gnu.org>
9254 * configure.ac: Set gcc_cv_as_mips_explicit_relocs if
9255 gcc_cv_as_mips_explicit_relocs_pcrel.
9256 * configure: Regenerate.
9258 2024-06-21 YunQiang Su <syq@gcc.gnu.org>
9260 * config/mips/mips.cc(mips_rtx_costs): Set condmove cost.
9261 * config/mips/mips.md(mov<GPR:mode>_on_<MOVECC:mode>,
9262 mov<GPR:mode>_on_<MOVECC:mode>_mips16e2,
9263 mov<GPR:mode>_on_<GPR2:mode>_ne
9264 mov<GPR:mode>_on_<GPR2:mode>_ne_mips16e2): Define name by
9265 remove starting *, so that we can use CODE_FOR_.
9267 2024-06-21 Kewen Lin <linkw@linux.ibm.com>
9268 Xionghu Luo <xionghuluo@tencent.com>
9272 * config/rs6000/altivec.md (altivec_vmrghw_direct_<VSX_W:mode>): Rename
9274 (altivec_vmrghw_direct_<VSX_W:mode>_be): ... this. Add the condition
9276 (altivec_vmrghw_direct_<VSX_W:mode>_le): New define_insn.
9277 (altivec_vmrglw_direct_<VSX_W:mode>): Rename to ...
9278 (altivec_vmrglw_direct_<VSX_W:mode>_be): ... this. Add the condition
9280 (altivec_vmrglw_direct_<VSX_W:mode>_le): New define_insn.
9281 (altivec_vmrghw): Adjust by calling gen_altivec_vmrghw_direct_v4si_be
9282 for BE and gen_altivec_vmrglw_direct_v4si_le for LE.
9283 (altivec_vmrglw): Adjust by calling gen_altivec_vmrglw_direct_v4si_be
9284 for BE and gen_altivec_vmrghw_direct_v4si_le for LE.
9285 (vec_widen_umult_hi_v8hi): Adjust the call to
9286 gen_altivec_vmrghw_direct_v4si by gen_altivec_vmrghw for BE
9287 and by gen_altivec_vmrglw for LE.
9288 (vec_widen_smult_hi_v8hi): Likewise.
9289 (vec_widen_umult_lo_v8hi): Adjust the call to
9290 gen_altivec_vmrglw_direct_v4si by gen_altivec_vmrglw for BE
9291 and by gen_altivec_vmrghw for LE
9292 (vec_widen_smult_lo_v8hi): Likewise.
9293 * config/rs6000/rs6000.cc (altivec_expand_vec_perm_const): Replace
9294 CODE_FOR_altivec_vmrghw_direct_v4si by
9295 CODE_FOR_altivec_vmrghw_direct_v4si_be for BE and
9296 CODE_FOR_altivec_vmrghw_direct_v4si_le for LE. And replace
9297 CODE_FOR_altivec_vmrglw_direct_v4si by
9298 CODE_FOR_altivec_vmrglw_direct_v4si_be for BE and
9299 CODE_FOR_altivec_vmrglw_direct_v4si_le for LE.
9300 * config/rs6000/vsx.md (vsx_xxmrghw_<VSX_W:mode>): Adjust by calling
9301 gen_altivec_vmrghw_direct_v4si_be for BE and
9302 gen_altivec_vmrglw_direct_v4si_le for LE.
9303 (vsx_xxmrglw_<VSX_W:mode>): Adjust by calling
9304 gen_altivec_vmrglw_direct_v4si_be for BE and
9305 gen_altivec_vmrghw_direct_v4si_le for LE.
9307 2024-06-20 Roger Sayle <roger@nextmovesoftware.com>
9309 * config/i386/i386-expand.cc (ix86_ternlog_idx): Allow any SUBREG
9310 that matches register_operand. Use rtx_equal_p to compare REG
9311 or SUBREG "leaf" operands.
9313 2024-06-20 Jeff Law <jlaw@ventanamicro.com>
9315 * config/riscv/bitmanip.md (<bit_optab><mode>): New unified
9316 pattern for bset/binv using a code iterator.
9317 (<bit_optab>i<mode>): Likewise.
9318 (<bit_optab><mode>_mask): Likewise. Support XOR via any_or.
9319 (<bit_optab>isidi): Likewise.
9320 * config/riscv/iterators.md (bit_optab): New iterator.
9322 2024-06-20 Hongyu Wang <hongyu.wang@intel.com>
9324 * config/i386/i386-options.cc (ix86_option_override_internal):
9325 Use TARGET_*_P (opts->x_ix86_isa_flags*) instead of TARGET_*
9326 for UINTR, LAM and APX_F.
9328 2024-06-20 Richard Biener <rguenther@suse.de>
9330 PR tree-optimization/114413
9331 * tree-vect-slp.cc (release_scalar_stmts_to_slp_tree_map):
9332 New function, split out from ...
9333 (vect_analyze_slp): ... here. Call it.
9334 (vect_cse_slp_nodes): New function.
9335 (vect_optimize_slp): Call it.
9337 2024-06-20 Feng Xue <fxue@os.amperecomputing.com>
9339 * tree-vect-loop.cc (vect_transform_reduction): Change assertion to
9340 cover all lane-reducing ops.
9342 2024-06-20 Feng Xue <fxue@os.amperecomputing.com>
9344 * tree-vect-loop.cc (vect_transform_reduction): Replace vec_oprnds0/1/2
9345 with one new array variable vec_oprnds[3].
9347 2024-06-20 Feng Xue <fxue@os.amperecomputing.com>
9349 * tree-vect-loop.cc (vectorizable_reduction): Remove v_reduc_type, and
9350 replace it to another local variable reduction_type.
9352 2024-06-20 Feng Xue <fxue@os.amperecomputing.com>
9354 * tree-vect-loop.cc (vectorizable_reduction): Remove the duplicated
9357 2024-06-20 Feng Xue <fxue@os.amperecomputing.com>
9359 * tree-vectorizer.h (lane_reducing_stmt_p): New function.
9360 * tree-vect-slp.cc (vect_analyze_slp): Use new function
9361 lane_reducing_stmt_p to check statement.
9363 2024-06-19 YunQiang Su <syq@gcc.gnu.org>
9366 2024-06-19 Collin Funk <collin.funk1@gmail.com>
9368 * configure.ac: Add missing quotation of variable
9369 gcc_cv_as_mips_explicit_relocs.
9370 * configure: Regenerate.
9372 2024-06-19 demin.han <demin.han@starfivetech.com>
9374 * config/riscv/riscv-vector-builtins-bases.cc: Remove eqne cond
9375 * config/riscv/vector.md (@pred_eqne<mode>_scalar): Remove patterns
9376 (*pred_eqne<mode>_scalar_merge_tie_mask): Ditto
9377 (*pred_eqne<mode>_scalar): Ditto
9378 (*pred_eqne<mode>_scalar_narrow): Ditto
9380 2024-06-19 Patrick O'Neill <patrick@rivosinc.com>
9382 * common/config/riscv/riscv-common.cc: Add 'a' extension to
9385 2024-06-19 Jakub Jelinek <jakub@redhat.com>
9387 PR tree-optimization/115544
9388 * gimple-lower-bitint.cc (gimple_lower_bitint): Disable optimizing
9389 loads used by COMPLEX_EXPR operands.
9391 2024-06-19 mayshao <mayshao-oc@zhaoxin.com>
9393 * common/config/i386/cpuinfo.h (get_zhaoxin_cpu): Recognize shijidadao.
9394 * common/config/i386/i386-common.cc: Add shijidadao.
9395 * common/config/i386/i386-cpuinfo.h (enum processor_subtypes):
9396 Add ZHAOXIN_FAM7H_SHIJIDADAO.
9397 * config.gcc: Add shijidadao.
9398 * config/i386/driver-i386.cc (host_detect_local_cpu):
9399 Let -march=native recognize shijidadao processors.
9400 * config/i386/i386-c.cc (ix86_target_macros_internal): Add shijidadao.
9401 * config/i386/i386-options.cc (m_ZHAOXIN): Add m_SHIJIDADAO.
9402 (m_SHIJIDADAO): New definition.
9403 * config/i386/i386.h (enum processor_type): Add PROCESSOR_SHIJIDADAO.
9404 * config/i386/x86-tune-costs.h (struct processor_costs):
9405 Add shijidadao_cost.
9406 * config/i386/x86-tune-sched.cc (ix86_issue_rate): Add shijidadao.
9407 (ix86_adjust_cost): Ditto.
9408 * config/i386/x86-tune.def (X86_TUNE_USE_GATHER_2PARTS): Add m_SHIJIDADAO.
9409 (X86_TUNE_USE_GATHER_4PARTS): Ditto.
9410 (X86_TUNE_USE_GATHER_8PARTS): Ditto.
9411 (X86_TUNE_AVOID_128FMA_CHAINS): Ditto.
9412 * doc/extend.texi: Add details about shijidadao.
9413 * doc/invoke.texi: Ditto.
9415 2024-06-19 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
9417 * config/xtensa/xtensa.cc (print_operand):
9418 When outputting MEMW before the instruction, check if the previous
9419 instruction is already that.
9421 2024-06-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
9422 Stam Markianos-Wright <stam.markianos-wright@arm.com>
9424 * config/arm/arm-protos.h (arm_target_bb_ok_for_lob): Change
9425 declaration to pass basic_block.
9426 (arm_attempt_dlstp_transform): New declaration.
9427 * config/arm/arm.cc (TARGET_LOOP_UNROLL_ADJUST): Define targethook.
9428 (TARGET_PREDICT_DOLOOP_P): Likewise.
9429 (arm_target_bb_ok_for_lob): Adapt condition.
9430 (arm_mve_get_vctp_lanes): New function.
9431 (arm_dl_usage_type): New internal enum.
9432 (arm_get_required_vpr_reg): New function.
9433 (arm_get_required_vpr_reg_param): New function.
9434 (arm_get_required_vpr_reg_ret_val): New function.
9435 (arm_mve_get_loop_vctp): New function.
9436 (arm_mve_insn_predicated_by): New function.
9437 (arm_mve_across_lane_insn_p): New function.
9438 (arm_mve_load_store_insn_p): New function.
9439 (arm_mve_impl_pred_on_outputs_p): New function.
9440 (arm_mve_impl_pred_on_inputs_p): New function.
9441 (arm_last_vect_def_insn): New function.
9442 (arm_mve_impl_predicated_p): New function.
9443 (arm_mve_check_reg_origin_is_num_elems): New function.
9444 (arm_mve_dlstp_check_inc_counter): New function.
9445 (arm_mve_dlstp_check_dec_counter): New function.
9446 (arm_mve_loop_valid_for_dlstp): New function.
9447 (arm_predict_doloop_p): New function.
9448 (arm_loop_unroll_adjust): New function.
9449 (arm_emit_mve_unpredicated_insn_to_seq): New function.
9450 (arm_attempt_dlstp_transform): New function.
9451 * config/arm/arm.opt (mdlstp): New option.
9452 * config/arm/iterators.md (dlstp_elemsize, letp_num_lanes,
9453 letp_num_lanes_neg, letp_num_lanes_minus_1): New attributes.
9454 (DLSTP, LETP): New iterators.
9455 * config/arm/mve.md (predicated_doloop_end_internal<letp_num_lanes>,
9456 dlstp<dlstp_elemsize>_insn): New insn patterns.
9457 * config/arm/thumb2.md (doloop_end): Adapt to support tail-predicated
9459 (doloop_begin): Likewise.
9460 * config/arm/types.md (mve_misc): New mve type to represent
9461 predicated_loop_end insn sequences.
9462 * config/arm/unspecs.md:
9463 (DLSTP8, DLSTP16, DLSTP32, DSLTP64,
9464 LETP8, LETP16, LETP32, LETP64): New unspecs for DLSTP and LETP.
9466 2024-06-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
9467 Stam Markianos-Wright <stam.markianos-wright@arm.com>
9469 * df-core.cc (df_bb_regno_only_def_find): New helper function.
9470 * df.h (df_bb_regno_only_def_find): Declare new function.
9471 * loop-doloop.cc (doloop_condition_get): Add support for detecting
9472 predicated vectorized hardware loops.
9473 (doloop_modify): Add support for GTU condition checks.
9474 (doloop_optimize): Update costing computation to support alterations to
9475 desc->niter_expr by the backend.
9477 2024-06-19 Collin Funk <collin.funk1@gmail.com>
9479 * configure.ac: Add missing quotation of variable
9480 gcc_cv_as_mips_explicit_relocs.
9481 * configure: Regenerate.
9483 2024-06-19 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
9485 * config/xtensa/xtensa-protos.h (xtensa_constantsynth):
9486 Change the second argument from HOST_WIDE_INT to rtx.
9487 * config/xtensa/xtensa.cc (#include):
9488 Add "context.h" and "pass_manager.h".
9489 (machine_function): Add a new hash_map field "litpool_usage".
9490 (xtensa_constantsynth): Make "src" (the second operand) accept
9491 RTX literal instead of its value, and treat both bare and pooled
9492 SI/SFmode literals equally by bit-exact canonicalization into
9493 CONST_INT RTX internally. And then, make avoid synthesis if
9494 such multiple identical canonicalized literals are found in same
9495 function when optimizing for size. Finally, for literals where
9496 synthesis is not possible or has been avoided, re-emit "move"
9497 RTXes with canonicalized ones to increase the chances of sharing
9498 literal pool entries.
9499 * config/xtensa/xtensa.md (split patterns for constant synthesis):
9500 Change to simply invoke xtensa_constantsynth() as mentioned above,
9501 and add new patterns for when TARGET_AUTO_LITPOOLS is enabled.
9503 2024-06-18 Edwin Lu <ewlu@rivosinc.com>
9504 Robin Dapp <rdapp@ventanamicro.com>
9506 * config/riscv/riscv-v.cc: Move assert out of conditional block
9508 2024-06-18 Edwin Lu <ewlu@rivosinc.com>
9509 Robin Dapp <rdapp@ventanamicro.com>
9511 * config/riscv/autovec-opt.md: Fix mode mismatch
9513 2024-06-18 Andrew Pinski <quic_apinski@quicinc.com>
9515 * config/aarch64/aarch64-cores.def: Add comment
9516 saying thunderxt81/t83 are aliases of octeontx81/83.
9518 2024-06-18 Andrew Pinski <quic_apinski@quicinc.com>
9520 * config/aarch64/aarch64-cores.def (thunderxt88p1): Make an alias of thunderxt88 and
9521 move below thunderxt88.
9522 * config/aarch64/aarch64-tune.md: Regenerate.
9524 2024-06-18 David Malcolm <dmalcolm@redhat.com>
9526 * Makefile.in (OBJS): Move selftest-diagnostic-path.o,
9527 selftest-logical-location.o, and tree-diagnostic-path.o to...
9528 (OBJS-libcommon): ...here, renaming tree-diagnostic-path.o to
9530 * tree-diagnostic-path.cc: Rename to...
9531 * diagnostic-path.cc: ...this. Drop include of "tree.h".
9532 (tree_diagnostic_path_cc_tests): Rename to...
9533 (diagnostic_path_cc_tests): ...this.
9534 * selftest-run-tests.cc (selftest::run_tests): Update for above
9536 * selftest.h (tree_diagnostic_path_cc_tests): Rename decl to...
9537 (diagnostic_path_cc_tests): ...this.
9539 2024-06-18 David Malcolm <dmalcolm@redhat.com>
9541 * diagnostic-format-json.cc (diagnostic_output_format_init_json):
9542 Replace clearing of diagnostic_context::m_print_path callback with
9543 setting the path format to DPF_NONE.
9544 * diagnostic-format-sarif.cc
9545 (diagnostic_output_format_init_sarif): Likewise.
9546 * diagnostic.cc (diagnostic_context::show_any_path): Replace call
9547 to diagnostic_context::m_print_path callback with a direct call to
9548 diagnostic_context::print_path.
9549 * diagnostic.h (diagnostic_context::print_path): New decl.
9550 (diagnostic_context::m_print_path): Delete callback.
9551 * tree-diagnostic-path.cc (default_tree_diagnostic_path_printer):
9553 (diagnostic_context::print_path): ...this.
9554 * tree-diagnostic.cc (tree_diagnostics_defaults): Delete
9555 initialization of m_print_path.
9556 * tree-diagnostic.h (default_tree_diagnostic_path_printer): Delete
9559 2024-06-18 David Malcolm <dmalcolm@redhat.com>
9561 * diagnostic-macro-unwinding.cc: New file, with material taken
9562 from tree-diagnostic.cc.
9563 * diagnostic-macro-unwinding.h: New file, with material taken
9564 from tree-diagnostic.h.
9565 * tree-diagnostic-path.cc: Repalce include of "tree-diagnostic.h"
9566 with "diagnostic-macro-unwinding.h".
9567 * tree-diagnostic.cc (struct loc_map_pair): Move to
9568 diagnostic-macro-unwinding.cc.
9569 (maybe_unwind_expanded_macro_loc): Likewise.
9570 (virt_loc_aware_diagnostic_finalizer): Likewise.
9571 * tree-diagnostic.h (virt_loc_aware_diagnostic_finalizer): Move
9572 decl to diagnostic-macro-unwinding.h.
9573 (maybe_unwind_expanded_macro_loc): Likewise.
9575 2024-06-18 David Malcolm <dmalcolm@redhat.com>
9577 * Makefile.in (OBJS): Add diagnostic-macro-unwinding.o.
9579 2024-06-18 David Malcolm <dmalcolm@redhat.com>
9581 * diagnostic-format-json.cc: Include "diagnostic-path.h" and
9582 "logical-location.h".
9583 (make_json_for_path): Move tree-diagnostic-path.cc's
9584 default_tree_make_json_for_path here, renaming it and making it
9586 (json_output_format::on_end_diagnostic): Replace call of
9587 m_context's m_make_json_for_path callback with a direct call to
9589 * diagnostic.h (diagnostic_context::m_make_json_for_path): Drop
9591 * tree-diagnostic-path.cc: Drop include of "json.h".
9592 (default_tree_make_json_for_path): Rename to make_json_for_path
9593 and move to diagnostic-format-json.cc.
9594 * tree-diagnostic.cc (tree_diagnostics_defaults): Drop
9595 initialization of m_make_json_for_path.
9596 * tree-diagnostic.h (default_tree_make_json_for): Delete decl.
9598 2024-06-18 David Malcolm <dmalcolm@redhat.com>
9600 * Makefile.in (OBJS): Add selftest-diagnostic-path.o and
9601 selftest-logical-location.o.
9602 * logical-location.h: Include "label-text.h".
9603 (class logical_location): Update leading comment.
9604 * selftest-diagnostic-path.cc: New file, adapted from
9605 simple-diagnostic-path.cc and from material in
9606 tree-diagnostic-path.cc.
9607 * selftest-diagnostic-path.h: New file, adapted from
9608 simple-diagnostic-path.h and from material in
9609 tree-diagnostic-path.cc.
9610 * selftest-logical-location.cc: New file.
9611 * selftest-logical-location.h: New file.
9612 * tree-diagnostic-path.cc: Remove includes of "tree-pretty-print.h",
9613 "langhooks.h", and "simple-diagnostic-path.h". Add include of
9614 "selftest-diagnostic-path.h".
9615 (class test_diagnostic_path): Delete, in favor of new
9616 implementation in selftest-diagnostic-path.{h,cc}, which is
9617 directly derived from diagnostic_path, rather than from
9618 simple_diagnostic_path.
9619 (selftest::test_intraprocedural_path): Eliminate tree usage,
9620 via change to test_diagnostic_path, using strings rather than
9621 function_decls for identifying functions in the test.
9622 (selftest::test_interprocedural_path_1): Likewise.
9623 (selftest::test_interprocedural_path_2): Likewise.
9624 (selftest::test_recursion): Likewise.
9625 (selftest::test_control_flow_1): Likewise.
9626 (selftest::test_control_flow_2): Likewise.
9627 (selftest::test_control_flow_3): Likewise.
9628 (selftest::assert_cfg_edge_path_streq): Likewise.
9629 (selftest::test_control_flow_5): Likewise.
9630 (selftest::test_control_flow_6): Likewise.
9632 2024-06-18 David Malcolm <dmalcolm@redhat.com>
9634 * diagnostic.cc: Include "logical-location.h".
9635 (diagnostic_path::get_first_event_in_a_function): Fix typo in
9636 leading comment. Rewrite to use logical_location rather than
9637 tree. Drop test on stack depth.
9638 (diagnostic_path::interprocedural_p): Rewrite to use
9639 logical_location rather than tree.
9640 (logical_location::function_p): New.
9641 * diagnostic-path.h (diagnostic_event::get_fndecl): Eliminate
9643 (diagnostic_path::same_function_p): New pure virtual func.
9644 * logical-location.h (logical_location::get_name_for_path_output):
9645 New pure virtual func.
9646 * simple-diagnostic-path.cc
9647 (simple_diagnostic_path::same_function_p): New.
9648 (simple_diagnostic_event::simple_diagnostic_event): Initialize
9650 * simple-diagnostic-path.h: Include "tree-logical-location.h".
9651 (simple_diagnostic_event::get_fndecl): Convert from a vfunc
9652 implementation to an accessor.
9653 (simple_diagnostic_event::get_logical_location): Use
9655 (simple_diagnostic_event::m_logical_loc): New field.
9656 (simple_diagnostic_path::same_function_p): New decl.
9657 * tree-diagnostic-path.cc: Move pragma disabling -Wformat-diag to
9658 cover the whole file.
9659 (can_consolidate_events): Add params "path", "ev1_idx", and
9660 "ev2_idx". Rewrite to use diagnostic_path::same_function_p rather
9662 (per_thread_summary::per_thread_summary): Add "path" param
9663 (per_thread_summary::m_path): New field.
9664 (event_range::event_range): Update for conversion of m_fndecl to
9666 (event_range::maybe_add_event): Rename param "idx" to
9667 "new_ev_idx". Update call to can_consolidate_events to pass in
9668 "m_path", "m_start_idx", and "new_ev_idx".
9669 (event_range::m_fndecl): Replace with...
9670 (event_range::m_logical_loc): ...this.
9671 (path_summary::get_or_create_events_for_thread_id): Pass "path" to
9672 per_thread_summary ctor.
9673 (per_thread_summary::interprocedural_p): Rewrite to use
9674 diagnostic_path::same_function_p rather than tree.
9675 (print_fndecl): Delete.
9676 (thread_event_printer::print_swimlane_for_event_range): Update for
9677 conversion from tree to logical_location.
9678 (default_tree_diagnostic_path_printer): Likewise.
9679 (default_tree_make_json_for_path): Likewise.
9680 * tree-logical-location.cc: Include "intl.h".
9681 (compiler_logical_location::get_name_for_tree_for_path_output):
9683 (tree_logical_location::get_name_for_path_output): New.
9684 (current_fndecl_logical_location::get_name_for_path_output): New.
9685 * tree-logical-location.h
9686 (compiler_logical_location::get_name_for_tree_for_path_output):
9688 (tree_logical_location::get_name_for_path_output): New decl.
9689 (current_fndecl_logical_location::get_name_for_path_output): New
9692 2024-06-18 David Malcolm <dmalcolm@redhat.com>
9694 * Makefile.in (OBJS): Add simple-diagnostic-path.o.
9695 * diagnostic-path.h (class simple_diagnostic_event): Move to
9696 simple-diagnostic-path.h.
9697 (class simple_diagnostic_thread): Likewise.
9698 (class simple_diagnostic_path): Likewise.
9699 * diagnostic.cc (simple_diagnostic_path::simple_diagnostic_path):
9700 Move to simple-diagnostic-path.cc.
9701 (simple_diagnostic_path::num_events): Likewise.
9702 (simple_diagnostic_path::get_event): Likewise.
9703 (simple_diagnostic_path::num_threads): Likewise.
9704 (simple_diagnostic_path::get_thread): Likewise.
9705 (simple_diagnostic_path::add_thread): Likewise.
9706 (simple_diagnostic_path::add_event): Likewise.
9707 (simple_diagnostic_path::add_thread_event): Likewise.
9708 (simple_diagnostic_path::connect_to_next_event): Likewise.
9709 (simple_diagnostic_event::simple_diagnostic_event): Likewise.
9710 (simple_diagnostic_event::~simple_diagnostic_event): Likewise.
9711 * selftest-run-tests.cc (selftest::run_tests): Call
9712 selftest::simple_diagnostic_path_cc_tests.
9713 * selftest.h (selftest::simple_diagnostic_path_cc_tests): New
9715 * simple-diagnostic-path.cc: New file, from the above material.
9716 * simple-diagnostic-path.h: New file, from the above material
9717 from diagnostic-path.h.
9718 * tree-diagnostic-path.cc: Include "simple-diagnostic-path.h".
9720 2024-06-18 Pan Li <pan2.li@intel.com>
9722 * match.pd: Add form 7 and 8 for the unsigned .SAT_ADD match.
9724 2024-06-18 Pan Li <pan2.li@intel.com>
9726 * match.pd: Add form 11 match pattern for .SAT_SUB.
9728 2024-06-18 Richard Biener <rguenther@suse.de>
9730 PR tree-optimization/115537
9731 * tree-vect-loop.cc (vectorizable_reduction): Also reject
9732 SLP condition reductions of EXTRACT_LAST kind when multiple
9733 statement copies are involved.
9735 2024-06-18 Jeff Law <jlaw@ventanamicro.com>
9737 * config/riscv/bitmanip.md (bset splitters): New patterns for
9738 generating bset when bit position is limited.
9740 2024-06-18 Richard Sandiford <richard.sandiford@arm.com>
9742 * config/aarch64/aarch64.cc (aarch64_addti_scratch_regs): Use
9743 force_highpart_subreg instead of gen_highpart and simplify_gen_subreg.
9744 (aarch64_subvti_scratch_regs): Likewise.
9746 2024-06-18 Richard Sandiford <richard.sandiford@arm.com>
9748 * explow.h (force_highpart_subreg): Declare.
9749 * explow.cc (force_highpart_subreg): New function.
9750 * builtins.cc (expand_builtin_issignaling): Use it.
9751 * expmed.cc (emit_store_flag_1): Likewise.
9753 2024-06-18 Richard Sandiford <richard.sandiford@arm.com>
9755 * builtins.cc (expand_builtin_issignaling): Use force_lowpart_subreg
9756 instead of simplify_gen_subreg and lowpart_subreg.
9757 * expr.cc (convert_mode_scalar, expand_expr_real_2): Likewise.
9758 * optabs.cc (expand_doubleword_mod): Likewise.
9760 2024-06-18 Richard Sandiford <richard.sandiford@arm.com>
9763 * config/aarch64/aarch64-builtins.cc (aarch64_expand_fcmla_builtin)
9764 (aarch64_expand_rwsr_builtin): Use force_lowpart_subreg instead of
9765 simplify_gen_subreg and lowpart_subreg.
9766 * config/aarch64/aarch64-sve-builtins-base.cc
9767 (svset_neonq_impl::expand): Likewise.
9768 * config/aarch64/aarch64-sve-builtins-sme.cc
9769 (add_load_store_slice_operand): Likewise.
9770 * config/aarch64/aarch64.cc (aarch64_sve_reinterpret): Likewise.
9771 (aarch64_addti_scratch_regs, aarch64_subvti_scratch_regs): Likewise.
9773 2024-06-18 Richard Sandiford <richard.sandiford@arm.com>
9775 * explow.h (force_lowpart_subreg): Declare.
9776 * explow.cc (force_lowpart_subreg): New function.
9777 * optabs.cc (lowpart_subreg_maybe_copy): Delete.
9778 (expand_absneg_bit): Use force_lowpart_subreg instead of
9779 lowpart_subreg_maybe_copy.
9780 (expand_copysign_bit): Likewise.
9782 2024-06-18 Richard Sandiford <richard.sandiford@arm.com>
9784 * expmed.cc (store_bit_field_using_insv): Use force_subreg
9785 instead of simplify_gen_subreg.
9786 (store_bit_field_1): Likewise.
9787 (extract_bit_field_as_subreg): Likewise.
9788 (extract_integral_bit_field): Likewise.
9789 (emit_store_flag_1): Likewise.
9790 * expr.cc (convert_move): Likewise.
9791 (convert_modes): Likewise.
9792 (emit_group_load_1): Likewise.
9793 (emit_group_store): Likewise.
9794 (expand_assignment): Likewise.
9796 2024-06-18 Richard Sandiford <richard.sandiford@arm.com>
9798 * config/aarch64/aarch64-builtins.cc (aarch64_expand_fcmla_builtin):
9799 Use force_subreg instead of simplify_gen_subreg.
9800 * config/aarch64/aarch64-simd.md (ctz<mode>2): Likewise.
9801 * config/aarch64/aarch64-sve-builtins-base.cc
9802 (svget_impl::expand): Likewise.
9803 (svget_neonq_impl::expand): Likewise.
9804 * config/aarch64/aarch64-sve-builtins-functions.h
9805 (multireg_permute::expand): Likewise.
9807 2024-06-18 Richard Sandiford <richard.sandiford@arm.com>
9809 * explow.cc (force_subreg): Emit no instructions on failure.
9811 2024-06-18 Jakub Jelinek <jakub@redhat.com>
9814 * config/rs6000/rs6000-gen-builtins.cc (write_decls): Change
9815 declaration of rs6000_init_generated_builtins from no arguments
9816 to 4 pointer arguments.
9817 (write_init_bif_table): Change rs6000_builtin_info_fntype to
9818 builtin_info_fntype and rs6000_builtin_decls to builtin_decls.
9819 (write_init_ovld_table): Change rs6000_instance_info_fntype to
9820 instance_info_fntype, rs6000_builtin_decls to builtin_decls and
9821 rs6000_overload_info to overload_info.
9822 (write_init_file): Add __noipa__ attribute to
9823 rs6000_init_generated_builtins for GCC 8.1+ and change the function
9824 from no arguments to 4 pointer arguments. Change rs6000_builtin_decls
9826 * config/rs6000/rs6000-builtin.cc (rs6000_init_builtins): Adjust
9827 rs6000_init_generated_builtins caller.
9829 2024-06-18 Richard Biener <rguenther@suse.de>
9831 PR tree-optimization/115493
9832 * tree-vect-loop.cc (vect_create_epilog_for_reduction): Use
9833 the first scalar result.
9835 2024-06-18 Richard Biener <rguenther@suse.de>
9837 PR tree-optimization/111793
9838 * tree-ssa-alias.h (ref_can_have_store_data_races): Declare.
9839 * tree-ssa-alias.cc (ref_can_have_store_data_races): New
9841 * tree-if-conv.cc (ifcvt_memrefs_wont_trap): Use
9842 ref_can_have_store_data_races to allow more unconditional
9844 * tree-ssa-loop-im.cc (execute_sm): Likewise.
9845 * tree-ssa-phiopt.cc (cond_store_replacement): Likewise.
9847 2024-06-18 Hu, Lin1 <lin1.hu@intel.com>
9849 * config/i386/avxintrin.h: Move cmp[p|s][s|d] to [e|x]mmintrin.h,
9850 and move macros to xmmintrin.h
9851 * config/i386/emmintrin.h: Add cmp[p|s]s intrins.
9852 * config/i386/i386-builtin.def: Modify __builtin_ia32_cmp[p|s][s|d].
9853 * config/i386/i386-expand.cc
9854 (ix86_expand_args_builtin): Raise error when imm is in range of
9855 [8, 32] without avx.
9856 * config/i386/predicates.md (cmpps_imm_operand): New predicate.
9857 * config/i386/sse.md (avx_cmp<mode>3): Modefy define_insn.
9858 (avx_vmcmp<mode>3): Ditto.
9859 * config/i386/xmmintrin.h (_CMP_EQ_OQ): New macro for sse/sse2.
9862 (_CMP_UNORD_Q): Ditto
9863 (_CMP_NEQ_UQ): Ditto
9864 (_CMP_NLT_US): Ditto
9865 (_CMP_NLE_US): Ditto
9867 (_mm_cmp_ps): Move intrin from avxintrin.h to xmmintrin.h
9868 (_mm_cmp_ss): Ditto.
9870 2024-06-17 Jeff Law <jlaw@ventanamicro.com>
9872 * config/riscv/bitmanip.md (bsetclr_zero_extract): New pattern.
9874 2024-06-17 Jakub Jelinek <jakub@redhat.com>
9877 * opts-common.cc (add_misspelling_candidates): If opt1 is non-NULL,
9878 add a space and opt1 to the alternative suggestion text.
9880 2024-06-17 Patrick O'Neill <patrick@rivosinc.com>
9882 * common/config/riscv/riscv-common.cc
9883 (riscv_subset_list::to_string): Skip zaamo/zalrsc when not
9884 supported by the assembler.
9885 * config.in: Regenerate.
9886 * configure: Regenerate.
9887 * configure.ac: Add zaamo/zalrsc assmeber check.
9889 2024-06-17 Gerald Pfeifer <gerald@pfeifer.com>
9891 * doc/install.texi (Configuration): Mark up __cxa_atexit as @code.
9893 2024-06-17 Peter Bergner <bergner@linux.ibm.com>
9896 * config/rs6000/rs6000-logue.cc (rs6000_stack_info): Compute
9897 rop_hash_save_offset for non-Altivec compiles.
9899 2024-06-17 Jeff Law <jlaw@ventanamicro.com>
9901 * config/riscv/bitmanip.md (bsetdi_2): New pattern.
9903 2024-06-17 Richard Biener <rguenther@suse.de>
9905 PR tree-optimization/115508
9906 * tree-vect-slp.cc (vect_schedule_slp_node): Guard check on
9909 2024-06-17 Richard Biener <rguenther@suse.de>
9912 2024-05-06 Richard Biener <rguenther@suse.de>
9914 PR tree-optimization/100923
9915 * tree-ssa-sccvn.cc (ao_ref_init_from_vn_reference): Valueize
9917 (vn_reference_lookup_3): Adjust vn_context_bb around calls
9918 to ao_ref_init_from_vn_reference.
9919 (vn_reference_lookup_pieces): Revert original PR100923 fix.
9920 (vn_reference_lookup): Likewise.
9922 2024-06-17 Aldy Hernandez <aldyh@redhat.com>
9924 * data-streamer-in.cc (streamer_read_value_range): Rename
9925 Value_Range to value_range.
9926 * data-streamer.h (streamer_read_value_range): Same.
9927 * gimple-pretty-print.cc (dump_ssaname_info): Same.
9928 * gimple-range-cache.cc (ssa_block_ranges::dump): Same.
9929 (ssa_lazy_cache::merge): Same.
9930 (block_range_cache::dump): Same.
9931 (ssa_cache::merge_range): Same.
9932 (ssa_cache::dump): Same.
9933 (ranger_cache::edge_range): Same.
9934 (ranger_cache::propagate_cache): Same.
9935 (ranger_cache::fill_block_cache): Same.
9936 (ranger_cache::resolve_dom): Same.
9937 (ranger_cache::range_from_dom): Same.
9938 (ranger_cache::register_inferred_value): Same.
9939 * gimple-range-fold.cc (op1_range): Same.
9941 (fold_relations): Same.
9942 (fold_using_range::range_of_range_op): Same.
9943 (fold_using_range::range_of_phi): Same.
9944 (fold_using_range::range_of_call): Same.
9945 (fold_using_range::condexpr_adjust): Same.
9946 (fold_using_range::range_of_cond_expr): Same.
9947 (fur_source::register_outgoing_edges): Same.
9948 * gimple-range-fold.h (gimple_range_type): Same.
9949 (gimple_range_ssa_p): Same.
9950 * gimple-range-gori.cc (gori_compute::compute_operand_range): Same.
9951 (gori_compute::logical_combine): Same.
9952 (gori_compute::refine_using_relation): Same.
9953 (gori_compute::compute_operand1_range): Same.
9954 (gori_compute::compute_operand2_range): Same.
9955 (gori_compute::compute_operand1_and_operand2_range): Same.
9956 (gori_calc_operands): Same.
9957 (gori_name_helper): Same.
9958 * gimple-range-infer.cc (gimple_infer_range::check_assume_func): Same.
9959 (gimple_infer_range::gimple_infer_range): Same.
9960 (infer_range_manager::maybe_adjust_range): Same.
9961 (infer_range_manager::add_range): Same.
9962 * gimple-range-infer.h: Same.
9963 * gimple-range-op.cc
9964 (gimple_range_op_handler::gimple_range_op_handler): Same.
9965 (gimple_range_op_handler::calc_op1): Same.
9966 (gimple_range_op_handler::calc_op2): Same.
9967 (gimple_range_op_handler::maybe_builtin_call): Same.
9968 * gimple-range-path.cc (path_range_query::internal_range_of_expr): Same.
9969 (path_range_query::ssa_range_in_phi): Same.
9970 (path_range_query::compute_ranges_in_phis): Same.
9971 (path_range_query::compute_ranges_in_block): Same.
9972 (path_range_query::add_to_exit_dependencies): Same.
9973 * gimple-range-trace.cc (debug_seed_ranger): Same.
9974 * gimple-range.cc (gimple_ranger::range_of_expr): Same.
9975 (gimple_ranger::range_on_entry): Same.
9976 (gimple_ranger::range_on_edge): Same.
9977 (gimple_ranger::range_of_stmt): Same.
9978 (gimple_ranger::prefill_stmt_dependencies): Same.
9979 (gimple_ranger::register_inferred_ranges): Same.
9980 (gimple_ranger::register_transitive_inferred_ranges): Same.
9981 (gimple_ranger::export_global_ranges): Same.
9982 (gimple_ranger::dump_bb): Same.
9983 (assume_query::calculate_op): Same.
9984 (assume_query::calculate_phi): Same.
9985 (assume_query::dump): Same.
9986 (dom_ranger::range_of_stmt): Same.
9987 * ipa-cp.cc (ipcp_vr_lattice::meet_with_1): Same.
9988 (ipa_vr_operation_and_type_effects): Same.
9989 (ipa_value_range_from_jfunc): Same.
9990 (propagate_bits_across_jump_function): Same.
9991 (propagate_vr_across_jump_function): Same.
9992 (ipcp_store_vr_results): Same.
9994 * ipa-fnsummary.cc (evaluate_conditions_for_known_args): Same.
9995 (evaluate_properties_for_edge): Same.
9996 * ipa-prop.cc (struct ipa_vr_ggc_hash_traits): Same.
9997 (ipa_vr::get_vrange): Same.
9998 (ipa_vr::streamer_read): Same.
9999 (ipa_vr::streamer_write): Same.
10000 (ipa_vr::dump): Same.
10001 (ipa_set_jfunc_vr): Same.
10002 (ipa_compute_jump_functions_for_edge): Same.
10003 (ipcp_get_parm_bits): Same.
10004 (ipcp_update_vr): Same.
10005 (ipa_record_return_value_range): Same.
10006 (ipa_return_value_range): Same.
10007 * ipa-prop.h (ipa_return_value_range): Same.
10008 (ipa_record_return_value_range): Same.
10009 * range-op.h (range_cast): Same.
10011 (dom_opt_dom_walker::set_global_ranges_from_unreachable_edges): Same.
10012 (cprop_operand): Same.
10013 * tree-ssa-loop-ch.cc (loop_static_stmt_p): Same.
10014 * tree-ssa-loop-niter.cc (record_nonwrapping_iv): Same.
10015 * tree-ssa-loop-split.cc (split_at_bb_p): Same.
10016 * tree-ssa-phiopt.cc (value_replacement): Same.
10017 * tree-ssa-strlen.cc (get_range): Same.
10018 * tree-ssa-threadedge.cc (hybrid_jt_simplifier::simplify): Same.
10019 (hybrid_jt_simplifier::compute_exit_dependencies): Same.
10020 * tree-ssanames.cc (set_range_info): Same.
10021 (duplicate_ssa_name_range_info): Same.
10022 * tree-vrp.cc (remove_unreachable::handle_early): Same.
10023 (remove_unreachable::remove_and_update_globals): Same.
10024 (execute_ranger_vrp): Same.
10025 * value-query.cc (range_query::value_of_expr): Same.
10026 (range_query::value_on_edge): Same.
10027 (range_query::value_of_stmt): Same.
10028 (range_query::value_on_entry): Same.
10029 (range_query::value_on_exit): Same.
10030 (range_query::get_tree_range): Same.
10031 * value-range-storage.cc (vrange_storage::set_vrange): Same.
10032 * value-range.cc (Value_Range::dump): Same.
10033 (value_range::dump): Same.
10035 * value-range.h (enum value_range_discriminator): Same.
10036 (class vrange): Same.
10037 (class Value_Range): Same.
10038 (class value_range): Same.
10039 (Value_Range::Value_Range): Same.
10040 (value_range::value_range): Same.
10041 (Value_Range::~Value_Range): Same.
10042 (value_range::~value_range): Same.
10043 (Value_Range::set_type): Same.
10044 (value_range::set_type): Same.
10045 (Value_Range::init): Same.
10046 (value_range::init): Same.
10047 (Value_Range::operator=): Same.
10048 (value_range::operator=): Same.
10049 (Value_Range::operator==): Same.
10050 (value_range::operator==): Same.
10051 (Value_Range::operator!=): Same.
10052 (value_range::operator!=): Same.
10053 (Value_Range::supports_type_p): Same.
10054 (value_range::supports_type_p): Same.
10055 * vr-values.cc (simplify_using_ranges::fold_cond_with_ops): Same.
10056 (simplify_using_ranges::legacy_fold_cond): Same.
10058 2024-06-17 Hu, Lin1 <lin1.hu@intel.com>
10061 * config/i386/i386-builtin.def: Change CODE_FOR_* for cvtt*'s builtins.
10062 * config/i386/sse.md:
10063 (unspec_avx512fp16_fix<vcvtt_uns_suffix>
10064 _trunc<mode>2<mask_name><round_saeonly_name>):
10065 Use UNSPEC instead of FIX/UNSIGNED_FIX.
10066 (unspec_avx512fp16_fix<vcvtt_uns_suffix>_trunc<mode>2<mask_name>):
10068 (unspec_avx512fp16_fix<vcvtt_uns_suffix>_truncv2di2<mask_name>): Ditto.
10069 (unspec_avx512fp16_fix<vcvtt_uns_suffix>_trunc<mode>2<round_saeonly_name>):
10071 (unspec_sse_cvttps2pi): Ditto.
10072 (unspec_sse_cvttss2si<rex64namesuffix><round_saeonly_name>): Ditto.
10073 (unspec_fix<vcvtt_uns_suffix>_truncv16sfv16si2<mask_name><round_saeonly_name>):
10075 (unspec_fix_truncv8sfv8si2<mask_name>): Ditto.
10076 (unspec_fix_truncv4sfv4si2<mask_name>): Ditto.
10077 (unspec_sse2_cvttpd2pi): Ditto.
10078 (unspec_fixuns_truncv2dfv2si2): Ditto.
10079 (unspec_avx512f_vcvttss2usi<rex64namesuffix><round_saeonly_name>):
10081 (unspec_avx512f_vcvttsd2usi<rex64namesuffix><round_saeonly_name>):
10083 (unspec_sse2_cvttsd2si<rex64namesuffix><round_saeonly_name>): Ditto.
10084 (unspec_fix<vcvtt_uns_suffix>_truncv8dfv8si2<mask_name><round_saeonly_name>):
10086 (*unspec_fixuns_truncv2dfv2si2): Ditto.
10087 (unspec_fixuns_truncv2dfv2si2_mask): Ditto.
10088 (unspec_fix_truncv4dfv4si2<mask_name>): Ditto.
10089 (unspec_fixuns_truncv4dfv4si2<mask_name>): Ditto.
10090 (unspec_fix<vcvtt_uns_suffix>
10091 _trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
10093 (unspec_fix<vcvtt_uns_suffix>
10094 _trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
10096 (unspec_avx512dq_fix<vcvtt_uns_suffix>_truncv2sfv2di2<mask_name>):
10098 (<mask_codefor>unspec_fixuns_trunc<mode><sseintvecmodelower>2<mask_name>):
10100 (unspec_sse2_cvttpd2dq<mask_name>): Ditto.
10102 2024-06-17 Levy Hsu <admin@levyhsu.com>
10104 * config/i386/i386-expand.cc
10105 (ix86_vectorize_vec_perm_const): Convert BF to HI using subreg.
10106 * config/i386/predicates.md
10107 (vcvtne2ps2bf_parallel): New define_insn_and_split.
10108 * config/i386/sse.md
10109 (vpermt2_sepcial_bf16_shuffle_<mode>): New predicates matches odd increasing perm.
10111 2024-06-17 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
10113 * config/s390/vector.md (*vmrhf_half<mode>): New.
10114 (extendv2sfv2df2): New.
10116 2024-06-17 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
10119 * config/s390/s390.md (any_extend,extend_insn,zero_extend):
10120 New code attributes and code iterator.
10121 * config/s390/vector.md (V_EXTEND): New mode iterator.
10122 (<extend_insn><V_EXTEND:mode><vec_2x_wide>2): New insn.
10124 2024-06-16 Andrew Pinski <quic_apinski@quicinc.com>
10127 * config/aarch64/aarch64.h (machine_function): Fix the size
10128 of reg_is_wrapped_separately.
10130 2024-06-16 Jeff Law <jlaw@ventanamicro.com>
10132 * config/riscv/bitmanip.md ((1 << N) | C): New splitter for IOR/XOR
10133 of a single bit an a DImode object.
10135 2024-06-16 Jeff Law <jlaw@ventanamicro.com>
10137 * config/sh/sh.md (neg_zero_extract_4b): New pattern.
10139 2024-06-16 Peter Damianov <peter0x44@disroot.org>
10141 * pretty-print.cc (mingw_ansi_fputs): Don't translate escape sequences if
10142 the console has ENABLE_VIRTUAL_TERMINAL_PROCESSING.
10144 2024-06-16 Peter Damianov <peter0x44@disroot.org>
10146 * diagnostic-color.cc (auto_enable_urls): Don't hardcode to return
10147 false on mingw hosts.
10148 (auto_enable_urls): Return true if console
10149 supports ansi escape sequences.
10151 2024-06-16 Peter Damianov <peter0x44@disroot.org>
10153 * diagnostic-color.cc (should_colorize): Enable processing of VT100
10154 escape sequences on windows consoles
10156 2024-06-15 Christoph Müllner <christoph.muellner@vrull.eu>
10158 * config/riscv/riscv-target-attr.cc (riscv_target_attr_parser::parse_arch):
10159 Fix allocation size of buffer.
10160 (riscv_process_one_target_attr): Likewise.
10161 (riscv_process_target_attr): Likewise.
10163 2024-06-15 Gerald Pfeifer <gerald@pfeifer.com>
10166 * doc/install.texi (Specific): Remove pointer to old versions
10169 2024-06-14 Andrew MacLeod <amacleod@redhat.com>
10171 * gimple-range-gori.cc (gori_calc_operands): Do not continue nor
10172 add the range when VARYING is produced for an operand.
10174 2024-06-14 Andrew MacLeod <amacleod@redhat.com>
10176 * gimple-range-cache.cc (ssa_lazy_cache::merge): New.
10177 * gimple-range-cache.h (ssa_lazy_cache::merge): New prototype.
10179 2024-06-14 Andrew MacLeod <amacleod@redhat.com>
10181 * gimple-range-fold.cc (fold_using_range::range_of_call): Ensure
10182 LHS is an SSA_NAME before invoking gimple_range_global.
10184 2024-06-14 Pan Li <pan2.li@intel.com>
10186 * match.pd: Add more match for unsigned sat_sub.
10187 * tree-ssa-math-opts.cc (match_unsigned_saturation_sub): Add new
10188 func impl to match phi node for .SAT_SUB.
10189 (math_opts_dom_walker::after_dom_children): Try match .SAT_SUB
10190 for the phi node, MULT_EXPR, BIT_XOR_EXPR and BIT_AND_EXPR.
10192 2024-06-14 Jan Beulich <jbeulich@suse.com>
10194 * configure.ac: Drop ${objdir}/ from NM and AR. Move setting of
10195 ld_ver out of conditional.
10196 * configure: Re-generate.
10198 2024-06-14 Richard Biener <rguenther@suse.de>
10200 * tree-vect-loop.cc (vectorizable_reduction): Allow
10201 single-def-use cycles with SLP.
10202 (vect_transform_reduction): Handle SLP single def-use cycles.
10203 (vect_transform_cycle_phi): Likewise.
10205 2024-06-14 Gerald Pfeifer <gerald@pfeifer.com>
10207 * doc/invoke.texi (x86 Options): Consolidate duplicate MOVBE
10208 listings for haswell, broadwell, skylake, skylake-avx512,
10209 cannonlake, icelake-client, icelake-server, cascadelake,
10210 cooperlake, tigerlake, sapphirerapids, rocketlake, graniterapids,
10211 and graniterapids-d options to -march.
10213 2024-06-14 Pan Li <pan2.li@intel.com>
10216 * config/riscv/vector-iterators.md: Leverage V_ZVFH instead of V
10217 which contains the VF_ZVFHMIN for alignment.
10219 2024-06-14 Gerald Pfeifer <gerald@pfeifer.com>
10222 * doc/install.texi (Specific): Remove stale reference to Interix.
10224 2024-06-14 Richard Biener <rguenther@suse.de>
10226 * tree-vect-stmts.cc (get_group_load_store_type): Do not
10227 re-use poly-int remain but re-compute with non-poly values.
10228 Verify the shortened load is good enough to be covered with
10229 a single scalar gap iteration before accepting it.
10231 2024-06-14 liuhongt <hongtao.liu@intel.com>
10233 * config/i386/i386.cc (ix86_rtx_costs): Adjust rtx_cost for
10234 pternlog_operand under AVX512, also adjust VEC_DUPLICATE
10235 according since vec_dup:mem can't be that cheap.
10237 2024-06-14 liuhongt <hongtao.liu@intel.com>
10239 * config/i386/x86-tune.def (X86_TUNE_ONE_IF_CONV_INSN): Remove
10240 latest Intel processors.
10241 Co-authored by: Lingling Kong <lingling.kong@intel.com>
10243 2024-06-14 Roger Sayle <roger@nextmovesoftware.com>
10245 * config/i386/i386-expand.cc (ix86_expand_ternlog): Try performing
10246 logic operation in a different vector mode if that enables use of
10247 a 32-bit or 64-bit broadcast addressing mode.
10249 2024-06-14 Andrew Pinski <quic_apinski@quicinc.com>
10251 PR middle-end/113212
10252 * expr.h (const_seqpops): New typedef.
10253 (expand_expr_real_2): Constify the first argument.
10254 * optabs.cc (expand_widen_pattern_expr): Likewise.
10255 * optabs.h (expand_widen_pattern_expr): Likewise.
10256 * expr.cc (expand_expr_real_2): Likewise
10257 (do_store_flag): Likewise. Remove incorrect store to ops->code.
10259 2024-06-13 Patrick O'Neill <patrick@rivosinc.com>
10261 * config/riscv/sync-rvwmo.md: Add support for subword fenced
10263 * config/riscv/sync-ztso.md: Ditto.
10264 * config/riscv/sync.md: Ditto.
10266 2024-06-13 Gerald Pfeifer <gerald@pfeifer.com>
10268 * doc/extend.texi (AArch64 Function Attributes): Add
10269 (AVR Variable Attributes): Ditto.
10270 (Common Type Attributes): Ditto.
10272 2024-06-13 Hongyu Wang <hongyu.wang@intel.com>
10276 * target.def (have_ccmp): New target hook.
10277 * targhooks.cc (default_have_ccmp): New function.
10278 * targhooks.h (default_have_ccmp): New prototype.
10279 * doc/tm.texi.in: Add TARGET_HAVE_CCMP.
10280 * doc/tm.texi: Regenerate.
10281 * cfgexpand.cc (expand_gimple_cond): Call targetm.have_ccmp
10282 instead of checking if targetm.gen_ccmp_first exists.
10283 * expr.cc (expand_expr_real_gassign): Likewise.
10284 * config/i386/i386.cc (ix86_have_ccmp): New target hook to
10285 check if APX_CCMP enabled.
10286 (TARGET_HAVE_CCMP): Define.
10288 2024-06-13 Richard Sandiford <richard.sandiford@arm.com>
10291 * simplify-rtx.cc (simplify_context::simplify_subreg): Don't try
10292 to fold two subregs together if their relationship isn't known
10294 * explow.h (force_subreg): Declare.
10295 * explow.cc (force_subreg): New function.
10296 * config/aarch64/aarch64-sve-builtins-base.cc
10297 (svset_neonq_impl::expand): Use it instead of simplify_gen_subreg.
10299 2024-06-13 Pan Li <pan2.li@intel.com>
10302 * config/riscv/autovec.md: Take ZVFH mode iterator instead of
10303 the ZVFHMIN for the alignment.
10304 * config/riscv/vector-iterators.md: Add 2 new iterator
10305 V_VLS_ZVFH and VLS_ZVFH.
10307 2024-06-13 Hongyu Wang <hongyu.wang@intel.com>
10309 * config/i386/i386.md (@ccmp<mode>): Add new alternative
10310 <r>,C and adjust output templates. Also adjust UNSPEC mode
10313 2024-06-13 Gerald Pfeifer <gerald@pfeifer.com>
10316 * doc/install.texi (Prerequisites): Simplify note on the C++
10317 compiler required. Drop requirements for versions of GCC prior
10318 to 3.4. Fix grammar.
10320 2024-06-13 Richard Biener <rguenther@suse.de>
10322 * tree-vect-stmts.cc (get_group_load_store_type): Consistently
10323 use VMAT_STRIDED_SLP for strided SLP accesses and not
10325 (vectorizable_store): Adjust VMAT_STRIDED_SLP handling to
10326 allow not only half-size but also smaller accesses.
10327 (vectorizable_load): Likewise.
10329 2024-06-13 Richard Biener <rguenther@suse.de>
10331 PR tree-optimization/115385
10332 * tree-vect-stmts.cc (get_group_load_store_type): Peeling
10333 of a single scalar iteration is sufficient if we can narrow
10334 the access to the next power of two of the bits in the last
10336 (vectorizable_load): Ensure that the last access is narrowed.
10338 2024-06-13 Richard Biener <rguenther@suse.de>
10340 PR tree-optimization/114107
10341 PR tree-optimization/110445
10342 * tree-vect-stmts.cc (get_group_load_store_type): Refactor
10343 contiguous access case. Make sure peeling for gap constraints
10344 are always tested and consistently relax when we know we can
10345 avoid touching excess elements during code generation. But
10346 rewrite the check poly-int aware.
10348 2024-06-13 Andi Kleen <ak@linux.intel.com>
10350 * doc/extend.texi: Use std::string_view in asm constexpr
10353 2024-06-13 liuhongt <hongtao.liu@intel.com>
10356 * config/i386/i386-features.cc (scalar_chain::convert_op): Use
10357 reg_or_subregno instead of REGNO to avoid ICE.
10359 2024-06-13 YunQiang Su <syq@gcc.gnu.org>
10361 * config/mips/mips-cpus.def: Use PROCESSOR_24KF1_1 for mips32;
10362 Use PROCESSOR_5KF for mips64/mips64r2/mips64r3/mips64r5.
10364 2024-06-13 YunQiang Su <syq@gcc.gnu.org>
10366 * config/mips/mips-modes.def: New CC_MODE CCE.
10367 * config/mips/mips-protos.h(mips_output_compare): New function.
10368 * config/mips/mips.cc(mips_allocate_fcc): Set CCEmode count=1.
10369 (mips_emit_compare): Use CCEmode for LTGT/LT/LE for pre-R6.
10370 (mips_output_compare): New function. Convert lt/le to slt/sle
10371 for R6; convert ueq to ngl for CCEmode.
10372 (mips_hard_regno_mode_ok_uncached): Mention CCEmode.
10373 * config/mips/mips.h: Mention CCEmode for LOAD_EXTEND_OP.
10374 * config/mips/mips.md(FPCC): Add CCE.
10375 (define_mode_iterator MOVECC): Mention CCE.
10376 (define_mode_attr reg): Add CCE with "z".
10377 (define_mode_attr fpcmp): Add CCE with "c".
10378 (define_code_attr fcond): ltgt should use sne instead of ne.
10379 (s<code>_<SCALARF:mode>_using_<FPCC:mode>): call mips_output_compare.
10381 2024-06-13 Lingling Kong <lingling.kong@intel.com>
10383 * config/i386/i386-opts.h (enum apx_features): Add apx_zu.
10384 * config/i386/i386.h (TARGET_APX_ZU): Define.
10385 * config/i386/i386.md (*imulhi<mode>zu): New define_insn.
10386 (*setcc_<mode>_zu): Ditto.
10387 * config/i386/i386.opt: Add enum value for zu.
10389 2024-06-12 David Malcolm <dmalcolm@redhat.com>
10391 PR bootstrap/115465
10392 * config/aarch64/aarch64-early-ra.cc (early_ra::process_block):
10393 Update for fields of pretty_printer becoming private in
10394 r15-1209-gc5e3be456888aa.
10396 2024-06-12 Andrew Pinski <quic_apinski@quicinc.com>
10399 * config/aarch64/aarch64-simd.md (aarch64_rbit<mode><vczle><vczbe>): Use
10400 bitreverse instead of unspec.
10401 * config/aarch64/aarch64-sve-builtins-base.cc (svrbit): Convert over to using
10402 rtx_code_function instead of unspec_based_function.
10403 * config/aarch64/aarch64-sve.md: Update comment where RBIT is included.
10404 * config/aarch64/aarch64.cc (aarch64_rtx_costs): Handle BITREVERSE like BSWAP.
10405 Remove UNSPEC_RBIT support.
10406 * config/aarch64/aarch64.md (unspec): Remove UNSPEC_RBIT.
10407 (aarch64_rbit<mode>): Use bitreverse instead of unspec.
10408 * config/aarch64/iterators.md (SVE_INT_UNARY): Add bitreverse.
10410 (sve_int_op): Likewise.
10411 (SVE_INT_UNARY): Remove UNSPEC_RBIT.
10413 (sve_int_op): Likewise.
10414 (min_elem_bits): Likewise.
10416 2024-06-12 Andrew Pinski <quic_apinski@quicinc.com>
10418 PR tree-optimization/115449
10419 * gimple-match-head.cc (gimple_maybe_truncate): New declaration.
10420 (gimple_bitwise_equal_p): Match truncations that differ only
10421 in types with the same precision.
10422 (gimple_bitwise_inverted_equal_p): For matching after bit_not_with_nop
10423 call gimple_bitwise_equal_p.
10424 * match.pd (maybe_truncate): New match pattern.
10426 2024-06-12 Victor Do Nascimento <victor.donascimento@arm.com>
10428 PR tree-optimization/114061
10429 * tree-data-ref.cc (get_references_in_stmt): set
10430 `clobbers_memory' to false for __builtin_prefetch.
10431 * tree-vect-loop.cc (vect_transform_loop): Drop all
10432 __builtin_prefetch calls from loops.
10434 2024-06-12 David Malcolm <dmalcolm@redhat.com>
10436 * dumpfile.cc (dump_pretty_printer::emit_items): Update for
10437 changes to chunk_info.
10438 * pretty-print.cc (chunk_info::append_formatted_chunk): New, based
10439 on code in cp/error.cc's append_formatted_chunk.
10440 (chunk_info::pop_from_output_buffer): New, based on code in
10441 pp_output_formatted_text and dump_pretty_printer::emit_items.
10442 (on_begin_quote): Convert to...
10443 (chunk_info::on_begin_quote): ...this.
10444 (on_end_quote): Convert to...
10445 (chunk_info::on_end_quote): ...this.
10446 (pretty_printer::format): Update for chunk_info becoming a class
10447 and its fields gaining "m_" prefixes. Update for on_begin_quote
10448 and on_end_quote moving to chunk_info.
10449 (quoting_info::handle_phase_3): Update for changes to chunk_info.
10450 (pp_output_formatted_text): Likewise. Move cleanup code to
10451 chunk_info::pop_from_output_buffer.
10452 * pretty-print.h (class output_buffer): New forward decl.
10453 (class urlifier): New forward decl.
10454 (struct chunk_info): Convert to...
10455 (class chunk_info): ...this. Add friend class pretty_printer.
10456 (chunk_info::get_args): New accessor.
10457 (chunk_info::get_quoting_info): New accessor.
10458 (chunk_info::append_formatted_chunk): New decl.
10459 (chunk_info::pop_from_output_buffer): New decl.
10460 (chunk_info::on_begin_quote): New decl.
10461 (chunk_info::on_end_quote): New decl.
10462 (chunk_info::prev): Rename to...
10463 (chunk_info::m_prev): ...this.
10464 (chunk_info::args): Rename to...
10465 (chunk_info::m_args): ...this.
10466 (output_buffer::cur_chunk_array): Drop "struct" from decl.
10468 2024-06-12 David Malcolm <dmalcolm@redhat.com>
10470 * diagnostic.cc (diagnostic_context::urls_init): Update for fields
10471 of pretty_printer becoming private.
10472 (diagnostic_context::print_any_cwe): Likewise.
10473 (diagnostic_context::print_any_rules): Likewise.
10474 (diagnostic_context::print_option_information): Likewise.
10475 * diagnostic.h (diagnostic_format_decoder): Likewise.
10476 (diagnostic_prefixing_rule): Likewise, fixing typo.
10477 * digraph.cc (test_dump_to_dot): Likewise.
10478 * digraph.h (digraph<GraphTraits>::dump_dot_to_file): Likewise.
10480 (dump_pretty_printer::emit_any_pending_textual_chunks): Likewise.
10481 * gimple-pretty-print.cc (print_gimple_stmt): Likewise.
10482 (print_gimple_expr): Likewise.
10483 (print_gimple_seq): Likewise.
10484 (dump_ssaname_info_to_file): Likewise.
10485 (gimple_dump_bb): Likewise.
10486 * graph.cc (print_graph_cfg): Likewise.
10487 (start_graph_dump): Likewise.
10488 * langhooks.cc (lhd_print_error_function): Likewise.
10489 * lto-wrapper.cc (print_lto_docs_link): Likewise.
10490 * pretty-print.cc (pp_set_real_maximum_length): Convert to...
10491 (pretty_printer::set_real_maximum_length): ...this.
10492 (pp_clear_state): Convert to...
10493 (pretty_printer::clear_state): ...this.
10494 (pp_wrap_text): Update for pp_remaining_character_count_for_line
10495 becoming a member function.
10496 (urlify_quoted_string): Update for fields of pretty_printer becoming
10498 (pp_format): Convert to...
10499 (pretty_printer::format): ...this. Reduce the scope of local
10500 variables "old_line_length" and "old_wrapping_mode" and make
10501 const. Reduce the scope of locals "args", "new_chunk_array",
10502 "curarg", "any_unnumbered", and "any_numbered".
10503 (pp_output_formatted_text): Update for fields of pretty_printer
10505 (pp_flush): Likewise.
10506 (pp_really_flush): Likewise.
10507 (pp_set_line_maximum_length): Likewise.
10508 (pp_set_prefix): Convert to...
10509 (pretty_printer::set_prefix): ...this.
10510 (pp_take_prefix): Update for fields of pretty_printer gaining
10512 (pp_destroy_prefix): Likewise.
10513 (pp_emit_prefix): Convert to...
10514 (pretty_printer::emit_prefix): ...this.
10515 (pretty_printer::pretty_printer): Update both ctors for fields
10516 gaining "m_" prefixes.
10517 (pretty_printer::~pretty_printer): Likewise for dtor.
10518 (pp_append_text): Update for pp_emit_prefix becoming
10519 pretty_printer::emit_prefix.
10520 (pp_remaining_character_count_for_line): Convert to...
10521 (pretty_printer::remaining_character_count_for_line): ...this.
10522 (pp_character): Update for above change.
10523 (pp_maybe_space): Convert to...
10524 (pretty_printer::maybe_space): ...this.
10525 (pp_begin_url): Convert to...
10526 (pretty_printer::begin_url): ...this.
10527 (get_end_url_string): Update for fields of pretty_printer
10529 (pp_end_url): Convert to...
10530 (pretty_printer::end_url): ...this.
10531 (selftest::test_pretty_printer::test_pretty_printer): Update for
10532 fields of pretty_printer becoming private.
10533 (selftest::test_urls): Likewise.
10534 (selftest::test_null_urls): Likewise.
10535 (selftest::test_urlification): Likewise.
10536 * pretty-print.h (pp_line_cutoff): Convert from macro to inline
10538 (pp_prefixing_rule): Likewise.
10539 (pp_wrapping_mode): Likewise.
10540 (pp_format_decoder): Likewise.
10541 (pp_needs_newline): Likewise.
10542 (pp_indentation): Likewise.
10543 (pp_translate_identifiers): Likewise.
10544 (pp_show_color): Likewise.
10545 (pp_buffer): Likewise.
10546 (pp_get_prefix): Add forward decl to allow friend decl.
10547 (pp_take_prefix): Likewise.
10548 (pp_destroy_prefix): Likewise.
10549 (class pretty_printer): Fix typo in leading comment. Add
10550 "friend" decls for the various new accessor functions that were
10551 formerly macros and for pp_get_prefix, pp_take_prefix, and
10552 pp_destroy_prefix. Make all fields private.
10553 (pretty_printer::set_output_stream): New.
10554 (pretty_printer::set_prefix): New decl.
10555 (pretty_printer::emit_prefix): New decl.
10556 (pretty_printer::format): New decl.
10557 (pretty_printer::maybe_space): New decl.
10558 (pretty_printer::supports_urls_p): New.
10559 (pretty_printer::get_url_format): New.
10560 (pretty_printer::set_url_format): New.
10561 (pretty_printer::begin_url): New decl.
10562 (pretty_printer::end_url): New decl.
10563 (pretty_printer::set_verbatim_wrapping): New.
10564 (pretty_printer::set_padding): New.
10565 (pretty_printer::get_padding): New.
10566 (pretty_printer::clear_state): New decl.
10567 (pretty_printer::set_real_maximum_length): New decl.
10568 (pretty_printer::remaining_character_count_for_line): New decl.
10569 (pretty_printer::buffer): Rename to...
10570 (pretty_printer::m_buffer): ...this.
10571 (pretty_printer::prefix): Rename to...
10572 (pretty_printer::m_prefix): ...this;
10573 (pretty_printer::padding): Rename to...
10574 (pretty_printer::m_padding): ...this;
10575 (pretty_printer::maximum_length): Rename to...
10576 (pretty_printer::m_maximum_length): ...this;
10577 (pretty_printer::indent_skip): Rename to...
10578 (pretty_printer::m_indent_skip): ...this;
10579 (pretty_printer::wrapping): Rename to...
10580 (pretty_printer::m_wrapping): ...this;
10581 (pretty_printer::format_decoder): Rename to...
10582 (pretty_printer::m_format_decoder): ...this;
10583 (pretty_printer::emitted_prefix): Rename to...
10584 (pretty_printer::m_emitted_prefix): ...this;
10585 (pretty_printer::need_newline): Rename to...
10586 (pretty_printer::m_need_newline): ...this;
10587 (pretty_printer::translate_identifiers): Rename to...
10588 (pretty_printer::m_translate_identifiers): ...this;
10589 (pretty_printer::show_color): Rename to...
10590 (pretty_printer::m_show_color): ...this;
10591 (pretty_printer::url_format): Rename to...
10592 (pretty_printer::m_url_format): ...this;
10593 (pp_get_prefix): Reformat.
10594 (pp_format_postprocessor): New inline function.
10595 (pp_take_prefix): Move decl to before class pretty_printer.
10596 (pp_destroy_prefix): Likewise.
10597 (pp_set_prefix): Convert to inline function.
10598 (pp_emit_prefix): Convert to inline function.
10599 (pp_format): Convert to inline function.
10600 (pp_maybe_space): Convert to inline function.
10601 (pp_begin_url): Convert to inline function.
10602 (pp_end_url): Convert to inline function.
10603 (pp_set_verbatim_wrapping): Convert from macro to inline
10604 function, renaming...
10605 (pp_set_verbatim_wrapping_): ...this.
10606 * print-rtl.cc (dump_value_slim): Update for fields of
10607 pretty_printer becoming private.
10608 (dump_insn_slim): Likewise.
10609 (dump_rtl_slim): Likewise.
10610 * print-tree.cc (print_node): Likewise.
10611 * sched-rgn.cc (dump_rgn_dependencies_dot): Likewise.
10612 * text-art/canvas.cc (canvas::print_to_pp): Likewise.
10613 (canvas::debug): Likewise.
10614 (selftest::test_canvas_urls): Likewise.
10615 * text-art/dump.h (dump_to_file): Likewise.
10616 * text-art/selftests.cc (selftest::assert_canvas_streq): Likewise.
10617 * text-art/style.cc (style::print_changes): Likewise.
10618 * text-art/styled-string.cc (styled_string::from_fmt_va):
10620 * tree-diagnostic-path.cc (control_flow_tests): Update for
10621 pp_show_color becoming an inline function.
10622 * tree-loop-distribution.cc (dot_rdg_1): Update for fields of
10623 pretty_printer becoming private.
10624 * tree-pretty-print.cc (maybe_init_pretty_print): Likewise.
10625 * value-range.cc (vrange::dump): Likewise.
10626 (irange_bitmask::dump): Likewise.
10628 2024-06-12 David Malcolm <dmalcolm@redhat.com>
10630 * gimple-pretty-print.cc: Rename pretty_printer "buffer" to "pp"
10632 * print-tree.cc (print_node): Likewise.
10633 * tree-loop-distribution.cc (dot_rdg_1): Likewise.
10634 * tree-pretty-print.h (dump_location): Likewise.
10635 * value-range.cc (vrange::dump): Likewise.
10636 (irange_bitmask::dump): Likewise.
10638 2024-06-12 Xi Ruoyao <xry111@xry111.site>
10640 * config/loongarch/predicates.md (high_bitmask_operand): New
10642 * config/loongarch/constraints.md (Yy): New constriant.
10643 * config/loongarch/loongarch.md (and<mode>3_align): New
10644 define_insn_and_split.
10646 2024-06-12 Xi Ruoyao <xry111@xry111.site>
10648 * config/loongarch/loongarch.cc
10649 (loongarch_expand_conditional_move): Compare mode size with
10650 UNITS_PER_WORD instead of word_mode.
10652 2024-06-12 Torbjörn SVENSSON <torbjorn.svensson@foss.st.com>
10653 Yvan ROUX <yvan.roux@foss.st.com>
10656 * config/arm/arm.cc (cmse_nonsecure_call_inline_register_clear):
10657 Sign extend for Thumb1.
10658 (thumb1_expand_prologue): Add zero/sign extend.
10660 2024-06-12 Gerald Pfeifer <gerald@pfeifer.com>
10663 * doc/install.texi (Specific) <*-*-cygwin>: Update web link.
10665 2024-06-12 Pan Li <pan2.li@intel.com>
10667 * tree-ssa-math-opts.cc (math_opts_dom_walker::after_dom_children):
10668 Leverage gsi_after_labels instead of gsi_start_bb to skip the
10669 leading labels of bb.
10671 2024-06-12 Gerald Pfeifer <gerald@pfeifer.com>
10674 * doc/install.texi (Specific) <*-*-linux-gnu>: Do not list
10675 glibc 2.1 and binutils 2.12 as minimum dependencies.
10677 2024-06-12 Alexandre Oliva <oliva@adacore.com>
10679 PR tree-optimization/113681
10680 * tree-profile.cc (pass_ipa_tree_profile::gate): Skip if
10683 2024-06-12 liuhongt <hongtao.liu@intel.com>
10686 * simplify-rtx.cc (simplify_context::simplify_binary_operation_1):
10687 Only do the simplification of (AND (ASHIFTRT A imm) mask)
10688 to (LSHIFTRT A imm) when the component of const_vector is
10691 2024-06-11 Joseph Myers <josmyers@redhat.com>
10693 * doc/cpp.texi (__STDC_VERSION__): Document C2Y handling.
10694 * doc/invoke.texi (-Wc23-c2y-compat, -std=c2y, -std=gnu2y):
10696 (-std=gnu23): Update documentation.
10697 * doc/standards.texi (C Language): Document C2Y. Update C23
10699 * config/rl78/rl78.cc (rl78_option_override): Handle "GNU C2Y"
10701 * dwarf2out.cc (highest_c_language, gen_compile_unit_die):
10704 2024-06-11 Gerald Pfeifer <gerald@pfeifer.com>
10707 * doc/install.texi (Specific) <x86_64-*-solaris2*>: Remove
10708 redundant introduction of x86-64.
10710 2024-06-11 Robin Dapp <rdapp@ventanamicro.com>
10712 PR tree-optimization/115382
10713 * tree-vect-loop.cc (vectorize_fold_left_reduction): Use
10715 * tree-vect-stmts.cc (check_load_store_for_partial_vectors):
10716 Remove static of prepare_vec_mask.
10717 * tree-vectorizer.h (prepare_vec_mask): Export.
10719 2024-06-11 Patrick O'Neill <patrick@rivosinc.com>
10721 * config/riscv/sync.md (atomic_<atomic_optab><mode>): New expand pattern.
10722 (amo_atomic_<atomic_optab><mode>): Rename amo pattern.
10723 (atomic_fetch_<atomic_optab><mode>): New lrsc sequence pattern.
10724 (lrsc_atomic_<atomic_optab><mode>): New expand pattern.
10725 (amo_atomic_fetch_<atomic_optab><mode>): Rename amo pattern.
10726 (lrsc_atomic_fetch_<atomic_optab><mode>): New lrsc sequence pattern.
10727 (atomic_exchange<mode>): New expand pattern.
10728 (amo_atomic_exchange<mode>): Rename amo pattern.
10729 (lrsc_atomic_exchange<mode>): New lrsc sequence pattern.
10731 2024-06-11 Patrick O'Neill <patrick@rivosinc.com>
10733 * doc/sourcebuild.texi: Add docs for atomic extension testsuite infra.
10735 2024-06-11 Edwin Lu <ewlu@rivosinc.com>
10736 Patrick O'Neill <patrick@rivosinc.com>
10738 * common/config/riscv/riscv-common.cc: Add Zaamo and Zalrsc.
10739 * config/riscv/arch-canonicalize: Make A imply Zaamo and Zalrsc.
10740 * config/riscv/riscv.opt: Add Zaamo and Zalrsc
10741 * config/riscv/sync.md: Convert TARGET_ATOMIC to TARGET_ZAAMO and
10744 2024-06-11 Uros Bizjak <ubizjak@gmail.com>
10747 * config/i386/i386.md (usadd<mode>3): Emit insn sequence
10748 involving conditional move for TARGET_CMOVE targets.
10749 (ussub<mode>3): Ditto.
10751 2024-06-11 Pengxuan Zheng <quic_pzheng@quicinc.com>
10753 * config/aarch64/aarch64-builtins.cc (VAR1): Remap float_truncate_lo_
10754 builtin codes to standard optab ones.
10755 * config/aarch64/aarch64-simd.md (aarch64_float_truncate_lo_<mode><vczle><vczbe>):
10757 (trunc<Vwide><mode>2<vczle><vczbe>): ... This.
10759 2024-06-11 Andi Kleen <ak@linux.intel.com>
10761 * doc/extend.texi: Document constexpr asm.
10763 2024-06-11 Andrew MacLeod <amacleod@redhat.com>
10765 * gimple-range-fold.cc (range_of_ssa_name_with_loop_info): Issue a
10766 message if SCEV is not invoked due to a mismatch.
10768 2024-06-11 Roger Sayle <roger@nextmovesoftware.com>
10771 * config/i386/i386-expand.cc (ix86_expand_ternlog): Move call to
10772 ix86_broadcast_from_constant before call to validize_mem, but after
10773 call to force_const_mem.
10775 2024-06-11 Pan Li <pan2.li@intel.com>
10777 * config/riscv/autovec.md (ussub<mode>3): Add new pattern impl
10778 for the unsigned vector modes.
10779 * config/riscv/riscv-protos.h (expand_vec_ussub): Add new func
10780 decl to expand .SAT_SUB for vector mode.
10781 * config/riscv/riscv-v.cc (emit_vec_saddu): Add new func impl
10782 to expand .SAT_SUB for vector mode.
10783 (emit_vec_binary_alu): Add new helper func to emit binary alu.
10784 (expand_vec_ussub): Leverage above helper func.
10786 2024-06-10 Gerald Pfeifer <gerald@pfeifer.com>
10788 * doc/gm2.texi (Documentation): Fix typos, grammar, and a link.
10790 2024-06-10 Andrew MacLeod <amacleod@redhat.com>
10792 * gimple-array-bounds.cc (array_bounds_checker::array_bounds_checker):
10793 Always use current range_query.
10794 (pass_data_array_bounds): New.
10795 (pass_array_bounds): New.
10796 (make_pass_array_bounds): New.
10797 * gimple-array-bounds.h (array_bounds_checker): Adjust prototype.
10798 * passes.def (pass_array_bounds): New. Add after VRP1.
10799 * timevar.def (TV_TREE_ARRAY_BOUNDS): New timevar.
10800 * tree-pass.h (make_pass_array_bounds): Add prototype.
10801 * tree-vrp.cc (execute_ranger_vrp): Remove warning param and do
10802 not invoke array bounds warning pass.
10803 (pass_vrp::pass_vrp): Adjust params.
10804 (pass_vrp::close): Adjust parameters.
10805 (pass_vrp::warn_array_bounds_p): Remove.
10806 (make_pass_vrp): Remove warning param.
10807 (make_pass_early_vrp): Remove warning param.
10808 (make_pass_fast_vrp): Remove warning param.
10810 2024-06-10 Raphael Zinsly <rzinsly@ventanamicro.com>
10812 * config/riscv/bitmanip.md (*bextdisi): New pattern.
10814 2024-06-10 Pan Li <pan2.li@intel.com>
10817 * tree-ssa-math-opts.cc (math_opts_dom_walker::after_dom_children): Take
10818 the gsi of start_bb instead of last_bb.
10820 2024-06-10 Raphael Zinsly <rzinsly@ventanamicro.com>
10822 * config/riscv/bitmanip.md (*bextdisi): New pattern.
10824 2024-06-10 Richard Biener <rguenther@suse.de>
10826 PR tree-optimization/115388
10827 * tree-ssa-dse.cc (dse_classify_store): Handle irreducible
10829 (pass_dse::execute): Make sure to mark backedges.
10831 2024-06-10 Richard Biener <rguenther@suse.de>
10833 PR tree-optimization/115395
10834 * tree-vect-loop.cc (vect_create_epilog_for_reduction):
10835 Handle STMT_VINFO_REDUC_EPILOGUE_ADJUSTMENT also for SLP
10836 reductions of group_size one.
10838 2024-06-10 Andreas Krebbel <krebbel@linux.ibm.com>
10840 * config/s390/s390.cc (expand_perm_as_replicate): Handle memory
10842 * config/s390/vx-builtins.md (vec_splats<mode>): Turn into parameterized expander.
10843 (@vec_splats<mode>): New expander.
10845 2024-06-10 Richard Biener <rguenther@suse.de>
10847 PR tree-optimization/115383
10848 * tree-vect-stmts.cc (vectorizable_condition): Handle
10849 generating a chain of .FOLD_EXTRACT_LAST.
10851 2024-06-09 Andreas Tobler <andreast@gcc.gnu.org>
10853 * config/freebsd-spec.h: Change fbsd-lib-spec for FreeBSD > 13,
10854 do not link against profiled system libraries if -pg is invoked.
10855 Add a define to note about this change.
10856 * config/aarch64/aarch64-freebsd.h: Use the note to inform if
10857 -pg is invoked on FreeBSD > 13.
10858 * config/arm/freebsd.h: Likewise.
10859 * config/i386/freebsd.h: Likewise.
10860 * config/i386/freebsd64.h: Likewise.
10861 * config/riscv/freebsd.h: Likewise.
10862 * config/rs6000/freebsd64.h: Likewise.
10863 * config/rs6000/sysv4.h: Likeise.
10865 2024-06-09 Jeff Law <jlaw@ventanamicro.com>
10867 * config/riscv/riscv.cc (riscv_move_integer): Initialize "x".
10869 2024-06-09 Uros Bizjak <ubizjak@gmail.com>
10872 * config/i386/i386.md (ussub<mode>3): New expander.
10873 (sub<mode>_3): Ditto.
10875 2024-06-09 Gerald Pfeifer <gerald@pfeifer.com>
10877 * doc/install.texi (avr): Remove link to www.amelek.gda.pl/avr/.
10879 2024-06-09 Roger Sayle <roger@nextmovesoftware.com>
10881 * expmed.cc (expand_shift_1): Use add_optab instead of ior_optab
10882 to generate PLUS instead or IOR when unioning disjoint bitfields.
10883 * optabs.cc (expand_subword_shift): Likewise.
10884 (expand_binop): Likewise for double-word rotate.
10886 2024-06-08 Peter Bergner <bergner@linux.ibm.com>
10888 * config/rs6000/rs6000-logue.cc (rs6000_stack_info): Update comment.
10890 2024-06-08 Uros Bizjak <ubizjak@gmail.com>
10893 * config/i386/i386.md (usadd<mode>3): New expander.
10894 (x86_mov<mode>cc_0_m1_neg): Use SWI mode iterator.
10896 2024-06-08 Pan Li <pan2.li@intel.com>
10898 * config/riscv/riscv-protos.h (riscv_expand_ussub): Add new func
10899 decl for ussub expanding.
10900 * config/riscv/riscv.cc (riscv_expand_ussub): Ditto but for impl.
10901 * config/riscv/riscv.md (ussub<mode>3): Add new pattern ussub
10904 2024-06-07 David Malcolm <dmalcolm@redhat.com>
10906 * doc/invoke.texi: Add -Wanalyzer-undefined-behavior-ptrdiff.
10908 2024-06-07 Jason Merrill <jason@redhat.com>
10910 * doc/invoke.texi (C++ Modules): Mention -include.
10912 2024-06-07 Roger Sayle <roger@nextmovesoftware.com>
10915 * config/i386/i386.cc (ix86_rtx_costs): Provide estimates for
10916 the *concatditi3 and *insvti_highpart patterns, about two insns.
10918 2024-06-07 Roger Sayle <roger@nextmovesoftware.com>
10919 Hongtao Liu <hongtao.liu@intel.com>
10921 * config/i386/i386-expand.cc (ix86_expand_args_builtin): Call
10922 fixup_modeless_constant before testing predicates. Only call
10923 copy_to_mode_reg on memory operands (after the first one).
10924 (ix86_gen_bcst_mem): Helper function to convert a CONST_VECTOR
10925 into a VEC_DUPLICATE if possible.
10926 (ix86_ternlog_idx): Convert an RTX expression into a ternlog
10927 index between 0 and 255, recording the operands in ARGS, if
10928 possible or return -1 if this is not possible/valid.
10929 (ix86_ternlog_leaf_p): Helper function to identify "leaves"
10930 of a ternlog expression, e.g. REG_P, MEM_P, CONST_VECTOR, etc.
10931 (ix86_ternlog_operand_p): Test whether a expression is suitable
10932 for and prefered as an UNSPEC_TERNLOG.
10933 (ix86_expand_ternlog_binop): Helper function to construct the
10934 binary operation corresponding to a sufficiently simple ternlog.
10935 (ix86_expand_ternlog_andnot): Helper function to construct a
10936 ANDN operation corresponding to a sufficiently simple ternlog.
10937 (ix86_expand_ternlog): Expand a 3-operand ternary logic
10938 expression, constructing either an UNSPEC_TERNLOG or simpler
10939 rtx expression. Called from builtin expanders and pre-reload
10941 * config/i386/i386-protos.h (ix86_ternlog_idx): Prototype here.
10942 (ix86_ternlog_operand_p): Likewise.
10943 (ix86_expand_ternlog): Likewise.
10944 * config/i386/predicates.md (ternlog_operand): New predicate
10945 that calls xi86_ternlog_operand_p.
10946 * config/i386/sse.md (<avx512>_vpternlog<mode>_0): New
10947 define_insn_and_split that recognizes a SET_SRC of ternlog_operand
10948 and expands it via ix86_expand_ternlog pre-reload.
10949 (<avx512>_vternlog<mode>_mask): Convert from define_insn to
10950 define_expand. Use ix86_expand_ternlog if the mask operand is
10952 (*<avx512>_vternlog<mode>_mask): define_insn renamed from above.
10954 2024-06-07 Michal Jires <mjires@suse.cz>
10956 * common.opt: Add cache partitioning.
10957 * flag-types.h (enum lto_partition_model): Likewise.
10959 2024-06-07 Richard Biener <rguenther@suse.de>
10961 * tree-vect-loop.cc (vectorize_fold_left_reduction): Fix
10962 mask vector operand indexing.
10964 2024-06-07 Jakub Jelinek <jakub@redhat.com>
10966 PR middle-end/115352
10967 * gimple-lower-bitint.cc (lower_addsub_overflow): Don't disable
10968 single_comparison if cmp_code is GE_EXPR.
10970 2024-06-07 Alexandre Oliva <oliva@adacore.com>
10972 * target.def (call_offset_return_label): New hook.
10973 * doc/tm.texi.in (TARGET_CALL_OFFSET_RETURN_LABEL): Add
10975 * doc/tm.texi: Rebuild.
10976 * dwarf2out.cc (struct call_arg_loc_node): Record call_insn
10977 instead of call_arg_loc_note.
10978 (add_AT_lbl_id): Add optional offset argument.
10979 (gen_call_site_die): Compute and pass on a return pc offset.
10980 (gen_subprogram_die): Move call_arg_loc_note computation...
10981 (dwarf2out_var_location): ... from here. Set call_insn.
10983 2024-06-06 Pan Li <pan2.li@intel.com>
10985 * doc/match-and-simplify.texi: Add doc for the matching flag '^'.
10986 * genmatch.cc (cmp_operand): Add match_phi comparation.
10987 (dt_node::gen_kids_1): Add cond_expr bool flag for phi match.
10988 (dt_operand::gen_phi_on_cond): Add new func to gen phi matching
10990 (parser::parse_expr): Add handling for the expr flag '^'.
10991 * match.pd: Add more form for unsigned .SAT_ADD.
10992 * tree-ssa-math-opts.cc (build_saturation_binary_arith_call): Add
10993 new func impl to build call for phi gimple.
10994 (match_unsigned_saturation_add): Add new func impl to match the
10995 .SAT_ADD for phi gimple.
10996 (math_opts_dom_walker::after_dom_children): Add phi matching
10997 try for all gimple phi stmt.
10999 2024-06-06 Pengxuan Zheng <quic_pzheng@quicinc.com>
11003 * config/aarch64/aarch64-builtins.cc (VAR1): Remap float_extend_lo_
11004 builtin codes to standard optab ones.
11005 * config/aarch64/aarch64-simd.md (aarch64_float_extend_lo_<Vwide>): Rename
11007 (extend<mode><Vwide>2): ... This.
11009 2024-06-06 Andrew Pinski <quic_apinski@quicinc.com>
11012 * Makefile.in (CPPLIB_H): Add label-text.h.
11014 2024-06-06 Richard Ball <richard.ball@arm.com>
11016 * config/aarch64/aarch64-c.cc (aarch64_define_unconditional_macros):
11017 Add missing __ARM_NEON_SVE_BRIDGE.
11019 2024-06-06 Richard Ball <richard.ball@arm.com>
11022 * config/arm/arm.h (enum arm_auto_incmodes):
11023 Correct CASE_VECTOR_SHORTEN_MODE query.
11025 2024-06-06 Tamar Christina <tamar.christina@arm.com>
11027 * config/aarch64/aarch64-sve.md (@aarch64_pred_cmp<cmp_op><mode>,
11028 *cmp<cmp_op><mode>_cc, *cmp<cmp_op><mode>_ptest,
11029 @aarch64_pred_cmp<cmp_op><mode>_wide,
11030 *aarch64_pred_cmp<cmp_op><mode>_wide_cc,
11031 *aarch64_pred_cmp<cmp_op><mode>_wide_ptest): Fix Upl tie alternative.
11032 * config/aarch64/aarch64-sve2.md (@aarch64_pred_<sve_int_op><mode>): Fix
11033 Upl tie alternative.
11035 2024-06-06 Thomas Schwinge <tschwinge@baylibre.com>
11037 * config/nvptx/nvptx.md (nvptx_uniform_warp_check): Make fit for
11038 non-full-warp execution, via 'vote.all.pred'.
11040 2024-06-06 Pan Li <pan2.li@intel.com>
11042 * match.pd: Add new form for vector mode recog.
11043 * tree-vect-patterns.cc (gimple_unsigned_integer_sat_sub): Add
11044 new match func decl;
11045 (vect_recog_build_binary_gimple_call): Extract helper func to
11046 build gcall with given internal_fn.
11047 (vect_recog_sat_sub_pattern): Add new func impl to recog .SAT_SUB.
11049 2024-06-06 Michal Jires <mjires@suse.cz>
11051 * lto-streamer.cc (lto_get_section_name): Remove suffixes after WPA.
11053 2024-06-06 Michal Jires <mjires@suse.cz>
11055 * lto-opts.cc (lto_write_options): Skip OPT_fltrans_output_list_.
11057 2024-06-06 Robin Dapp <rdapp@ventanamicro.com>
11059 * config/riscv/riscv.opt.urls: Regenerate.
11061 2024-06-06 Hongyu Wang <hongyu.wang@intel.com>
11063 * config/i386/i386-expand.cc (ix86_gen_ccmp_first):
11064 Add fp compare and check the allowed fp compare type.
11065 (ix86_gen_ccmp_next): Adjust compare_code input to ccmp for
11068 2024-06-06 Hongyu Wang <hongyu.wang@intel.com>
11070 * ccmp.cc (expand_ccmp_expr_1): Check ret and ret2 of
11071 expand_ccmp_next, returns the valid one first instead of
11074 2024-06-06 Hongyu Wang <hongyu.wang@intel.com>
11076 * config/i386/i386-expand.cc (ix86_gen_ccmp_first): New function
11077 that test if the first compare can be generated.
11078 (ix86_gen_ccmp_next): New function to emit a simgle compare and ccmp
11080 * config/i386/i386-opts.h (enum apx_features): Add apx_ccmp.
11081 * config/i386/i386-protos.h (ix86_gen_ccmp_first): New proto
11083 (ix86_gen_ccmp_next): Likewise.
11084 (ix86_get_flags_cc): Likewise.
11085 * config/i386/i386.cc (ix86_flags_cc): New enum.
11086 (ix86_ccmp_dfv_mapping): New string array to map conditional
11088 (ix86_print_operand): Handle special dfv flag for CCMP.
11089 (ix86_get_flags_cc): New function to return x86 CC enum.
11090 (TARGET_GEN_CCMP_FIRST): Define.
11091 (TARGET_GEN_CCMP_NEXT): Likewise.
11092 * config/i386/i386.h (TARGET_APX_CCMP): Define.
11093 * config/i386/i386.md (@ccmp<mode>): New define_insn to support
11095 (UNSPEC_APX_DFV): New unspec for ccmp dfv.
11096 (ALL_CC): New mode iterator.
11097 (cstorecc4): Change to ...
11098 (cstore<mode>4) ... this, use ALL_CC to loop through all
11100 * config/i386/i386.opt (apx_ccmp): Add enum value for ccmp.
11102 2024-06-06 Richard Biener <rguenther@suse.de>
11104 * tree-vect-loop.cc (vectorizable_reduction): Allow
11105 single-lane SLP in-order reductions.
11106 (vectorize_fold_left_reduction): Handle SLP reduction with
11107 conditional reduction op.
11109 2024-06-06 Richard Biener <rguenther@suse.de>
11111 * tree-vect-loop.cc (vect_analyze_scalar_cycles_1): Queue
11112 double reductions in LOOP_VINFO_REDUCTIONS.
11113 (vect_create_epilog_for_reduction): Remove asserts disabling
11114 SLP for double reductions.
11115 (vectorizable_reduction): Analyze SLP double reductions
11116 only once and start off the correct places.
11117 * tree-vect-slp.cc (vect_get_and_check_slp_defs): Allow
11118 vect_double_reduction_def.
11119 (vect_build_slp_tree_2): Fix condition for the ignored
11120 reduction initial values.
11121 * tree-vect-stmts.cc (vect_analyze_stmt): Allow
11122 vect_double_reduction_def.
11124 2024-06-06 Richard Biener <rguenther@suse.de>
11126 * tree-vect-loop.cc (vect_create_epilog_for_reduction):
11127 Adjust for single-lane COND_REDUCTION SLP vectorization.
11128 (vectorizable_reduction): Likewise.
11129 (vect_transform_cycle_phi): Likewise.
11131 2024-06-06 Richard Biener <rguenther@suse.de>
11133 * tree-vect-stmts.cc (vectorizable_condition): Allow
11134 single-lane SLP, but not when we need to swap then and
11137 2024-06-06 YunQiang Su <syq@gcc.gnu.org>
11139 * config/mips/mips.cc(mips_insn_cost): Add missing COSTS_N_INSNS
11142 2024-06-06 liuhongt <hongtao.liu@intel.com>
11145 * config/i386/i386.cc (ix86_rtx_costs): Adjust cost for
11146 CONST_VECTOR_DUPLICATE_P in constant_pool.
11147 * config/i386/i386-expand.cc (ix86_broadcast_from_constant):
11149 * config/i386/i386-protos.h (ix86_broadcast_from_constant):
11152 2024-06-06 liuhongt <hongtao.liu@intel.com>
11156 (simplify_context::simplify_binary_operation_1):
11157 Simplify (AND (ASHIFTRT A imm) mask) to (LSHIFTRT A imm) for
11160 2024-06-05 Robin Dapp <rdapp.gcc@gmail.com>
11162 * config/riscv/riscv-opts.h (TARGET_VECTOR_MISALIGN_SUPPORTED):
11164 * config/riscv/riscv.h (TARGET_VECTOR_MISALIGN_SUPPORTED):
11165 ...to here and map to riscv_vector_unaligned_access_p.
11166 * config/riscv/riscv.opt: Add -mvector-strict-align.
11167 * config/riscv/riscv.cc (struct riscv_tune_param): Add
11168 vector_unaligned_access.
11169 (riscv_override_options_internal): Set
11170 riscv_vector_unaligned_access_p.
11171 * doc/invoke.texi: Document -mvector-strict-align.
11173 2024-06-05 Tamar Christina <tamar.christina@arm.com>
11175 * config/aarch64/tuning_models/neoversen2.h (neoversen2_tunings): Add
11176 AARCH64_EXTRA_TUNE_AVOID_PRED_RMW.
11177 * config/aarch64/tuning_models/neoversev1.h (neoversev1_tunings): Add
11178 AARCH64_EXTRA_TUNE_AVOID_PRED_RMW.
11179 * config/aarch64/tuning_models/neoversev2.h (neoversev2_tunings): Add
11180 AARCH64_EXTRA_TUNE_AVOID_PRED_RMW.
11182 2024-06-05 Tamar Christina <tamar.christina@arm.com>
11184 * config/aarch64/aarch64-sve.md (and<mode>3,
11185 @aarch64_pred_<optab><mode>_z, *<optab><mode>3_cc,
11186 *<optab><mode>3_ptest, aarch64_pred_<nlogical><mode>_z,
11187 *<nlogical><mode>3_cc, *<nlogical><mode>3_ptest,
11188 aarch64_pred_<logical_nn><mode>_z, *<logical_nn><mode>3_cc,
11189 *<logical_nn><mode>3_ptest, @aarch64_pred_cmp<cmp_op><mode>,
11190 *cmp<cmp_op><mode>_cc, *cmp<cmp_op><mode>_ptest,
11191 @aarch64_pred_cmp<cmp_op><mode>_wide,
11192 *aarch64_pred_cmp<cmp_op><mode>_wide_cc,
11193 *aarch64_pred_cmp<cmp_op><mode>_wide_ptest, @aarch64_brk<brk_op>,
11194 *aarch64_brk<brk_op>_cc, *aarch64_brk<brk_op>_ptest,
11195 @aarch64_brk<brk_op>, *aarch64_brk<brk_op>_cc,
11196 *aarch64_brk<brk_op>_ptest, aarch64_rdffr_z, *aarch64_rdffr_z_ptest,
11197 *aarch64_rdffr_ptest, *aarch64_rdffr_z_cc, *aarch64_rdffr_cc): Add
11200 * config/aarch64/aarch64-sve2.md
11201 (@aarch64_pred_<sve_int_op><mode>): Likewise.
11203 2024-06-05 Tamar Christina <tamar.christina@arm.com>
11205 * config/aarch64/aarch64-tuning-flags.def
11206 (AVOID_PRED_RMW): New.
11207 * config/aarch64/aarch64.h (TARGET_SVE_PRED_CLOBBER): New.
11208 * config/aarch64/aarch64.md (pred_clobber): New.
11209 (arch_enabled): Use it.
11211 2024-06-05 Tamar Christina <tamar.christina@arm.com>
11213 * config/aarch64/aarch64-sve.md (and<mode>3,
11214 @aarch64_pred_<optab><mode>_z, *<optab><mode>3_cc,
11215 *<optab><mode>3_ptest, aarch64_pred_<nlogical><mode>_z,
11216 *<nlogical><mode>3_cc, *<nlogical><mode>3_ptest,
11217 aarch64_pred_<logical_nn><mode>_z, *<logical_nn><mode>3_cc,
11218 *<logical_nn><mode>3_ptest, *cmp<cmp_op><mode>_ptest,
11219 @aarch64_pred_cmp<cmp_op><mode>_wide,
11220 *aarch64_pred_cmp<cmp_op><mode>_wide_cc,
11221 *aarch64_pred_cmp<cmp_op><mode>_wide_ptest, *aarch64_brk<brk_op>_cc,
11222 *aarch64_brk<brk_op>_ptest, @aarch64_brk<brk_op>,
11223 *aarch64_brk<brk_op>_cc, *aarch64_brk<brk_op>_ptest, aarch64_rdffr_z,
11224 *aarch64_rdffr_z_ptest, *aarch64_rdffr_ptest, *aarch64_rdffr_z_cc,
11225 *aarch64_rdffr_cc): Convert to compact syntax.
11226 * config/aarch64/aarch64-sve2.md
11227 (@aarch64_pred_<sve_int_op><mode>): Likewise.
11229 2024-06-05 Jakub Jelinek <jakub@redhat.com>
11230 Frederik Harwath <frederik@codesourcery.com>
11231 Sandra Loosemore <sandra@codesourcery.com>
11233 * tree.def (OMP_TILE, OMP_UNROLL): New tree codes.
11234 * tree-core.h (enum omp_clause_code): Add OMP_CLAUSE_PARTIAL,
11235 OMP_CLAUSE_FULL and OMP_CLAUSE_SIZES.
11236 * tree.h (OMP_LOOPXFORM_CHECK): Define.
11237 (OMP_LOOPXFORM_LOWERED): Define.
11238 (OMP_CLAUSE_PARTIAL_EXPR): Define.
11239 (OMP_CLAUSE_SIZES_LIST): Define.
11240 * tree.cc (omp_clause_num_ops, omp_clause_code_name): Add entries
11241 for OMP_CLAUSE_{PARTIAL,FULL,SIZES}.
11242 * tree-pretty-print.cc (dump_omp_clause): Handle
11243 OMP_CLAUSE_{PARTIAL,FULL,SIZES}.
11244 (dump_generic_node): Handle OMP_TILE and OMP_UNROLL. Skip printing
11245 loops with NULL OMP_FOR_INIT (node) vector element.
11246 * gimplify.cc (is_gimple_stmt): Handle OMP_TILE and OMP_UNROLL.
11247 (gimplify_omp_taskloop_expr): For SAVE_EXPR use gimplify_save_expr.
11248 (gimplify_omp_loop_xform): New function.
11249 (gimplify_omp_for): Call omp_maybe_apply_loop_xforms and if that
11250 reshuffles what the passed pointer points to, retry or return GS_OK.
11251 Handle OMP_TILE and OMP_UNROLL.
11252 (gimplify_omp_loop): Call omp_maybe_apply_loop_xforms and if that
11253 reshuffles what the passed pointer points to, return GS_OK.
11254 (gimplify_expr): Handle OMP_TILE and OMP_UNROLL.
11255 * omp-general.h (omp_loop_number_of_iterations,
11256 omp_maybe_apply_loop_xforms): Declare.
11257 * omp-general.cc (omp_adjust_for_condition): For LE_EXPR and GE_EXPR
11258 with pointers, don't add/subtract one, but the size of what the
11260 (omp_loop_number_of_iterations, omp_apply_tile,
11261 find_nested_loop_xform, omp_maybe_apply_loop_xforms): New functions.
11263 2024-06-05 Kewen Lin <linkw@linux.ibm.com>
11265 * config/darwin.cc (darwin_patch_builtins): Use TYPE_PRECISION of
11266 long_double_type_node to replace LONG_DOUBLE_TYPE_SIZE.
11268 2024-06-05 Pan Li <pan2.li@intel.com>
11272 * internal-fn.def (SAT_SUB): Add new IFN define for SAT_SUB.
11273 * match.pd: Add new match for SAT_SUB.
11274 * optabs.def (OPTAB_NL): Remove fixed-point for ussub/ssub.
11275 * tree-ssa-math-opts.cc (gimple_unsigned_integer_sat_sub): Add
11276 new decl for generated in match.pd.
11277 (build_saturation_binary_arith_call): Add new helper function
11278 to build the gimple call to binary SAT alu.
11279 (match_saturation_arith): Rename from.
11280 (match_unsigned_saturation_add): Rename to.
11281 (match_unsigned_saturation_sub): Add new func to match the
11283 (math_opts_dom_walker::after_dom_children): Add SAT_SUB matching
11284 try when COND_EXPR.
11286 2024-06-05 Gerald Pfeifer <gerald@pfeifer.com>
11289 * doc/install.texi (Prerequisites): Drop reference to GNU awk
11290 version 3.1.5. Remove fluff.
11292 2024-06-05 liuhongt <hongtao.liu@intel.com>
11294 PR rtl-optimization/100927
11295 PR rtl-optimization/115161
11296 PR rtl-optimization/115115
11297 * simplify-rtx.cc (simplify_const_unary_operation): Prevent
11298 simplication of FIX/UNSIGNED_FIX for NAN/INF/out-of-range
11299 constant when flag_trapping_math.
11300 * fold-const.cc (fold_convert_const_int_from_real): Don't fold
11301 for overflow value when_trapping_math.
11303 2024-06-05 Xiao Zeng <zengxiao@eswincomputing.com>
11305 * config/riscv/iterators.md: Add mode_iterator between
11306 floating-point modes and BFmode.
11307 * config/riscv/riscv.cc (riscv_output_move): Handle BFmode move
11309 * config/riscv/riscv.md (trunc<mode>bf2): New pattern for BFmode.
11310 (extendbfsf2): Dotto.
11311 (*movhf_hardfloat): Add BFmode.
11312 (*mov<mode>_hardfloat): Dotto.
11314 2024-06-04 Jakub Jelinek <jakub@redhat.com>
11316 PR tree-optimization/115337
11317 * gimple-range-op.cc (cfn_clz::fold_range): For
11318 m_gimple_call_internal_p handle as a special case also second argument
11319 of -1 next to prec.
11321 2024-06-04 Jakub Jelinek <jakub@redhat.com>
11323 PR tree-optimization/115337
11324 * fold-const.cc (tree_call_nonnegative_warnv_p): Handle
11325 CASE_CFN_CTZ like CASE_CFN_CLZ.
11327 2024-06-04 Jakub Jelinek <jakub@redhat.com>
11329 * fold-const.cc (tree_call_nonnegative_warnv_p): Formatting fixes.
11330 (tree_invalid_nonnegative_warnv_p): Likewise.
11331 * gimple-fold.cc (gimple_call_nonnegative_warnv_p): Likewise.
11333 2024-06-04 Jakub Jelinek <jakub@redhat.com>
11335 PR tree-optimization/115337
11336 * fold-const.cc (tree_call_nonnegative_warnv_p) <CASE_CFN_CLZ>:
11337 If arg1 is non-NULL, RECURSE on it, otherwise return true.
11339 2024-06-04 Jakub Jelinek <jakub@redhat.com>
11341 PR middle-end/108789
11342 * builtins.cc (fold_builtin_arith_overflow): For ovf_only,
11343 don't call save_expr and don't build REALPART_EXPR, otherwise
11344 set TREE_SIDE_EFFECTS on call before calling save_expr.
11345 (fold_builtin_addc_subc): Set TREE_SIDE_EFFECTS on call before
11348 2024-06-04 Jakub Jelinek <jakub@redhat.com>
11350 * doc/invoke.texi (lujiazui): Clarify that while the CPUs do support
11351 AVX and F16C, -march=lujiazui actually doesn't enable those.
11353 2024-06-04 Richard Biener <rguenther@suse.de>
11355 * tree-vect-slp.cc (vect_build_slp_tree_2): Only multi-lane
11356 discoveries are reduction chains and need special backedge
11358 (vect_analyze_slp): Fall back to single-lane SLP discovery
11359 for reductions. Make sure to try single-lane SLP reduction
11360 for all reductions as fallback.
11361 (vectorizable_load): Avoid outer loop SLP vectorization with
11362 multi-copy vector stmts in the inner loop.
11363 (vectorizable_store): Likewise.
11364 * tree-vect-loop.cc (vect_create_epilog_for_reduction): Allow
11365 direct opcode and shift reduction also for SLP reductions
11366 with a single lane.
11367 * tree-vect-stmts.cc (get_group_load_store_type): For SLP also
11368 check for the PR65518 single-element interleaving case as done in
11369 vect_grouped_load_supported.
11371 2024-06-04 Richard Biener <rguenther@suse.de>
11373 * tree-vect-slp.cc (vect_schedule_slp_node): For mask/len
11374 loops make sure to not advance the insertion iterator
11375 beyond a GIMPLE_COND.
11377 2024-06-03 Jakub Jelinek <jakub@redhat.com>
11380 * config/rs6000/rs6000-gen-builtins.cc (write_decls): Remove
11381 GTY markup from struct bifdata and struct ovlddata and remove their
11382 fntype members. Change next member in struct ovlddata and
11383 first_instance member of struct ovldrecord to have int type rather
11384 than struct ovlddata *. Remove GTY markup from rs6000_builtin_info
11385 and rs6000_instance_info arrays, declare new
11386 rs6000_builtin_info_fntype and rs6000_instance_info_fntype arrays,
11387 which have GTY markup.
11388 (write_bif_static_init): Adjust for the above changes.
11389 (write_ovld_static_init): Likewise.
11390 (write_init_bif_table): Likewise.
11391 (write_init_ovld_table): Likewise.
11392 * config/rs6000/rs6000-builtin.cc (rs6000_init_builtins): Likewise.
11393 * config/rs6000/rs6000-c.cc (find_instance): Likewise. Make static.
11394 (altivec_resolve_overloaded_builtin): Adjust for the above changes.
11396 2024-06-03 David Malcolm <dmalcolm@redhat.com>
11398 * diagnostic-format-sarif.cc: Include "ordered-hash-map.h" and
11400 (enum class diagnostic_artifact_role): New.
11401 (class sarif_artifact): New.
11402 (sarif_builder::maybe_make_artifact_content_object): Make public.
11403 (sarif_builder::m_filenames): Replace with...
11404 (sarif_builder::m_filename_to_artifact_map): ...this.
11405 (sarif_artifact::add_role): New.
11406 (sarif_artifact::populate_contents): New.
11407 (get_artifact_role_string): New.
11408 (sarif_artifact::populate_roles): New.
11409 (sarif_result::on_nested_diagnostic): Pass role to
11410 make_location_object.
11411 (sarif_ice_notification::sarif_ice_notification): Likewise.
11412 (sarif_builder::sarif_builder): Add "main_input_filename_" param.
11413 Mark it as the artifact that the tool was instructed to scan.
11414 (sarif_builder::make_result_object): Pass role to
11415 make_locations_arr.
11416 (sarif_builder::make_locations_arr): Add "role" param and pass it
11417 to make_location_object.
11418 (sarif_builder::make_location_object): Add "role" param and pass
11419 it to maybe_make_physical_location_object.
11420 (sarif_builder::maybe_make_physical_location_object): Add "role"
11421 param and pass it to call to get_or_create_artifact, rather than
11422 adding to now-removed "m_filenames". Flag the artifact for its
11423 contents to be embedded.
11424 (sarif_builder::make_thread_flow_location_object): Pass role to
11425 make_location_object.
11426 (sarif_builder::make_run_object): Update for change from
11427 m_filename to m_filename_to_artifact_map. Call populate_contents
11428 and populate_roles on each artifact_obj.
11429 (sarif_builder::make_artifact_object): Convert to...
11430 (sarif_builder::get_or_create_artifact): ...this, moving addition
11431 of contents to make_run_object, and conditionalizing setting of
11432 sourceLanguage on "role".
11433 (sarif_output_format::sarif_output_format): Add
11434 "main_input_filename_" param and pass to m_builder's ctor.
11435 (sarif_stream_output_format::sarif_stream_output_format):
11437 (sarif_file_output_format::sarif_file_output_format): Likewise.
11438 (diagnostic_output_format_init_sarif_stderr): Add
11439 "main_input_filename_" param and pass to ctor.
11440 (diagnostic_output_format_init_sarif_file): Likewise.
11441 (diagnostic_output_format_init_sarif_stream): Likewise.
11442 * diagnostic.cc (diagnostic_output_format_init): Add
11443 "main_input_filename_" param and pass to the
11444 diagnostic_output_format_init_sarif_* calls.
11445 * diagnostic.h (diagnostic_output_format_init): Add
11446 main_input_filename_" param to decl.
11447 (diagnostic_output_format_init_sarif_stderr): Likewise.
11448 (diagnostic_output_format_init_sarif_file): Likewise.
11449 (diagnostic_output_format_init_sarif_stream): Likewise.
11450 * gcc.cc (driver_handle_option): Pass main input filename to
11451 diagnostic_output_format_init.
11452 * opts.cc (common_handle_option): Likewise.
11454 2024-06-03 Eric Botcazou <ebotcazou@adacore.com>
11456 * dwarf2out.cc (loc_list_from_tree_1) <CEIL_DIV_EXPR>; Add const.
11457 <do_comp_binop>: Use a signed comparison for small unsigned types.
11458 Implement wrap-around arithmetics for small integer types.
11460 2024-06-03 Uros Bizjak <ubizjak@gmail.com>
11463 * config/i386/i386.md (bswapsi2): Force operand 1
11464 to a register also for !TARGET_BSWAP.
11466 2024-06-03 Aldy Hernandez <aldyh@redhat.com>
11468 * builtins.cc (expand_builtin_strnlen): Replace value_range use
11469 with int_range_max or irange when appropriate.
11470 (determine_block_size): Same.
11471 * fold-const.cc (minmax_from_comparison): Same.
11472 * gimple-array-bounds.cc (check_out_of_bounds_and_warn): Same.
11473 (array_bounds_checker::check_array_ref): Same.
11474 * gimple-fold.cc (size_must_be_zero_p): Same.
11475 * gimple-predicate-analysis.cc (find_var_cmp_const): Same.
11476 * gimple-ssa-sprintf.cc (get_int_range): Same.
11477 (format_integer): Same.
11478 (try_substitute_return_value): Same.
11479 (handle_printf_call): Same.
11480 * gimple-ssa-warn-restrict.cc
11481 (builtin_memref::extend_offset_range): Same.
11482 * graphite-sese-to-poly.cc (add_param_constraints): Same.
11483 * internal-fn.cc (get_min_precision): Same.
11485 * pointer-query.cc (get_size_range): Same.
11486 * range-op.cc (get_shift_range): Same.
11487 (operator_trunc_mod::op1_range): Same.
11488 (operator_trunc_mod::op2_range): Same.
11489 * range.cc (range_negatives): Same.
11490 * range.h (range_positives): Same.
11491 (range_negatives): Same.
11492 * tree-affine.cc (expr_to_aff_combination): Same.
11493 * tree-data-ref.cc (compute_distributive_range): Same.
11494 (nop_conversion_for_offset_p): Same.
11495 (split_constant_offset): Same.
11496 (split_constant_offset_1): Same.
11497 (dr_step_indicator): Same.
11498 * tree-dfa.cc (get_ref_base_and_extent): Same.
11499 * tree-scalar-evolution.cc (iv_can_overflow_p): Same.
11500 * tree-ssa-math-opts.cc (optimize_spaceship): Same.
11501 * tree-ssa-pre.cc (insert_into_preds_of_block): Same.
11502 * tree-ssa-reassoc.cc (optimize_range_tests_to_bit_test): Same.
11503 * tree-ssa-strlen.cc (compare_nonzero_chars): Same.
11504 (dump_strlen_info): Same.
11505 (get_range_strlen_dynamic): Same.
11506 (set_strlen_range): Same.
11507 (maybe_diag_stxncpy_trunc): Same.
11508 (strlen_pass::get_len_or_size): Same.
11509 (strlen_pass::handle_builtin_string_cmp): Same.
11510 (strlen_pass::count_nonzero_bytes_addr): Same.
11511 (strlen_pass::handle_integral_assign): Same.
11512 * tree-switch-conversion.cc (bit_test_cluster::emit): Same.
11513 * tree-vect-loop-manip.cc (vect_gen_vector_loop_niters): Same.
11514 (vect_do_peeling): Same.
11515 * tree-vect-patterns.cc (vect_get_range_info): Same.
11516 (vect_recog_divmod_pattern): Same.
11517 * tree.cc (get_range_pos_neg): Same.
11518 * value-range.cc (debug): Remove value_range variants.
11519 * value-range.h (value_range): Remove typedef.
11521 (simplify_using_ranges::op_with_boolean_value_range_p): Replace
11522 value_range use with int_range_max or irange when appropriate.
11523 (check_for_binary_op_overflow): Same.
11524 (simplify_using_ranges::legacy_fold_cond_overflow): Same.
11525 (find_case_label_ranges): Same.
11526 (simplify_using_ranges::simplify_abs_using_ranges): Same.
11527 (test_for_singularity): Same.
11528 (simplify_using_ranges::simplify_compare_using_ranges_1): Same.
11529 (simplify_using_ranges::simplify_casted_compare): Same.
11530 (simplify_using_ranges::simplify_switch_using_ranges): Same.
11531 (simplify_conversion_using_ranges): Same.
11532 (simplify_using_ranges::two_valued_val_range_p): Same.
11534 2024-06-03 Tobias Burnus <tburnus@baylibre.com>
11536 * doc/install.texi (gcn): Fix date of recommended newlib version.
11538 2024-06-03 Marc Poulhiès <poulhies@adacore.com>
11540 * config/aarch64/aarch64-ldp-fusion.cc (struct aarch64_pair_fusion):
11543 2024-06-03 Marc Poulhiès <poulhies@adacore.com>
11545 * pair-fusion.h (enum class writeback): Rename to...
11546 (enum class writeback_type): ...this.
11547 (struct pair_fusion): Adjust type name after renaming.
11548 * pair-fusion.cc (pair_fusion_bb_info::track_access): Likewise.
11549 (pair_fusion_bb_info::fuse_pair): Likewise.
11550 (pair_fusion::process_block): Likewise.
11552 2024-06-03 Richard Biener <rguenther@suse.de>
11554 * tree-vect-loop.cc (vect_analyze_loop_1): Avoid extra space
11557 2024-06-03 Richard Biener <rguenther@suse.de>
11559 * tree-vect-loop.cc (get_initial_defs_for_reduction):
11560 Always convert neutral_op.
11562 2024-06-03 liuhongt <hongtao.liu@intel.com>
11565 * config/i386/i386.cc (ix86_noce_conversion_profitable_p): Add
11566 some preference for floating point ifcvt when SSE4.1 is not
11569 2024-06-03 Haochen Jiang <haochen.jiang@intel.com>
11571 * common/config/i386/i386-common.cc: Change Granite Rapids
11572 series CPU type to P_PROC_AVX10_1_512.
11573 * common/config/i386/i386-cpuinfo.h (enum feature_priority):
11574 Revise comment part. Add P_AVX10_1_256, P_AVX10_1_512,
11575 P_PROC_AVX10_1_512.
11576 * common/config/i386/i386-isas.h: Link to avx10.1-256, avx10.1-512.
11578 2024-06-03 Lingling Kong <lingling.kong@intel.com>
11580 * config/i386/i386.md (clz<mode>2_lzcnt_nf): New define_insn.
11581 (*clz<mode>2_lzcnt_falsedep_nf): Ditto.
11582 (<lt_zcnt>_<mode>_nf): Ditto.
11583 (*<lt_zcnt>_<mode>_falsedep_nf): Ditto.
11584 (<lt_zcnt>_hi<nf_name>): Ditto.
11585 (popcount<mode>2_nf): Ditto.
11586 (*popcount<mode>2_falsedep_nf): Ditto.
11587 (popcounthi2<nf_name>): Ditto.
11589 2024-06-03 Lingling Kong <lingling.kong@intel.com>
11591 * config/i386/i386.md (*mul<mode>3_1<nf_name>): New define_insn.
11592 (*mulqi3_1<nf_name>): Ditto.
11593 (*<u>divmod<mode>4_noext_nf): Ditto.
11594 (<u>divmodhiqi3<nf_name>): Ditto.
11596 2024-06-03 Lingling Kong <lingling.kong@intel.com>
11598 * config/i386/i386.md (x86_64_shld): New define_insn.
11599 (x86_64_shld<nf_name>): Ditto.
11600 (x86_64_shld_ndd<nf_name>): Ditto.
11601 (x86_64_shld_1<nf_name>): Ditto.
11602 (x86_64_shld_ndd_1<nf_name>): Ditto.
11603 (*x86_64_shld_shrd_1_nozext_nf): Ditto.
11604 (x86_shld<nf_name>): Ditto.
11605 (x86_shld_ndd<nf_name>): Ditto.
11606 (x86_shld_1<nf_name>): Ditto.
11607 (x86_shld_ndd_1<nf_name>): Ditto.
11608 (*x86_shld_shrd_1_nozext_nf): Ditto.
11609 (<insn><dwi>3_doubleword_lowpart_nf): Ditto.
11610 (x86_64_shrd<nf_name>): Ditto.
11611 (x86_64_shrd_ndd<nf_name>): Ditto.
11612 (x86_64_shrd_1<nf_name>): Ditto.
11613 (x86_64_shrd_ndd_1<nf_name>): Ditto.
11614 (*x86_64_shrd_shld_1_nozext_nf): Ditto.
11615 (x86_shrd<nf_name>): Ditto.
11616 (x86_shrd_ndd<nf_name>): Ditto.
11617 (x86_shrd_1<nf_name>): Ditto.
11618 (x86_shrd_ndd_1<nf_name>): Ditto.
11619 (*x86_shrd_shld_1_nozext_nf): Ditto.
11621 2024-06-03 Lingling Kong <lingling.kong@intel.com>
11623 * config/i386/i386.md (ashr<mode>3_cvt<nf_name>): New
11625 (*<insn><mode>3_1<nf_name>): Ditto.
11627 2024-06-03 Lingling Kong <lingling.kong@intel.com>
11629 * config/i386/i386.md (*ashr<mode>3_1<nf_name>): New
11631 (*lshr<mode>3_1<nf_name>): Ditto.
11632 (*lshrqi3_1<nf_name>): Ditto.
11633 (*lshrhi3_1<nf_name>): Ditto.
11635 2024-06-03 Lingling Kong <lingling.kong@intel.com>
11637 * config/i386/i386.md (*ashl<mode>3_1<nf_name>): New
11639 (*ashlhi3_1<nf_name>): Ditto.
11640 (*ashlqi3_1<nf_name>): Ditto.
11641 * config/i386/sse.md: New define_split.
11643 2024-06-03 Lingling Kong <lingling.kong@intel.com>
11645 * config/i386/i386.md (nf_nonf_attr): New subst_attr.
11646 (nf_nonf_x64_attr): Ditto.
11647 (*sub<mode>_1<nf_name>): New define_insn.
11648 (*anddi_1<nf_name>): Ditto.
11649 (*and<mode>_1<nf_name>): Ditto.
11650 (*andqi_1<nf_name>): Ditto.
11651 (*<code><mode>_1<nf_name>): Ditto.
11652 (*<code>qi_1<nf_name>): Ditto.
11653 (*neg<mode>_1<nf_name>): Ditto.
11654 * config/i386/sse.md: New define_split.
11656 2024-06-03 Lingling Kong <lingling.kong@intel.com>
11657 Hongyu Wong <hongyu.wang@intel.com>
11659 * config/i386/i386-opts.h (enum apx_features): Add nf
11661 * config/i386/i386.h (TARGET_APX_NF): New.
11662 * config/i386/i386.md (nf_name): New subst_att.
11663 (nf_prefix): Ditto.
11664 (nf_condition): Ditto.
11665 (nf_mem_constraint): Ditto.
11666 (nf_applied): Ditto.
11667 (nf_subst): Add new define_subst.
11668 (*add<mode>_1<nf_name>): New define_insn.
11669 (*addhi_1<nf_name>): Ditto.
11670 (*addqi_1<nf_name>): Diito.
11671 * config/i386/i386.opt: Add apx_nf enumeration.
11673 2024-06-03 Hu, Lin1 <lin1.hu@intel.com>
11676 * config/i386/sse.md
11677 (*kortest_cmp<mode>_setcc): New define_insn_and_split.
11678 (*kortest_cmp<mode>_jcc): Ditto.
11680 2024-06-01 Georg-Johann Lay <avr@gjlay.de>
11682 PR tree-optimization/115307
11683 * config/avr/avr.md (SFDF): New mode iterator.
11684 (isinf<mode>2) [sf, df]: New expanders.
11686 2024-06-01 Jeff Law <jlaw@ventanamicro.com>
11688 * config/riscv/riscv.cc (riscv_integer_op): Add new field.
11689 (riscv_build_integer_1): Initialize the new field.
11690 (riscv_built_integer): Recognize more cases where Zbkb's
11691 pack instruction is profitable.
11692 (riscv_move_integer): Loop over all the codes. If requested,
11693 save the current constant into a temporary. Generate pack
11694 for more cases using the saved constant.
11696 2024-06-01 Feng Xue <fxue@os.amperecomputing.com>
11698 * tree-vect-loop.cc (vect_is_emulated_mixed_dot_prod): Remove parameter
11699 loop_vinfo. Get input vectype from stmt_info instead of reduction PHI.
11700 (vect_model_reduction_cost): Remove loop_vinfo argument of call to
11701 vect_is_emulated_mixed_dot_prod.
11702 (vect_transform_reduction): Likewise.
11703 (vectorizable_reduction): Likewise, and bind input vectype to
11704 lane-reducing operation.
11706 2024-06-01 Feng Xue <fxue@os.amperecomputing.com>
11708 * tree-vect-loop.cc (vect_reduction_update_partial_vector_usage): New
11710 (vectorizable_reduction): Move partial vectorization checking code to
11711 vect_reduction_update_partial_vector_usage.
11713 2024-06-01 Feng Xue <fxue@os.amperecomputing.com>
11715 * tree-vectorizer.h (lane_reducing_op_p): New function.
11716 * tree-vect-slp.cc (vect_analyze_slp): Use new function
11717 lane_reducing_op_p to check statement code.
11718 * tree-vect-loop.cc (vect_transform_reduction): Likewise.
11719 (vectorizable_reduction): Likewise, and change name of a local
11720 variable that holds the result flag.
11722 2024-05-31 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
11724 * config/xtensa/xtensa-protos.h (xtensa_expand_call):
11725 Add the third argument as boolean.
11726 (xtensa_expand_epilogue): Remove the first argument.
11727 * config/xtensa/xtensa.cc (xtensa_expand_call):
11728 Add the third argument "sibcall_p", and modify in order to prepend
11729 "(use A0_REG)" to CALL_INSN_FUNCTION_USAGE if the argument is true.
11730 (xtensa_expand_epilogue): Remove the first argument "sibcall_p" and
11731 its conditional clause.
11732 * config/xtensa/xtensa.md (call, call_value, sibcall, sibcall_value):
11733 Append a boolean value to the argument of xtensa_expand_call()
11734 indicating whether it is sibling call or not.
11735 (epilogue): Remove the boolean argument from xtensa_expand_epilogue(),
11736 and then append emitting "(return)".
11737 (sibcall_epilogue): Remove the boolean argument from
11738 xtensa_expand_epilogue().
11740 2024-05-31 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
11742 * config/xtensa/predicates.md
11743 (subreg_HQI_lowpart_operator, xtensa_sminmax_operator):
11744 New operator predicates.
11745 * config/xtensa/xtensa-protos.h (xtensa_match_CLAMPS_imms_p):
11747 * config/xtensa/xtensa.cc (xtensa_match_CLAMPS_imms_p): Ditto.
11748 * config/xtensa/xtensa.md
11749 (*addsubx, *extzvsi-1bit_ashlsi3, *extzvsi-1bit_addsubx):
11750 Revise the output statements by conditional ternary operator rather
11751 than switch-case clause in order to avoid using gcc_unreachable().
11752 (xtensa_clamps): Reduce to a single pattern definition using the
11753 predicate added above.
11754 (Some split patterns to assist *masktrue_const_bitcmpl): Ditto.
11756 2024-05-31 Robin Dapp <rdapp@ventanamicro.com>
11758 * config/riscv/riscv-v.cc (expand_const_vector): Document.
11759 (shuffle_extract_and_slide1up_patterns): Remove.
11761 2024-05-31 Robin Dapp <rdapp@ventanamicro.com>
11763 * config/riscv/autovec.md (ctz<mode>2): New expander.
11764 (clz<mode>2): Ditto.
11765 * config/riscv/generic-vector-ooo.md: Add bitmanip ops to insn
11767 * config/riscv/vector-crypto.md: Add VLS modes to insns.
11768 * config/riscv/vector.md: Add bitmanip ops to mode_idx and other
11771 2024-05-31 Robin Dapp <rdapp@ventanamicro.com>
11773 * config/riscv/autovec-opt.md (*vandn_<mode>): New pattern.
11774 * config/riscv/vector.md: Add vandn to mode_idx.
11776 2024-05-31 Robin Dapp <rdapp@ventanamicro.com>
11778 * config/riscv/riscv-v.cc (expand_gather_scatter): Use vwsll if
11780 * config/riscv/vector-crypto.md: Remove mode from vwsll shift
11782 * config/riscv/vector.md: Add vwsll to mode iterator.
11784 2024-05-31 Robin Dapp <rdapp@ventanamicro.com>
11786 * config/riscv/autovec-opt.md (*vwsll_zext1_<mode>): New
11788 (*vwsll_zext2_<mode>): Ditto.
11789 (*vwsll_zext1_scalar_<mode>): Ditto.
11790 (*vwsll_zext1_trunc_<mode>): Ditto.
11791 (*vwsll_zext2_trunc_<mode>): Ditto.
11792 (*vwsll_zext1_trunc_scalar_<mode>): Ditto.
11793 * config/riscv/vector-crypto.md: Make pattern similar to other
11794 narrowing/widening patterns.
11796 2024-05-31 Robin Dapp <rdapp@ventanamicro.com>
11798 * config/riscv/vector.md: Split vwadd.wx/vwsub.wx pattern and
11799 add extended_scalar patterns.
11801 2024-05-31 Robin Dapp <rdapp@ventanamicro.com>
11804 * config/riscv/vector.md: Split vfw<insn>.wf pattern.
11806 2024-05-31 Qing Zhao <qing.zhao@oracle.com>
11808 * tree-object-size.cc (access_with_size_object_size): Use the type
11809 of the 6th argument for the type of the element.
11810 * internal-fn.cc (expand_ACCESS_WITH_SIZE): Update the comment with
11813 2024-05-31 Qing Zhao <qing.zhao@oracle.com>
11815 * tree-object-size.cc (access_with_size_object_size): New function.
11816 (call_object_size): Call the new function.
11818 2024-05-31 Qing Zhao <qing.zhao@oracle.com>
11820 * internal-fn.cc (expand_ACCESS_WITH_SIZE): New function.
11821 * internal-fn.def (ACCESS_WITH_SIZE): New internal function.
11822 * tree.cc (is_access_with_size_p): New function.
11823 (get_ref_from_access_with_size): New function.
11824 * tree.h (is_access_with_size_p): New prototype.
11825 (get_ref_from_access_with_size): New prototype.
11827 2024-05-31 Qing Zhao <qing.zhao@oracle.com>
11829 * doc/extend.texi: Document attribute counted_by.
11831 2024-05-31 Uros Bizjak <ubizjak@gmail.com>
11834 * config/alpha/alpha.md (<any_divmod:code>si3): Wrap DImode
11835 operands 3 and 4 with truncate:SI RTX.
11836 (*divmodsi_internal_er): Ditto for operands 1 and 2.
11837 (*divmodsi_internal_er_1): Ditto.
11838 (*divmodsi_internal): Ditto.
11839 * config/alpha/constraints.md ("b"): Correct register
11840 number in the description.
11842 2024-05-31 Thomas Schwinge <tschwinge@baylibre.com>
11844 * config/nvptx/nvptx.h: Configure global constructor, destructor
11847 2024-05-31 Richard Biener <rguenther@suse.de>
11849 PR tree-optimization/115278
11850 * tree-if-conv.cc (ifcvt_local_dce): Do not DSE volatile stores.
11852 2024-05-31 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11854 * config.gcc: Move ${target_min} from obsolete to unsupported
11857 2024-05-31 Andrew Pinski <quic_apinski@quicinc.com>
11860 * doc/invoke.texi (fstrub=disable): Fix opindex.
11861 (minline-memops-threshold): Fix opindex.
11862 (mcmodel=): Add opindex and fix them.
11863 * common.opt.urls: Regenerate.
11864 * config/aarch64/aarch64.opt.urls: Regenerate.
11865 * config/bpf/bpf.opt.urls: Regenerate.
11866 * config/i386/i386.opt.urls: Regenerate.
11867 * config/loongarch/loongarch.opt.urls: Regenerate.
11868 * config/nds32/nds32-elf.opt.urls: Regenerate.
11869 * config/nds32/nds32-linux.opt.urls: Regenerate.
11870 * config/or1k/or1k.opt.urls: Regenerate.
11871 * config/riscv/riscv.opt.urls: Regenerate.
11872 * config/rs6000/aix64.opt.urls: Regenerate.
11873 * config/rs6000/linux64.opt.urls: Regenerate.
11874 * config/sparc/sparc.opt.urls: Regenerate.
11876 2024-05-31 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
11878 * config/xtensa/xtensa-protos.h
11879 (xtensa_use_return_instruction_p): Remove.
11880 * config/xtensa/xtensa.cc
11881 (machine_function): Remove "epilogue_done" field.
11882 (xtensa_expand_epilogue): Remove "cfun->machine->epilogue_done" usage.
11883 (xtensa_use_return_instruction_p): Remove.
11884 * config/xtensa/xtensa.md ("return"):
11885 Replace calling "xtensa_use_return_instruction_p()" with inline code.
11887 2024-05-31 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
11889 * config/xtensa/xtensa.cc (xtensa_valid_move, constantpool_address_p,
11890 xtensa_tls_symbol_p, gen_int_relational, xtensa_emit_move_sequence,
11891 xtensa_copy_incoming_a7, xtensa_expand_block_move,
11892 xtensa_expand_nonlocal_goto, xtensa_emit_call,
11893 xtensa_legitimate_address_p, xtensa_legitimize_address,
11894 xtensa_tls_referenced_p, print_operand, print_operand_address,
11895 xtensa_output_literal):
11896 Replace RTX code comparisons with their predicate macros such as
11898 * config/xtensa/xtensa.h (CONSTANT_ADDRESS_P,
11899 LEGITIMATE_PIC_OPERAND_P): Ditto.
11900 * config/xtensa/xtensa.md (reload<mode>_literal, indirect_jump):
11903 2024-05-31 Martin Uecker <uecker@tugraz.at>
11905 PR tree-optimization/115157
11906 PR tree-optimization/115177
11907 * godump.cc (go_output_typedef): Use TYPE_MAIN_VARIANT instead
11910 2024-05-31 liuhongt <hongtao.liu@intel.com>
11912 * config/i386/emmintrin.h (__double_u): Rename from double_u.
11913 (_mm_load_sd): Replace double_u with __double_u.
11914 (_mm_store_sd): Ditto.
11915 (_mm_loadh_pd): Ditto.
11916 (_mm_loadl_pd): Ditto.
11917 * config/i386/xmmintrin.h (__float_u): Rename from float_u.
11918 (_mm_load_ss): Ditto.
11919 (_mm_store_ss): Ditto.
11921 2024-05-30 Uros Bizjak <ubizjak@gmail.com>
11924 * config/i386/i386.md (bswaphi2): Also enable for !TARGET_MOVBE.
11925 (*bswaphi2): New insn pattern.
11926 (bswaphisi2_lowpart): Rename from bswaphi_lowpart. Rewrite
11927 insn RTX to match the expected form of the combine pass.
11928 Remove rol{w} alternative and corresponding attributes.
11929 (bswsaphisi2_lowpart peephole2): New peephole2 pattern to
11930 conditionally convert bswaphisi2_lowpart to rotlhi3_1_slp.
11931 (bswapsi2): Update expander for rename.
11932 (rotlhi3_1_slp splitter): Conditionally split to bswaphi2.
11934 2024-05-30 Richard Sandiford <richard.sandiford@arm.com>
11936 PR rtl-optimization/115281
11937 * ira-conflicts.cc (go_through_subreg): Use the natural size of
11938 the inner mode rather than the outer mode.
11940 2024-05-30 Ajit Kumar Agarwal <aagarwa1@linux.ibm.com>
11942 * pair-fusion.h: Generic header code for load store pair fusion
11943 that can be shared across different architectures.
11944 * pair-fusion.cc: Generic source code implementation for
11945 load store pair fusion that can be shared across different architectures.
11946 * Makefile.in: Add new object file pair-fusion.o.
11947 * config/aarch64/aarch64-ldp-fusion.cc: Delete generic code and move it
11948 to pair-fusion.cc in the middle-end.
11949 * config/aarch64/t-aarch64: Add header file dependency on pair-fusion.h.
11950 Remove unnecessary header file dependency.
11952 2024-05-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11955 * config/sparc/sol2.h (GGC_QUIRE_SIZE): Define as 510.
11957 2024-05-30 David Malcolm <dmalcolm@redhat.com>
11959 * Makefile.in (OBJS-libcommon): Add text-art/tree-widget.o.
11960 * doc/analyzer.texi: Rewrite discussion of dumping state to
11961 cover the text_art::tree_widget-based dumps, with a more
11962 interesting example.
11963 * text-art/dump-widget-info.h: New file.
11964 * text-art/dump.h: New file.
11965 * text-art/selftests.cc (selftest::text_art_tests): Call
11966 text_art_tree_widget_cc_tests.
11967 * text-art/selftests.h (selftest::text_art_tree_widget_cc_tests):
11969 * text-art/theme.cc (ascii_theme::get_cppchar): Handle the various
11971 (unicode_theme::get_cppchar): Likewise.
11972 * text-art/theme.h (enum class theme::cell_kind): Add
11973 TREE_CHILD_NON_FINAL, TREE_CHILD_FINAL, TREE_X_CONNECTOR, and
11975 * text-art/tree-widget.cc: New file.
11976 * text-art/tree-widget.h: New file.
11978 2024-05-30 liuhongt <hongtao.liu@intel.com>
11980 * config/i386/sse.md (vcond_mask_<mode><mode>): New expander.
11982 2024-05-30 liuhongt <hongtao.liu@intel.com>
11984 PR tree-optimization/112325
11985 * tree-ssa-loop-ivcanon.cc (estimated_unrolled_size): Move the
11986 2 / 3 loop body size reduction to ..
11987 (try_unroll_loop_completely): .. here, add it for the check of
11988 body size shrink, and the check of comparison against
11989 param_max_completely_peeled_insns when
11990 (!cunrolli ||loop->inner).
11991 (canonicalize_loop_induction_variables): Add new parameter
11992 cunrolli and pass down.
11993 (tree_unroll_loops_completely_1): Ditto.
11994 (canonicalize_induction_variables): Pass cunrolli as false to
11995 canonicalize_loop_induction_variables.
11996 (tree_unroll_loops_completely): Set cunrolli to true at
11997 beginning and set it to false after CHANGED is true.
11999 2024-05-30 Alexandre Oliva <oliva@adacore.com>
12001 * doc/sourcebuild.texi (dg-additional-sources): Document
12002 newly-added support for target selectors, and implicit discard
12003 on non-linking tests that name the compiler output explicitly.
12005 2024-05-30 Jiawei <jiawei@iscas.ac.cn>
12007 * tree-ssa-pre.cc (create_component_ref_by_pieces_1): New conditions.
12009 2024-05-30 Hans-Peter Nilsson <hp@axis.com>
12012 2024-05-28 Hans-Peter Nilsson <hp@axis.com>
12014 * resource.cc: Include cfgrtl.h. Use BLOCK_FOR_INSN (insn)->index
12015 instead of calling find_basic_block (insn). Assert for not -1.
12016 (find_basic_block): Remove function.
12017 (init_resource_info): Call compute_bb_for_insn.
12018 (free_resource_info): Call free_bb_for_insn.
12020 2024-05-30 Hans-Peter Nilsson <hp@axis.com>
12023 2024-05-28 Hans-Peter Nilsson <hp@axis.com>
12025 * resource.cc (mark_target_live_regs): Remove redundant check for b
12026 being -1, after gcc_assert.
12028 2024-05-30 Hans-Peter Nilsson <hp@axis.com>
12031 2024-05-28 Hans-Peter Nilsson <hp@axis.com>
12033 * resource.cc (free_resource_info, clear_hashed_info_for_insn): Don't
12034 check for non-null target_hash_table and bb_ticks.
12035 (mark_target_live_regs): Ditto. Replace check for non-NULL result from
12036 BLOCK_FOR_INSN with a call to gcc_assert. Fold code conditioned on
12039 2024-05-29 YunQiang Su <syq@gcc.gnu.org>
12041 * config/mips/mips.cc(mips16_gp_pseudo_reg): Mark
12042 MIPS16_PIC_TEMP and MIPS_PROLOGUE_TEMP clobbered.
12043 (mips_emit_call_insn): Mark MIPS16_PIC_TEMP and
12044 MIPS_PROLOGUE_TEMP clobbered if MIPS16 and CALL_CLOBBERED_GP.
12046 2024-05-29 Andrew Pinski <quic_apinski@quicinc.com>
12048 PR tree-optimization/115224
12049 * generic-match-head.cc (bitwise_inverted_equal_p): Add `a ^ CST`
12051 * gimple-match-head.cc (gimple_bit_xor_cst): New declaration.
12052 (gimple_bitwise_inverted_equal_p): Add `a ^ CST` case.
12053 * match.pd (bit_xor_cst): New match.
12054 (maybe_bit_not): Add bit_xor_cst case.
12056 2024-05-29 Andrew Pinski <quic_apinski@quicinc.com>
12058 * match.pd (bit_not_with_nop): Unconditionalize.
12059 (maybe_cmp): Likewise.
12060 (maybe_bit_not): New match pattern.
12061 (`~X & X`): Use maybe_bit_not and add `:c` back.
12062 (`~x ^ x`/`~x | x`): Likewise.
12064 2024-05-29 Richard Sandiford <richard.sandiford@arm.com>
12067 * config/aarch64/aarch64-simd.md (aarch64_combinev16qi): Allow
12068 the split before reload.
12069 * config/aarch64/aarch64.cc (aarch64_split_combinev16qi): Generalize
12070 into a form that handles pseudo registers.
12072 2024-05-29 Feng Xue <fxue@os.amperecomputing.com>
12074 * tree-vect-loop.c : Removed.
12076 2024-05-29 Feng Xue <fxue@os.amperecomputing.com>
12078 * tree-vect-loop.cc (_loop_vec_info::_loop_vec_info): Move
12079 initialization of bbs to explicit construction code. Adjust the
12080 definition of nbbs.
12081 (update_epilogue_loop_vinfo): Update nbbs for epilog vinfo.
12082 * tree-vect-patterns.cc (vect_determine_precisions): Make
12083 loop_vec_info and bb_vec_info share same code.
12084 (vect_pattern_recog): Remove duplicated vect_pattern_recog_1 loop.
12085 * tree-vect-slp.cc (vect_get_and_check_slp_defs): Access to bbs[0]
12086 via base vec_info class.
12087 (_bb_vec_info::_bb_vec_info): Initialize bbs and nbbs using data
12088 fields of input auto_vec<> bbs.
12089 (vect_slp_region): Use access to nbbs to replace original
12091 (vect_schedule_slp_node): Access to bbs[0] via base vec_info class.
12092 * tree-vectorizer.cc (vec_info::vec_info): Add initialization of
12094 (vec_info::insert_seq_on_entry): Access to bbs[0] via base vec_info
12096 * tree-vectorizer.h (vec_info): Add new fields bbs and nbbs.
12097 (LOOP_VINFO_NBBS): New macro.
12098 (BB_VINFO_BBS): Rename BB_VINFO_BB to BB_VINFO_BBS.
12099 (BB_VINFO_NBBS): New macro.
12100 (_loop_vec_info): Remove field bbs.
12101 (_bb_vec_info): Rename field bbs.
12102 * tree-vect-loop.c: New file.
12104 2024-05-29 Jeff Law <jlaw@ventanamicro.com>
12106 * config/riscv/crypto.md (riscv_xpack_<X:mode>_<HX:mode>_2): Remove '*'
12107 allow it to be used via the gen_* interface.
12108 * config/riscv/riscv.cc (riscv_build_integer): Identify when Zbkb
12109 can be used to profitably synthesize repeating constants.
12110 (riscv_move_integer): Codegen changes to generate those Zbkb sequences.
12112 2024-05-29 Jason Merrill <jason@redhat.com>
12114 * doc/invoke.texi: Update module extension docs.
12116 2024-05-29 Tobias Burnus <tburnus@baylibre.com>
12118 * config/gcn/gcn-hsa.h (gcn_local_sym_hash): Fix typo.
12120 2024-05-29 Richard Biener <rguenther@suse.de>
12122 PR tree-optimization/115252
12123 * tree-vect-stmts.cc (get_group_load_store_type): Enhance
12124 detecting the number of cases where we can avoid accessing a gap
12125 during code generation.
12126 (vectorizable_load): Remove old half-vector peeling for gap
12127 avoidance which is now redundant. Add gap-aligned case where
12128 it's OK to access the gap. Add assert that we have peeling for
12129 gaps enabled when we access a gap.
12131 2024-05-29 Richard Biener <rguenther@suse.de>
12133 PR tree-optimization/114435
12134 * tree-predcom.cc (tree_predictive_commoning): Queue
12135 the next scalar cleanup sub-pipeline to be run when we
12138 2024-05-29 Hongyu Wang <hongyu.wang@intel.com>
12141 * config/i386/i386-options.cc (ix86_override_options_after_change):
12142 Remove call to ix86_default_align and
12143 ix86_recompute_optlev_based_flags.
12144 (ix86_option_override_internal): Call ix86_default_align and
12145 ix86_recompute_optlev_based_flags.
12147 2024-05-29 liuhongt <hongtao.liu@intel.com>
12149 * config/i386/i386.cc (ix86_avoid_jump_mispredicts): Change
12150 gen_pad to gen_max_skip_align.
12151 (ix86_align_loops): New function.
12152 (ix86_reorg): Call ix86_align_loops.
12153 * config/i386/i386.md (pad): Rename to ..
12154 (max_skip_align): .. this, and accept 2 operands for align and
12157 2024-05-29 Haochen Jiang <haochen.jiang@intel.com>
12159 * config/i386/x86-tune-costs.h (generic_cost): Change from
12162 2024-05-29 Andrew MacLeod <amacleod@redhat.com>
12164 * gimple-range-gori.cc (gori_on_edge): Always use static ranges
12165 from the specified range_query.
12166 * gimple-range-gori.h (gori_on_edge): Change prototype.
12167 * gimple-range.cc (dom_ranger::maybe_push_edge): Change arguments
12170 2024-05-29 Kewen Lin <linkw@linux.ibm.com>
12173 * config/rs6000/rs6000-logue.cc (rs6000_emit_epilogue): As
12174 EPILOGUE_TYPE_EH_RETURN would be passed as epilogue_type directly
12175 now, adjust the relevant handlings on it.
12176 * config/rs6000/rs6000.md (eh_return expander): Append by calling
12177 gen_eh_return_internal and emit_barrier.
12178 (eh_return_internal): New define_insn_and_split, call function
12179 rs6000_emit_epilogue with epilogue type EPILOGUE_TYPE_EH_RETURN.
12181 2024-05-28 liuhongt <hongtao.liu@intel.com>
12184 * config/i386/i386.cc (ix86_rtx_costs): Reduce cost of MEM (A
12185 + imm) to "cost of MEM (A)" + 1.
12187 2024-05-28 Andrew MacLeod <amacleod@redhat.com>
12189 * gimple-range.cc (dom_ranger::dom_ranger): Do not initialize m_out.
12190 (dom_ranger::maybe_push_edge): Use gori () rather than m_out.
12191 * gimple-range.h (dom_ranger::m_out): Remove.
12192 * tree-vrp.cc (remove_unreachable::remove_unreachable): Use a
12193 range-query ranther than a gimple_ranger.
12194 (remove_unreachable::remove): New.
12195 (remove_unreachable::m_ranger): Change to a range_query.
12196 (remove_unreachable::handle_early): If there is no dependency
12197 information, do nothing.
12198 (remove_unreachable::remove_and_update_globals): Do not update
12199 globals if there is no dependecy info to use.
12201 2024-05-28 Hans-Peter Nilsson <hp@axis.com>
12203 * resource.cc (free_resource_info, clear_hashed_info_for_insn): Don't
12204 check for non-null target_hash_table and bb_ticks.
12205 (mark_target_live_regs): Ditto. Replace check for non-NULL result from
12206 BLOCK_FOR_INSN with a call to gcc_assert. Fold code conditioned on
12209 2024-05-28 Hans-Peter Nilsson <hp@axis.com>
12211 * resource.cc (mark_target_live_regs): Remove redundant check for b
12212 being -1, after gcc_assert.
12214 2024-05-28 Hans-Peter Nilsson <hp@axis.com>
12216 * resource.cc: Include cfgrtl.h. Use BLOCK_FOR_INSN (insn)->index
12217 instead of calling find_basic_block (insn). Assert for not -1.
12218 (find_basic_block): Remove function.
12219 (init_resource_info): Call compute_bb_for_insn.
12220 (free_resource_info): Call free_bb_for_insn.
12222 2024-05-28 Hans-Peter Nilsson <hp@axis.com>
12224 PR rtl-optimization/115182
12225 * resource.cc (mark_target_live_regs): Don't look for
12226 unconditional branches after the target to improve on the
12228 (find_dead_or_set_registers): Remove unused function.
12230 2024-05-28 Uros Bizjak <ubizjak@gmail.com>
12232 * config/i386/sync.md (atomic_loaddi_fpu): Use movd/pextrd
12233 to move DImode value from XMM to GPR for TARGET_SSE4_1.
12234 (atomic_storedi_fpu): Use movd/pinsrd to move DImode value
12235 from GPR to XMM for TARGET_SSE4_1.
12237 2024-05-28 David Malcolm <dmalcolm@redhat.com>
12239 * diagnostic-color.cc: Define INCLUDE_VECTOR.
12240 Include "label-text.h" and "selftest.h".
12241 (struct color_cap): Replace with...
12242 (struct color_default): ...this, adding "m_" prefixes to fields
12243 and dropping "name_len" and "free_val" field.
12244 (color_dict): Convert to...
12245 (gcc_color_defaults): ...this, making const, dropping the trailing
12246 strlen and "false" from each entry.
12247 (class diagnostic_color_dict): New.
12248 (g_color_dict): New.
12249 (colorize_start): Reimplement in terms of g_color_dict.
12250 (diagnostic_color_dict::get_entry_by_name): New, based on
12252 (diagnostic_color_dict::get_start_by_name): Likewise.
12253 (diagnostic_color_dict::diagnostic_color_dict): New.
12254 (parse_gcc_colors): Reimplement, moving body...
12255 (diagnostic_color_dict::parse_envvar_value): ...here.
12256 (colorize_init): Lazily create g_color_dict.
12257 (selftest::test_empty_color_dict): New.
12258 (selftest::test_default_color_dict): New.
12259 (selftest::test_color_dict_envvar_parsing): New.
12260 (selftest::diagnostic_color_cc_tests): New.
12261 * selftest-run-tests.cc (selftest::run_tests): Call
12262 selftest::diagnostic_color_cc_tests.
12263 * selftest.h (selftest::diagnostic_color_cc_tests): New decl.
12265 2024-05-28 David Malcolm <dmalcolm@redhat.com>
12267 * function-tests.cc: Include "selftest-tree.h".
12268 * selftest-tree.h: New file.
12269 * selftest.h (make_fndecl): Move to selftest-tree.h.
12271 2024-05-28 David Malcolm <dmalcolm@redhat.com>
12273 * config/v850/v850.opt.urls: Regenerate, with fix.
12274 * config/vax/vax.opt.urls: Likewise.
12275 * regenerate-opt-urls.py (TARGET_SPECIFIC_PAGES): Fix transposed
12276 values for "vax" and "v850".
12278 2024-05-28 Andrew MacLeod <amacleod@redhat.com>
12280 PR tree-optimization/115221
12281 * gimple-range-fold.cc (range_of_ssa_name_with_loop_info): Do
12282 not invoke SCEV is range_query's do not match.
12284 2024-05-28 Andrew MacLeod <amacleod@redhat.com>
12286 * tree-ssa-strlen.cc (strlen_pass::strlen_pass): Add function
12287 pointer and initialize ptr_qry with current range_query.
12288 (strlen_pass::m_ranger): Remove.
12289 (printf_strlen_execute): Enable and disable ranger.
12291 2024-05-28 David Malcolm <dmalcolm@redhat.com>
12294 * diagnostic-path.h
12295 (simple_diagnostic_path::disable_event_localization): New.
12296 (simple_diagnostic_path::m_localize_events): New field.
12298 (simple_diagnostic_path::simple_diagnostic_path): Initialize
12300 (simple_diagnostic_path::add_event): Only localize fmt if
12301 m_localize_events is true.
12302 * tree-diagnostic-path.cc
12303 (test_diagnostic_path::test_diagnostic_path): Call
12304 disable_event_localization.
12306 2024-05-28 David Malcolm <dmalcolm@redhat.com>
12308 PR bootstrap/115167
12309 * Makefile.in (C_COMMON_OBJS): Add c-family/c-type-mismatch.o.
12310 * gcc-rich-location.cc
12311 (maybe_range_label_for_tree_type_mismatch::get_text): Move to
12312 c-family/c-type-mismatch.cc.
12313 (binary_op_rich_location::binary_op_rich_location): Likewise.
12314 (binary_op_rich_location::use_operator_loc_p): Likewise.
12315 * gcc-rich-location.h (class range_label_for_type_mismatch):
12317 (class maybe_range_label_for_tree_type_mismatch): Likewise.
12318 (class op_location_t): Likewise for forward decl.
12319 (class binary_op_rich_location): Likewise.
12321 2024-05-28 Lyut Nersisyan <lyut.nersisyan@gmail.com>
12323 * config/riscv/crypto.md: Add new combiner patterns to generate
12324 pack, packh, packw instrutions.
12325 * config/riscv/iterators.md (HX): New iterator for half X mode.
12326 * config/riscv/riscv.md (<optab>_shift_reverse<X:mode>): Tighten
12327 cases to avoid. Do not lose bits for XOR/IOR.
12329 2024-05-28 Feng Xue <fxue@os.amperecomputing.com>
12331 PR tree-optimization/115060
12332 * tree-vect-patterns.cc (vect_get_internal_def): Return statement for
12334 (vect_widened_op_tree): Call vect_get_internal_def instead of look_def
12335 to get statement information.
12336 (vect_recog_widen_abd_pattern): No need to call vect_stmt_to_vectorize.
12338 2024-05-28 Richard Biener <rguenther@suse.de>
12340 PR tree-optimization/115236
12341 * tree-ssa-structalias.cc (build_pred_graph): Properly
12342 handle *ANYTHING = X.
12343 (build_succ_graph): Likewise. Do not elide direct nodes
12344 from receiving from STOREDANYTHING.
12346 2024-05-28 Richard Biener <rguenther@suse.de>
12348 * tree-ssa-structalias.cc (find_func_aliases): Use
12349 get_constraint_for_address_of to build escape constraints
12350 for asm inputs and outputs.
12352 2024-05-28 Richard Biener <rguenther@suse.de>
12354 PR tree-optimization/115254
12355 * tree-vect-slp.cc (vect_build_slp_tree): Only account
12356 multi-lane SLP to limit.
12358 2024-05-28 Richard Biener <rguenther@suse.de>
12360 * tree-vect-loop.cc (get_initial_defs_for_reduction): Convert
12361 neutral op to the vector component type.
12363 2024-05-28 liuhongt <hongtao.liu@intel.com>
12365 * config/i386/sse.md
12366 (<avx512>_<complexopname>_<mode>_mask<round_name>): Align
12367 operands' predicate with corresponding expander.
12368 (<avx512>_<complexopname>_<mode><maskc_name><round_name>):
12371 2024-05-28 Xi Ruoyao <xry111@xry111.site>
12374 * config/loongarch/loongarch.cc
12375 (loongarch_expand_conditional_move): Guard REGNO with REG_P.
12377 2024-05-27 Andrew Pinski <quic_apinski@quicinc.com>
12379 PR tree-optimization/115238
12380 * generic-match-head.cc (bitwise_inverted_equal_p): Use
12381 uniform_integer_cst_p instead of checking INTEGER_CST.
12382 * gimple-match-head.cc (gimple_bitwise_inverted_equal_p): Likewise.
12384 2024-05-27 Gaius Mulley <gaiusmod2@gmail.com>
12386 * doc/gm2.texi: Replace all occurrences of xref
12387 {foo, , , gm2} with xref {foo}.
12389 2024-05-27 Richard Biener <rguenther@suse.de>
12391 * tree-ssa-structalias.cc (scc_visit): Mark the node we
12392 collapse to as being in a component.
12394 2024-05-27 Richard Biener <rguenther@suse.de>
12396 PR tree-optimization/115220
12397 PR tree-optimization/115226
12398 * tree-ssa-sink.cc (statement_sink_location): When ignoring
12399 paths to kills when sinking stores make sure the final
12400 sink location is still post-dominated by the original one.
12401 Otherwise we'd need to insert a PHI node to merge virtual operands.
12403 2024-05-27 TheShermanTanker <tanksherman27@gmail.com>
12405 * config/mingw/mingw32.h: Add new define for POSIX
12408 2024-05-27 Richard Biener <rguenther@suse.de>
12410 PR tree-optimization/115232
12411 * gimple-ssa-warn-access.cc (new_delete_mismatch_p): Handle
12412 failure to demangle gracefully.
12414 2024-05-27 Gerald Pfeifer <gerald@pfeifer.com>
12416 * doc/gm2.texi (What is GNU Modula-2): Move gcc.gnu.org links to
12418 (Other languages): Ditto. And fix casing of GCC.
12420 2024-05-27 Liao Shihua <shihua@iscas.ac.cn>
12422 * config/riscv/riscv.cc (riscv_rtx_costs): Add TARGET_ZMMUL.
12424 2024-05-27 Maciej W. Rozycki <macro@orcam.me.uk>
12426 * doc/invoke.texi (Option Summary): Add `-md', `-md-float', and
12427 `-mg-float' options. Reorder, matching VAX Options.
12428 (VAX Options): Reword the description of `-mg' option. Add
12429 `-md', `-md-float', and `-mg-float' options.
12431 2024-05-27 Abe Skolnik <abe_skolnik@yahoo.com>
12434 * config/vax/vax.opt (md, md-float, mg, mg-float): Correct
12437 2024-05-27 Lyut Nersisyan <lyut.nersisyan@gmail.com>
12439 * config/riscv/riscv.md (<optab>_shift_reverse<X:mode>): New pattern.
12441 2024-05-27 Levy Hsu <admin@levyhsu.com>
12442 H.J. Lu <hjl.tools@gmail.com>
12445 * config/i386/i386-expand.cc (expand_vec_perm_psrlw_psllw_por): Replace arithmatic shift
12446 gen_ashrv4hi3 with logic shift gen_lshrv4hi3.
12447 Replace gen_vlshrv8hi3 with gen_lshrv8hi3 and gen_vashlv8hi3 with gen_ashlv8hi3.
12449 2024-05-27 Pan Li <pan2.li@intel.com>
12451 * genmatch.cc (dt_node::gen_kids_1): Fix indenet mis-aligned.
12453 2024-05-26 Jeff Law <jlaw@ventanamicro.com>
12455 * config/riscv/riscv.cc (riscv_build_integer_one): Verify there
12456 are no bits left to set in the constant when generating bseti.
12457 (riscv_built_integer): Synthesize ~value and if it's cheap use it
12458 with a trailing xori with -1.
12460 2024-05-26 Gerald Pfeifer <gerald@pfeifer.com>
12462 * doc/extend.texi (Attribute Syntax): Use @samp{=} instead of @code{=}.
12463 (Extended Asm): Ditto.
12465 2024-05-26 Jeff Law <jlaw@ventanamicro.com>
12467 * config/riscv/riscv.cc (riscv_build_integer_1): Try generating
12468 a nearby simpler constant, then using a final addi to set low
12471 2024-05-26 Andrew MacLeod <amacleod@redhat.com>
12473 PR tree-optimization/115208
12474 * value-query.cc (range_query::create_gori): Confirm gori_map is NULL.
12475 (range_query::destroy_gori): Free gori_map if one was allocated.
12477 2024-05-25 Jeff Law <jlaw@ventanamicro.com>
12479 * simplify-rtx.cc (simplify_context::simplify_binary_operation_1): Handle
12480 more logical simplifications.
12482 2024-05-24 Jeff Law <jlaw@ventanamicro.com>
12484 * config/riscv/predicates.md (arith_operand_or_mode_mask): Renamed to..
12485 (arith_or_mode_mask_or_zbs_operand): New predicate.
12486 * config/riscv/riscv.md (and<mode>3): Update predicate for operand 2.
12487 * config/riscv/riscv.cc (riscv_build_integer_1): Use bclri to clear
12488 bits, particularly bits 31..63 when profitable to do so.
12490 2024-05-24 Richard Sandiford <richard.sandiford@arm.com>
12492 PR tree-optimization/115192
12493 * tree-data-ref.cc (create_intersect_range_checks): Take the
12494 alignment of the access sizes into account.
12496 2024-05-24 Gaius Mulley <gaiusmod2@gmail.com>
12498 * doc/gm2.texi: Replace all occurrences of xref {, , , gm2}
12499 with xref {, , , m2}.
12501 2024-05-24 Manolis Tsamis <manolis.tsamis@vrull.eu>
12503 * match.pd: Allow no-op view_convert between permutes.
12505 2024-05-24 Richard Biener <rguenther@suse.de>
12507 PR tree-optimization/115144
12508 * tree-ssa-sink.cc (do_not_sink): New function, split out
12510 (select_best_block): Here. First pick valid block to
12511 sink to. From that search for the best valid block,
12512 avoiding sinking across conditions to exceptional code.
12513 (sink_code_in_bb): When updating vuses of stores in
12514 paths we do not sink a store to make sure we didn't
12515 pick a dominating sink location.
12517 2024-05-24 Andrew Pinski <quic_apinski@quicinc.com>
12519 * tree-ssa-phiprop.cc (phiprop_insert_phi): Add
12520 dce_ssa_names argument. Add the phi's result to it.
12521 (propagate_with_phi): Add dce_ssa_names argument.
12522 Update call to phiprop_insert_phi.
12523 (pass_phiprop::execute): Update call to propagate_with_phi.
12524 Call simple_dce_from_worklist if there was a change.
12526 2024-05-24 Richard Biener <rguenther@suse.de>
12528 * tree-vect-slp.cc (vect_build_slp_instance): Do not split
12529 store dataref groups on loop SLP discovery failure but create
12530 a single SLP instance for the stores but branch to SLP sub-trees
12531 and merge with a series of VEC_PERM nodes.
12533 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12535 * gimple-range-edge.h (range_query::condexpr_adjust): Delete.
12536 * gimple-range-fold.cc (fold_using_range::range_of_range_op): Use
12538 (fold_using_range::range_of_address): Likewise.
12539 (fold_using_range::range_of_phi): Likewise.
12540 (fold_using_range::condexpr_adjust): Relocated from gori_compute.
12541 (fold_using_range::range_of_cond_expr): Use local condexpr_adjust.
12542 (fur_source::register_outgoing_edges): Use gori_ssa routine.
12543 * gimple-range-fold.h (gori_ssa): Rename from gori_bb.
12544 (fold_using_range::condexpr_adjust): Add prototype.
12545 * gimple-range-gori.cc (gori_compute::condexpr_adjust): Relocate.
12546 * gimple-range-gori.h (gori_compute::condexpr_adjust): Delete.
12548 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12550 * gimple-range-cache.cc (ranger_cache::ranger_cache): Use gori_ssa.
12551 (ranger_cache::dump): Likewise.
12552 (ranger_cache::get_global_range): Likewise.
12553 (ranger_cache::set_global_range): Likewise.
12554 (ranger_cache::register_inferred_value): Likewise.
12555 * gimple-range-edge.h (gimple_outgoing_range::map): Remove.
12556 * gimple-range-fold.cc (fold_using_range::range_of_range_op): Use
12558 (fold_using_range::range_of_address): Likewise.
12559 (fold_using_range::range_of_phi): Likewise.
12560 (fur_source::register_outgoing_edges): Likewise.
12561 * gimple-range-fold.h (fur_source::query): Make const.
12563 * gimple-range-gori.cc (gori_map::dump): Use 'this' pointer.
12564 (gori_compute::gori_compute): Construct with a gori_map.
12565 * gimple-range-gori.h (gori_compute:gori_compute): Change
12567 (gori_compute::map): Delete.
12568 (gori_compute::m_map): Change to a reference.
12569 (FOR_EACH_GORI_IMPORT_NAME): Change parameter gori to gorimap.
12570 (FOR_EACH_GORI_EXPORT_NAME): Likewise.
12571 * gimple-range-path.cc (path_range_query::compute_ranges_in_block):
12572 Use gori_ssa method.
12573 (path_range_query::compute_exit_dependencies): Likewise.
12574 * gimple-range.cc (gimple_ranger::range_of_stmt): Likewise.
12575 (gimple_ranger::register_transitive_inferred_ranges): Likewise.
12576 * tree-ssa-dom.cc (set_global_ranges_from_unreachable_edges):
12578 * tree-ssa-threadedge.cc (compute_exit_dependencies): Likewise.
12579 * tree-vrp.cc (remove_unreachable::handle_early): Likewise.
12580 (remove_unreachable::remove_and_update_globals): Likewise.
12581 * value-query.cc (range_query::create_gori): Create gori map.
12582 (range_query::share_query): Copy gori map member.
12583 (range_query::range_query): Initiialize gori_map member.
12584 * value-query.h (range_query::gori_ssa): New.
12585 (range_query::m_map): New.
12587 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12589 * gimple-range-cache.cc (ranger_cache::ranger_cache): Create
12590 GORi via the range_query instead of a local member.
12591 (ranger_cache::dump_bb): Use gori via from the range_query parent.
12592 (ranger_cache::get_global_range): Likewise.
12593 (ranger_cache::set_global_range): Likewise.
12594 (ranger_cache::edge_range): Likewise.
12595 (anger_cache::block_range): Likewise.
12596 (ranger_cache::fill_block_cache): Likewise.
12597 (ranger_cache::range_from_dom): Likewise.
12598 (ranger_cache::register_inferred_value): Likewise.
12599 * gimple-range-cache.h (ranger_cache::m_gori): Delete.
12600 * gimple-range-fold.cc (fur_source::fur_source): Set m_depend_p.
12601 (fur_depend::fur_depend): Remove gori parameter.
12602 * gimple-range-fold.h (fur_source::gori): Adjust.
12603 (fur_source::m_gori): Delete.
12604 (fur_source::m_depend): New.
12605 (fur_depend::fur_depend): Adjust prototype.
12606 * gimple-range-path.cc (path_range_query::path_range_query): Share
12608 (path_range_query::range_defined_in_block): Use oracle directly.
12609 (path_range_query::compute_ranges_in_block): Use new gori() method.
12610 (path_range_query::adjust_for_non_null_uses): Use oracle directly.
12611 (path_range_query::compute_exit_dependencies): Likewise.
12612 (jt_fur_source::jt_fur_source): No gori in the parameters.
12613 (path_range_query::range_of_stmt): Likewise.
12614 (path_range_query::compute_outgoing_relations): Likewise.
12615 * gimple-range.cc (gimple_ranger::fold_range_internal): Likewise.
12616 (gimple_ranger::range_of_stmt): Access gori via gori () method.
12617 (assume_query::range_of_expr): Create a gori object.
12618 (assume_query::~assume_query): Destroy a gori object.
12619 (assume_query::calculate_op): Remove old gori() accessor.
12620 * gimple-range.h (gimple_ranger::gori): Delete.
12621 (assume_query::~assume_query): New.
12622 (assume_query::m_gori): Delete.
12623 * tree-ssa-dom.cc (set_global_ranges_from_unreachable_edges): use
12625 * tree-ssa-threadedge.cc (compute_exit_dependencies): Likewise.
12626 * value-query.cc (default_gori): New.
12627 (range_query::create_gori): New.
12628 (range_query::destroy_gori): New.
12629 (range_query::share_oracles): Set m_gori.
12630 (range_query::range_query): Set m_gori to default.
12631 (range_query::~range_query): call destroy gori.
12632 * value-query.h (range_query): Adjust prototypes
12633 (range_query::m_gori): New.
12635 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12637 * gimple-range-cache.cc (ranger_cache::ranger_cache): Adjust
12638 m_gori constructor.
12639 (ranger_cache::edge_range): Use renamed edge_range_p name.
12640 (ranger_cache::range_from_dom): Likewise.
12641 * gimple-range-edge.h (gimple_outgoing_range::condexpr_adjust): New.
12642 (gimple_outgoing_range::has_edge_range_p): New.
12643 (gimple_outgoing_range::dump): New.
12644 (gimple_outgoing_range::compute_operand_range): New.
12645 (gimple_outgoing_range::map): New.
12646 * gimple-range-fold.cc (fur_source::register_outgoing_edges ): Use
12647 renamed edge_range_p routine
12648 * gimple-range-gori.cc (gori_compute::gori_compute): Adjust
12650 (gori_compute::~gori_compute): New.
12651 (gori_compute::edge_range_p): Rename from outgoing_edge_range_p
12652 and use inherited routine instead of member method.
12653 * gimple-range-gori.h (class gori_compute): Inherit from
12654 gimple_outgoing_range, adjust protoypes.
12655 (gori_compute::outgpoing): Delete.
12656 * gimple-range-path.cc (path_range_query::compute_ranges_in_block): Use
12657 renamed edge_range_p routine.
12658 * tree-ssa-loop-unswitch.cc (evaluate_control_stmt_using_entry_checks):
12661 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12663 * gimple-range-cache.cc (ranger_cache::ranger_cache): Access
12664 gori_map via member call.
12665 (ranger_cache::dump_bb): Likewise.
12666 (ranger_cache::get_global_range): Likewise.
12667 (ranger_cache::set_global_range): Likewise.
12668 (ranger_cache::register_inferred_value): Likewise.
12669 * gimple-range-fold.cc (fold_using_range::range_of_range_op): Likewise.
12670 (fold_using_range::range_of_address): Likewise.
12671 (fold_using_range::range_of_phi): Likewise.
12672 * gimple-range-gori.cc (gori_compute::compute_operand_range_switch):
12674 (gori_compute::compute_operand_range): Likewise.
12675 (gori_compute::compute_logical_operands): Likewise.
12676 (gori_compute::refine_using_relation): Likewise.
12677 (gori_compute::compute_operand1_and_operand2_range): Likewise.
12678 (gori_compute::may_recompute_p): Likewise.
12679 (gori_compute::has_edge_range_p): Likewise.
12680 (gori_compute::outgoing_edge_range_p): Likewise.
12681 (gori_compute::condexpr_adjust): Likewise.
12682 * gimple-range-gori.h (class gori_compute): Do not inherit from
12684 (gori_compute::m_map): New.
12685 * gimple-range-path.cc (gimple-range-path.cc): Use gori_map member.
12686 (path_range_query::compute_exit_dependencies): Likewise.
12687 * gimple-range.cc (gimple_ranger::range_of_stmt): Likewise.
12688 (gimple_ranger::register_transitive_inferred_ranges): Likewise.
12689 * tree-ssa-dom.cc (set_global_ranges_from_unreachable_edges): Likewise.
12690 * tree-ssa-threadedge.cc (compute_exit_dependencies): Likewise.
12691 * tree-vrp.cc (remove_unreachable::handle_early): Likewise.
12692 (remove_unreachable::remove_and_update_globals): Likewise.
12694 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12696 * gimple-range-edge.cc (gimple_outgoing_range::gimple_outgoing_range):
12697 Do not allocate a range allocator at construction time.
12698 (gimple_outgoing_range::~gimple_outgoing_range): Delete allocator
12699 if one was allocated.
12700 (gimple_outgoing_range::set_switch_limit): New.
12701 (gimple_outgoing_range::switch_edge_range): Create an allocator if one
12703 (gimple_outgoing_range::edge_range_p): Check for zero edges.
12704 * gimple-range-edge.h (class gimple_outgoing_range): Adjust prototypes.
12706 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12708 PR tree-optimization/113879
12709 * gimple-range-fold.cc (op1_range): New.
12711 * gimple-range-fold.h (op1_range): New prototypes.
12712 (op2_range): New prototypes.
12713 * gimple-range-infer.cc (gimple_infer_range::add_range): Do not
12714 add an inferred range if it is VARYING.
12715 (gimple_infer_range::gimple_infer_range): Add inferred ranges
12716 for any range-op statements if requested.
12717 * gimple-range-infer.h (gimple_infer_range): Add parameter.
12719 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12721 * gimple-range-cache.cc (ranger_cache::ranger_cache): Create an infer
12722 oracle instead of a local member.
12723 (ranger_cache::~ranger_cache): Destroy the oracle.
12724 (ranger_cache::edge_range): Use oracle.
12725 (ranger_cache::fill_block_cache): Likewise.
12726 (ranger_cache::range_from_dom): Likewise.
12727 (ranger_cache::apply_inferred_ranges): Likewise.
12728 * gimple-range-cache.h (ranger_cache::m_exit): Delete.
12729 * gimple-range-infer.cc (infer_oracle): New static object;
12730 (class infer_oracle): New.
12731 (non_null_wrapper::non_null_wrapper): New.
12732 (non_null_wrapper::add_nonzero): New.
12733 (non_null_wrapper::add_range): New.
12734 (non_null_loadstore): Use nonnull_wrapper.
12735 (gimple_infer_range::gimple_infer_range): New alternate constructor.
12736 (exit_range::stmt): New.
12737 (infer_range_manager::has_range_p): Combine seperate methods.
12738 (infer_range_manager::maybe_adjust_range): Adjust has_range_p call.
12739 (infer_range_manager::add_ranges): New.
12740 (infer_range_manager::add_range): Take stmt rather than BB.
12741 (infer_range_manager::add_nonzero): Adjust from BB to stmt.
12742 * gimple-range-infer.h (class gimple_infer_range): Adjust methods.
12743 (infer_range_oracle): New.
12744 (class infer_range_manager): Inherit from infer_range_oracle.
12746 * gimple-range-path.cc (path_range_query::range_defined_in_block): Use
12748 (path_range_query::adjust_for_non_null_uses): Likewise.
12749 * gimple-range.cc (gimple_ranger::range_on_edge): Likewise
12750 (gimple_ranger::register_transitive_inferred_ranges): Likewise.
12751 * value-query.cc (default_infer_oracle): New.
12752 (range_query::create_infer_oracle): New.
12753 (range_query::destroy_infer_oracle): New.
12754 (range_query::share_query): Copy infer pointer.
12755 (range_query::range_query): Initialize infer pointer.
12756 (range_query::~range_query): destroy infer object.
12757 * value-query.h (range_query::infer_oracle): New.
12758 (range_query::create_infer_oracle): New prototype.
12759 (range_query::destroy_infer_oracle): New prototype.
12760 (range_query::m_infer): New.
12762 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12764 * gimple-range.cc (gimple_ranger::gimple_ranger): Share the
12765 components from ranger_cache.
12766 (gimple_ranger::~gimple_ranger): Don't clear pointer.
12767 * value-query.cc (range_query::share_query): New.
12768 (range_query::range_query): Clear shared component flag.
12769 (range_query::~range_query): Don't free shared component copies.
12770 * value-query.h (share_query): New prototype.
12771 (m_shared_copy_p): New member.
12773 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12775 * gimple-range-cache.cc (ranger_cache::dump_bb): Use m_relation.
12776 (ranger_cache::fill_block_cache): Likewise
12777 * gimple-range-fold.cc (fur_stmt::get_phi_operand): Use new names.
12778 (fur_depend::register_relation): Likewise.
12779 (fold_using_range::range_of_phi): Likewise.
12780 * gimple-range-path.cc (path_range_query::path_range_query): Likewise.
12781 (path_range_query::~path_range_query): Likewise.
12782 (ath_range_query::compute_ranges): Likewise.
12783 (jt_fur_source::register_relation): Likewise.
12784 (jt_fur_source::query_relation): Likewise.
12785 (path_range_query::maybe_register_phi_relation): Likewise.
12786 * gimple-range-path.h (get_path_oracle): Likewise.
12787 * gimple-range.cc (gimple_ranger::gimple_ranger): Likewise.
12788 (gimple_ranger::~gimple_ranger): Likewise.
12789 * value-query.cc (range_query::create_relation_oracle): Likewise.
12790 (range_query::destroy_relation_oracle): Likewise.
12791 (range_query::share_oracles): Likewise.
12792 (range_query::range_query): Likewise.
12793 * value-query.h (value_query::relation): Rename from oracle.
12794 (m_relation): Rename from m_oracle.
12795 * value-relation.cc (relation_oracle::query): Rename from
12797 (equiv_oracle::query): Likewise.
12798 (equiv_oracle::record): Rename from register_relation.
12799 (relation_oracle::record): Likewise.
12800 (dom_oracle::record): Likewise.
12801 (dom_oracle::query): Rename from query_relation.
12802 (path_oracle::record): Rename from register_relation.
12803 (path_oracle::query): Rename from query_relation.
12804 * value-relation.h (*::record): Rename from register_relation.
12805 (*::query): Rename from query_relation.
12807 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12809 * gimple-range-cache.cc (ranger_cache::dump_bb): Remove check for
12810 NULL oracle pointer.
12811 (ranger_cache::fill_block_cache): Likewise.
12812 * gimple-range-fold.cc (fur_stmt::get_phi_operand): Likewise.
12813 (fur_depend::fur_depend): Likewise.
12814 (fur_depend::register_relation): Likewise, use qury_relation.
12815 (fold_using_range::range_of_phi): Likewise.
12816 (fold_using_range::relation_fold_and_or): Likewise.
12817 * gimple-range-fold.h (fur_source::m_oracle): Delete. Oracle
12818 can be accessed dirctly via m_query now.
12819 * gimple-range-path.cc (path_range_query::path_range_query):
12820 Adjust for oracle reference pointer.
12821 (path_range_query::compute_ranges): Likewise.
12822 (jt_fur_source::jt_fur_source): Adjust for no m_oracle member.
12823 (jt_fur_source::register_relation): Do not check for NULL
12825 (jt_fur_source::query_relation): Likewise.
12826 * gimple-range.cc (gimple_ranger::gimple_ranger): Adjust for
12828 * value-query.cc (default_relation_oracle): New.
12829 (range_query::create_relation_oracle): Relocate from header.
12830 Ensure not being added to global query.
12831 (range_query::destroy_relation_oracle): Relocate from header.
12832 (range_query::range_query): Initailize to default oracle.
12833 (ange_query::~range_query): Call destroy_relation_oracle.
12834 * value-query.h (class range_query): Adjust prototypes.
12835 (range_query::create_relation_oracle): Move to source file.
12836 (range_query::destroy_relation_oracle): Move to source file.
12837 * value-relation.cc (relation_oracle::validate_relation): Delete.
12838 (relation_oracle::register_stmt): Rename to register_relation.
12839 (relation_oracle::register_edge): Likewise.
12840 * value-relation.h (register_stmt): Rename to register_relation and
12841 provide default function in base class.
12842 (register_edge): Likewise.
12843 (relation_oracle::validate_relation): Delete.
12844 (relation_oracle::query_relation): Provide default in base class.
12845 (relation_oracle::dump): Likewise.
12846 (relation_oracle::equiv_set): Likewise.
12847 (default_relation_oracle): New extenal reference.
12848 (partial_equiv_set, add_partial_equiv): Move to protected.
12850 2024-05-23 Andrew MacLeod <amacleod@redhat.com>
12852 * gimple-range-cache.cc (ranger_cache::ranger_cache): Call
12853 create_relation_oracle.
12854 (ranger_cache::~ranger_cache): Call destroy_relation_oracle.
12855 * gimple-range-fold.cc (fur_stmt::get_phi_operand): Check for
12856 relation oracle bnefore calling query_relation.
12857 (fold_using_range::range_of_phi): Likewise.
12858 * gimple-range-path.cc (path_range_query::~path_range_query): Set
12859 relation oracle pointer to NULL when done.
12860 * gimple-range.cc (gimple_ranger::~gimple_ranger): Likewise.
12861 * value-query.cc (range_query::~range_query): Ensure any
12862 relation oracle is destroyed.
12863 (range_query::query_relation): relocate to relation_oracle object.
12864 * value-query.h (class range_query): Adjust method proototypes.
12865 (range_query::create_relation_oracle): New.
12866 (range_query::destroy_relation_oracle): New.
12867 * value-relation.cc (relation_oracle::query_relation): Relocate
12868 from range query class.
12869 * value-relation.h (Call relation_oracle): New prototypes.
12871 2024-05-23 Pan Li <pan2.li@intel.com>
12873 * generic-match-head.cc (types_match): Add overloaded types_match
12875 * gimple-match-head.cc (types_match): Ditto.
12876 * match.pd: Leverage overloaded types_match.
12878 2024-05-23 Richard Biener <rguenther@suse.de>
12880 PR tree-optimization/115197
12881 * tree-loop-distribution.cc (copy_loop_before): Constant PHI
12882 args remain the same.
12884 2024-05-23 Richard Biener <rguenther@suse.de>
12886 PR tree-optimization/115199
12887 * tree-ssa-structalias.cc (process_constraint): Also
12888 record &ANYTHING = X as *ANYTING = X in the end.
12890 2024-05-23 Richard Biener <rguenther@suse.de>
12892 PR tree-optimization/115138
12893 * tree-ssa-alias.cc (ptrs_compare_unequal): Make sure
12894 pt.vars_contains_nonlocal differs since we do not represent
12895 FUNCTION_DECLs or LABEL_DECLs in vars explicitly.
12897 2024-05-23 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
12900 * config/s390/s390.cc (TARGET_NOCE_CONVERSION_PROFITABLE_P):
12902 (s390_noce_conversion_profitable_p): Implement.
12904 2024-05-23 Aldy Hernandez <aldyh@redhat.com>
12906 PR tree-optimization/115191
12907 * tree-ssa-phiopt.cc (value_replacement): Use Value_Range instead
12910 2024-05-23 Andrew Pinski <quic_apinski@quicinc.com>
12911 Joel Jones <quic_joeljone@quicinc.com>
12912 Wei Zhao <quic_wezhao@quicinc.com>
12914 * config/aarch64/aarch64-cores.def (oryon-1): New entry.
12915 * config/aarch64/aarch64-tune.md: Regenerate.
12916 * doc/invoke.texi (AArch64 Options): Document oryon-1.
12918 2024-05-22 Pengxuan Zheng <quic_pzheng@quicinc.com>
12921 * config/aarch64/aarch64-builtins.cc (AARCH64_SIMD_VGET_HIGH_BUILTINS):
12922 New macro to create definitions for all vget_high intrinsics.
12923 (VGET_HIGH_BUILTIN): Likewise.
12924 (enum aarch64_builtins): Add vget_high function codes.
12925 (AARCH64_SIMD_VGET_LOW_BUILTINS): Delete duplicate macro.
12926 (aarch64_general_fold_builtin): Fold vget_high calls.
12927 * config/aarch64/aarch64-simd-builtins.def: Delete vget_high builtins.
12928 * config/aarch64/aarch64-simd.md (aarch64_get_high<mode>): Delete.
12929 (aarch64_vget_hi_halfv8bf): Likewise.
12930 * config/aarch64/arm_neon.h (__attribute__): Delete.
12931 (vget_high_f16): Likewise.
12932 (vget_high_f32): Likewise.
12933 (vget_high_f64): Likewise.
12934 (vget_high_p8): Likewise.
12935 (vget_high_p16): Likewise.
12936 (vget_high_p64): Likewise.
12937 (vget_high_s8): Likewise.
12938 (vget_high_s16): Likewise.
12939 (vget_high_s32): Likewise.
12940 (vget_high_s64): Likewise.
12941 (vget_high_u8): Likewise.
12942 (vget_high_u16): Likewise.
12943 (vget_high_u32): Likewise.
12944 (vget_high_u64): Likewise.
12945 (vget_high_bf16): Likewise.
12947 2024-05-22 Eric Botcazou <ebotcazou@adacore.com>
12949 PR rtl-optimization/115038
12950 * fold-mem-offsets.cc (fold_offsets): Return 0 if the defining
12951 instruction of the register is frame related.
12953 2024-05-22 Roger Sayle <roger@nextmovesoftware.com>
12955 * config/i386/i386.cc (ix86_rtx_costs) <case CONST_INT>:
12956 A CONST_INT that isn't x86_64_immediate_operand requires an extra
12957 (expensive) movabsq insn to load, so return COSTS_N_INSNS (1) + 1.
12959 2024-05-22 Roger Sayle <roger@nextmovesoftware.com>
12961 * except.cc (output_function_exception_table): Move call to
12962 get_personality_function after targetm_common.except_unwind_info
12963 check, to avoid ICE on targets that don't support exceptions.
12965 2024-05-22 Richard Biener <rguenther@suse.de>
12967 * tree-vect-slp.cc (change_vec_perm_layout): Ignore an
12968 input partition of -1.
12970 2024-05-22 Richard Biener <rguenther@suse.de>
12972 * tree-vect-slp.cc (vect_schedule_slp_node): Avoid looking
12973 at SLP_REPRESENTATIVE for VEC_PERM nodes.
12975 2024-05-22 Richard Biener <rguenther@suse.de>
12977 * tree-vect-stmts.cc (vect_check_store_rhs): Look at *rhs
12978 only when it's a vec_constant_def.
12979 (vect_is_simple_use): When we have no representative for
12980 an internal node, fill in *op with error_mark_node.
12982 2024-05-22 Richard Biener <rguenther@suse.de>
12984 * doc/invoke.texi (C++ Modules): Fix typo.
12986 2024-05-22 Jakub Jelinek <jakub@redhat.com>
12988 PR tree-optimization/115152
12989 * tree-ssa-strlen.cc (strlen_pass::count_nonzero_bytes_addr): If
12990 !si->full_string_p, clear *nulterm and set maxlen to nbytes.
12992 2024-05-22 Jakub Jelinek <jakub@redhat.com>
12994 PR sanitizer/115172
12995 * ubsan.cc (instrument_bool_enum_load): If rhs is not in generic
12996 address space, use qualified version of utype with the right
12997 address space. Formatting fix.
12999 2024-05-22 Haochen Jiang <haochen.jiang@intel.com>
13002 * config/i386/i386-expand.cc (ix86_expand_vecop_qihi2):
13003 Do not enable the optimization when AVX512BW is not enabled.
13005 2024-05-21 Vineet Gupta <vineetg@rivosinc.com>
13007 * config/riscv/riscv.cc (riscv_expand_epilogue): Handle offset
13008 being sum of two S12.
13010 2024-05-21 Vineet Gupta <vineetg@rivosinc.com>
13013 * config/riscv/riscv.h: New macros for with aligned offsets.
13014 * config/riscv/riscv.cc (riscv_split_sum_of_two_s12): New
13015 function to split a sum of two s12 values into constituents.
13016 (riscv_expand_prologue): Handle offset being sum of two S12.
13017 (riscv_expand_epilogue): Ditto.
13018 * config/riscv/riscv-protos.h (riscv_split_sum_of_two_s12): New.
13020 2024-05-21 Andrew Pinski <quic_apinski@quicinc.com>
13022 PR tree-optimization/115154
13023 * match.pd (convert (mult zero_one_valued_p@1 INTEGER_CST@2)): Disable
13024 for 1bit signed types.
13026 2024-05-21 Richard Biener <rguenther@suse.de>
13028 PR tree-optimization/115137
13029 * tree-ssa-structalias.cc (pt_solution_includes_const_pool): NONLOCAL
13030 also includes constant pool entries.
13032 2024-05-21 Richard Sandiford <richard.sandiford@arm.com>
13034 * hard-reg-set.h (target_hard_regs::x_eh_return_data_regs): New field.
13035 (eh_return_data_regs): New macro.
13036 * reginfo.cc (init_reg_sets_1): Initialize x_eh_return_data_regs.
13037 * df-scan.cc (df_get_exit_block_use_set): Use it.
13038 * ira-lives.cc (process_out_of_region_eh_regs): Likewise.
13040 2024-05-21 Richard Biener <rguenther@suse.de>
13042 PR tree-optimization/115149
13043 * tree-ssa-live.cc (virtual_operand_live::get_live_in):
13044 Explicitly track the first processed edge.
13046 2024-05-21 liuhongt <hongtao.liu@intel.com>
13049 * config/i386/i386-expand.cc (expand_vec_perm_even_odd_pack):
13050 Use pblendw instead of pand to clear upper bits.
13052 2024-05-21 Kewen Lin <linkw@linux.ibm.com>
13054 * config/rs6000/rs6000.md (@ieee_128bit_vsx_neg<IEEE128>2): Remove
13055 the use of operands[3].
13056 (@ieee_128bit_vsx_neg<IEEE128>2): Likewise.
13057 (*ieee_128bit_vsx_nabs<mode>2): Likewise.
13059 2024-05-21 Kewen Lin <linkw@linux.ibm.com>
13061 * config/rs6000/rs6000.md (mode attribute rreg): Remove useless
13062 entries with modes TF, TD, V4SF and V2DF.
13064 2024-05-21 Kewen Lin <linkw@linux.ibm.com>
13066 * config/rs6000/vector.md (define_expand vector_load_<mode>): Remove.
13067 (vector_store_<mode>): Likewise.
13069 2024-05-21 Kewen Lin <linkw@linux.ibm.com>
13071 * config/rs6000/rs6000-call.cc (rs6000_darwin64_record_arg_recurse):
13072 Clean up TFmode and TDmode check with FLOAT128_2REG_P.
13074 2024-05-21 Kewen Lin <linkw@linux.ibm.com>
13076 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Remove
13077 useless check on TARGET_P8_VECTOR && !TARGET_ALTIVEC and add an
13078 assertion on !TARGET_VSX if !TARGET_ALTIVEC.
13080 2024-05-21 Kewen Lin <linkw@linux.ibm.com>
13083 * config/rs6000/rs6000.cc (rs6000_generate_compare): Make IEEE128
13084 handling without vsx go with libcall.
13086 2024-05-20 Andrew Pinski <quic_apinski@quicinc.com>
13088 PR tree-optimization/115143
13089 * tree-ssa-phiopt.cc (minmax_replacement): Check for empty
13090 phi nodes for middle bbs for the case where middle bb is not empty.
13092 2024-05-20 Pengxuan Zheng <quic_pzheng@quicinc.com>
13095 * config/aarch64/aarch64-builtins.cc (AARCH64_SIMD_VGET_LOW_BUILTINS):
13096 New macro to create definitions for all vget_low intrinsics.
13097 (VGET_LOW_BUILTIN): Likewise.
13098 (enum aarch64_builtins): Add vget_low function codes.
13099 (aarch64_general_fold_builtin): Fold vget_low calls.
13100 * config/aarch64/aarch64-simd-builtins.def: Delete vget_low builtins.
13101 * config/aarch64/aarch64-simd.md (aarch64_get_low<mode>): Delete.
13102 (aarch64_vget_lo_halfv8bf): Likewise.
13103 * config/aarch64/arm_neon.h (__attribute__): Delete.
13104 (vget_low_f16): Likewise.
13105 (vget_low_f32): Likewise.
13106 (vget_low_f64): Likewise.
13107 (vget_low_p8): Likewise.
13108 (vget_low_p16): Likewise.
13109 (vget_low_p64): Likewise.
13110 (vget_low_s8): Likewise.
13111 (vget_low_s16): Likewise.
13112 (vget_low_s32): Likewise.
13113 (vget_low_s64): Likewise.
13114 (vget_low_u8): Likewise.
13115 (vget_low_u16): Likewise.
13116 (vget_low_u32): Likewise.
13117 (vget_low_u64): Likewise.
13118 (vget_low_bf16): Likewise.
13120 2024-05-20 Wilco Dijkstra <wilco.dijkstra@arm.com>
13122 * config/aarch64/aarch64.cc (aarch64_rtx_costs): Improve CTZ costing.
13124 2024-05-20 Wilco Dijkstra <wilco.dijkstra@arm.com>
13126 * config/aarch64/aarch64.md (movsi_aarch64): Use '\;' to force
13127 newline in 2-instruction pattern.
13128 (movdi_aarch64): Likewise.
13130 2024-05-20 Ajit Kumar Agarwal <aagarwa1@linux.ibm.com>
13132 * config/aarch64/aarch64-ldp-fusion.cc: Rename generic parts of code
13133 to avoid "ldp" and "stp".
13135 2024-05-20 Mark Wielaard <mark@klomp.org>
13137 * config/riscv/riscv.opt.urls: Regenerate.
13138 * config/i386/i386.opt.urls: Likewise.
13140 2024-05-20 Ajit Kumar Agarwal <aagarwa1@linux.ibm.com>
13142 * config/aarch64/aarch64-ldp-fusion.cc: Factor out a
13143 target-independent interface and move it to the head of the file
13145 2024-05-20 YunQiang Su <syq@gcc.gnu.org>
13147 * config/mips/mips.cc(mips_option_override):
13148 Drop mips_lra_flag variable;
13149 (mips_lra_p): Removed.
13150 (TARGET_LRA_P): Remove definition here to use the default one.
13151 * config/mips/mips.md(*mul_acc_si, *mul_acc_si_r3900, *mul_sub_si):
13152 Drop mips_lra_flag variable.
13153 * config/mips/mips.opt(-mlra): Removed.
13154 * config/mips/mips.opt.urls(mlra): Removed.
13156 2024-05-20 Haochen Jiang <haochen.jiang@intel.com>
13158 * common/config/i386/cpuinfo.h
13159 (get_intel_cpu): Remove Xeon Phi cpus.
13160 (get_available_features): Remove Xeon Phi ISAs.
13161 * common/config/i386/i386-common.cc
13162 (OPTION_MASK_ISA_AVX512PF_SET): Removed.
13163 (OPTION_MASK_ISA_AVX512ER_SET): Ditto.
13164 (OPTION_MASK_ISA2_AVX5124FMAPS_SET): Ditto.
13165 (OPTION_MASK_ISA2_AVX5124VNNIW_SET): Ditto.
13166 (OPTION_MASK_ISA_PREFETCHWT1_SET): Ditto.
13167 (OPTION_MASK_ISA_AVX512F_UNSET): Remove AVX512PF and AVX512ER.
13168 (OPTION_MASK_ISA_AVX512PF_UNSET): Removed.
13169 (OPTION_MASK_ISA_AVX512ER_UNSET): Ditto.
13170 (OPTION_MASK_ISA2_AVX5124FMAPS_UNSET): Ditto.
13171 (OPTION_MASK_ISA2_AVX5124VNNIW_UNSET): Ditto.
13172 (OPTION_MASK_ISA_PREFETCHWT1_UNSET): Ditto.
13173 (OPTION_MASK_ISA2_AVX512F_UNSET): Remove AVX5124FMAPS and
13175 (ix86_handle_option): Remove Xeon Phi options.
13176 (processor_names): Remove Xeon Phi cpus.
13177 (processor_alias_table): Ditto.
13178 * common/config/i386/i386-cpuinfo.h
13179 (enum processor_types): Ditto.
13180 (enum processor_features): Remove Xeon Phi ISAs.
13181 * common/config/i386/i386-isas.h: Ditto.
13182 * config.gcc: Remove Xeon Phi cpus and ISAs.
13183 * config/i386/avx5124fmapsintrin.h: Remove intrin support.
13184 * config/i386/avx5124vnniwintrin.h: Ditto.
13185 * config/i386/avx512erintrin.h: Ditto.
13186 * config/i386/avx512pfintrin.h: Ditto.
13187 * config/i386/cpuid.h (bit_AVX512PF): Removed.
13188 (bit_AVX512ER): Ditto.
13189 (bit_PREFETCHWT1): Ditto.
13190 (bit_AVX5124VNNIW): Ditto.
13191 (bit_AVX5124FMAPS): Ditto.
13192 * config/i386/driver-i386.cc
13193 (host_detect_local_cpu): Remove Xeon Phi.
13194 * config/i386/i386-builtin-types.def: Remove unused types.
13195 * config/i386/i386-builtin.def (BDESC): Remove builtins.
13196 * config/i386/i386-builtins.cc (ix86_init_mmx_sse_builtins): Ditto.
13197 * config/i386/i386-c.cc (ix86_target_macros_internal): Remove Xeon
13199 * config/i386/i386-expand.cc (ix86_expand_builtin): Remove Xeon Phi
13201 (ix86_emit_swdivsf): Ditto.
13202 (ix86_emit_swsqrtsf): Ditto.
13203 * config/i386/i386-isa.def: Remove Xeon Phi ISAs.
13204 * config/i386/i386-options.cc (m_KNL): Removed.
13206 (isa2_opts): Remove Xeon Phi ISAs.
13208 (processor_cost_table): Remove Xeon Phi cpus.
13209 (ix86_valid_target_attribute_inner_p): Remove Xeon Phi ISAs.
13210 (ix86_option_override_internal): Remove Xeon Phi related handlers.
13211 * config/i386/i386-rust.cc (ix86_rust_target_cpu_info): Remove Xeon
13213 * config/i386/i386.cc (ix86_hard_regno_mode_ok): Remove Xeon Phi
13215 * config/i386/i386.h (TARGET_EMIT_VZEROUPPER): Removed.
13216 (enum processor_type): Remove Xeon Phi cpus.
13217 * config/i386/i386.md (prefetch): Remove PREFETCHWT1.
13218 (*prefetch_3dnow): Ditto.
13219 (*prefetch_prefetchwt1): Removed.
13220 * config/i386/i386.opt: Remove Xeon Phi ISAs.
13221 * config/i386/immintrin.h: Ditto.
13222 * config/i386/sse.md (VF1_AVX512ER_128_256): Removed.
13223 (rsqrt<mode>2): Change iterator from VF1_AVX512ER_128_256 to
13225 (GATHER_SCATTER_SF_MEM_MODE): Removed.
13226 (avx512pf_gatherpf<mode>sf): Ditto.
13227 (*avx512pf_gatherpf<VI48_512:mode>sf_mask): Ditto.
13228 (avx512pf_gatherpf<mode>df): Ditto.
13229 (*avx512pf_gatherpf<VI4_256_8_512:mode>df_mask): Ditto.
13230 (avx512pf_scatterpf<mode>sf): Ditto.
13231 (*avx512pf_scatterpf<VI48_512:mode>sf_mask): Ditto.
13232 (avx512pf_scatterpf<mode>df): Ditto.
13233 (*avx512pf_scatterpf<VI4_256_8_512:mode>df_mask): Ditto.
13234 (exp2<mode>2): Ditto.
13235 (avx512er_exp2<mode><mask_name><round_saeonly_name>): Ditto.
13236 (<mask_codefor>avx512er_rcp28<mode><mask_name><round_saeonly_name>):
13238 (avx512er_vmrcp28<mode><mask_name><round_saeonly_name>): Ditto.
13239 (<mask_codefor>avx512er_rsqrt28<mode><mask_name><round_saeonly_name>):
13241 (avx512er_vmrsqrt28<mode><mask_name><round_saeonly_name>): Ditto.
13243 (imod4_narrow): Ditto.
13244 (mov<mode>): Ditto.
13245 (*mov<mode>_internal): Ditto.
13246 (avx5124fmaddps_4fmaddps): Ditto.
13247 (avx5124fmaddps_4fmaddps_mask): Ditto.
13248 (avx5124fmaddps_4fmaddps_maskz): Ditto.
13249 (avx5124fmaddps_4fmaddss): Ditto.
13250 (avx5124fmaddps_4fmaddss_mask): Ditto.
13251 (avx5124fmaddps_4fmaddss_maskz): Ditto.
13252 (avx5124fmaddps_4fnmaddps): Ditto.
13253 (avx5124fmaddps_4fnmaddps_mask): Ditto.
13254 (avx5124fmaddps_4fnmaddps_maskz): Ditto.
13255 (avx5124fmaddps_4fnmaddss): Ditto.
13256 (avx5124fmaddps_4fnmaddss_mask): Ditto.
13257 (avx5124fmaddps_4fnmaddss_maskz): Ditto.
13258 (avx5124vnniw_vp4dpwssd): Ditto.
13259 (avx5124vnniw_vp4dpwssd_mask): Ditto.
13260 (avx5124vnniw_vp4dpwssd_maskz): Ditto.
13261 (avx5124vnniw_vp4dpwssds): Ditto.
13262 (avx5124vnniw_vp4dpwssds_mask): Ditto.
13263 (avx5124vnniw_vp4dpwssds_maskz): Ditto.
13264 * config/i386/x86-tune-sched.cc (ix86_issue_rate): Remove Xeon Phi cpus.
13265 (ix86_adjust_cost): Ditto.
13266 * config/i386/x86-tune.def (X86_TUNE_SCHEDULE): Ditto.
13267 (X86_TUNE_PARTIAL_REG_DEPENDENCY): Ditto.
13268 (X86_TUNE_MOVX): Ditto.
13269 (X86_TUNE_MEMORY_MISMATCH_STALL): Ditto.
13270 (X86_TUNE_ACCUMULATE_OUTGOING_ARGS): Ditto.
13271 (X86_TUNE_FOUR_JUMP_LIMIT): Ditto.
13272 (X86_TUNE_USE_INCDEC): Ditto.
13273 (X86_TUNE_INTEGER_DFMODE_MOVES): Ditto.
13274 (X86_TUNE_OPT_AGU): Ditto.
13275 (X86_TUNE_AVOID_LEA_FOR_ADDR): Ditto.
13276 (X86_TUNE_AVOID_MEM_OPND_FOR_CMOVE): Ditto.
13277 (X86_TUNE_USE_SAHF): Ditto.
13278 (X86_TUNE_USE_CLTD): Ditto.
13279 (X86_TUNE_USE_BT): Ditto.
13280 (X86_TUNE_ONE_IF_CONV_INSN): Ditto.
13281 (X86_TUNE_EXPAND_ABS): Ditto.
13282 (X86_TUNE_USE_SIMODE_FIOP): Ditto.
13283 (X86_TUNE_EXT_80387_CONSTANTS): Ditto.
13284 (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL): Ditto.
13285 (X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Ditto.
13286 (X86_TUNE_SPLIT_MEM_OPND_FOR_FP_CONVERTS): Ditto.
13287 (X86_TUNE_SLOW_PSHUFB): Ditto.
13288 (X86_TUNE_EMIT_VZEROUPPER): Removed.
13289 * config/i386/xmmintrin.h (enum _mm_hint): Remove _MM_HINT_ET1.
13290 * doc/extend.texi: Remove Xeon Phi.
13291 * doc/invoke.texi: Ditto.
13293 2024-05-20 Pan Li <pan2.li@intel.com>
13295 * dse.cc (get_stored_val): Make sure read_mode/write_mode
13296 is valid subreg before gen_lowpart.
13298 2024-05-19 Jeff Law <jlaw@ventanamicro.com>
13301 * config/riscv/riscv.cc (mem_shadd_or_shadd_rtx_p): Make sure
13302 shifted argument is a register.
13304 2024-05-19 Eric Botcazou <ebotcazou@adacore.com>
13306 * optabs-query.cc (can_mult_highpart_p): Test for the existence of
13307 a wider mode instead of requiring it.
13309 2024-05-19 Roger Sayle <roger@nextmovesoftware.com>
13311 * config/nvptx/nvptx.md (popcount<mode>2): Split into...
13312 (popcountsi2): define_insn handling SImode popcount.
13313 (popcountdi2): define_insn handling DImode popcount, with an
13314 explicit truncate:SI to produce an SImode result.
13316 2024-05-18 Palmer Dabbelt <palmer@rivosinc.com>
13318 * config/riscv/riscv.opt: Add -mno-fence-tso.
13319 * config/riscv/sync-rvwmo.md (mem_thread_fence_rvwmo): Respect
13321 * doc/invoke.texi (RISC-V): Document -mno-fence-tso.
13323 2024-05-18 Jeff Law <jlaw@ventanamicro.com>
13325 * config/riscv/riscv.md: Add new patterns to allow selection
13326 between (x << C1) + C2 vs (x + C2') << C1 depending on the
13329 2024-05-18 Xiao Zeng <zengxiao@eswincomputing.com>
13331 * config/riscv/riscv.cc (riscv_legitimize_move): Optimize movbf
13332 with Nan-boxing value.
13333 * config/riscv/riscv.md (*movhf_softfloat_boxing): Expand movbf
13334 with Nan-boxing value.
13335 (*mov<HFBF:mode>_softfloat_boxing): Ditto.
13336 with Nan-boxing value.
13337 (*movbf_softfloat_boxing): Delete abandon pattern.
13339 2024-05-18 Xiao Zeng <zengxiao@eswincomputing.com>
13341 * config/riscv/riscv-builtins.cc (riscv_init_builtin_types):
13342 Modify _Bfloat16 to __bf16.
13343 * config/riscv/riscv.cc (riscv_mangle_type): Ditto.
13345 2024-05-18 Pan Li <pan2.li@intel.com>
13349 * config/riscv/autovec.md (usadd<mode>3): New pattern expand for
13350 the unsigned SAT_ADD in vector mode.
13351 * config/riscv/riscv-protos.h (riscv_expand_usadd): New func decl
13352 to expand usadd<mode>3 pattern.
13353 (expand_vec_usadd): Ditto but for vector.
13354 * config/riscv/riscv-v.cc (emit_vec_saddu): New func impl to emit
13356 (expand_vec_usadd): New func impl to expand usadd<mode>3 for vector.
13357 * config/riscv/riscv.cc (riscv_expand_usadd): New func impl to
13358 expand usadd<mode>3 for scalar.
13359 * config/riscv/riscv.md (usadd<mode>3): New pattern expand for
13360 the unsigned SAT_ADD in scalar mode.
13361 * config/riscv/vector.md: Allow VLS mode for vsaddu.
13363 2024-05-17 David Malcolm <dmalcolm@redhat.com>
13365 * common.opt.urls: Regenerate to add
13366 fdiagnostics-show-event-links.
13368 2024-05-17 Robin Dapp <rdapp@ventanamicro.com>
13370 * config/riscv/riscv-protos.h (struct common_vector_cost): Add
13371 segment_permute cost.
13372 * config/riscv/riscv-vector-costs.cc (costs::adjust_stmt_cost):
13373 Handle segment loads/stores.
13374 * config/riscv/riscv.cc: Initialize segment_permute_[2-8] to 1.
13376 2024-05-17 Robin Dapp <rdapp@ventanamicro.com>
13378 PR middle-end/113474
13379 * internal-fn.cc (expand_vec_cond_mask_optab_fn): Remove
13382 2024-05-17 Tom Tromey <tromey@adacore.com>
13384 * dwarf2out.cc (gen_namespace_die): Use DW_TAG_module for Ada.
13386 2024-05-17 David Malcolm <dmalcolm@redhat.com>
13388 * common.opt (fdiagnostics-show-event-links): New option.
13389 * diagnostic-label-effects.h: New file.
13390 * diagnostic-path.h (diagnostic_event::connect_to_next_event_p):
13391 New pure virtual function.
13392 (simple_diagnostic_event::connect_to_next_event_p): Implement it.
13393 (simple_diagnostic_event::connect_to_next_event): New.
13394 (simple_diagnostic_event::m_connected_to_next_event): New field.
13395 (simple_diagnostic_path::connect_to_next_event): New decl.
13396 * diagnostic-show-locus.cc: Include "text-art/theme.h" and
13397 "diagnostic-label-effects.h".
13398 (colorizer::set_cfg_edge): New.
13399 (layout::m_fallback_theme): New field.
13400 (layout::m_theme): New field.
13401 (layout::m_effect_info): New field.
13402 (layout::m_link_lhs_state): New enum and field.
13403 (layout::m_link_rhs_column): New field.
13404 (layout_range::has_in_edge): New.
13405 (layout_range::has_out_edge): New.
13406 (layout::layout): Add "effect_info" optional param. Initialize
13407 m_theme, m_link_lhs_state, and m_link_rhs_column.
13408 (layout::maybe_add_location_range): Remove stray "FIXME" from
13410 (layout::print_source_line): Replace space after margin with a
13411 call to print_leftmost_column.
13412 (layout::print_leftmost_column): New.
13413 (layout::start_annotation_line): Make non-const. Gain
13414 responsibility for printing the leftmost column after the margin.
13415 (layout::print_annotation_line): Drop pp_space, as this is now
13416 added by start_annotation_line.
13417 (line_label::line_label): Add "has_in_edge" and "has_out_edge"
13418 params and initialize...
13419 (line_label::m_has_in_edge): New field.
13420 (line_label::m_has_out_edge): New field.
13421 (layout::print_any_labels): Pass edge information to line_label
13422 ctor. Keep track of in-edges and out-edges, adding visualizations
13423 of these links between labels.
13424 (layout::print_leading_fixits): Drop pp_character, as this is now
13425 added by start_annotation_line.
13426 (layout::print_trailing_fixits): Fix off-by-one errors in column
13428 (layout::move_to_column): Add comment about debugging.
13429 (layout::show_ruler): Make non-const. Drop pp_space calls, as
13430 this is now added by start_annotation_line.
13431 (layout::print_line): Call print_any_right_to_left_edge_lines.
13432 (layout::print_any_right_to_left_edge_lines): New.
13433 (layout::update_any_effects): New.
13434 (gcc_rich_location::add_location_if_nearby): Initialize
13436 (diagnostic_context::maybe_show_locus): Add "effects" param and
13437 pass it to diagnostic_context::show_locus.
13438 (diagnostic_context::show_locus): Add "effects" param, passing it
13439 to layout's ctor. Call update_any_effects on the layout after
13440 printing the lines.
13441 (selftest::test_layout_x_offset_display_utf8): Update expected
13442 result for eliminated trailing newline.
13443 (selftest::test_layout_x_offset_display_utf8): Likewise.
13444 (selftest::test_layout_x_offset_display_tab): Likewise.
13445 * diagnostic.cc (diagnostic_context::initialize): Initialize
13446 m_source_printing.show_event_links_p.
13447 (simple_diagnostic_path::connect_to_next_event): New.
13448 (simple_diagnostic_event::simple_diagnostic_event): Initialize
13449 m_connected_to_next_event.
13450 * diagnostic.h (class diagnostic_source_effect_info): New forward
13452 (diagnostic_source_printing_options::show_event_links_p): New
13454 (diagnostic_context::maybe_show_locus): Add optional "effect_info"
13456 (diagnostic_context::show_locus): Add "effect_info" param.
13457 (diagnostic_show_locus): Add optional "effect_info" param.
13458 * doc/invoke.texi: Add -fno-diagnostics-show-event-links.
13459 * lto-wrapper.cc (merge_and_complain): Add
13460 OPT_fdiagnostics_show_event_links to switch.
13461 (append_compiler_options): Likewise.
13462 (append_diag_options): Likewise.
13463 * opts-common.cc (decode_cmdline_options_to_array): Add
13464 "-fno-diagnostics-show-event-links" to -fdiagnostics-plain-output.
13465 * opts.cc (common_handle_option): Add case for
13466 OPT_fdiagnostics_show_event_links.
13467 * text-art/theme.cc (ascii_theme::get_cppchar): Handle
13469 (unicode_theme::get_cppchar): Likewise.
13470 * text-art/theme.h (theme::cell_kind): Add CFG_*.
13471 * toplev.cc (general_init): Initialize
13472 global_dc->m_source_printing.show_event_links_p.
13473 * tree-diagnostic-path.cc: Define INCLUDE_ALGORITHM,
13474 INCLUDE_MEMORY, and INCLUDE_STRING. Include
13475 "diagnostic-label-effects.h".
13476 (path_label::path_label): Initialize m_effects.
13477 (path_label::get_effects): New.
13478 (class path_label::path_label_effects): New.
13479 (path_label::m_effects): New field.
13480 (class per_thread_summary): Add "friend struct event_range;".
13481 (per_thread_summary::per_thread_summary): Initialize m_last_event.
13482 (per_thread_summary::m_last_event): New field.
13483 (struct event_range::per_source_line_info): New.
13484 (event_range::event_range): Make "t" non-const. Add
13485 "show_event_links" param and use it to initialize
13486 m_show_event_links. Add info for initial event.
13487 (event_range::get_per_source_line_info): New.
13488 (event_range::maybe_add_event): Verify compatibility of the new
13489 label and existing labels with respect to the link-printing code.
13490 Update per-source-line info when an event is added.
13491 (event_range::print): Add"effect_info" param and pass to
13492 diagnostic_show_locus.
13493 (event_range::m_per_thread_summary): Make non-const.
13494 (event_range::m_source_line_info_map): New field.
13495 (event_range::m_show_event_links): New field.
13496 (path_summary::path_summary): Add "show_event_links" optional
13497 param, passing it to event_range ctor calls. Update
13499 (thread_event_printer::print_swimlane_for_event_range): Add
13500 "effect_info" param and pass it to range->print.
13501 (print_path_summary_as_text): Keep track of the column for any
13502 out-edges at the end of printing each event_range and use as
13503 the leading in-edge for the next event_range.
13504 (default_tree_diagnostic_path_printer): Pass in show_event_links_p
13505 to path_summary ctor.
13506 (selftest::path_events_have_column_data_p): New.
13507 (class selftest::control_flow_test): New.
13508 (selftest::test_control_flow_1): New.
13509 (selftest::test_control_flow_2): New.
13510 (selftest::test_control_flow_3): New.
13511 (selftest::assert_cfg_edge_path_streq): New.
13512 (ASSERT_CFG_EDGE_PATH_STREQ): New macro.
13513 (selftest::test_control_flow_4): New.
13514 (selftest::test_control_flow_5): New.
13515 (selftest::test_control_flow_6): New.
13516 (selftest::control_flow_tests): New.
13517 (selftest::tree_diagnostic_path_cc_tests): Disable colorization on
13518 global_dc's printer. Convert event_pp to a std::unique_ptr. Call
13519 control_flow_tests via for_each_line_table_case.
13520 (gen_command_line_string): Likewise.
13522 2024-05-17 Uros Bizjak <ubizjak@gmail.com>
13524 PR middle-end/112600
13525 * config/i386/mmx.md (<insn><mode>3): New expander.
13526 * config/i386/sse.md
13527 (<sse2_avx2>_<sat_plusminus:insn><mode>3<mask_name>):
13528 Rename expander to <sat_plusminus:insn><mode>3<mask_name>.
13529 (<umaxmin:code><mode>3): Update for rename.
13530 * config/i386/i386-builtin.def: Update for rename.
13532 2024-05-17 Aldy Hernandez <aldyh@redhat.com>
13534 PR middle-end/115131
13535 * value-range.cc (prange::intersect): Set VARYING if intersection
13536 of bitmasks made the range span the entire domain.
13537 (range_tests_misc): New test.
13539 2024-05-17 Alexander Monakov <amonakov@ispras.ru>
13542 * tree-into-ssa.cc (prune_unused_phi_nodes): Add dfs_out entries
13543 to the 'defs' array in the reverse order.
13545 2024-05-17 Aldy Hernandez <aldyh@redhat.com>
13547 PR middle-end/115128
13548 * ipa-cp.cc (ipa_value_range_from_jfunc): Check for undefined_p
13549 before looking at type.
13550 (propagate_vr_across_jump_function): Same.
13552 2024-05-17 Richard Biener <rguenther@suse.de>
13554 PR middle-end/115110
13555 * tree-ssa-alias.cc (view_converted_memref_p): Fix.
13557 2024-05-17 Eric Botcazou <ebotcazou@adacore.com>
13559 * expmed.h (expmed_mult_highpart_optab): Declare.
13560 * expmed.cc (expmed_mult_highpart_optab): Remove static keyword.
13561 Do not assume that OP1 is a constant integer. Fix pasto.
13562 (expmed_mult_highpart): Pass OP1 narrowed to MODE in all the calls
13563 to expmed_mult_highpart_optab.
13564 * optabs-query.cc (can_mult_highpart_p): Use 2 for integer widening
13565 and shift subsequent values accordingly.
13566 * optabs.cc (expand_mult_highpart): Call expmed_mult_highpart_optab
13567 when can_mult_highpart_p returns 2 and adjust to above change.
13569 2024-05-17 Richard Biener <rguenther@suse.de>
13571 * tree-ssa-alias.h (pt_solution_includes_const_pool): Declare.
13572 * tree-ssa-alias.cc (ptrs_compare_unequal): Use
13573 pt_solution_includes_const_pool.
13574 * tree-ssa-structalias.cc (pt_solution_includes_const_pool): New.
13576 2024-05-17 Alexandre Oliva <oliva@adacore.com>
13578 * common.opt (freg-struct-return): Make it explicitly
13579 fpcc-struct-return's NegativeAlias. Copy Optimization...
13580 (freg-struct-return): ... here.
13582 2024-05-17 Pan Li <pan2.li@intel.com>
13584 * config/riscv/.riscv.cc.swo: Removed.
13585 * config/riscv/j: Removed.
13587 2024-05-16 Pan Li <pan2.li@intel.com>
13589 * config/riscv/autovec-opt.md(*vcond_mask_len_popcount_<VB_VLS:mode><P:mode>):
13590 New pattern of vcond_mask_len_popcount for vector bool mode.
13591 * config/riscv/autovec.md (vcond_mask_len_<mode>): New pattern of
13592 vcond_mask_len for vector bool mode.
13593 (cbranch<mode>4): New pattern for vector bool mode.
13594 * config/riscv/vector-iterators.md: Add new unspec UNSPEC_SELECT_MASK.
13595 * config/riscv/vector.md (@pred_popcount<VB:mode><P:mode>): Add VLS mode
13596 to popcount pattern.
13597 (@pred_popcount<VB_VLS:mode><P:mode>): Ditto.
13599 2024-05-16 Jan Hubicka <jh@suse.cz>
13602 * ipa-fnsummary.cc (points_to_local_or_readonly_memory_p): Do not
13603 look into TARGET_MEM_REFS with constant opreand 0.
13605 2024-05-16 Richard Biener <rguenther@suse.de>
13607 PR tree-optimization/13962
13608 PR tree-optimization/96564
13609 * tree-ssa-alias.h (pt_solution::const_pool): New flag.
13610 * tree-ssa-alias.cc (ptrs_compare_unequal): Handle pointer-pointer
13612 (dump_points_to_solution): Dump the const_pool flag, fix guard
13614 * gimple-pretty-print.cc (pp_points_to_solution): Likewise.
13615 * tree-ssa-structalias.cc (find_what_var_points_to): Set
13616 the const_pool flag for STRING.
13617 (pt_solution_ior_into): Handle the const_pool flag.
13618 (ipa_escaped_pt): Initialize it.
13620 2024-05-16 Richard Biener <rguenther@suse.de>
13622 * tree-ssa-structalias.cc (get_constraint_for_1): For
13623 volatile referenced or decls use ANYTHING.
13625 2024-05-16 Pan Li <pan2.li@intel.com>
13627 * tree-vect-loop.cc (vect_gen_loop_len_mask): New func to gen
13629 * tree-vect-stmts.cc (vectorizable_early_exit): Invoke the
13630 vect_gen_loop_len_mask for 1 or more stmt(s).
13631 * tree-vectorizer.h (vect_gen_loop_len_mask): New func decl
13632 for vect_gen_loop_len_mask.
13634 2024-05-16 Pan Li <pan2.li@intel.com>
13638 * tree-vect-patterns.cc (gimple_unsigned_integer_sat_add): New
13639 func decl generated by match.pd match.
13640 (vect_recog_sat_add_pattern): New func impl to recog the pattern
13641 for unsigned SAT_ADD.
13643 2024-05-16 Pan Li <pan2.li@intel.com>
13647 * internal-fn.cc (commutative_binary_fn_p): Add type IFN_SAT_ADD
13648 to the return true switch case(s).
13649 * internal-fn.def (SAT_ADD): Add new signed optab SAT_ADD.
13650 * match.pd: Add unsigned SAT_ADD match(es).
13651 * optabs.def (OPTAB_NL): Remove fixed-point limitation for
13653 * tree-ssa-math-opts.cc (gimple_unsigned_integer_sat_add): New
13654 extern func decl generated in match.pd match.
13655 (match_saturation_arith): New func impl to match the saturation arith.
13656 (math_opts_dom_walker::after_dom_children): Try match saturation
13657 arith when IOR expr.
13659 2024-05-16 Aldy Hernandez <aldyh@redhat.com>
13662 2024-05-10 Aldy Hernandez <aldyh@redhat.com>
13665 2024-05-08 Aldy Hernandez <aldyh@redhat.com>
13667 * gimple-range-cache.cc (sbr_sparse_bitmap::sbr_sparse_bitmap):
13668 Change irange to prange.
13669 * gimple-range-fold.cc (fold_using_range::fold_stmt): Same.
13670 (fold_using_range::range_of_address): Same.
13671 * gimple-range-fold.h (range_of_address): Same.
13672 * gimple-range-infer.cc (gimple_infer_range::add_nonzero): Same.
13673 * gimple-range-op.cc (class cfn_strlen): Same.
13674 * gimple-range-path.cc
13675 (path_range_query::adjust_for_non_null_uses): Same.
13676 * gimple-ssa-warn-access.cc (pass_waccess::check_pointer_uses): Same.
13677 * tree-ssa-structalias.cc (find_what_p_points_to): Same.
13678 * range-op-ptr.cc (range_op_table::initialize_pointer_ops): Remove
13679 hybrid entries in table.
13680 * range-op.cc (range_op_table::range_op_table): Add pointer
13681 entries for bitwise and/or and min/max.
13682 * value-range.cc (irange::verify_range): Add assert.
13683 * value-range.h (irange::varying_compatible_p): Remove check for
13685 (irange::supports_p): Remove pointer support.
13686 * ipa-cp.h (ipa_supports_p): Add prange support.
13688 2024-05-16 Aldy Hernandez <aldyh@redhat.com>
13690 PR tree-optimization/114985
13691 * gimple-range-op.cc: Remove pointers_handled_p.
13692 * ipa-cp.cc (ipa_value_range_from_jfunc): Skip range folding if
13693 operands don't match.
13694 (propagate_vr_across_jump_function): Same.
13695 * range-op-mixed.h: Remove pointers_handled_p and tweak
13697 * range-op-ptr.cc (range_operator::pointers_handled_p): Remove.
13698 (pointer_plus_operator::pointers_handled_p): Remove.
13699 (class operator_pointer_diff): Remove pointers_handled_p.
13700 (operator_pointer_diff::pointers_handled_p): Remove.
13701 (operator_identity::pointers_handled_p): Remove.
13702 (operator_cst::pointers_handled_p): Remove.
13703 (operator_cast::pointers_handled_p): Remove.
13704 (operator_min::pointers_handled_p): Remove.
13705 (operator_max::pointers_handled_p): Remove.
13706 (operator_addr_expr::pointers_handled_p): Remove.
13707 (operator_bitwise_and::pointers_handled_p): Remove.
13708 (operator_bitwise_or::pointers_handled_p): Remove.
13709 (operator_equal::pointers_handled_p): Remove.
13710 (operator_not_equal::pointers_handled_p): Remove.
13711 (operator_lt::pointers_handled_p): Remove.
13712 (operator_le::pointers_handled_p): Remove.
13713 (operator_gt::pointers_handled_p): Remove.
13714 (operator_ge::pointers_handled_p): Remove.
13715 * range-op.cc (TRAP_ON_UNHANDLED_POINTER_OPERATORS): Remove.
13716 (range_op_handler::lhs_op1_relation): Remove pointers_handled_p checks.
13717 (range_op_handler::lhs_op2_relation): Same.
13718 (range_op_handler::op1_op2_relation): Same.
13719 * range-op.h: Remove RO_* declarations.
13721 2024-05-16 Aldy Hernandez <aldyh@redhat.com>
13723 PR tree-optimization/114985
13724 * vr-values.cc (simplify_using_ranges::fold_cond_with_ops): Use
13725 boolean type when folding conditionals.
13727 2024-05-16 Richard Biener <rguenther@suse.de>
13729 PR tree-optimization/79958
13730 PR tree-optimization/109087
13731 PR tree-optimization/100314
13732 PR tree-optimization/114774
13733 * tree-ssa-dse.cc (dse_classify_store): New forwarder.
13734 (dse_classify_store): Add arguments cnt and visited, recurse
13735 to track multiple paths when we end up with multiple defs.
13737 2024-05-16 David Malcolm <dmalcolm@redhat.com>
13739 * text-art/theme.cc (ascii_theme::get_cppchar): Add
13740 cell_kind::INTERPROCEDURAL_*.
13741 (unicode_theme::get_cppchar): Likewise.
13742 * text-art/theme.h (theme::cell_kind): Likewise.
13743 * tree-diagnostic-path.cc:
13744 (thread_event_printer::print_swimlane_for_event_range): Use the
13745 above to get characters for indicating interprocedural stack
13746 depth activity, falling back to ascii.
13747 (selftest::test_interprocedural_path_1): Test with both ascii
13748 and unicode themes.
13749 (selftest::test_interprocedural_path_2): Likewise.
13750 (selftest::test_recursion): Likewise.
13752 2024-05-16 David Malcolm <dmalcolm@redhat.com>
13754 * tree-diagnostic-path.cc: Include "text-art/theme.h".
13755 (path_label::get_text): If the event has
13756 diagnostic_event::VERB_danger, and the theme enables emojis, then
13757 add a warning emoji between the event number and the event text.
13759 2024-05-16 David Malcolm <dmalcolm@redhat.com>
13761 * tree-diagnostic-path.cc (per_thread_summary::interprocedural_p):
13763 (thread_event_printer::print_swimlane_for_event_range): Don't
13764 indent and print the stack depth line if this thread's events are
13765 purely intraprocedural.
13766 (selftest::test_intraprocedural_path): Update expected output.
13768 2024-05-16 David Malcolm <dmalcolm@redhat.com>
13770 * diagnostic-path.h: Update leading comment to reflect
13771 intraprocedural cases. Fix typo in comment.
13772 * doc/invoke.texi: Update intraprocedural example.
13774 2024-05-16 David Malcolm <dmalcolm@redhat.com>
13776 * diagnostic-show-locus.cc: Define INCLUDE_VECTOR and include
13777 "text-art/types.h".
13778 (line_label::line_label): Drop "policy" argument. Use
13779 styled_string::calc_canvas_width when computing m_display_width,
13780 as this skips SGR codes.
13781 (layout::print_any_labels): Update for line_label ctor change.
13782 (selftest::test_one_liner_labels_utf8): Update expected text to
13783 reflect that the labels can fit on one line if we don't get
13784 confused by SGR colorization codes.
13786 2024-05-16 Xiao Zeng <zengxiao@eswincomputing.com>
13788 * common/config/riscv/riscv-common.cc:
13789 (riscv_implied_info): Add zvfbfwma item.
13790 (riscv_ext_version_table): Ditto.
13791 (riscv_ext_flag_table): Ditto.
13792 * config/riscv/riscv.opt:
13793 (MASK_ZVFBFWMA): New macro.
13794 (TARGET_ZVFBFWMA): Ditto.
13796 2024-05-16 liuhongt <hongtao.liu@intel.com>
13799 * config/i386/i386-expand.cc (ix86_expand_vecop_qihi_partial):
13800 Set d.one_operand_p to true when TARGET_SSSE3.
13802 2024-05-16 liuhongt <hongtao.liu@intel.com>
13805 * config/i386/i386-expand.cc
13806 (ix86_expand_vec_shift_qihi_constant): Optimize ashift >> 7 to
13808 (ix86_expand_vecop_qihi_partial): Ditto.
13810 2024-05-15 Jeff Law <jlaw@ventanamicro.com>
13812 * config/riscv/riscv-string.cc: Add missing hunk from last change.
13814 2024-05-15 Christoph Müllner <christoph.muellner@vrull.eu>
13816 * config/riscv/riscv-string.cc (emit_strcmp_scalar_load_and_compare):
13817 Use adjust_address() to calculate MEM-PLUS pattern.
13819 2024-05-15 Christoph Müllner <christoph.muellner@vrull.eu>
13821 * config/riscv/riscv-protos.h (riscv_expand_block_compare): New
13823 * config/riscv/riscv-string.cc (GEN_EMIT_HELPER2): New helper
13825 (do_load_from_addr): Add support for HI and SI/64 modes.
13826 (do_load): Add helper for zero-extended loads.
13827 (emit_memcmp_scalar_load_and_compare): New helper to emit memcmp.
13828 (emit_memcmp_scalar_result_calculation): Likewise.
13829 (riscv_expand_block_compare_scalar): Likewise.
13830 (riscv_expand_block_compare): New RISC-V expander for memory compare.
13831 * config/riscv/riscv.md (cmpmemsi): New cmpmem expansion.
13833 2024-05-15 Marek Polacek <polacek@redhat.com>
13838 * doc/invoke.texi: Update -Wextra-semi documentation.
13840 2024-05-15 Jakub Jelinek <jakub@redhat.com>
13842 PR rtl-optimization/114902
13843 PR rtl-optimization/115092
13844 * combine.cc (simplify_compare_const): Don't optimize
13845 GE op0 SIGNED_MIN or LT op0 SIGNED_MIN into NE op0 const0_rtx or
13848 2024-05-15 Richard Biener <rguenther@suse.de>
13850 PR tree-optimization/114589
13851 * tree-ssa-sink.cc (select_best_block): Remove profile-based
13852 heuristics. Instead reject sink locations that sink
13853 to post-dominators. Move empty latch check here from
13854 statement_sink_location. Also consider early_bb for the
13856 (statement_sink_location): Remove superfluous check. Remove
13858 (pass_sink_code::execute): Compute/release post-dominators.
13860 2024-05-15 Richard Biener <rguenther@suse.de>
13862 PR middle-end/111422
13863 * cfgexpand.cc (add_scope_conflicts_2): Handle PHIs
13864 by recursing to their arguments.
13866 2024-05-15 Wilco Dijkstra <wilco.dijkstra@arm.com>
13868 * config/aarch64/aarch64-simd.md (aarch64_combine_internal<mode>):
13869 Use UZP1 instead of INS.
13870 (aarch64_combine_internal_be<mode>): Likewise.
13872 2024-05-15 Jan Hubicka <jh@suse.cz>
13874 * alias.cc (reference_alias_ptr_type_1): Use view_converted_memref_p.
13875 * alias.h (view_converted_memref_p): Declare.
13876 * tree-ssa-alias.cc (view_converted_memref_p): Export.
13877 (ao_compare::compare_ao_refs): Use same_type_for_tbaa.
13879 2024-05-15 Christoph Müllner <christoph.muellner@vrull.eu>
13881 * config/riscv/riscv-string.cc (riscv_block_move_straight):
13882 Hand over up to 2xXLEN bytes to move_by_pieces().
13884 2024-05-15 Christoph Müllner <christoph.muellner@vrull.eu>
13886 * config/riscv/riscv-string.cc (riscv_block_move_straight): Add
13888 (riscv_adjust_block_mem): Replace parameter length by align.
13889 (riscv_block_move_loop): Add parameter align.
13890 (riscv_expand_block_move_scalar): Set alignment properly if the
13891 target has fast unaligned access.
13893 2024-05-15 Aldy Hernandez <aldyh@redhat.com>
13895 PR tree-optimization/114995
13896 * range-op-ptr.cc (range_operator::pointers_handled_p): Default to true.
13898 2024-05-15 Andrew Pinski <quic_apinski@quicinc.com>
13900 PR tree-optimization/114301
13901 * tree-cfg.cc (gimple_can_duplicate_bb_p): Check returns_twice
13902 only on the last call statement rather than all.
13904 2024-05-15 Jeff Law <jlaw@ventanamicro.com>
13906 * config/riscv/riscv-string.cc
13907 (riscv_expand_block_clear_zicboz_zic64b): Handle rv32 correctly.
13909 2024-05-15 Levy Hsu <admin@levyhsu.com>
13912 * config/i386/i386-expand.cc (expand_vec_perm_psrlw_psllw_por): New
13914 (ix86_expand_vec_perm_const_1): Call expand_vec_perm_psrlw_psllw_por.
13916 2024-05-15 Jeff Law <jlaw@ventanamicro.com>
13918 * config/riscv/riscv.md: Add pattern for sign extended shift-add
13919 sequence with a masked input.
13921 2024-05-14 Dimitar Dimitrov <dimitar@dinux.eu>
13923 PR rtl-optimization/115013
13924 * config/pru/pru.cc (pru_class_likely_spilled_p): Implement
13925 to mark classes containing one SImode register as likely
13927 (TARGET_CLASS_LIKELY_SPILLED_P): Define.
13929 2024-05-14 Vineet Gupta <vineetg@rivosinc.com>
13931 * config/riscv/riscv.h: New macros to check for sum of two S12
13933 * config/riscv/constraints.md: New constraint.
13934 * config/riscv/predicates.md: New Predicate.
13935 * config/riscv/riscv.md: New splitter.
13936 * config/riscv/riscv.cc (riscv_reg_frame_related): New helper.
13937 * config/riscv/riscv-protos.h: New helper prototype.
13939 2024-05-14 Richard Biener <rguenther@suse.de>
13941 PR tree-optimization/99954
13942 * tree-data-ref.cc (dr_may_alias_p): For bases that are
13943 not completely analyzed fall back to TBAA and points-to.
13944 * tree-loop-distribution.cc
13945 (loop_distribution::classify_builtin_ldst): When there
13946 is no dependence again classify as memcpy.
13947 * tree-ssa-alias.cc (ptr_deref_may_alias_decl_p): Verify
13948 the pointer is an SSA name.
13950 2024-05-14 Christoph Müllner <christoph.muellner@vrull.eu>
13952 * config/riscv/riscv-protos.h (riscv_expand_block_clear): New prototype.
13953 * config/riscv/riscv-string.cc (riscv_expand_block_clear_zicboz_zic64b):
13954 New function to expand a block-clear with cbo.zero.
13955 (riscv_expand_block_clear): New RISC-V block-clear expansion function.
13956 * config/riscv/riscv.md (setmem<mode>): New setmem expansion.
13958 2024-05-14 Christoph Müllner <christoph.muellner@vrull.eu>
13960 * expr.cc (clear_by_pieces): Remove static from clear_by_pieces.
13961 * expr.h (clear_by_pieces): Add prototype for clear_by_pieces.
13963 2024-05-14 Tom de Vries <tdevries@suse.de>
13966 * dwarf2out.cc (output_macinfo_op): Fix DW_MACRO_define_strx/strp
13967 choice for v4 .debug_macro.dwo. Add asserts to check that choice.
13969 2024-05-14 Jan Hubicka <jh@suse.cz>
13972 * ipa-inline.cc (enum can_inline_edge_by_limits_flags): New enum.
13973 (can_inline_edge_by_limits_p): Take flags instead of multiple bools; add flag
13974 for forcing inlinie limits.
13975 (can_early_inline_edge_p): Update.
13976 (want_inline_self_recursive_call_p): Update; use FORCE_LIMITS mode.
13977 (check_callers): Update.
13978 (update_caller_keys): Update.
13979 (update_callee_keys): Update.
13980 (recursive_inlining): Update.
13981 (add_new_edges_to_heap): Update.
13982 (speculation_useful_p): Update.
13983 (inline_small_functions): Clear DECL_DISREGARD_INLINE_LIMITS on self recursion.
13984 (flatten_function): Update.
13985 (inline_to_all_callers_1): Update.
13987 2024-05-14 Haochen Gui <guihaoc@gcc.gnu.org>
13989 * config/rs6000/rs6000.cc (TARGET_OVERLAP_OP_BY_PIECES_P): Define.
13991 2024-05-14 Jeff Law <jlaw@ventanamicro.com>
13994 2024-05-13 Sergei Lewis <slewis@rivosinc.com>
13996 * config/riscv/riscv.md (movmem<mode>): Use riscv_vector::expand_block_move,
13997 if and only if we know the entire operation can be performed using one vector
13998 load followed by one vector store
14000 2024-05-14 Pan Li <pan2.li@intel.com>
14002 * config/riscv/riscv-vector-builtins.cc
14003 (validate_instance_type_required_extensions): Remove the
14004 operator from the trailing and put it to new line.
14006 2024-05-13 Jeff Law <jlaw@ventanamicro.com>
14008 * config/riscv/bitmanip.md: Add new splitter for AND with
14009 a constant that masks off bits 32..63 and needs synthesis.
14011 2024-05-13 Sergei Lewis <slewis@rivosinc.com>
14013 * config/riscv/riscv.md (movmem<mode>): Use riscv_vector::expand_block_move,
14014 if and only if we know the entire operation can be performed using one vector
14015 load followed by one vector store
14017 2024-05-13 Vladimir N. Makarov <vmakarov@redhat.com>
14019 PR rtl-optimization/115013
14020 * lra-constraints.cc (process_alt_operands): Update all_used_nregs
14021 only for winreg. Ignore reg starvation for small reg classes.
14023 2024-05-13 Pan Li <pan2.li@intel.com>
14026 * config/riscv/riscv-vector-builtins.cc
14027 (validate_instance_type_required_extensions): New func impl to
14028 validate the intrinisc func type ops.
14029 (expand_builtin): Validate instance type before expand.
14031 2024-05-13 Jeff Law <jlaw@ventanamicro.com>
14033 * config/riscv/bitmanip.md (bextseqzdisi): New patterns.
14034 * config/riscv/.riscv.cc.swo: New file.
14035 * config/riscv/j: New file.
14037 2024-05-13 Richard Biener <rguenther@suse.de>
14039 PR tree-optimization/60276
14040 * tree-vect-stmts.cc (vectorizable_load): Do not exempt
14041 pure_slp grouped loads from the STMT_VINFO_MIN_NEG_DIST
14044 2024-05-13 Richard Biener <rguenther@suse.de>
14046 * tree-vect-slp.cc (vect_analyze_slp_instance): Remove
14047 slp_inst_kind_reduc_group handling.
14048 (vect_analyze_slp): Add the meat here.
14050 2024-05-13 Jakub Jelinek <jakub@redhat.com>
14052 PR middle-end/113982
14053 * tree-ssa-math-opts.cc (arith_overflow_check_p): Also return 1
14054 for RSHIFT_EXPR by precision of maxval if shift result is only
14055 used in a cast or comparison against zero.
14056 (match_arith_overflow): Handle the RSHIFT_EXPR use case.
14058 2024-05-13 YunQiang Su <syq@debian.org>
14061 2024-05-09 YunQiang Su <syq@gcc.gnu.org>
14063 * config/mips/constraints.md: Add new constraint 'w'.
14065 2024-05-12 Roger Sayle <roger@nextmovesoftware.com>
14066 Kyrill Tkachov <kyrylo.tkachov@foss.arm.com>
14068 * config/arm/arm.md (*arm_zeroextractsi2_8_8, *arm_signextractsi2_8_8,
14069 *arm_zeroextractsi2_8_16, *arm_signextractsi2_8_16,
14070 *arm_zeroextractsi2_16_8, *arm_signextractsi2_16_8): New.
14072 2024-05-12 Jeff Law <jlaw@ventanamicro.com>
14074 * config/riscv/riscv.cc (riscv_build_integer_1): Use slli.uw more.
14076 2024-05-12 Jeff Law <jlaw@ventanamicro.com>
14078 * config/riscv/riscv.cc (riscv_build_integer_1): Fix thinko in testing
14079 when lui can be used to set several bits in bseti path.
14081 2024-05-12 Mark Wielaard <mark@klomp.org>
14083 * config/mingw/cygming.opt.urls: Regenerate.
14084 * config/mingw/mingw.opt.urls: Likewise.
14086 2024-05-11 Mark Harmstone <mark@harmstone.com>
14088 * dwarf2codeview.cc (DEBUG_S_SYMBOLS): Define.
14089 (S_COMPILE3, CV_CFL_80386, CV_CFL_X64): Likewise.
14090 (CV_CFL_C, CV_CFL_CXX): Likewise.
14091 (SYMBOL_START_LABEL, SYMBOL_END_LABEL): Likewise.
14092 (start_processor, language_constant): New functions.
14093 (write_compile3_symbol, write_codeview_symbols): Likewise.
14094 (codeview_debug_finish): Call write_codeview_symbols.
14096 2024-05-11 Mark Harmstone <mark@harmstone.com>
14098 * dwarf2codeview.cc (DEBUG_S_LINES, LINE_LABEL): Define.
14099 (END_FUNC_LABEL): Likewise.
14100 (struct codeview_line, codeview_line_block): New structures.
14101 (codeview_function): Likewise.
14102 (line_label_num, func_label_num, funcs, last_func): New variables.
14103 (last_filename, last_file_id): Likewise.
14104 (codeview_source_line, write_line_numbers): New functions.
14105 (codeview_switch_text_section, codeview_end_epilogue): Likewise.
14106 (codeview_debug_finish): Call write_line_numbers.
14107 * dwarf2codeview.h (codeview_source_line): Prototype.
14108 (codeview_switch_text_secction, codeview_end_epilogue): Likewise.
14109 * dwarf2out.cc (dwarf2_end_epilogue): Add codeview support.
14110 (dwarf2out_switch_text_section): Likewise.
14111 (dwarf2out_source_line): Likewise.
14112 * opts.cc (finish_options): Handle codeview debugging symbols.
14114 2024-05-11 Mark Harmstone <mark@harmstone.com>
14116 * dwarf2codeview.cc (DEBUG_S_STRINGTABLE): Define.
14117 (DEBUG_S_FILECHKSMS, CHKSUM_TYPE_MD5, HASH_SIZE): Likewise.
14118 (codeview_string, codeview_source_file): New structures.
14119 (struct string_hasher): New class for codeview_string hashing.
14120 (files, last_file, num_files, string_offset): New variables.
14121 (strings_hstab, strings, last_string): Likewise.
14122 (add_string, codevie_start_source_file): New functions.
14123 (write_strings_tabe, write_soruce_files): Likewise.
14124 (codeview_debug_finish): Call new functions.
14125 * dwarf2codeview.h (codeview_start_source_file): Prototype.
14126 * dwarf2out.cc (dwarf2out_start_source_file): Handle codeview.
14128 2024-05-11 Mark Harmstone <mark@harmstone.com>
14130 * Makefile.in (OBJS): Add dwarf2codeview.o.
14131 (GTFILES): Add dwarf2codeview.cc
14132 * config/i386/cygming.h (CODEVIEW_DEBUGGING_INFO): Define.
14133 * dwarf2codeview.cc: New file.
14134 * dwarf2codeview.h: New file.
14135 * dwarf2out.cc: Include dwarf2codeview.h.
14136 (dwarf2out_finish): Call codeview_debug_finish as needed.
14137 * flag-types.h (DINFO_TYPE_CODEVIEW): Add enum member.
14138 (CODEVIEW_DEBUG): Define.
14139 * flags.h (codeview_debuginfo_p): Proottype.
14140 * opts.cc (debug_type_names): Add codeview.
14141 (debug_type_masks): Add CODEVIEW_DEBUG.
14142 (df_set_names): Add codeview.
14143 (codeview_debuginfo_p): New function.
14144 (dwarf_based_debuginfo_p): Add CODEVIEW clause.
14145 (set_debug_level): Handle CODEVIEW_DEBUG.
14146 * toplev.cc (process_options): Handle codeview.
14148 2024-05-11 dzhao.ampere <di.zhao@amperecomputing.com>
14150 PR tree-optimization/114760
14151 * tree-ssa-loop-niter.cc (is_lshift_by_1): New function
14152 to check if STMT is equivalent to x << 1.
14153 (is_rshift_by_1): New function to check if STMT is
14154 equivalent to x >> 1.
14155 (number_of_iterations_cltz): Enhance the identification
14156 of logical shift by one.
14157 (number_of_iterations_cltz_complement): Enhance the
14158 identification of logical shift by one.
14160 2024-05-11 Aldy Hernandez <aldyh@redhat.com>
14162 * range-op-ptr.cc (range_operator::fold_range): Return false.
14164 2024-05-11 Aldy Hernandez <aldyh@redhat.com>
14166 * range-op.cc (TRAP_ON_UNHANDLED_POINTER_OPERATORS): New
14167 (range_op_handler::fold_range): Use it.
14168 (range_op_handler::op1_range): Same.
14169 (range_op_handler::op2_range): Same.
14170 (range_op_handler::lhs_op1_relation): Same.
14171 (range_op_handler::lhs_op2_relation): Same.
14172 (range_op_handler::op1_op2_relation): Same.
14174 2024-05-10 Jeff Law <jlaw@ventanamicro.com>
14176 * config/riscv/riscv.cc (riscv_build_integer_1): Recognize cases where
14177 we can use shNadd to improve constant synthesis.
14178 (riscv_move_integer): Handle code generation for shNadd.
14180 2024-05-10 Roger Sayle <roger@nextmovesoftware.com>
14181 Hongtao Liu <hongtao.liu@intel.com>
14183 * config/i386/i386-expand.cc (ix86_expand_vecop_qihi_partial):
14184 Don't attempt ix86_expand_vec_shift_qihi_constant on SSE4.1.
14186 2024-05-10 Dimitar Dimitrov <dimitar@dinux.eu>
14188 * config/pru/predicates.md (pru_mulsrc0_operand): Use register
14189 class instead of register number for the check.
14190 (pru_mulsrc1_operand): Ditto.
14192 2024-05-10 Vladimir N. Makarov <vmakarov@redhat.com>
14195 * lra-constraints.cc (struct input_reload): Add new member early_clobber_p.
14196 (get_reload_reg): Add new arg early_clobber_p, don't reuse input
14197 reload with true early_clobber_p member value, use the arg for new
14198 element of curr_insn_input_reloads.
14199 (match_reload): Assign false to early_clobber_p member.
14200 (process_addr_reg, simplify_operand_subreg, curr_insn_transform):
14201 Adjust get_reload_reg calls.
14203 2024-05-10 Aldy Hernandez <aldyh@redhat.com>
14205 PR tree-optimization/115026
14206 * value-range.cc (prange::update_bitmask): Use operand bitmask.
14208 2024-05-10 Richard Biener <rguenther@suse.de>
14210 PR tree-optimization/114998
14211 * tree-loop-distribution.cc (free_rdg): Take loop argument.
14212 Reset UIDs of stmts still in the IL rather than all stmts
14213 referenced from the RDG.
14214 (loop_distribution::build_rdg): Pass loop to free_rdg.
14215 (loop_distribution::distribute_loop): Likewise.
14216 (loop_distribution::transform_reduction_loop): Likewise.
14218 2024-05-10 Richard Biener <rguenther@suse.de>
14220 * tree-vect-patterns.cc (vect_pattern_recog_1): Do not
14221 remove reductions involving patterns.
14222 * tree-vect-loop.cc (vectorizable_reduction): Reject SLP
14223 reduction groups with multiple lane-reducing reductions.
14224 * tree-vect-slp.cc (vect_analyze_slp_instance): When discovering
14225 SLP reduction groups avoid including lane-reducing ones.
14227 2024-05-10 Jose E. Marchesi <jose.marchesi@oracle.com>
14229 * config/bpf/bpf.cc (bpf_print_operand_address): Include
14230 surrounding parenthesis around mem operands in pseudoc asm
14232 * config/bpf/bpf.md (*mov<MM:mode>): Adapt accordingly.
14233 (zero_extendhidi2): Likewise.
14234 (zero_extendqidi2): Likewise.
14235 (*extendsidi2): Likewise.
14236 (*extendsidi2): Likewise.
14237 (extendhidi2): Likewise.
14238 (extendqidi2): Likewise.
14239 (extendhisi2): Likewise.
14240 * config/bpf/atomic.md (atomic_add<AMO:mode>): Likewise.
14241 (atomic_and<AMO:mode>): Likewise.
14242 (atomic_or<AMO:mode>): Likewise.
14243 (atomic_xor<AMO:mode>): Likewise.
14244 (atomic_fetch_add<AMO:mode>): Likewise.
14245 (atomic_fetch_and<AMO:mode>): Likewise.
14246 (atomic_fetch_or<AMO:mode>): Likewise.
14247 (atomic_fetch_xor<AMO:mode>): Likewise.
14249 2024-05-10 Jakub Jelinek <jakub@redhat.com>
14252 * target.def (use_atexit_for_cxa_atexit): Remove spurious space
14254 (adjust_cdtor_callabi_fntype): New cxx target hook.
14255 * targhooks.h (default_cxx_adjust_cdtor_callabi_fntype): Declare.
14256 * targhooks.cc (default_cxx_adjust_cdtor_callabi_fntype): New
14258 * doc/tm.texi.in (TARGET_CXX_ADJUST_CDTOR_CALLABI_FNTYPE): Add.
14259 * doc/tm.texi: Regenerate.
14260 * config/i386/i386.cc (ix86_cxx_adjust_cdtor_callabi_fntype): New
14262 (TARGET_CXX_ADJUST_CDTOR_CALLABI_FNTYPE): Redefine.
14264 2024-05-10 Aldy Hernandez <aldyh@redhat.com>
14266 PR tree-optimization/115009
14267 * value-range-storage.cc (prange_storage::alloc): Do not assume
14268 all pointers are the same size.
14269 (prange_storage::prange_storage): Same.
14270 (prange_storage::fits_p): Same.
14272 2024-05-10 Kito Cheng <kito.cheng@sifive.com>
14274 * config/riscv/riscv-vsetvl.cc: Fix typos in comments.
14275 (get_all_predecessors): Ditto.
14276 (pre_vsetvl::m_unknow_info): Rename to...
14277 (pre_vsetvl::m_unknown_info): this.
14278 (pre_vsetvl::compute_vsetvl_def_data): Rename m_unknow_info to
14280 (pre_vsetvl::cleaup): Rename to...
14281 (pre_vsetvl::cleanup): this.
14282 (pre_vsetvl::compute_vsetvl_def_data): Fix typos.
14283 (pass_vsetvl::lazy_vsetvl): Update function name and fix typos.
14284 * config/riscv/riscv.cc: Fix typos in comments.
14285 (struct machine_function): Fix typo in comments.
14286 (riscv_valid_lo_sum_p): Ditto.
14287 (riscv_force_address): Ditto.
14288 (riscv_immediate_operand_p): Ditto.
14289 (riscv_in_small_data_p): Ditto.
14290 (riscv_first_stack_step): Ditto.
14291 (riscv_expand_prologue): Ditto.
14292 (riscv_convert_vector_chunks): Ditto.
14293 (riscv_override_options_internal): Ditto.
14294 (get_common_costs): Ditto.
14296 2024-05-10 Xi Ruoyao <xry111@xry111.site>
14299 * opts-common.cc (prune_options): Move -fdiagnostics-urls=
14300 early like -fdiagnostics-color=.
14302 2024-05-10 Jeff Law <jlaw@ventanamicro.com>
14304 * config/riscv/bitmanip.md: Add splitter for shadd feeding another
14307 2024-05-10 Aldy Hernandez <aldyh@redhat.com>
14310 2024-05-08 Aldy Hernandez <aldyh@redhat.com>
14312 * gimple-range-cache.cc (sbr_sparse_bitmap::sbr_sparse_bitmap):
14313 Change irange to prange.
14314 * gimple-range-fold.cc (fold_using_range::fold_stmt): Same.
14315 (fold_using_range::range_of_address): Same.
14316 * gimple-range-fold.h (range_of_address): Same.
14317 * gimple-range-infer.cc (gimple_infer_range::add_nonzero): Same.
14318 * gimple-range-op.cc (class cfn_strlen): Same.
14319 * gimple-range-path.cc
14320 (path_range_query::adjust_for_non_null_uses): Same.
14321 * gimple-ssa-warn-access.cc (pass_waccess::check_pointer_uses): Same.
14322 * tree-ssa-structalias.cc (find_what_p_points_to): Same.
14323 * range-op-ptr.cc (range_op_table::initialize_pointer_ops): Remove
14324 hybrid entries in table.
14325 * range-op.cc (range_op_table::range_op_table): Add pointer
14326 entries for bitwise and/or and min/max.
14327 * value-range.cc (irange::verify_range): Add assert.
14328 * value-range.h (irange::varying_compatible_p): Remove check for
14330 (irange::supports_p): Remove pointer support.
14331 * ipa-cp.h (ipa_supports_p): Add prange support.
14333 2024-05-09 Roger Sayle <roger@nextmovesoftware.com>
14335 * simplify-rtx.cc (simplify_const_binary_operation): Constant
14336 fold binary operations where the LHS is CONST_VECTOR and the
14337 RHS is CONST_INT (or CONST_DOUBLE) such as vector shifts.
14339 2024-05-09 Martin Jambor <mjambor@suse.cz>
14341 * tree-sra.cc (sra_modify_assign): Remove the original statement
14342 also when dealing with a store to a fully covered aggregate from a
14345 2024-05-09 YunQiang Su <syq@gcc.gnu.org>
14347 * config/mips/constraints.md: Add new constraint 'w'.
14349 2024-05-09 Hu, Lin1 <lin1.hu@intel.com>
14352 * config/i386/emmintrin.h
14353 (_mm_load_sd): Remove alignment requirement.
14354 (_mm_store_sd): Ditto.
14355 (_mm_loadh_pd): Ditto.
14356 (_mm_loadl_pd): Ditto.
14357 (_mm_storel_pd): Add alignment requirement.
14358 * config/i386/xmmintrin.h
14359 (_mm_loadh_pi): Remove alignment requirement.
14360 (_mm_loadl_pi): Ditto.
14361 (_mm_load_ss): Ditto.
14362 (_mm_store_ss): Ditto.
14364 2024-05-09 Aldy Hernandez <aldyh@redhat.com>
14366 PR tree-optimization/114912
14367 * value-range.h (class Value_Range): Use a union.
14369 2024-05-09 Aldy Hernandez <aldyh@redhat.com>
14371 * range-op.cc (range_op_handler::discriminator_fail): Reword error
14374 2024-05-09 konglin1 <lingling.kong@intel.com>
14376 * config/i386/i386.cc (ix86_hardreg_mov_ok): Relax
14377 hard reg mov restriction when lra in progress.
14379 2024-05-08 Xiao Zeng <zengxiao@eswincomputing.com>
14381 * config/riscv/riscv.cc (riscv_legitimize_move): Expand movbf
14382 with Nan-boxing value.
14383 * config/riscv/riscv.md (*movbf_softfloat_boxing): New pattern.
14385 2024-05-08 Jeff Law <jlaw@ventanamicro.com>
14387 * config/riscv/riscv.cc (riscv_build_integer_1): Fix incorrect
14388 if-then-else nesting of Zbs code.
14390 2024-05-08 Vladimir N. Makarov <vmakarov@redhat.com>
14393 * lra-constraints.cc (process_alt_operands): Calculate union reg
14394 class for the alternative, peak matched regs and required reload
14395 regs. Recognize alternatives with lack of available registers and
14396 make them costly. Add debug print about this case.
14398 2024-05-08 Andrew Pinski <quic_apinski@quicinc.com>
14400 PR tree-optimization/112392
14401 * match.pd (`x CMP nonnegative ? x : ABS<x>`): New pattern;
14402 where CMP is ==, > and >=.
14403 (`x CMP nonnegative@y ? y : ABS<x>`): New pattern.
14405 2024-05-08 Ajit Kumar Agarwal <aagarwa1@linux.ibm.com>
14407 PR tree-optimization/81953
14408 * tree-ssa-sink.cc (statement_sink_location):Sink statements at
14409 the begining of the basic block after labels.
14411 2024-05-08 Christoph Müllner <christoph.muellner@vrull.eu>
14413 * config/riscv/iterators.md (ashiftrt): New code attribute
14414 'extract_shift' and adding extractions to optab.
14415 * config/riscv/riscv.md (*lshr<GPR:mode>3_zero_extend_4): Rename to...
14416 (*<any_extract:optab><GPR:mode>3):...this and add support for
14419 2024-05-08 Christoph Müllner <christoph.muellner@vrull.eu>
14422 * config/riscv/riscv.md (*lshr<GPR:mode>3_zero_extend_4): New
14423 pattern for zero-extraction.
14425 2024-05-08 Christoph Müllner <christoph.muellner@vrull.eu>
14427 * config/riscv/iterators.md (sraiw): New code iterator 'any_extract'.
14428 New code attribute 'extract_sidi_shift'.
14429 * config/riscv/riscv.md (*lshrsi3_zero_extend_2): Rename to...
14430 (*lshrsi3_extend_2):...this and add support for sign-extensions.
14432 2024-05-08 Richard Biener <rguenther@suse.de>
14434 * tree-vect-loop.cc (get_initial_defs_for_reduction): Convert
14435 initial value to the vector component type.
14437 2024-05-08 Richard Biener <rguenther@suse.de>
14439 * tree-vect-data-refs.cc (vect_enhance_data_refs_alignment):
14440 Properly guard DR_GROUP_SIZE access with STMT_VINFO_GROUPED_ACCESS.
14442 2024-05-08 Alex Coplan <alex.coplan@arm.com>
14445 * config/aarch64/aarch64-ldp-fusion.cc (combine_reg_notes):
14446 Ensure insn iN has its REG_FRAME_RELATED_EXPR (if any) stored in
14447 FR_EXPR[N-1], thus matching the correspondence expected by the
14450 2024-05-08 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
14452 * tree-ssa-loop-prefetch.cc (determine_unroll_factor): Honour
14455 2024-05-08 Georg-Johann Lay <avr@gjlay.de>
14458 * config/avr/avr.md: Add combine pattern for
14459 8-bit parity detection.
14461 2024-05-08 Georg-Johann Lay <avr@gjlay.de>
14464 * config/avr/avr.md: Add combine pattern for
14465 8-bit popcount detection.
14467 2024-05-08 Richard Biener <rguenther@suse.de>
14469 * tree-into-ssa.cc (insert_updated_phi_nodes_for): Skip
14470 pruning when the nearest common dominator is the successor
14471 of ENTRY_BLOCK. Do not copy IDF but prune it directly.
14473 2024-05-08 Jakub Jelinek <jakub@redhat.com>
14475 PR tree-optimization/114965
14476 * tree-ssa-reassoc.cc (optimize_range_tests_to_bit_test): Don't try to
14477 optimize away exp - lowi subtraction from shift count unless entry
14478 test is emitted or unless r.upper_bound () is smaller than prec.
14480 2024-05-08 Eric Botcazou <ebotcazou@adacore.com>
14482 * expmed.h (choose_multiplier): Tweak description and remove last
14484 * expmed.cc (choose_multiplier): Likewise. Add assertion for the
14485 third parameter and adds details to various comments.
14486 (invert_mod2n): Tweak description and add assertion for the first
14488 (expand_divmod): Adjust calls to choose_multiplier.
14489 * tree-vect-generic.cc (expand_vector_divmod): Likewise.
14490 * tree-vect-patterns.cc (vect_recog_divmod_pattern): Likewise.
14492 2024-05-08 konglin1 <lingling.kong@intel.com>
14495 * config/i386/i386.cc (ix86_rtx_costs): The XEXP (x, 0) for cmov
14496 is an operator do not need to compute cost.
14498 2024-05-08 Aldy Hernandez <aldyh@redhat.com>
14500 * gimple-range-cache.cc (sbr_sparse_bitmap::sbr_sparse_bitmap):
14501 Change irange to prange.
14502 * gimple-range-fold.cc (fold_using_range::fold_stmt): Same.
14503 (fold_using_range::range_of_address): Same.
14504 * gimple-range-fold.h (range_of_address): Same.
14505 * gimple-range-infer.cc (gimple_infer_range::add_nonzero): Same.
14506 * gimple-range-op.cc (class cfn_strlen): Same.
14507 * gimple-range-path.cc
14508 (path_range_query::adjust_for_non_null_uses): Same.
14509 * gimple-ssa-warn-access.cc (pass_waccess::check_pointer_uses): Same.
14510 * tree-ssa-structalias.cc (find_what_p_points_to): Same.
14511 * range-op-ptr.cc (range_op_table::initialize_pointer_ops): Remove
14512 hybrid entries in table.
14513 * range-op.cc (range_op_table::range_op_table): Add pointer
14514 entries for bitwise and/or and min/max.
14515 * value-range.cc (irange::verify_range): Add assert.
14516 * value-range.h (irange::varying_compatible_p): Remove check for
14518 (irange::supports_p): Remove pointer support.
14519 * ipa-cp.h (ipa_supports_p): Add prange support.
14521 2024-05-07 Andrew Pinski <quic_apinski@quicinc.com>
14523 PR tree-optimization/19661
14524 * tree-ssa-dce.cc (is_cxa_atexit): New function.
14525 (is_removable_cxa_atexit_call): New function.
14526 (mark_stmt_if_obviously_necessary): Don't mark removable
14528 (mark_all_reaching_defs_necessary_1): Likewise.
14529 (propagate_necessity): Likewise.
14531 2024-05-07 Andrew Pinski <quic_apinski@quicinc.com>
14533 PR tree-optimization/114894
14534 * match.pd (`a != 0 ? a / b : 0`): New pattern.
14535 (`a != 0 ? a * b : 0`): New pattern.
14536 (`a != 0 ? a & b : 0`): New pattern.
14538 2024-05-07 Jeff Law <jlaw@ventanamicro.com>
14540 * config/riscv/riscv.cc (generic_ooo_tune_info): Turn on
14541 overlap_op_by_pieces.
14543 2024-05-07 Christoph Müllner <christoph.muellner@vrull.eu>
14545 * config/riscv/riscv.cc (struct riscv_tune_param): Add new
14546 "overlap_op_by_pieces" field.
14547 (rocket_tune_info, sifive_7_tune_info): Set it.
14548 (sifive_p400_tune_info, sifive_p600_tune_info): Likewise.
14549 (thead_c906_tune_info, xiangshan_nanhu_tune_info): Likewise.
14550 (generic_ooo_tune_info, optimize_size_tune_info): Likewise.
14551 (riscv_overlap_op_by_pieces): New function.
14552 (TARGET_OVERLAP_OP_BY_PIECES_P): define.
14554 2024-05-07 Jakub Jelinek <jakub@redhat.com>
14556 PR middle-end/114907
14557 * expr.cc (convert_mode_scalar): Use trunc_optab rather than
14558 sext_optab for HF->BF conversions.
14559 * optabs-libfuncs.cc (gen_trunc_conv_libfunc): Likewise.
14561 2024-05-07 Jakub Jelinek <jakub@redhat.com>
14563 PR sanitizer/114956
14564 * tree-inline.cc: Include asan.h.
14565 (copy_bb): Remove also .ASAN_MARK calls if id->dst_fn has asan/hwasan
14566 sanitization disabled.
14568 2024-05-07 Jeff Law <jlaw@ventanamicro.com>
14570 * config/riscv/riscv-string.cc (riscv_expand_strcmp): Do not inline
14571 strncmp with zero size.
14572 (emit_strcmp_scalar_compare_subword): Adjust rotation for rv32 vs rv64.
14573 * config/riscv/riscv.opt (var_inline_strcmp): Enable by default.
14574 (vriscv_inline_strncmp, riscv_inline_strlen): Likewise.
14576 2024-05-07 Zac Walker <zacwalker@microsoft.com>
14578 * config.gcc: Build and add objects for Cygwin and MinGW. Add Cygwin
14579 and MinGW options to the target.
14581 2024-05-07 Zac Walker <zacwalker@microsoft.com>
14583 * config/i386/mingw-w64.opt.urls: Rename options' name and
14584 regenerate option URLs.
14585 * config/lynx.opt.urls: Likewise.
14586 * config/mingw/cygming.opt.urls: Likewise.
14587 * config/mingw/mingw.opt.urls: Likewise.
14588 * doc/invoke.texi: Likewise.
14590 2024-05-07 Zac Walker <zacwalker@microsoft.com>
14592 * config/aarch64/aarch64.h (struct seh_frame_state): Declare SEH
14593 structure in machine_function.
14594 (GTY): Add SEH field.
14596 2024-05-07 Zac Walker <zacwalker@microsoft.com>
14598 * config.gcc: Add Cygwin and MinGW difinitions.
14599 * config/aarch64/aarch64-protos.h
14600 (mingw_pe_maybe_record_exported_symbol): Declare functions
14601 which are used in Cygwin and MinGW environment.
14602 (mingw_pe_section_type_flags): Likewise.
14603 (mingw_pe_unique_section): Likewise.
14604 (mingw_pe_encode_section_info): Likewise.
14605 * config/aarch64/cygming.h: New file.
14607 2024-05-07 Zac Walker <zacwalker@microsoft.com>
14609 * config.gcc: Define TARGET_AARCH64_MS_ABI.
14610 * config/mingw/mingw-stdint.h (INTPTR_TYPE): Use
14611 TARGET_AARCH64_MS_ABI to adjust MinGW headers for
14613 (UINTPTR_TYPE): Likewise.
14614 (defined): Likewise.
14615 * config/mingw/mingw32.h (DEFAULT_ABI): Likewise.
14616 (defined): Likewise.
14617 * config/mingw/winnt.cc (defined): Use TARGET_ARM64_MS_ABI to
14618 exclude ix86_get_callcvt.
14619 (i386_pe_maybe_mangle_decl_assembler_name): Likewise.
14620 (i386_pe_mangle_decl_assembler_name): Likewise.
14622 2024-05-07 Zac Walker <zacwalker@microsoft.com>
14624 * config/i386/cygming.h (SUBTARGET_ENCODE_SECTION_INFO):
14625 Rename functions in mingw folder which will be reused for
14627 (TARGET_ASM_UNIQUE_SECTION): Likewise.
14628 (TARGET_ASM_NAMED_SECTION): Likewise.
14629 (TARGET_SECTION_TYPE_FLAGS): Likewise.
14630 (ASM_DECLARE_COLD_FUNCTION_NAME): Likewise.
14631 (ASM_OUTPUT_EXTERNAL_LIBCALL): Likewise.
14632 * config/i386/i386-protos.h (i386_pe_unique_section):
14634 (mingw_pe_unique_section): ... this.
14635 (i386_pe_declare_function_type): Rename into ...
14636 (mingw_pe_declare_function_type): ... this.
14637 (i386_pe_encode_section_info): Rename into ...
14638 (mingw_pe_encode_section_info): ... this.
14639 (i386_pe_maybe_record_exported_symbol): Rename into ...
14640 (mingw_pe_maybe_record_exported_symbol): ... this.
14641 (i386_pe_section_type_flags): Rename into ...
14642 (mingw_pe_section_type_flags): ... this.
14643 (i386_pe_asm_named_section): Rename into ...
14644 (mingw_pe_asm_named_section): ... this.
14645 * config/mingw/winnt.cc (i386_pe_encode_section_info):
14647 (mingw_pe_encode_section_info): ... this.
14648 (i386_pe_unique_section): Rename into ...
14649 (mingw_pe_unique_section): ... this.
14650 (i386_pe_section_type_flags): Rename into ...
14651 (mingw_pe_section_type_flags): ... this.
14652 (i386_pe_asm_named_section): Rename into ...
14653 (mingw_pe_asm_named_section): ... this.
14654 (i386_pe_asm_output_aligned_decl_common): Likewise.
14655 (i386_pe_declare_function_type): Rename into ...
14656 (mingw_pe_declare_function_type): ... this.
14657 (i386_pe_maybe_record_exported_symbol): Rename into ...
14658 (mingw_pe_maybe_record_exported_symbol): ... this.
14659 (i386_pe_start_function): Likewise.
14660 * varasm.cc (switch_to_comdat_section): Likewise.
14662 2024-05-07 Zac Walker <zacwalker@microsoft.com>
14664 * config.gcc: Adjust targets after moving MinGW related files
14665 from i386 to mingw folder.
14666 * config/i386/cygming.opt: Move to...
14667 * config/mingw/cygming.opt: ...here.
14668 * config/i386/cygming.opt.urls: Move to...
14669 * config/mingw/cygming.opt.urls: ...here.
14670 * config/i386/cygwin-d.cc: Move to...
14671 * config/mingw/cygwin-d.cc: ...here.
14672 * config/i386/mingw-stdint.h: Move to...
14673 * config/mingw/mingw-stdint.h: ...here.
14674 * config/i386/mingw.opt: Move to...
14675 * config/mingw/mingw.opt: ...here.
14676 * config/i386/mingw.opt.urls: Move to...
14677 * config/mingw/mingw.opt.urls: ...here.
14678 * config/i386/mingw32.h: Move to...
14679 * config/mingw/mingw32.h: ...here.
14680 * config/i386/msformat-c.cc: Move to...
14681 * config/mingw/msformat-c.cc: ...here.
14682 * config/i386/t-cygming: Move to...
14683 * config/mingw/t-cygming: ...here and updated.
14684 * config/i386/winnt-cxx.cc: Move to...
14685 * config/mingw/winnt-cxx.cc: ...here.
14686 * config/i386/winnt-d.cc: Move to...
14687 * config/mingw/winnt-d.cc: ...here.
14688 * config/i386/winnt-stubs.cc: Move to...
14689 * config/mingw/winnt-stubs.cc: ...here.
14690 * config/i386/winnt.cc: Move to...
14691 * config/mingw/winnt.cc: ...here.
14693 2024-05-07 Zac Walker <zacwalker@microsoft.com>
14695 * config.gcc: Add COFF format support definitions.
14696 * config/aarch64/aarch64-coff.h: New file.
14698 2024-05-07 Zac Walker <zacwalker@microsoft.com>
14700 * config.gcc: Define TARGET_AARCH64_MS_ABI when
14701 AArch64 MS ABI is used.
14702 * config/aarch64/aarch64.h (FIXED_X18): Adjust
14703 FIXED_REGISTERS, CALL_REALLY_USED_REGISTERS and
14704 STATIC_CHAIN_REGNUM for AArch64 MS ABI.
14705 (CALL_USED_X18): Likewise.
14706 (FIXED_REGISTERS): Likewise.
14707 * config/aarch64/aarch64-abi-ms.h: New file.
14709 2024-05-07 Zac Walker <zacwalker@microsoft.com>
14711 * config.gcc: Add aarch64-w64-mingw32 target.
14713 2024-05-07 Alex Coplan <alex.coplan@arm.com>
14716 * config/aarch64/aarch64-ldp-fusion.cc (ldp_bb_info::fuse_pair):
14717 Use replace_equiv_address_nv on a change of base instead of
14718 adjust_address_nv on the other access.
14720 2024-05-07 Richard Biener <rguenther@suse.de>
14722 * tree-into-ssa.cc (insert_updated_phi_nodes_for): Fix block
14725 2024-05-07 Richard Biener <rguenther@suse.de>
14727 * tree-ssa-live.cc (init_var_map): Pre-allocate vec_bbs vector
14728 to the correct size and use quick_push.
14730 2024-05-07 Richard Biener <rguenther@suse.de>
14732 PR middle-end/27800
14733 * gimplify.cc (gimplify_modify_expr_rhs): For a COND_EXPR
14734 avoid a temporary from gimplify_cond_expr when the LHS is
14735 a register by pushing the assignment into the COND_EXPR arms.
14737 2024-05-07 Richard Biener <rguenther@suse.de>
14739 * gimplify.cc (gimplify_hasher::equal): Remove redundant
14742 2024-05-07 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
14744 PR tree-optimization/110490
14745 * tree-scalar-evolution.cc (expression_expensive_p): Also
14746 consider mode widening for popcount, clz, and ctz.
14748 2024-05-07 Richard Biener <rguenther@suse.de>
14750 * cfgexpand.cc (stack_var::representative): Use 'unsigned'
14751 for stack var indexes instead of 'size_t'.
14752 (stack_var::next): Likewise.
14754 (stack_vars_alloc): Likewise.
14755 (stack_vars_num): Likewise.
14756 (decl_to_stack_part): Likewise.
14757 (stack_vars_sorted): Likewise.
14758 (add_stack_var): Likewise.
14759 (add_stack_var_conflict): Likewise.
14760 (stack_var_conflict_p): Likewise.
14761 (visit_op): Likewise.
14762 (visit_conflict): Likewise.
14763 (add_scope_conflicts_1): Likewise.
14764 (stack_var_cmp): Likewise.
14765 (part_hashmap): Likewise.
14766 (update_alias_info_with_stack_vars): Likewise.
14767 (union_stack_vars): Likewise.
14768 (partition_stack_vars): Likewise.
14769 (dump_stack_var_partition): Likewise.
14770 (expand_stack_vars): Likewise.
14771 (account_stack_vars): Likewise.
14772 (stack_protect_decl_phase_1): Likewise.
14773 (stack_protect_decl_phase_2): Likewise.
14774 (asan_decl_phase_3): Likewise.
14775 (init_vars_expansion): Likewise.
14776 (estimated_stack_frame_size): Likewise.
14778 2024-05-07 Richard Biener <rguenther@suse.de>
14780 PR middle-end/114931
14781 * tree.cc (type_hash_canon_hash): Hash TYPE_STRUCTURAL_EQUALITY_P.
14782 (type_cache_hasher::equal): Compare TYPE_STRUCTURAL_EQUALITY_P.
14783 (build_array_type_1): Set TYPE_STRUCTURAL_EQUALITY_P before
14784 probing with type_hash_canon.
14785 (build_function_type): Likewise.
14786 (build_method_type_directly): Likewise.
14787 (build_offset_type): Likewise.
14788 (build_complex_type): Likewise.
14789 * attribs.cc (build_type_attribute_qual_variant): Likewise.
14791 2024-05-07 Aldy Hernandez <aldyh@redhat.com>
14793 * ipa-cp.cc (ipa_vr_operation_and_type_effects): Use ipa_supports_p.
14794 (ipa_value_range_from_jfunc): Change Value_Range type.
14795 (propagate_vr_across_jump_function): Same.
14796 * ipa-cp.h (ipa_supports_p): New.
14797 * ipa-fnsummary.cc (evaluate_conditions_for_known_args): Change Value_Range type.
14798 * ipa-prop.cc (ipa_compute_jump_functions_for_edge): Use ipa_supports_p.
14799 (ipcp_get_parm_bits): Same.
14801 2024-05-07 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
14803 * config.gcc: Move *-*-solaris2.11.[0-3]* to unsupported list.
14804 <*-*-solaris2*> (default_use_cxa_atexit): Set unconditionally.
14805 * configure.ac (AX_LIB_SOCKET_NSL): Don't call.
14807 (gcc_cv_ld_aligned_shf_merge): Remove.
14808 (hidden_linkonce) <i?86-*-solaris2* | x86_64-*-solaris2*>: Remove.
14809 (gcc_cv_target_dl_iterate_phdr) <*-*-solaris2*>: Always set to yes.
14810 * Makefile.in (NETLIBS): Remove.
14811 * configure, config.in, aclocal.m4: Regenerate.
14812 * config/sol2.h: Don't check HAVE_SOLARIS_CRTS.
14813 (STARTFILE_SPEC): Remove !HAVE_SOLARIS_CRTS case.
14814 [USE_GLD] (LINK_EH_SPEC): Remove TARGET_DL_ITERATE_PHDR guard.
14815 * config/i386/i386.cc (USE_HIDDEN_LINKONCE): Remove guard.
14816 * varasm.cc (mergeable_string_section): Remove
14817 HAVE_LD_ALIGNED_SHF_MERGE handling.
14818 (mergeable_constant_section): Likewise.
14819 * doc/install.texi (Specific,i?86-*-solaris2*): Reference Solaris
14821 (Specific, *-*-solaris2*): Document Solaris 11.3 removal. Remove
14822 11.3 references and caveats. Update for 11.4.
14824 2024-05-07 Richard Biener <rguenther@suse.de>
14827 2024-04-10 Richard Biener <rguenther@suse.de>
14830 2024-03-27 Segher Boessenkool <segher@kernel.crashing.org>
14832 PR rtl-optimization/101523
14833 * combine.cc (try_combine): Don't do a 2-insn combination if
14834 it does not in fact change I2.
14836 2024-05-07 Andrew Pinski <quic_apinski@quicinc.com>
14838 PR middle-end/97263
14839 * doc/invoke.texi(fmath-errno): Document it is turned on
14841 (funsafe-math-optimizations): Likewise.
14842 (ffinite-math-only): Likewise.
14843 (fno-trapping-math): Likewise and use less strong language.
14845 2024-05-07 liuhongt <hongtao.liu@intel.com>
14847 * config/i386/sse.md (usdot_prodv*qi): Extend to VI1_AVX512
14848 with vpmaddwd when avxvnni/avx512vnni is not available.
14850 2024-05-07 liuhongt <hongtao.liu@intel.com>
14853 * config/i386/mmx.md (usdot_prodv8qi): New expander.
14854 (sdot_prodv8qi): Ditto.
14855 (udot_prodv8qi): Ditto.
14856 (usdot_prodv4hi): Ditto.
14857 (udot_prodv4hi): Ditto.
14858 (sdot_prodv4hi): Ditto.
14860 2024-05-07 liuhongt <hongtao.liu@intel.com>
14863 * config/i386/i386-expand.cc
14864 (expand_vec_perm_punpckldq_pshuf): New function.
14865 (ix86_expand_vec_perm_const_1): Try
14866 expand_vec_perm_punpckldq_pshuf for sequence of 2
14869 2024-05-07 Dimitar Dimitrov <dimitar@dinux.eu>
14871 * config/pru/pru-passes.cc (class pass_pru_minrt_check): New
14873 (pass_pru_minrt_check::execute): New method.
14874 (make_pru_minrt_check): New function.
14875 * config/pru/pru-passes.def (INSERT_PASS_AFTER): Register the
14877 * config/pru/pru-protos.h (make_pru_minrt_check): Add
14880 2024-05-07 Dimitar Dimitrov <dimitar@dinux.eu>
14882 * config/pru/pru-passes.cc (class pass_tiabi_check): Rename to
14884 (class pass_pru_tiabi_check): Ditto.
14885 (pass_tiabi_check::execute): Ditto.
14886 (pass_pru_tiabi_check::execute): Ditto.
14887 (make_pru_tiabi_check): Ditto.
14888 (pru_register_abicheck_pass): Remove.
14889 * config/pru/pru-protos.h (pru_register_abicheck_pass): Remove.
14890 (make_pru_tiabi_check): Add declaration.
14891 * config/pru/pru.cc (pru_option_override): Remove explicit pass
14893 * config/pru/t-pru: Register PRU passes definition file.
14894 * config/pru/pru-passes.def: New file.
14896 2024-05-07 Dimitar Dimitrov <dimitar@dinux.eu>
14898 * config/pru/pru.md (lshrdi3): Use HOST_WIDE_INT_1U macro.
14901 2024-05-07 Dimitar Dimitrov <dimitar@dinux.eu>
14903 * config/pru/pru-passes.cc: Drop ATTRIBUTE_UNUSED and remove
14905 * config/pru/pru-pragma.cc (pru_pragma_ctable_entry): Ditto.
14906 * config/pru/pru.cc (pru_function_profiler): Ditto.
14907 (pru_can_eliminate): Ditto.
14908 (pru_rtx_costs): Ditto.
14909 (pru_insert_attributes): Ditto.
14910 (pru_function_value): Ditto.
14911 (pru_libcall_value): Ditto.
14912 (pru_return_in_memory): Ditto.
14913 (pru_builtin_decl): Ditto.
14914 (pru_expand_builtin): Ditto.
14916 2024-05-07 Dimitar Dimitrov <dimitar@dinux.eu>
14918 * config/pru/pru.cc (prologue_saved_reg_p): Skip saving
14919 if function will not return.
14921 2024-05-07 Dimitar Dimitrov <dimitar@dinux.eu>
14923 * config/pru/alu-zext.md (_noz0): New subst attribute.
14924 (<code>_impl): Allow zero-extending the destination.
14925 (<shift_op>): Remove unified pattern
14926 (ashl_impl): New distinct pattern.
14927 (lshr_impl): Ditto.
14928 (alu3_zext_op0_subst): New subst iterator to zero-extend the
14929 destination register.
14931 2024-05-07 Dimitar Dimitrov <dimitar@dinux.eu>
14933 * config/pru/pru.md (extzv<mode>): Make it an expand pattern,
14934 handle efficiently zero-positioned bit-fields.
14935 (insv<mode>): New expand pattern.
14937 2024-05-07 Dimitar Dimitrov <dimitar@dinux.eu>
14939 * config/pru/pru.md: New pattern alternative for zero-filling
14942 2024-05-07 Dimitar Dimitrov <dimitar@dinux.eu>
14944 * config/pru/pru.cc (pru_address_cost): Implement address cost
14946 (TARGET_ADDRESS_COST): Define for PRU.
14948 2024-05-07 Richard Biener <rguenther@suse.de>
14950 PR tree-optimization/114921
14951 * tree-vect-stmts.cc (vectorizable_assignment): Use
14952 tree_nop_conversion_p to identify converts we can vectorize
14953 with a simple assignment.
14955 2024-05-07 Roger Sayle <roger@nextmovesoftware.com>
14956 Hongtao Liu <hongtao.liu@intel.com>
14959 * config/i386/i386-expand.cc (enum ix86_vec_bcast_alg): New.
14960 (struct ix86_vec_bcast_map_simode_t): New type for table below.
14961 (ix86_vec_bcast_map_simode): Table of SImode constants that may
14962 be efficiently synthesized by a ix86_vec_bcast_alg method.
14963 (ix86_vec_bcast_map_simode_cmp): New comparator for bsearch.
14964 (ix86_vector_duplicate_simode_const): Efficiently synthesize
14965 V4SImode and V8SImode constants that duplicate special constants.
14966 (ix86_vector_duplicate_value): Attempt to synthesize "special"
14967 vector constants using ix86_vector_duplicate_simode_const.
14968 * config/i386/i386.cc (ix86_rtx_costs) <case ABS>: ABS of a
14969 vector integer mode costs with a single SSE instruction.
14971 2024-05-06 Xiao Zeng <zengxiao@eswincomputing.com>
14973 * common/config/riscv/riscv-common.cc (riscv_implied_info): zfbfmin
14975 (riscv_ext_version_table, riscv_ext_flag_table): Add zfbfmin.
14976 * config/riscv/riscv.opt (ZFBFMIN): Add optoion.
14978 2024-05-06 Xiao Zeng <zengxiao@eswincomputing.com>
14979 Jin Ma <jinma@linux.alibaba.com>
14981 * config/riscv/iterators.md: New mode iterator HFBF.
14982 * config/riscv/riscv-builtins.cc (riscv_init_builtin_types):
14983 Initialize data type _Bfloat16.
14984 * config/riscv/riscv-modes.def (FLOAT_MODE): New.
14985 (ADJUST_FLOAT_FORMAT): New.
14986 * config/riscv/riscv.cc (riscv_mangle_type): Support for BFmode.
14987 (riscv_scalar_mode_supported_p): Ditto.
14988 (riscv_libgcc_floating_mode_supported_p): Ditto.
14989 (riscv_init_libfuncs): Set the conversion method for BFmode and
14991 (riscv_block_arith_comp_libfuncs_for_mode): Set the arithmetic
14992 and comparison libfuncs for the mode.
14993 * config/riscv/riscv.md (mode" ): Add BF.
14994 (movhf): Support for BFmode.
14995 (mov<mode>): Ditto.
14996 (*movhf_softfloat): Ditto.
14997 (*mov<mode>_softfloat): Ditto.
14999 2024-05-06 Palmer Dabbelt <palmer@rivosinc.com>
15001 * doc/invoke.texi (RISC-V): Add -mcmodel=large.
15003 2024-05-06 Jeff Law <jlaw@ventanamicro.com>
15005 * config/riscv/riscv.cc (riscv_integer_op): Add field tracking if we
15006 want to use a "uw" instruction variant.
15007 (riscv_build_integer_1): Initialize the new field in various places.
15008 Use lui+slli.uw for some constants.
15009 (riscv_move_integer): Handle slli.uw.
15011 2024-05-06 Qing Zhao <qing.zhao@oracle.com>
15014 * stor-layout.cc (place_union_field): Use zero sizes for flexible array
15017 2024-05-06 Qing Zhao <qing.zhao@oracle.com>
15020 * doc/extend.texi: Add documentation for Flexible Array Members in
15021 Unions and Flexible Array Members alone in Structures.
15023 2024-05-06 Georg-Johann Lay <avr@gjlay.de>
15026 * config/avr/avr.cc (avr_option_override): Set
15027 flag_ipa_icf_variables = 0.
15029 2024-05-06 Sandra Loosemore <sloosemore@baylibre.com>
15031 * tree-nested.cc (convert_tramp_reference_stmt): Use the correct
15032 accessor for GIMPLE_OMP_TARGET clauses.
15034 2024-05-06 Richard Biener <rguenther@suse.de>
15036 PR tree-optimization/100923
15037 * tree-ssa-sccvn.cc (ao_ref_init_from_vn_reference): Valueize
15039 (vn_reference_lookup_3): Adjust vn_context_bb around calls
15040 to ao_ref_init_from_vn_reference.
15041 (vn_reference_lookup_pieces): Revert original PR100923 fix.
15042 (vn_reference_lookup): Likewise.
15044 2024-05-06 Richard Biener <rguenther@suse.de>
15046 * tree-ssa-sccvn.cc (ao_ref_init_from_vn_reference): Add
15047 TARGET_MEM_REF support. Handle more bases.
15049 2024-05-06 YunQiang Su <syq@gcc.gnu.org>
15052 * expmed.cc(store_bit_field_using_insv): TRUNCATE value1 if
15055 2024-05-05 Andrew Pinski <quic_apinski@quicinc.com>
15057 * gimple-loop-versioning.cc (loop_versioning): Remove m_nloops field.
15058 (loop_versioning::loop_versioning): Remove initialization of
15059 m_nloops field and move it to be a local variable.
15060 (loop_versioning::analyze_blocks): Fix formating.
15062 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15064 * gimple-range-op.cc (class cfn_pass_through_arg1): Add overloads
15065 for prange operations.
15066 (cfn_strlen): Same.
15068 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15070 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15071 * range-op-ptr.cc (operator_ge::fold_range): New.
15072 (operator_ge::op1_range): New.
15073 (operator_ge::op2_range): New.
15074 (operator_ge::op1_op2_relation): New.
15075 (operator_ge::pointers_handled_p): New.
15077 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15079 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15080 * range-op-ptr.cc (operator_gt::fold_range): New.
15081 (operator_gt::op1_range): New.
15082 (operator_gt::op2_range): New.
15083 (operator_gt::op1_op2_relation): New.
15084 (operator_gt::pointers_handled_p): New.
15086 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15088 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15089 * range-op-ptr.cc (operator_le::fold_range): New.
15090 (operator_le::op1_range): New.
15091 (operator_le::op2_range): New.
15092 (operator_le::op1_op2_relation): New.
15093 (operator_le::pointers_handled_p): New.
15095 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15097 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15098 * range-op-ptr.cc (max_limit): New.
15104 (operator_lt::fold_range): New.
15105 (operator_lt::op1_range): New.
15106 (operator_lt::op2_range): New.
15107 (operator_lt::op1_op2_relation): New.
15108 (operator_lt::pointers_handled_p): New.
15110 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15112 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15113 * range-op-ptr.cc (operator_equal::fold_range): New.
15114 (operator_equal::op1_range): New.
15115 (operator_equal::op2_range): New.
15116 (operator_equal::op1_op2_relation): New.
15117 (operator_equal::pointers_handled_p): New.
15119 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15121 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15122 * range-op-ptr.cc (operator_not_equal::fold_range): New.
15123 (operator_not_equal::op1_range): New.
15124 (operator_not_equal::op2_range): New.
15125 (operator_not_equal::op1_op2_relation): New.
15126 (operator_not_equal::pointers_handled_p): New.
15128 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15130 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15131 * range-op-ptr.cc (operator_bitwise_or::pointers_handled_p): New.
15133 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15135 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15136 * range-op-ptr.cc (operator_bitwise_and::fold_range): New.
15137 (operator_bitwise_and::pointers_handled_p): New.
15139 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15142 (operator_pointer_diff::op1_op2_relation_effect): New.
15143 (operator_pointer_diff::pointers_handled_p): New.
15145 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15147 * range-op-ptr.cc (class pointer_plus_operator): Add overloaded declarations
15148 for pointer variants.
15149 (pointer_plus_operator::fold_range): New.
15150 (pointer_plus_operator::op2_range): New.
15151 (pointer_plus_operator::pointers_handled_p): New.
15153 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15155 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15156 * range-op-ptr.cc (operator_addr_expr::op1_range): New.
15157 (operator_addr_expr::pointers_handled_p): New.
15159 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15161 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15162 * range-op-ptr.cc (operator_min::fold_range): New.
15163 (operator_min::pointers_handled_p): New.
15164 (operator_max::fold_range): New.
15165 (operator_max::pointers_handled_p): New.
15167 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15169 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15170 * range-op-ptr.cc (operator_cast::fold_range): New.
15171 (operator_cast::op1_range): New.
15172 (operator_cast::lhs_op1_relation): New.
15173 (operator_cast::pointers_handled_p): New.
15175 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15177 * range-op-mixed.h: Add overloaded declarations for pointer variants.
15178 * range-op-ptr.cc (operator_cst::fold_range): New.
15179 (operator_cst::pointers_handled_p): New.
15181 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15183 * range-op-mixed.h: Add overloaded declarations for fold_range, op1_range,
15184 lhs_op1_relation, pointers_handled_p.
15185 * range-op-ptr.cc (operator_identity::fold_range): New.
15186 (operator_identity::lhs_op1_relation): New.
15187 (operator_identity::op1_range): New.
15188 (operator_identity::pointers_handled_p): New.
15190 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15192 * range-op-mixed.h: Add using declarator for all classes.
15193 * range-op-ptr.cc (range_operator::pointers_handled_p): New.
15194 (range_operator::fold_range): New.
15195 (range_operator::op1_op2_relation_effect): New.
15196 (range_operator::op1_range): New.
15197 (range_operator::op2_range): New.
15198 (range_operator::op1_op2_relation): New.
15199 (range_operator::lhs_op1_relation): New.
15200 (range_operator::update_bitmask): New.
15201 (class pointer_plus_operator): New.
15202 (class operator_pointer_diff): New.
15203 (class hybrid_min_operator): New.
15204 (class hybrid_max_operator): New.
15205 * range-op.cc: Add RO_PPP, RO_PPI, RO_IPP, RO_IPI, RO_PIP, RO_PII.
15206 (range_op_handler::discriminator_fail): New.
15207 (has_pointer_operand_p): New.
15208 (range_op_handler::fold_range): Add pointer support.
15209 (range_op_handler::op1_range): Same.
15210 (range_op_handler::op2_range): Same.
15211 (range_op_handler::lhs_op1_relation): Same.
15212 (range_op_handler::lhs_op2_relation): Same.
15213 (range_op_handler::op1_op2_relation): Same.
15214 (class operator_div): Add using.
15215 (class operator_lshift): Add using.
15216 (class operator_rshift):Add using.
15217 (class operator_trunc_mod):Add using.
15218 (class operator_absu):Add using.
15219 * range-op.h (enum range_op_dispatch_type): New.
15220 Add extern definitions for RO_*.
15222 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15224 * value-range.cc (get_legacy_range): New version for prange.
15226 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15228 * value-range.cc (add_vrange): Add prange support.
15230 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15232 * value-range-storage.cc (vrange_allocator::clone_varying): Add
15234 (vrange_allocator::clone_undefined): Same.
15235 (vrange_storage::alloc): Same.
15236 (vrange_storage::set_vrange): Same.
15237 (vrange_storage::get_vrange): Same.
15238 (vrange_storage::fits_p): Same.
15239 (vrange_storage::equal_p): Same.
15240 (prange_storage::alloc): New.
15241 (prange_storage::prange_storage): New.
15242 (prange_storage::set_prange): New.
15243 (prange_storage::get_prange): New.
15244 (prange_storage::equal_p): New.
15245 (prange_storage::fits_p): New.
15246 * value-range-storage.h (class prange_storage): Add prange support.
15248 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15250 * data-streamer-in.cc (streamer_read_value_range): Add prange support.
15251 * data-streamer-out.cc (streamer_write_vrange): Same.
15253 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15255 * value-range-pretty-print.cc (vrange_printer::visit): New.
15256 * value-range-pretty-print.h: Declare prange visit() method.
15257 * value-range.cc (vrange::operator=): Add prange support.
15258 (vrange::operator==): Same.
15259 (prange::accept): New.
15260 (prange::set_nonnegative): New.
15261 (prange::set): New.
15262 (prange::contains_p): New.
15263 (prange::singleton_p): New.
15264 (prange::lbound): New.
15265 (prange::ubound): New.
15266 (prange::union_): New.
15267 (prange::intersect): New.
15268 (prange::operator=): New.
15269 (prange::operator==): New.
15270 (prange::invert): New.
15271 (prange::verify_range): New.
15272 (prange::update_bitmask): New.
15273 (range_tests_misc): Use prange.
15274 * value-range.h (enum value_range_discriminator): Add VR_PRANGE.
15275 (class prange): New.
15276 (Value_Range::init): Add prange support.
15277 (Value_Range::operator=): Same.
15278 (Value_Range::supports_type_p): Same.
15279 (prange::prange): New.
15280 (prange::supports_p): New.
15281 (prange::supports_type_p): New.
15282 (prange::set_undefined): New.
15283 (prange::set_varying): New.
15284 (prange::set_nonzero): New.
15285 (prange::set_zero): New.
15286 (prange::contains_p): New.
15287 (prange::zero_p): New.
15288 (prange::nonzero_p): New.
15289 (prange::type): New.
15290 (prange::lower_bound): New.
15291 (prange::upper_bound): New.
15292 (prange::varying_compatible_p): New.
15293 (prange::get_bitmask): New.
15294 (prange::fits_p): New.
15296 2024-05-04 Aldy Hernandez <aldyh@redhat.com>
15298 * value-range.h (class prange): New.
15300 2024-05-03 Andrew Pinski <quic_apinski@quicinc.com>
15302 PR middle-end/23872
15303 * tree-pretty-print.cc (dump_generic_node <case COMPOUND_EXPR>): Fix
15304 calls to dump_generic_node and also remove unreachable code that is testing
15305 `flags & TDF_SLIM`.
15307 2024-05-03 Vineet Gupta <vineetg@rivosinc.com>
15309 * config/riscv/riscv.cc: Comment updates.
15310 * config/riscv/riscv.h: Ditto.
15312 2024-05-03 Vineet Gupta <vineetg@rivosinc.com>
15314 * doc/rtl.texi: Add entry for GET_MODE_INNER.
15316 2024-05-03 Richard Biener <rguenther@suse.de>
15318 * bitmap.cc (bitmap_alloc): When using the global bitmap obstack
15319 assert that is initialized.
15321 2024-05-03 Richard Biener <rguenther@suse.de>
15323 PR middle-end/114931
15324 * tree.cc (build_array_type_1): Return early when type_hash_canon
15325 returned an older existing type.
15326 (build_function_type): Likewise.
15327 (build_method_type_directly): Likewise.
15328 (build_offset_type): Likewise.
15330 2024-05-03 Alex Coplan <alex.coplan@arm.com>
15332 PR rtl-optimization/114924
15333 * cfgrtl.cc (duplicate_insn_chain): When updating MEM_EXPRs,
15334 don't strip (e.g.) ARRAY_REFs from the final MEM_EXPR.
15336 2024-05-03 Jakub Jelinek <jakub@redhat.com>
15338 PR middle-end/113596
15339 * tree-inline.cc (expand_call_inline): Emit __builtin_stack_save
15340 and __builtin_stack_restore calls around inlined functions which
15343 2024-05-03 Richard Biener <rguenther@suse.de>
15345 PR tree-optimization/114921
15346 * tree-vect-stmts.cc (vectorizable_assignment): Require
15347 same vector component modes for input and output for
15348 CONVERT_EXPR_CODE_P.
15350 2024-05-02 Jeff Law <jlaw@ventanamicro.com>
15352 * config/riscv/riscv.md (<round_pattern><ANYF:mode>2): Adjust
15353 condition to match what can be properly implemented. Fix various
15355 (l<round_pattern><ANYF:mode>si2_sext): Fix formatting
15357 2024-05-02 Jeff Law <jlaw@ventanamicro.com>
15359 * config/riscv/predicates.md (arith_or_zbs_operand): New predicate.
15360 * config/riscv/riscv.cc (riscv_build_integer_one): Use bseti to set
15361 single bits when profitable.
15362 * config/riscv/riscv.md (*<optab><mode>3): Renamed with '*' prefix.
15363 (<optab><mode>3): New expander for IOR/XOR.
15365 2024-05-02 Richard Biener <rguenther@suse.de>
15367 * tree-vect-slp.cc (vect_print_slp_tree): Mark live lanes.
15368 (dot_slp_tree): New overload for multiple entries.
15370 2024-05-02 Gaius Mulley <gaiusmod2@gmail.com>
15373 * doc/gm2.texi (Compiler options): Add -fm2-debug-trace=,
15374 -fm2-dump, -fm2-dump-decl=, -fm2-dump-gimple=, -fm2-dump-quad=
15375 and -fm2-dump-filter=.
15377 2024-05-02 Marc Poulhiès <poulhies@adacore.com>
15379 * value-range.h: fix static_assert to use 2 arguments.
15381 2024-05-02 Peter Damianov <peter0x44@disroot.org>
15384 * lto-wrapper.cc (run_gcc): Instead of truncating a processed
15385 ltrans input from the Makefile use the new -truncate option
15386 to accomplish the same.
15388 2024-05-02 Peter Damianov <peter0x44@disroot.org>
15391 * common.opt (truncate): New internal option.
15392 * gcc.cc (totruncate_file): New global.
15393 (driver_handle_option): Handle -truncate <file>.
15394 (driver::final_actions): Truncate the file indicated.
15396 2024-05-02 Richard Biener <rguenther@suse.de>
15398 * graphds.cc (dump_graph): Dump in graphviz format.
15400 2024-05-02 Richard Biener <rguenther@suse.de>
15402 * tree-ssa-live.h (tree_live_info_d::global): Remove.
15403 (partition_is_global): Likewise.
15404 (make_live_on_entry): Do not set bit in global.
15405 * tree-ssa-live.cc (new_tree_live_info): Do not allocate
15407 (delete_tree_live_info): Do not release it.
15408 (set_var_live_on_entry): Do not set bits in it.
15410 2024-05-02 Richard Biener <rguenther@suse.de>
15412 PR middle-end/114579
15413 * cfgexpand.cc (add_scope_conflicts_1): Record all-to-all
15414 conflicts only when there's a CFG merge but for all CFG merges.
15416 2024-05-01 Gerald Pfeifer <gerald@pfeifer.com>
15420 * doc/install.texi (Specific) <*-*-freebsd*>: The Ada and D
15421 run-time libraries are broken on i386 which also can affect
15422 64-bit builds. Go is broken.
15424 2024-05-01 Jeff Law <jlaw@ventanamicro.com>
15426 * config/riscv/bitmanip.md (splitter to use w-form division): Remove
15428 (zero extended bitfield extraction): Similarly.
15429 * config/riscv/thead.md (*th_memidx_operand): Similarly.
15431 2024-05-01 Jeff Law <jlaw@ventanamicro.com>
15433 * config/riscv/riscv.cc (riscv_macro_fusion_pair_p): Break out
15434 tests for easier debugging in store pair fusion case. Fix offset
15437 2024-05-01 Gerald Pfeifer <gerald@pfeifer.com>
15441 * doc/install.texi (Specific) <*-*-freebsd*>: No longer refer
15442 to GCC or binutils in base. Recommend bootstrap using binutils.
15444 2024-05-01 Gerald Pfeifer <gerald@pfeifer.com>
15447 * doc/install.texi (Specific) <ia64-*-hpux*>: Remove details
15448 on libunwind for GCC 3.4 and earlier.
15450 2024-05-01 Aldy Hernandez <aldyh@redhat.com>
15452 * ipa-fnsummary.cc (evaluate_properties_for_edge): Initialize Value_Range's.
15453 * value-range.h (class Value_Range): Add a buffer and remove
15454 m_irange and m_frange.
15455 (Value_Range::Value_Range): Call init.
15456 (Value_Range::set_type): Same.
15457 (Value_Range::init): Use in place new to initialize buffer.
15458 (Value_Range::operator=): Tidy.
15460 2024-05-01 Aldy Hernandez <aldyh@redhat.com>
15462 * value-range.cc (unsupported_range::union_): Cast vrange to
15464 (unsupported_range::intersect): Same.
15465 (unsupported_range::operator=): Make argument an unsupported_range.
15466 * value-range.h: New constructor.
15468 2024-04-30 Andrew MacLeod <amacleod@redhat.com>
15470 * gimple-range-op.cc (gimple_range_op_handler::calc_op1): Don't
15471 assert that here are less than 3 operands.
15472 (gimple_range_op_handler::maybe_builtin_call): Simply return if
15473 there is no type for the function call.
15475 2024-04-30 Andrew MacLeod <amacleod@redhat.com>
15477 * gimple-range.cc (gimple_ranger::range_on_entry): Adjust for new
15478 API and support non-SSA expressions.
15479 (gimple_ranger::range_on_exit): Ditto.
15480 * gimple-range.h (range_on_entry, range_on_exit): Adjust API.
15481 * value-query.cc (range_query::range_on_entry): New.
15482 (range_query::range_on_exit): New.
15483 (range_query::value_on_entry): New.
15484 (range_query::value_on_exit): New.
15485 (range_query::invoke_range_of_expr): New.
15486 (range_query::get_tree_range): Allow stmt, on_entry or on_exit
15488 SSA_NAMES should invoke range_of_expr if possible.
15489 * value-query.h (class range_query): Adjust prototypes.
15491 2024-04-30 Andrew MacLeod <amacleod@redhat.com>
15493 * gimple-range.cc (gimple_ranger::range_of_expr): Call range_of_stmt
15494 when there is no context stmt.
15496 2024-04-30 Andrew MacLeod <amacleod@redhat.com>
15498 * gimple-range-cache.cc (ranger_cache::get_global_range): Do not
15499 pre-evaluate PHI nodes from the cache.
15500 (ranger_cache::fill_block_cache): Make re-entrant.
15502 2024-04-30 Andrew MacLeod <amacleod@redhat.com>
15504 * value-query.cc (get_range_global): Rename to gimple_range_global.
15505 (gimple_range_global): Remove wrapper function.
15506 (global_range_query::range_of_expr): Call gimple_range_global.
15508 2024-04-30 Andrew Pinski <quic_apinski@quicinc.com>
15510 * tree-cfg.cc (verify_gimple_assign): Remove quote
15511 mark to shut up the warning.
15513 2024-04-30 Andrew Pinski <quic_apinski@quicinc.com>
15515 * tree-ssa-phiopt.cc (value_replacement): Reject undef variables
15516 so they don't become unconditional used.
15518 2024-04-30 Andrew Pinski <quic_apinski@quicinc.com>
15520 * tree-ssa-phiopt.cc (value_replacement): Move check for
15523 2024-04-30 Andrew Pinski <quic_apinski@quicinc.com>
15525 * tree-ssa-phiopt.cc (single_non_singleton_phi_for_edges):
15526 Remove the special case of gimple_seq_singleton_p.
15528 2024-04-30 Andrew Pinski <quic_apinski@quicinc.com>
15530 PR middle-end/112976
15531 * cfgexpand.cc (expand_gimple_stmt_1): Remove
15532 support for expanding nontemporal "moves" with
15533 ssa names on the LHS.
15535 2024-04-30 Andrew Pinski <quic_apinski@quicinc.com>
15537 PR middle-end/112976
15538 * tree-cfg.cc (verify_gimple_assign): Verify that
15539 nontmporal moves are stores.
15540 * gimple.h (struct gimple): Note that only
15541 nontemporal stores are supported.
15543 2024-04-30 Jivan Hakobyan <jivanhakobyan9@gmail.com>
15545 * config/riscv/iterators.md (fix_ops, fix_uns): New iterators.
15546 (RINT, rint_pattern, rint_rm): Remove unused iterators.
15547 * config/riscv/riscv-protos.h (get_fp_rounding_coefficient): Prototype.
15548 * config/riscv/riscv-v.cc (get_fp_rounding_coefficient): Externalize.
15550 * config/riscv/riscv.md (UNSPEC_LROUND): Remove.
15551 (fix_trunc<ANYF:mode><GPR:mode>2): Replace with ...
15552 (<fix_uns>_trunc<ANYF:mode>si2): New expander & associated insn.
15553 (<fix_uns>_trunc<ANYF:mode>si2_ext): New insn.
15554 (<fix_uns>_trunc<ANYF:mode>di2): Likewise.
15555 (l<rint_pattern><ANYF:mode><GPR:mode>2): Replace with ...
15556 (lrint<ANYF:mode>si2): New expander and associated insn.
15557 (lrint<ANYF:mode>si2_ext, lrint<ANYF:mode>di2): New insns.
15558 (<round_pattern><ANYF:mode>2): Replace with....
15559 (l<round_pattern><ANYF:mode>si2): New expander and associated insn.
15560 (l<round_pattern><ANYF:mode>si2_sext): New insn.
15561 (l<round_pattern><ANYF:mode>di2): Likewise.
15562 (<round_pattern><ANYF:mode>2): New expander.
15564 2024-04-30 Aldy Hernandez <aldyh@redhat.com>
15566 * gimple-ssa-warn-access.cc (check_nul_terminated_array): Change
15567 int_range<2> to int_range_max.
15568 (memmodel_to_uhwi): Same.
15569 * tree-ssa-loop-niter.cc (refine_value_range_using_guard): Same.
15570 (determine_value_range): Same.
15571 (infer_loop_bounds_from_signedness): Same.
15572 (scev_var_range_cant_overflow): Same.
15574 2024-04-30 Richard Biener <rguenther@suse.de>
15576 PR middle-end/13421
15577 * optabs-tree.cc (optab_for_tree_code): Do not consider
15578 {add,sub}v or {us,ss}{add,sub} optabs for POINTER_DIFF_EXPR
15579 or POINTER_PLUS_EXPR.
15581 2024-04-30 Jakub Jelinek <jakub@redhat.com>
15583 PR tree-optimization/114876
15584 * gimple-ssa-sprintf.cc (format_character): For min == 0 && max == 0,
15585 set max, likely and unlikely members to 1 rather than 0. Remove
15586 useless res.knownrange = true;. Formatting fixes.
15588 2024-04-30 Jakub Jelinek <jakub@redhat.com>
15589 Hongtao Liu <hongtao.liu@intel.com>
15591 PR tree-optimization/114883
15592 * tree-vect-loop.cc (vect_transform_reduction): Allow IFN_COND_MIN and
15593 IFN_COND_MAX in the assert.
15595 2024-04-30 Jakub Jelinek <jakub@redhat.com>
15597 * doc/cpp.texi (__STDC_VERSION__): Document 202311L value
15598 for -std=c23/-std=gnu23.
15600 2024-04-30 Richard Biener <rguenther@suse.de>
15602 PR middle-end/114734
15603 * internal-fn.cc (expand_call_mem_ref): Use
15604 get_gimple_for_ssa_name to get at the def stmt of the address
15605 argument to honor SSA coalescing constraints.
15607 2024-04-29 demin.han <demin.han@starfivetech.com>
15610 * config/riscv/riscv-vector-costs.cc (non_contiguous_memory_access_p): Rename
15611 (need_additional_vector_vars_p): Rename and refine condition
15613 2024-04-29 Pan Li <pan2.li@intel.com>
15616 * config/riscv/riscv.cc (riscv_legitimize_subreg_const_poly_move): New
15617 func impl to take care of (const_int_poly:TI 8).
15618 (riscv_legitimize_move): Handle subreg is const_int_poly,
15620 2024-04-29 Christoph Müllner <christoph.muellner@vrull.eu>
15622 * common/config/riscv/riscv-common.cc: Move ziccamoa, ziccif,
15623 zicclsm, and ziccrse into riscv_zi_subext.
15624 * config/riscv/riscv.opt: Define MASK_ZIC64B for
15625 riscv_ziccmo_subext.
15627 2024-04-29 Jie Mei <jie.mei@oss.cipunited.com>
15629 * config/mips/i6400.md (i6400_fpu_minmax): New
15630 define_insn_reservation.
15631 * config/mips/mips.h (ISA_HAS_FMIN_FMAX): Define new macro.
15632 * config/mips/mips.md (UNSPEC_FMIN): New unspec.
15633 (UNSPEC_FMAX): Same as above.
15634 (type): Add fminmax.
15635 (smin<mode>3): Generates MIN.fmt instructions.
15636 (smax<mode>3): Generates MAX.fmt instructions.
15637 (fmin<mode>3): Generates MIN.fmt instructions.
15638 (fmax<mode>3): Generates MAX.fmt instructions.
15639 * config/mips/p6600.md (p6600_fpu_fabs): Include fminmax
15642 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15644 * tree-ssa-ccp.cc (ccp_finalize): Normalize before calling
15646 * value-range.cc (irange::intersect_bitmask): Calculate changed
15647 irange_bitmask bits on our own.
15648 (irange::union_bitmask): Same.
15649 (irange_bitmask::verify_mask): Verify that bits are normalized.
15650 * value-range.h (irange_bitmask::union_): Do not normalize.
15651 Remove return value.
15652 (irange_bitmask::intersect): Same.
15654 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15656 * range-op-ptr.cc (pointer_plus_operator::wi_fold): Use method
15657 range setters instead of out of line functions.
15658 (pointer_min_max_operator::wi_fold): Same.
15659 (pointer_and_operator::wi_fold): Same.
15660 (pointer_or_operator::wi_fold): Same.
15661 * range-op.cc (operator_negate::fold_range): Same.
15662 (operator_addr_expr::fold_range): Same.
15663 (range_op_cast_tests): Same.
15664 * range.cc (range_zero): Remove.
15665 (range_nonzero): Remove.
15666 * range.h (range_zero): Remove.
15667 (range_nonzero): Remove.
15668 * value-range.cc (range_tests_misc): Use method instead of out of
15671 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15673 * value-range-pretty-print.cc (print_int_bound): New.
15674 (print_irange_bitmasks): New.
15675 (vrange_printer::print_irange_bound): Remove.
15676 (vrange_printer::print_irange_bitmasks): Remove.
15677 * value-range-pretty-print.h: Remove print_irange_bitmasks and
15680 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15682 * value-range.h (range_includes_zero_p): Accept vrange.
15684 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15686 * tree-ssa-loop-split.cc (split_at_bb_p): Make int_range a Value_Range.
15687 * tree-ssa-strlen.cc (get_range): Same.
15688 * value-query.cc (range_query::get_tree_range): Handle both
15689 integers and pointers.
15690 * vr-values.cc (simplify_using_ranges::fold_cond_with_ops): Make
15691 r0 and r1 Value_Range's.
15693 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15695 * value-range.cc (get_bitmask_from_range): Move out of irange class.
15696 (irange::get_bitmask): Call function instead of internal method.
15697 * value-range.h (class irange): Remove get_bitmask_from_range.
15699 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15701 * value-range.cc (get_legacy_range): Make static and add another
15702 version of get_legacy_range that takes a vrange.
15703 * value-range.h (class irange): Remove unnecessary friendship with
15705 (get_legacy_range): Accept a vrange.
15707 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15709 * value-range-storage.cc (irange_storage::set_irange): Move
15710 verification code from here...
15711 (vrange_storage::set_vrange): ...to here.
15713 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15715 * gimple-range-op.cc (cfn_clz::fold_range): Change
15716 range_includes_zero_p argument to a reference.
15717 (cfn_ctz::fold_range): Same.
15718 * range-op.cc (operator_plus::lhs_op1_relation): Same.
15719 * value-range.h (range_includes_zero_p): Same.
15721 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15723 * vr-values.cc (simplify_using_ranges::fold_cond_with_ops): Remove
15724 type from range_true and range_false.
15726 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15728 * value-range-storage.h: Remove friends.
15729 * value-range.cc (gt_ggc_mx): Remove.
15730 (gt_pch_nx): Remove.
15731 * value-range.h (class vrange): Remove GTY markers.
15732 (class irange): Same.
15733 (class int_range): Same.
15734 (class frange): Same.
15735 (gt_ggc_mx): Remove.
15736 (gt_pch_nx): Remove.
15738 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15740 * ipa-cp.cc (propagate_bits_across_jump_function): Access bitmask
15741 through base class.
15742 (ipcp_store_vr_results): Same.
15743 * ipa-prop.cc (ipa_compute_jump_functions_for_edge): Same.
15744 (ipcp_get_parm_bits): Same.
15745 (ipcp_update_vr): Same.
15746 * range-op-mixed.h (update_known_bitmask): Change argument to vrange.
15747 * range-op.cc (update_known_bitmask): Same.
15748 * value-range.cc (vrange::update_bitmask): New.
15749 (irange::set_nonzero_bits): Move to vrange class.
15750 (irange::get_nonzero_bits): Same.
15751 * value-range.h (class vrange): Add update_bitmask, get_bitmask,
15752 get_nonzero_bits, and set_nonzero_bits.
15753 (class irange): Make bitmask methods virtual overrides.
15754 (class Value_Range): Add get_bitmask and update_bitmask.
15756 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15758 * tree-ssa-loop-niter.cc (refine_value_range_using_guard): Convert
15760 * value-range.cc (Value_Range::lower_bound): Remove.
15761 (Value_Range::upper_bound): Remove.
15762 (unsupported_range::lbound): New.
15763 (unsupported_range::ubound): New.
15764 (frange::lbound): New.
15765 (frange::ubound): New.
15766 (irange::lbound): New.
15767 (irange::ubound): New.
15768 * value-range.h (class vrange): Add lbound() and ubound().
15769 (class irange): Same.
15770 (class frange): Same.
15771 (class unsupported_range): Same.
15772 (class Value_Range): Rename lower_bound and upper_bound to lbound
15773 and ubound respectively.
15775 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15777 * gimple-ssa-warn-access.cc (check_nul_terminated_array): Make Value_Range an int_range.
15778 (memmodel_to_uhwi): Same
15779 * tree-ssa-loop-niter.cc (refine_value_range_using_guard): Same.
15780 (determine_value_range): Same.
15781 (infer_loop_bounds_from_signedness): Same.
15782 (scev_var_range_cant_overflow): Same.
15784 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15786 * value-range.h (vrange::~vrange): New.
15787 (int_range::~int_range): Make final override.
15789 2024-04-28 Aldy Hernandez <aldyh@redhat.com>
15791 * value-range.cc (unsupported_range::accept): Move down.
15792 (vrange::contains_p): Rename to...
15793 (unsupported_range::contains_p): ...this.
15794 (vrange::singleton_p): Rename to...
15795 (unsupported_range::singleton_p): ...this.
15796 (vrange::set): Rename to...
15797 (unsupported_range::set): ...this.
15798 (vrange::type): Rename to...
15799 (unsupported_range::type): ...this.
15800 (vrange::supports_type_p): Rename to...
15801 (unsupported_range::supports_type_p): ...this.
15802 (vrange::set_undefined): Rename to...
15803 (unsupported_range::set_undefined): ...this.
15804 (vrange::set_varying): Rename to...
15805 (unsupported_range::set_varying): ...this.
15806 (vrange::union_): Rename to...
15807 (unsupported_range::union_): ...this.
15808 (vrange::intersect): Rename to...
15809 (unsupported_range::intersect): ...this.
15810 (vrange::zero_p): Rename to...
15811 (unsupported_range::zero_p): ...this.
15812 (vrange::nonzero_p): Rename to...
15813 (unsupported_range::nonzero_p): ...this.
15814 (vrange::set_nonzero): Rename to...
15815 (unsupported_range::set_nonzero): ...this.
15816 (vrange::set_zero): Rename to...
15817 (unsupported_range::set_zero): ...this.
15818 (vrange::set_nonnegative): Rename to...
15819 (unsupported_range::set_nonnegative): ...this.
15820 (vrange::fits_p): Rename to...
15821 (unsupported_range::fits_p): ...this.
15822 (unsupported_range::operator=): New.
15823 (frange::fits_p): New.
15824 * value-range.h (class vrange): Make an abstract class.
15825 (class unsupported_range): Declare override methods.
15827 2024-04-28 Gerald Pfeifer <gerald@pfeifer.com>
15831 * doc/install.texi (Specific) <*-*-freebsd*>: Remove references to
15832 FreeBSD 7 and older.
15834 2024-04-28 Gerald Pfeifer <gerald@pfeifer.com>
15836 * doc/contrib.texi: Update David Binderman's entry.
15838 2024-04-28 liuhongt <hongtao.liu@intel.com>
15840 * config/i386/i386.md: (zero_extendsidi2): Adjust
15841 alternative *k to ?k.
15842 (zero_extend<mode>di2): Ditto.
15843 (*zero_extend<mode>si2): Ditto.
15844 (*zero_extendqihi2): Ditto.
15846 2024-04-28 Jiufu Guo <guojiufu@linux.ibm.com>
15849 * config/s390/s390-c.cc (s390_macro_to_expand): Avoid empty identifier.
15851 2024-04-28 Andrew Pinski <quic_apinski@quicinc.com>
15854 * config/aarch64/aarch64.cc (aarch64_evpc_reencode): Use
15855 vec_perm_indices::new_shrunk_vector instead of manually
15856 going through the indices.
15858 2024-04-27 Xi Ruoyao <xry111@xry111.site>
15861 * config/loongarch/loongarch.md (bstrins_<mode>_for_mask): Add
15862 constraints for operands.
15863 (bstrins_<mode>_for_ior_mask): Likewise.
15865 2024-04-27 Fangrui Song <maskray@gcc.gnu.org>
15867 * config/riscv/elf.h (LINK_SPEC): Add -X.
15868 * config/riscv/freebsd.h (LINK_SPEC): Add -X.
15869 * config/riscv/linux.h (LINK_SPEC): Add -X.
15871 2024-04-26 Wilco Dijkstra <wilco.dijkstra@arm.com>
15873 * config/aarch64/aarch64.cc (MAX_SET_SIZE): New define.
15874 (aarch64_progress_pointer): Remove function.
15875 (aarch64_set_one_block_and_progress_pointer): Simplify and clean up.
15876 (aarch64_expand_setmem): Clean up implementation, use byte offsets,
15877 simplify size calculation.
15879 2024-04-26 Wilco Dijkstra <wilco.dijkstra@arm.com>
15881 * config/aarch64/aarch64.cc (aarch64_mode_valid_for_sched_fusion_p):
15882 Remove check for AARCH64_EXTRA_TUNE_NO_LDP_STP_QREGS.
15883 (aarch64_advsimd_ldp_stp_p): Likewise.
15884 (aarch64_stp_sequence_cost): Likewise.
15885 (aarch64_expand_cpymem): Likewise.
15886 (aarch64_expand_setmem): Likewise.
15887 * config/aarch64/aarch64-ldp-fusion.cc (ldp_operand_mode_ok_p):
15889 * config/aarch64/aarch64-ldpstp.md: Likewise.
15890 * config/aarch64/aarch64-tuning-flags.def: Remove NO_LDP_STP_QREGS.
15891 * config/aarch64/tuning_models/emag.h: Likewise.
15892 * config/aarch64/tuning_models/xgene1.h: Likewise.
15894 2024-04-26 Frederik Harwath <frederik@harwath.name>
15896 * config.gcc: Add gfx90c.
15897 * config/gcn/gcn-hsa.h (NO_SRAM_ECC): Likewise.
15898 * config/gcn/gcn-opts.h (enum processor_type): Likewise.
15899 (TARGET_GFX90c): New macro.
15900 * config/gcn/gcn.cc (gcn_option_override): Handle gfx90c.
15901 (gcn_omp_device_kind_arch_isa): Likewise.
15902 (output_file_start): Likewise.
15903 * config/gcn/gcn.h: Add gfx90c.
15904 * config/gcn/gcn.opt: Likewise.
15905 * config/gcn/mkoffload.cc (EF_AMDGPU_MACH_AMDGCN_GFX90c): New macro.
15906 (get_arch): Handle gfx90c.
15907 (main): Handle EF_AMDGPU_MACH_AMDGCN_GFX90c
15908 * config/gcn/t-omp-device: Add gfx90c.
15909 * doc/install.texi: Likewise.
15910 * doc/invoke.texi: Likewise.
15912 2024-04-25 David Faust <david.faust@oracle.com>
15914 * config/bpf/bpf.h (PREFERRED_DEBUGGING_TYPE): Set to BTF_DEBUG.
15916 2024-04-25 David Faust <david.faust@oracle.com>
15918 * config/bpf/bpf.cc (bpf_option_override): Improve handling of CO-RE
15919 options to avoid issues with -gtoggle.
15921 2024-04-25 Jakub Jelinek <jakub@redhat.com>
15924 * tree-nested.cc (get_debug_decl): New function.
15925 (get_nonlocal_debug_decl): Use it.
15926 (get_local_debug_decl): Likewise.
15928 2024-04-25 Jose E. Marchesi <jose.marchesi@oracle.com>
15930 * config/bpf/bpf.opt: Use ASM_PSEUDOC for the default value of
15932 * config/bpf/bpf.h (ASM_SPEC): Adapt accordingly.
15933 * doc/invoke.texi (eBPF Options): Update.
15935 2024-04-25 Richard Ball <richard.ball@arm.com>
15938 * config/arm/arm.cc (cmse_nonsecure_call_inline_register_clear):
15939 Add zero/sign extend.
15940 (arm_expand_prologue): Add zero/sign extend.
15942 2024-04-25 Richard Biener <rguenther@suse.de>
15944 PR tree-optimization/114792
15945 * tree-ssa-loop-ch.cc (ch_order_loops): New function.
15946 (ch_base::copy_headers): Sort loops to unloop inner-to-outer.
15948 2024-04-25 Eric Botcazou <ebotcazou@adacore.com>
15951 * config/sparc/sparc.h (SUN_V9_ABI_COMPATIBILITY): New macro.
15952 * config/sparc/sol2.h (SUN_V9_ABI_COMPATIBILITY): Redefine it.
15953 * config/sparc/sparc.cc (fp_type_for_abi): New predicate.
15954 (traverse_record_type): Use it to spot floating-point types.
15955 (compute_fp_layout): Also deal with array types.
15957 2024-04-25 Pan Li <pan2.li@intel.com>
15959 * config/riscv/vector-crypto.md: Add early clobber to the
15960 dest operand of vwsll.
15962 2024-04-25 Haochen Gui <guihaoc@gcc.gnu.org>
15964 * config/rs6000/altivec.md (*bcdinvalid_<mode>): Replace bcdadd
15966 (bcdinvalid_<mode>): Likewise.
15968 2024-04-24 Jakub Jelinek <jakub@redhat.com>
15971 * opts.cc (get_option_url): Revert 2024-04-17 changes.
15972 * gcc-urlifier.cc: Don't include diagnostic-core.h.
15973 (gcc_urlifier::make_doc_url): Revert 2024-04-17 changes.
15974 * configure.ac (documentation-root-url): On release branches
15975 append gcc-MAJOR.MINOR.0/ to the default DOCUMENTATION_ROOT_URL.
15976 * doc/install.texi (--with-documentation-root-url=): Document
15977 the change of the default.
15978 * configure: Regenerate.
15980 2024-04-24 Pan Li <pan2.li@intel.com>
15983 2023-11-29 Juzhe-Zhong <juzhe.zhong@rivai.ai>
15984 kito-cheng <kito.cheng@sifive.com>
15985 kito-cheng <kito.cheng@gmail.com>
15988 * config/riscv/constraints.md (TARGET_VECTOR ? V_REGS : NO_REGS): New register filters.
15989 * config/riscv/riscv.md (no,W21,W42,W84,W41,W81,W82): Ditto.
15991 * config/riscv/vector.md: Support highpart register overlap for vwcvt.
15993 2024-04-24 Jose E. Marchesi <jose.marchesi@oracle.com>
15995 * config.gcc: Add bpf-c.o as a target object for C and C++.
15996 * config/bpf/bpf.cc (bpf_target_macros): Move to bpf-c.cc.
15997 * config/bpf/bpf-c.cc: New file.
15998 (bpf_target_macros): Move from bpf.cc and define BPF CPU
16000 * config/bpf/t-bpf: Add rules to build bpf-c.o.
16002 2024-04-24 Richard Biener <rguenther@suse.de>
16004 PR tree-optimization/114787
16005 * tree-cfg.cc (remove_edge_and_dominated_blocks): When
16006 removing a loop backedge clear niter info and when removing
16007 the last backedge of a loop mark that loop for removal.
16009 2024-04-24 Richard Biener <rguenther@suse.de>
16011 PR tree-optimization/114832
16012 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
16013 Fix dominance check.
16015 2024-04-24 Haochen Jiang <haochen.jiang@intel.com>
16017 * config/i386/i386-options.cc (ix86_valid_target_attribute_tree):
16018 Check whether AVX512F is explicitly enabled.
16020 2024-04-24 Pan Li <pan2.li@intel.com>
16023 2023-11-30 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16025 * config/riscv/vector.md: Support highpart overlap for vext.vf2
16027 2024-04-23 Jakub Jelinek <jakub@redhat.com>
16030 * config/i386/i386.md (*andn<dwi>3_doubleword_bmi): Split the =&r,r,ro
16031 alternative into =&r,r,r enabled only for x64 and =&r,r,o.
16033 2024-04-23 Jan Hubicka <jh@suse.cz>
16035 * doc/invoke.texi (-ftree-loop-distribute-patterns): Remove duplicated
16036 sentence about optimization flags implying this.
16038 2024-04-23 Jakub Jelinek <jakub@redhat.com>
16040 * config/darwin.opt (init): Spelling fix: initialiser -> initializer.
16042 2024-04-23 Jakub Jelinek <jakub@redhat.com>
16044 * config/epiphany/epiphany.opt (may-round-for-trunc): Spelling fix:
16045 floatig -> floating.
16046 * config/riscv/riscv.opt (mcsr-check): Spelling fix: CRS -> CSR.
16047 * params.opt (-param=ipa-cp-profile-count-base=): Spelling fix:
16048 frequncy -> frequency.
16050 2024-04-23 Richard Biener <rguenther@suse.de>
16052 PR tree-optimization/114799
16053 * tree-vect-slp.cc (vect_get_and_check_slp_defs): Properly
16054 update ->any_pattern when swapping operands.
16056 2024-04-23 Andreas Krebbel <krebbel@linux.ibm.com>
16059 * config/s390/s390-c.cc (s390_expand_overloaded_builtin): Use a
16060 MEM_REF with an addend of type ptr_type_node.
16062 2024-04-23 Yang Yujie <yangyujie@loongson.cn>
16064 * config.gcc: Add loongarch-evolution.o.
16065 * config/loongarch/genopts/genstr.sh: Enable generation of
16066 loongarch-evolution.[cc,h].
16067 * config/loongarch/t-loongarch: Likewise.
16068 * config/loongarch/genopts/gen-evolution.awk: New file.
16069 * config/loongarch/genopts/isa-evolution.in: Mark ISA version
16070 of introduction for each ISA evolution feature.
16071 * config/loongarch/loongarch-c.cc (loongarch_cpu_cpp_builtins):
16072 Define builtin macros for enabled ISA evolutions and the ISA
16074 * config/loongarch/loongarch-cpu.cc: Use loongarch-evolution.h.
16075 * config/loongarch/loongarch.h: Likewise.
16076 * config/loongarch/loongarch-cpucfg-map.h: Delete.
16077 * config/loongarch/loongarch-evolution.cc: New file.
16078 * config/loongarch/loongarch-evolution.h: New file.
16079 * config/loongarch/loongarch-opts.h (ISA_HAS_FRECIPE): Define.
16080 (ISA_HAS_DIV32): Likewise.
16081 (ISA_HAS_LAM_BH): Likewise.
16082 (ISA_HAS_LAMCAS): Likewise.
16083 (ISA_HAS_LD_SEQ_SA): Likewise.
16085 2024-04-23 Yang Yujie <yangyujie@loongson.cn>
16087 * config.gcc: Make la64v1.0 the default ISA preset of the lp64d ABI.
16088 * config/loongarch/genopts/loongarch-strings: Define la64v1.0, la64v1.1.
16089 * config/loongarch/genopts/loongarch.opt.in: Likewise.
16090 * config/loongarch/loongarch-c.cc (LARCH_CPP_SET_PROCESSOR): Likewise.
16091 (loongarch_cpu_cpp_builtins): Likewise.
16092 * config/loongarch/loongarch-cpu.cc (get_native_prid): Likewise.
16093 (fill_native_cpu_config): Likewise.
16094 * config/loongarch/loongarch-def.cc (array_tune): Likewise.
16095 * config/loongarch/loongarch-def.h: Likewise.
16096 * config/loongarch/loongarch-driver.cc (driver_set_m_parm): Likewise.
16097 (driver_get_normalized_m_opts): Likewise.
16098 * config/loongarch/loongarch-opts.cc (default_tune_for_arch): Likewise.
16099 (TUNE_FOR_ARCH): Likewise.
16100 (arch_str): Likewise.
16101 (loongarch_target_option_override): Likewise.
16102 * config/loongarch/loongarch-opts.h (TARGET_uARCH_LA464): Likewise.
16103 (TARGET_uARCH_LA664): Likewise.
16104 * config/loongarch/loongarch-str.h (STR_CPU_ABI_DEFAULT): Likewise.
16105 (STR_ARCH_ABI_DEFAULT): Likewise.
16106 (STR_TUNE_GENERIC): Likewise.
16107 (STR_ARCH_LA64V1_0): Likewise.
16108 (STR_ARCH_LA64V1_1): Likewise.
16109 * config/loongarch/loongarch.cc (loongarch_cpu_sched_reassociation_width): Likewise.
16110 (loongarch_asm_code_end): Likewise.
16111 * config/loongarch/loongarch.opt: Likewise.
16112 * doc/invoke.texi: Likewise.
16114 2024-04-22 Pan Li <pan2.li@intel.com>
16116 * config/riscv/vector-crypto.md:
16118 2024-04-22 Pan Li <pan2.li@intel.com>
16121 2023-11-30 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16123 * config/riscv/constraints.md (TARGET_VECTOR ? V_REGS : NO_REGS): Fix constraint.
16124 * config/riscv/riscv.md (no,W21,W42,W84,W41,W81,W82): Rename vconstraint into group_overlap.
16126 (none,W21,W42,W84,W43,W86,W87): Ditto.
16127 * config/riscv/vector.md: Ditto.
16129 2024-04-22 Pan Li <pan2.li@intel.com>
16132 2023-12-04 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16134 * config/riscv/riscv.md: Rostify the constraints.
16136 2024-04-22 Haochen Jiang <haochen.jiang@intel.com>
16138 * common/config/i386/i386-common.cc (processor_alias_table):
16139 Let Sierra Forest map to CPU_TYPE enum.
16141 2024-04-22 Andreas Krebbel <krebbel@linux.ibm.com>
16143 * config/s390/s390.cc (s390_option_override_internal): Check zarch
16144 flag before enabling -mvx.
16146 2024-04-22 Pan Li <pan2.li@intel.com>
16149 2023-11-30 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16152 * config/riscv/vector.md: Add widenning overlap.
16154 2024-04-22 Pan Li <pan2.li@intel.com>
16157 2023-12-01 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16160 * config/riscv/vector.md: Support highpart overlap for indexed load.
16162 2024-04-22 Pan Li <pan2.li@intel.com>
16165 2023-12-04 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16168 * config/riscv/vector.md: Add highest-number overlap support.
16170 2024-04-22 Pan Li <pan2.li@intel.com>
16173 2023-11-30 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16176 * config/riscv/vector.md: Add widening overlap of vf2/vf4.
16178 2024-04-21 Pan Li <pan2.li@intel.com>
16181 2023-12-01 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16184 * config/riscv/vector.md: Support highpart overlap for vx/vf.
16186 2024-04-20 Pan Li <pan2.li@intel.com>
16189 2023-12-04 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16192 * config/riscv/vector.md: Fix incorrect overlap in v0.
16194 2024-04-20 Pan Li <pan2.li@intel.com>
16197 2023-12-11 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16200 * config/riscv/vector.md: Support highest overlap for wv instructions.
16202 2024-04-20 Pan Li <pan2.li@intel.com>
16205 2023-12-18 Juzhe-Zhong <juzhe.zhong@rivai.ai>
16208 * config/riscv/riscv.md (none,W21,W42,W84,W43,W86,W87): Add W0.
16209 (none,W21,W42,W84,W43,W86,W87,W0): Ditto.
16210 * config/riscv/vector.md: Ditto.
16212 2024-04-19 Jakub Jelinek <jakub@redhat.com>
16215 * config/i386/sse.md (*avx2_eq<mode>3): Change last operand's
16216 constraint from "jm" to "xjm".
16218 2024-04-19 Jakub Jelinek <jakub@redhat.com>
16220 PR middle-end/114753
16221 * internal-fn.cc (expand_arith_overflow): Add one missing restore
16222 of flag_trapv before return.
16224 2024-04-19 Tamar Christina <tamar.christina@arm.com>
16226 PR tree-optimization/114769
16227 * tree-vect-patterns.cc:
16228 (vect_recog_absolute_difference): Have only one success condition.
16229 (vect_recog_abd_pattern): Handle further checks if
16230 vect_recog_absolute_difference fails.
16232 2024-04-19 Cupertino Miranda <cupertino.miranda@oracle.com>
16234 * config/bpf/core-builtins.cc (get_index_for_enum_value): Create
16236 (pack_enum_value): Check for enumerator and error out.
16237 (process_enum_value): Correct string allocation.
16239 2024-04-19 Cupertino Miranda <cupertino.miranda@oracle.com>
16241 * config/bpf/bpf-protos.h (bpf_add_core_reloc): Renamed function
16242 to bpf_output_move.
16243 * config/bpf/bpf.cc (bpf_legitimate_address_p): Allow
16244 UNSPEC_CORE_RELOC to match an address.
16245 (bpf_insn_cost): Make UNSPEC_CORE_RELOC immediate moves
16246 expensive to prioritize loads and stores.
16247 (TARGET_INSN_COST): Add hook.
16248 (bpf_output_move): Wrapper to call bpf_output_core_reloc.
16249 (bpf_print_operand): Add support to print immediate operands
16250 specified with the UNSPEC_CORE_RELOC.
16251 (bpf_print_operand_address): Likewise, but to support
16252 UNSPEC_CORE_RELOC in addresses.
16253 (bpf_init_builtins): Flag BPF_BUILTIN_CORE_RELOC as NOTHROW.
16254 * config/bpf/bpf.md: Wrap patterns for MOV, LD and ST
16255 instruction with bpf_output_move call.
16256 (mov_reloc_core<MM:mode>): Remove now spurious define_insn.
16257 * config/bpf/constraints.md: Added "c" and "C" constraints to
16258 match immediates represented with UNSPEC_CORE_RELOC.
16259 * config/bpf/core-builtins.cc (bpf_add_core_reloc): Remove
16260 (bpf_output_core_reloc): Add function to create the CO-RE
16261 relocations based on new matching rules.
16262 * config/bpf/core-builtins.h (bpf_output_core_reloc): Add
16264 * config/bpf/predicates.md (core_imm_operand) Add predicate.
16265 (mov_src_operand): Add match for core_imm_operand.
16267 2024-04-19 Jakub Jelinek <jakub@redhat.com>
16269 PR rtl-optimization/114768
16270 * rtlanal.cc (set_noop_p): Don't return true for MEM <- MEM
16271 sets if src has side-effects or for stores into ZERO_EXTRACT
16272 if ZERO_EXTRACT operand has side-effects.
16274 2024-04-19 Alexandre Oliva <oliva@adacore.com>
16276 * config/t-vxworks (vxw-glimits.h): Don't mangle c23-required
16277 __STDC_VERSION_LIMITS_H__ define.
16279 2024-04-18 Sandra Loosemore <sloosemore@baylibre.com>
16281 * config.gcc: Add nios2*-*-* to the list of obsoleted targets.
16283 2024-04-18 Alexandre Oliva <oliva@adacore.com>
16285 * doc/sourcebuild.texi (strndup): Add effective target.
16287 2024-04-18 Tamar Christina <tamar.christina@arm.com>
16290 * config/aarch64/aarch64.md (<optab><mode>3): Remove ^ from alt 2.
16291 (copysign<GPF:mode>3): Use SIMD version of IOR directly.
16293 2024-04-18 Jakub Jelinek <jakub@redhat.com>
16295 PR middle-end/114753
16296 * internal-fn.cc (expand_mul_overflow): Save flag_trapv and
16297 temporarily clear it for the duration of the function, then
16298 restore previous value.
16299 (expand_vector_ubsan_overflow): Likewise.
16300 (expand_arith_overflow): Likewise.
16302 2024-04-17 Jakub Jelinek <jakub@redhat.com>
16305 * opts.cc (get_option_url): On release branches append
16306 gcc-MAJOR.MINOR.0/ after DOCUMENTATION_ROOT_URL.
16307 * gcc-urlifier.cc (gcc_urlifier::make_doc_url): Likewise.
16309 2024-04-17 Richard Biener <rguenther@suse.de>
16311 PR tree-optimization/114749
16312 * tree-vect-loop.cc (vect_analyze_loop_2): Reset
16313 LOOP_VINFO_USING_PARTIAL_VECTORS_P when re-trying without SLP.
16315 2024-04-17 Georg-Johann Lay <avr@gjlay.de>
16318 * config/avr/avr.cc (avr_print_operand) [CONST_DOUBLE_P]: Handle DFmode.
16320 2024-04-17 Jakub Jelinek <jakub@redhat.com>
16322 PR sanitizer/114743
16323 * asan.cc (maybe_instrument_call): Don't instrument calls to
16324 .ABNORMAL_DISPATCHER.
16326 2024-04-16 Andrew Pinski <quic_apinski@quicinc.com>
16329 * doc/extend.texi (Using Vector Instructions): Add that
16330 the base_types could be a typedef of them.
16332 2024-04-16 Richard Biener <rguenther@suse.de>
16334 PR tree-optimization/114736
16335 * tree-vect-slp.cc (vect_optimize_slp_pass::is_cfg_latch_edge):
16336 Do not consider VEC_PERM_EXPRs as PHI use.
16338 2024-04-16 Richard Biener <rguenther@suse.de>
16340 PR tree-optimization/114733
16341 * tree-vect-loop.cc (vectorizable_nonlinear_induction): Reject
16342 neg induction vectorization of single element vectors.
16344 2024-04-16 Jakub Jelinek <jakub@redhat.com>
16346 * tree.cc (array_type_nelts): Ensure 2 spaces after . in comment
16347 instead of just one.
16348 (build_variant_type_copy): Likewise.
16349 (tree_check_failed): Likewise.
16350 (build_atomic_base): Likewise.
16351 * ipa-free-lang-data.cc (fld_incomplete_type_of): Use an indefinite
16352 article rather than a.
16354 2024-04-16 Fei Gao <gaofei@eswincomputing.com>
16356 * config/riscv/riscv.cc (riscv_expand_conditional_move):
16357 replace or with add when expanding zicond if possible.
16359 2024-04-16 Alexandre Oliva <oliva@adacore.com>
16361 PR middle-end/112938
16362 * ipa-strub.cc (pass_ipa_strub::execute): Drop volatility from
16364 (maybe_make_indirect): Restore volatility in dereferences.
16366 2024-04-16 Lulu Cheng <chenglulu@loongson.cn>
16368 * config/loongarch/loongarch.opt.urls: Regenerate.
16369 * config/mn10300/mn10300.opt.urls: Likewise.
16370 * config/msp430/msp430.opt.urls: Likewise.
16371 * config/nds32/nds32-elf.opt.urls: Likewise.
16372 * config/nds32/nds32-linux.opt.urls: Likewise.
16373 * config/nds32/nds32.opt.urls: Likewise.
16374 * config/pru/pru.opt.urls: Likewise.
16375 * config/riscv/riscv.opt.urls: Likewise.
16376 * config/rx/rx.opt.urls: Likewise.
16377 * config/sh/sh.opt.urls: Likewise.
16378 * config/sparc/sparc.opt.urls: Likewise.
16379 * doc/invoke.texi: Add indexes for some compilation options.
16381 2024-04-15 Georg-Johann Lay <avr@gjlay.de>
16383 * config/avr/avr-mcus.def: Add: avr16du14, avr16du20, avr16du28,
16384 avr16du32, avr32du14, avr32du20, avr32du28, avr32du32.
16385 * doc/avr-mmcu.texi: Rebuild.
16387 2024-04-15 Robin Dapp <rdapp@ventanamicro.com>
16390 * config/riscv/autovec.md: Add VLS.
16392 2024-04-15 Richard Biener <rguenther@suse.de>
16394 PR gcov-profile/114715
16395 * gimplify.cc (gimplify_switch_expr): Set the location of the
16398 2024-04-15 H.J. Lu <hjl.tools@gmail.com>
16401 * config/i386/i386.md (isa): Add apx_ndd_64.
16402 (enabled): Likewise.
16403 (*add<dwi>3_doubleword): Change rjO to r,ro,jO with 8-bit
16404 signed integer constant and enable jO only for apx_ndd_64.
16405 (*add<dwi>3_doubleword_cc_overflow_1): Likewise.
16406 (*and<dwi>3_doubleword): Likewise.
16407 (*<code><dwi>3_doubleword): Likewise.
16409 2024-04-15 Tamar Christina <tamar.christina@arm.com>
16411 PR tree-optimization/114403
16412 * tree-vect-loop.cc (vect_transform_loop): Adjust upper bounds for when
16413 peeling for gaps and early break.
16415 2024-04-15 Jakub Jelinek <jakub@redhat.com>
16418 * attribs.cc (diag_attr_exclusions): Set attrs[1] to NULL_TREE for
16419 decls with NULL TREE_TYPE.
16421 2024-04-12 Andrew Carlotti <andrew.carlotti@arm.com>
16423 * config/aarch64/aarch64-option-extensions.def: Add RCPC to
16424 RCPC3 dependencies.
16425 * config/aarch64/aarch64.h (AARCH64_ISA_RCPC8_4): Add test for
16428 2024-04-12 Andrew Carlotti <andrew.carlotti@arm.com>
16430 * config/aarch64/aarch64-arches.def: Add CSSC to V8_9A
16433 2024-04-12 Will Schmidt <will_schmidt@linux.ibm.com>
16434 Peter Bergner <bergner@linux.ibm.com>
16437 * config/rs6000/rs6000-builtin.cc (rs6000_builtin_is_supported): Use
16439 * config/rs6000/rs6000-c.cc (rs6000_target_modify_macros): Use
16440 OPTION_MASK_POWER8.
16441 * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Add OPTION_MASK_POWER8.
16442 (ISA_2_7_MASKS_SERVER): Likewise.
16443 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Update
16444 comment. Use OPTION_MASK_POWER8 and TARGET_POWER8.
16445 * config/rs6000/rs6000.h (TARGET_SYNC_HI_QI): Use TARGET_POWER8.
16446 * config/rs6000/rs6000.md (define_attr "isa"): Add p8.
16447 (define_attr "enabled"): Handle it.
16448 (define_insn "prefetch"): Use TARGET_POWER8.
16449 * config/rs6000/rs6000.opt (mpower8-internal): New.
16451 2024-04-12 Jason Merrill <jason@redhat.com>
16452 Patrick Palka <ppalka@redhat.com>
16455 * doc/invoke.texi: Document -Wcast-user-defined.
16457 2024-04-12 Tatsuyuki Ishi <ishitatsuyuki@gmail.com>
16459 * config/riscv/riscv.opt.urls: Regenerated.
16461 2024-04-12 Andrew Pinski <quic_apinski@quicinc.com>
16463 PR tree-optimization/114666
16464 * match.pd (`!a?b:c`): Reject signed types for the condition.
16465 (`a?~t:t`): Likewise.
16467 2024-04-12 Richard Sandiford <richard.sandiford@arm.com>
16469 * config/aarch64/aarch64.cc (aarch64_output_sme_zero_za): Require
16470 all tiles to have the same suffix.
16472 2024-04-12 Pan Li <pan2.li@intel.com>
16474 * config/riscv/riscv.cc (riscv_vector_float_type_p): Take int
16475 as the return value instead of unsigned.
16476 (riscv_vector_element_bitsize): Ditto.
16477 (riscv_vector_required_min_vlen): Ditto.
16478 (riscv_validate_vector_type): Take int type for local variable(s).
16480 2024-04-12 Jakub Jelinek <jakub@redhat.com>
16482 * tree-cfg.cc (gimple_verify_flow_info): Make the misplaced
16483 returns_twice diagnostics translatable.
16485 2024-04-12 Jakub Jelinek <jakub@redhat.com>
16487 PR sanitizer/114687
16488 * gimple-iterator.cc (gsi_safe_insert_before): Only use
16489 edge_before_returns_twice_call if bb_has_abnormal_pred.
16490 (gsi_safe_insert_seq_before): Likewise.
16491 * gimple-lower-bitint.cc (bitint_large_huge::lower_call): Only
16492 push to m_returns_twice_calls if bb_has_abnormal_pred.
16494 2024-04-12 Pan Li <pan2.li@intel.com>
16497 * config/riscv/riscv.cc (riscv_function_value_regno_p): Add
16498 TARGET_VECTOR predicate for V_RETURN regno.
16500 2024-04-11 David Faust <david.faust@oracle.com>
16502 * btfout.cc (btf_asm_type_ref): Convert IDs to BTF internally and
16503 fix potentially looking up wrong type for asm debug comment info.
16505 (btf_asm_datasec_type_ref): ... This. New.
16506 (btf_asm_datasec_entry): Call it here, instead of btf_asm_type_ref.
16507 (btf_asm_type, btf_asm_array, btf_asm_varent, btf_asm_sou_member)
16508 (btf_asm_func_arg, btf_asm_func_type): Adapt btf_asm_type_ref call.
16510 2024-04-11 David Faust <david.faust@oracle.com>
16512 * btfout.cc (btf_asm_sou_member): Always emit non-representable
16513 bitfield members as having 'void' type. Refactor slightly.
16515 2024-04-11 Andrew Carlotti <andrew.carlotti@arm.com>
16517 * config/aarch64/aarch64-option-extensions.def:
16518 Remove "memtag", "memtag2", "ssbs", "ssbs2", "ls64", "ls64_v"
16519 and "ls64_accdata" FMV features.
16521 2024-04-11 Andrew Carlotti <andrew.carlotti@arm.com>
16523 * config/aarch64/aarch64-option-extensions.def:
16524 Remove "flagm2", "sha1", "pmull", "dit", "dpb", "dpb2", "jscvt",
16525 "fcma", "rcpc2", "frintts", "dgh", "ebf16", "sve-bf16",
16526 "sve-ebf16", "sve-i8mm", "sve2-pmull128", "memtag3", "bti" and
16529 2024-04-11 Andrew Carlotti <andrew.carlotti@arm.com>
16531 * config/aarch64/aarch64-option-extensions.def:
16532 Fix "rmd"->"rdm", and add FMV to "rdma".
16533 * config/aarch64/aarch64.cc (FEAT_RDMA): Define as FEAT_RDM.
16535 2024-04-11 Andrew Carlotti <andrew.carlotti@arm.com>
16537 * config/aarch64/aarch64.cc (compare_feature_masks):
16538 Use ARRAY_SIZE and >=0 for iteration bounds.
16539 (aarch64_mangle_decl_assembler_name): Use ARRAY_SIZE.
16541 2024-04-11 Andrew Carlotti <andrew.carlotti@arm.com>
16543 * config/aarch64/aarch64-option-extensions.def: Reorder FMV entries.
16545 2024-04-11 Gaius Mulley <gaiusmod2@gmail.com>
16547 * doc/standards.texi (Language Standards Supported by GCC):
16548 Add Modula-2 language section.
16550 2024-04-11 Jakub Jelinek <jakub@redhat.com>
16552 PR middle-end/110027
16553 * asan.cc (asan_emit_stack_protection): Assert offsets[0] is
16554 zero if there is no stack protect guard, otherwise
16555 -ASAN_RED_ZONE_SIZE. If alignb > ASAN_RED_ZONE_SIZE and there is
16556 stack pointer guard, take the ASAN_RED_ZONE_SIZE bytes allocated at
16557 the top of the stack into account when computing base_align_bias.
16558 Recompute use_after_return_class from asan_frame_size + base_align_bias
16559 and set to -1 if that would overflow to 11.
16561 2024-04-11 Richard Biener <rguenther@suse.de>
16563 PR tree-optimization/109596
16564 * tree-ssa-loop-ch.cc (ch_base::copy_headers): Propagate
16565 debug stmts to nonexit->dest rather than exit->dest.
16567 2024-04-11 Richard Biener <rguenther@suse.de>
16569 PR middle-end/114681
16570 * tree-inline.cc (copy_bb): Key on the remapped stmt
16571 to identify gconds to have condition coverage data remapped.
16573 2024-04-11 Pan Li <pan2.li@intel.com>
16576 * config/riscv/riscv.cc (riscv_function_value_regno_p): New func
16577 impl for hook TARGET_FUNCTION_VALUE_REGNO_P.
16578 (riscv_get_raw_result_mode): New func imple for hook
16579 TARGET_GET_RAW_RESULT_MODE.
16580 (TARGET_FUNCTION_VALUE_REGNO_P): Impl the hook.
16581 (TARGET_GET_RAW_RESULT_MODE): Ditto.
16582 * config/riscv/riscv.h (V_RETURN): New macro for vector return.
16583 (GP_RETURN_FIRST): New macro for the first GPR in return.
16584 (GP_RETURN_LAST): New macro for the last GPR in return.
16585 (FP_RETURN_FIRST): Diito but for FPR.
16586 (FP_RETURN_LAST): Ditto.
16587 (FUNCTION_VALUE_REGNO_P): Remove as deprecated and replace by
16588 TARGET_FUNCTION_VALUE_REGNO_P.
16590 2024-04-11 Indu Bhagat <indu.bhagat@oracle.com>
16592 * btfout.cc (btf_asm_type): Do not skip emitting members of
16595 2024-04-11 Indu Bhagat <indu.bhagat@oracle.com>
16598 * dwarf2ctf.cc (gen_ctf_sou_type): Check for conditions before
16599 call to ctf_add_slice. Use CTF_K_UNKNOWN type if fail.
16601 2024-04-10 Marek Polacek <polacek@redhat.com>
16604 * config/i386/i386-options.cc (ix86_option_override_internal): Use
16605 opts_set rather than checking == CF_NONE.
16607 2024-04-10 David Malcolm <dmalcolm@redhat.com>
16609 * doc/analyzer.texi: Various tweaks.
16611 2024-04-10 Richard Biener <rguenther@suse.de>
16613 PR tree-optimization/114672
16614 * tree-ssa-math-opts.cc (convert_plusminus_to_widen): Only
16615 allow mode-precision results.
16617 2024-04-10 Andre Vieira <andre.simoesdiasvieira@arm.com>
16619 * config/aarch64/aarch64.cc (TARGET_C_BITINT_TYPE_INFO): Declare MACRO.
16620 (aarch64_bitint_type_info): New function.
16621 (aarch64_return_in_memory_1): Return large _BitInt's in memory.
16622 (aarch64_function_arg_alignment): Adapt to correctly return the ABI
16623 mandated alignment of _BitInt(N) where N > 128 as the alignment of
16625 (aarch64_composite_type_p): Return true for _BitInt(N), where N > 128.
16627 2024-04-10 Andre Vieira <andre.simoesdiasvieira@arm.com>
16629 * config/aarch64/aarch64.cc (bitint_or_aggr_of_bitint_p): New function.
16630 (aarch64_layout_arg): Don't emit diagnostics for types involving
16633 2024-04-10 Jakub Jelinek <jakub@redhat.com>
16636 * tree-core.h (enum annot_expr_kind): Add
16637 annot_expr_maybe_infinite_kind enumerator.
16638 * gimplify.cc (gimple_boolify): Handle annot_expr_maybe_infinite_kind.
16639 * tree-cfg.cc (replace_loop_annotate_in_block): Likewise.
16640 (replace_loop_annotate): Likewise. Move loop->finite_p initialization
16641 before the replace_loop_annotate_in_block calls.
16642 * tree-pretty-print.cc (dump_generic_node): Handle
16643 annot_expr_maybe_infinite_kind.
16645 2024-04-10 Richard Biener <rguenther@suse.de>
16648 2024-03-27 Segher Boessenkool <segher@kernel.crashing.org>
16650 PR rtl-optimization/101523
16651 * combine.cc (try_combine): Don't do a 2-insn combination if
16652 it does not in fact change I2.
16654 2024-04-10 Peter Bergner <bergner@linux.ibm.com>
16657 * config/rs6000/rs6000.h (TARGET_DIRECT_MOVE): Define.
16658 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Replace
16659 OPTION_MASK_DIRECT_MOVE with OPTION_MASK_P8_VECTOR. Delete redundant
16660 OPTION_MASK_DIRECT_MOVE usage. Delete TARGET_DIRECT_MOVE dead code.
16661 (rs6000_opt_masks): Neuter the "direct-move" option.
16662 * config/rs6000/rs6000-c.cc (rs6000_target_modify_macros): Replace
16663 OPTION_MASK_DIRECT_MOVE with OPTION_MASK_P8_VECTOR. Delete useless
16665 * config/rs6000/rs6000-cpus.def (ISA_2_7_MASKS_SERVER): Delete
16666 OPTION_MASK_DIRECT_MOVE.
16667 (OTHER_VSX_VECTOR_MASKS): Likewise.
16668 (POWERPC_MASKS): Likewise.
16669 * config/rs6000/rs6000.opt (mdirect-move): Remove Mask and Var.
16671 2024-04-10 Hongyu Wang <hongyu.wang@intel.com>
16673 * config/i386/sse.md (sha1msg1): Use "ja" instead of "Bm" for
16675 (sha1msg2): Likewise.
16676 (sha1nexte): Likewise.
16677 (sha1rnds4): Likewise.
16678 (sha256msg1): Likewise.
16679 (sha256msg2): Likewise.
16680 (sha256rnds2): Likewise.
16681 (aes<aesklvariant>u8): Use "jm" instead of "m" for memory
16683 (*aes<aeswideklvariant>u8): Likewise.
16684 (*encodekey128u32): Use "jr" instead of "r" for register
16686 (*encodekey256u32): Likewise.
16688 2024-04-09 Juergen Christ <jchrist@linux.ibm.com>
16690 * config/s390/s390.cc (expand_perm_as_replicate): Implement.
16691 (vectorize_vec_perm_const_1): Call new function.
16692 * config/s390/vx-builtins.md (vec_splat<mode>): Change to...
16693 (@vec_splat<mode>): ...this.
16695 2024-04-09 David Faust <david.faust@oracle.com>
16698 * btfout.cc (btf_asm_datasec_entry): Only emit a symbol reference when
16699 generating BTF for BPF CO-RE target.
16701 2024-04-09 Richard Ball <richard.ball@arm.com>
16703 * config/aarch64/aarch64-c.cc (aarch64_pragma_aarch64):
16704 Add functions_nulls parameter to pragma_handlers.
16705 * config/aarch64/aarch64-protos.h: Likewise.
16706 * config/aarch64/aarch64-sve-builtins.h
16707 (enum handle_pragma_index): Add enum to count
16708 number of pragmas to be handled.
16709 * config/aarch64/aarch64-sve-builtins.cc
16710 (GTY): Add global variable for initial indexes
16711 and change overload_names to an array.
16712 (function_builder::function_builder):
16713 Add pragma handler information.
16714 (function_builder::add_function):
16715 Add code for overwriting previous
16716 registered_functions entries.
16717 (add_unique_function):
16718 Use an array to register overload_names
16719 for both pragma handler modes.
16720 (add_overloaded_function): Likewise.
16722 Add functions_nulls parameter to pragma_handlers.
16723 (handle_arm_sve_h):
16724 Initialize pragma handler information.
16725 (handle_arm_neon_sve_bridge_h): Likewise.
16726 (handle_arm_sme_h): Likewise.
16728 2024-04-09 Richard Biener <rguenther@suse.de>
16731 * lto-wrapper.cc (merge_flto_options): Add force argument.
16732 (merge_and_complain): Do not force here.
16733 (run_gcc): But here to make the link-time -flto option override
16734 any compile-time one.
16736 2024-04-09 Sebastian Huber <sebastian.huber@embedded-brains.de>
16738 * config/rs6000/rtems.h (OS_MISSING_POWERPC64): Define.
16740 2024-04-09 Jørgen Kvalsvik <j@lambda.is>
16742 PR gcov-profile/114601
16743 * tree-profile.cc (condition_uid): Guard fn->cond_uids access.
16745 2024-04-09 Jakub Jelinek <jakub@redhat.com>
16748 * config/i386/i386.md (isa): Remove aes, add vaes_avx512vl.
16749 (enabled): Remove aes isa check, add vaes_avx512vl.
16750 * config/i386/sse.md (aesenc, aesenclast, aesdec, aesdeclast): Use
16751 jm instead of m for second alternative and emit {evex} prefix
16752 for it if !TARGET_AES. Use noavx,avx,vaes_avx512vl isa attribute.
16753 (vaesdec_<mode>, vaesdeclast_<mode>, vaesenc_<mode>,
16754 vaesenclast_<mode>): Add second alternative with x instead of v
16755 and jm instead of m.
16757 2024-04-09 Gaius Mulley <gaiusmod2@gmail.com>
16759 * doc/gm2.texi (Compiler options): Remove -fdebug-trace-quad.
16760 Remove -fdebug-trace-api.
16761 Add -fm2-debug-trace=.
16763 2024-04-09 Yang Yujie <yangyujie@loongson.cn>
16766 * config/loongarch/loongarch.cc (loongarch_reg_init):
16767 Reinitialize the loongarch_regno_mode_ok cache.
16768 (loongarch_option_override): Same.
16769 (loongarch_save_restore_target_globals): Restore target globals.
16770 (loongarch_set_current_function): Restore the target contexts
16772 (TARGET_SET_CURRENT_FUNCTION): Define.
16773 * config/loongarch/loongarch.h (SWITCHABLE_TARGET): Enable
16774 switchable target context.
16775 * config/loongarch/loongarch-builtins.cc (loongarch_init_builtins):
16776 Initialize all builtin functions at startup.
16777 (loongarch_expand_builtin): Turn assertion of builtin availability
16780 2024-04-09 Jørgen Kvalsvik <j@lambda.is>
16782 PR middle-end/114627
16783 * tree-profile.cc (instrument_decisions): Generate constant
16784 at the start of loop.
16786 2024-04-09 Jørgen Kvalsvik <j@lambda.is>
16788 PR middle-end/114599
16789 * tree-inline.cc (copy_bb): Copy cond_uids into callee.
16790 (prepend_lexical_block): Remove outdated comment.
16791 (add_local_variables): Remove bad cond_uids copy.
16793 2024-04-09 Jakub Jelinek <jakub@redhat.com>
16795 * expr.cc (convert_mode_scalar): Fix duplicated words in comment;
16796 into into -> it into.
16797 * function.h (function::cond_uids): Fix duplicated words in comment;
16799 * config/riscv/riscv-vector-costs.cc
16800 (costs::adjust_vect_cost_per_loop): Fix duplicated words in comment;
16801 model model -> model.
16802 * config/riscv/riscv-vector-builtins-shapes.cc (build_base): Fix
16803 duplicated words in comment; for for -> for.
16804 * config/riscv/riscv-avlprop.cc (pass_avlprop::execute): Fix
16805 duplicated words in comment; more more -> more.
16806 * config/aarch64/driver-aarch64.cc (host_detect_local_cpu): Fix
16807 duplicated words in comment; be be -> be.
16808 * tree-profile.cc (masking_vectors): Fix duplicated words in comment;
16809 has has -> has, the the -> the.
16810 * value-range.cc (irange::set_range_from_bitmask): Fix duplicated
16811 words in comment; the the -> the.
16812 * gcov.cc (add_condition_counts): Fix duplicated words in comment;
16814 * vr-values.cc (get_scev_info): Fix duplicated words in comment;
16816 * tree-vrp.cc (fully_replaceable): Fix duplicated words in comment;
16818 * mode-switching.cc (single_succ_confluence_n): Fix duplicated words
16819 in comment; the the -> the.
16820 * tree-ssa-phiopt.cc (value_replacement): Fix duplicated words in
16821 comment; can can -> we can.
16822 * gimple-range-phi.cc (phi_analyzer::process_phi): Fix duplicated words
16823 in comment; it it -> it is.
16824 * tree-ssa-sccvn.cc (visit_phi): Fix duplicated words in comment;
16826 * rtl-ssa/accesses.h (use_info::next_debug_insn_use): Fix duplicated
16827 words in comment; if if -> if.
16828 * doc/options.texi (InverseMask): Fix duplicated words; and and -> and.
16829 Change take to takes.
16830 * doc/invoke.texi (fanalyzer-undo-inlining): Fix duplicated words;
16832 (-minline-memops-threshold): Likewise.
16834 2024-04-09 Jakub Jelinek <jakub@redhat.com>
16836 PR middle-end/114628
16837 * gimple-lower-bitint.cc (gimple_lower_bitint): Keep debug stmts
16838 before returns_twice calls as is, don't push them into arg_stmts
16839 vector/move to edges.
16841 2024-04-09 Sergey Bugaev <bugaevc@gmail.com>
16843 * config.gcc: Recognize aarch64*-*-gnu* targets.
16844 * config/aarch64/aarch64-gnu.h: New file.
16846 2024-04-09 Sergey Bugaev <bugaevc@gmail.com>
16848 * config/i386/gnu.h: Move GNU/Hurd STARTFILE_SPEC from here...
16849 * config/gnu.h: ...to here.
16851 2024-04-09 Richard Biener <rguenther@suse.de>
16853 PR middle-end/114604
16854 * gimple-range.cc (enable_ranger): Initialize the global
16856 (disable_ranger): Release it.
16858 2024-04-09 Sebastian Huber <sebastian.huber@embedded-brains.de>
16860 * config.gcc (aarch64-*-rtems*): Add target makefile fragment
16862 * config/aarch64/t-aarch64-rtems: New file.
16864 2024-04-09 H.J. Lu <hjl.tools@gmail.com>
16867 * config/i386/i386-c.cc (ix86_target_macros_internal): Define
16868 __APX_INLINE_ASM_USE_GPR32__ for -mapx-inline-asm-use-gpr32.
16870 2024-04-09 Kewen Lin <linkw@linux.ibm.com>
16871 Andrew Pinski <quic_apinski@quicinc.com>
16874 * config/rs6000/rs6000-builtin.cc (rs6000_gimple_fold_builtin): Fix
16875 wrong align passed to function build_aligned_type.
16876 * tree-ssa-loop-prefetch.cc (is_miss_rate_acceptable): Add an
16877 assertion to ensure align_unit should be positive.
16878 * tree.cc (build_qualified_type): Update function comments.
16880 2024-04-08 Uros Bizjak <ubizjak@gmail.com>
16882 PR rtl-optimization/112560
16883 * combine.cc (try_combine): Replace cc_use_loc with the entire
16884 new RTX only in case cc_use_loc satisfies COMPARISON_P predicate.
16885 Otherwise scan the entire cc_use_loc RTX for CC reg to be updated
16887 * config/i386/i386.md (@pushf<mode>2): Allow all CC modes for
16890 2024-04-08 Thomas Schwinge <tschwinge@baylibre.com>
16892 * config/gcn/gcn.opt (--param=gcn-preferred-vectorization-factor):
16894 * config/gcn/gcn.cc (gcn_vectorize_preferred_simd_mode) Use it.
16895 * doc/invoke.texi (Optimize Options): Document it.
16897 2024-04-08 Thomas Schwinge <tschwinge@baylibre.com>
16899 * doc/sourcebuild.texi (Effective-Target Keywords): Document
16900 'asm_goto_with_outputs'. Add comment to 'lra'.
16902 2024-04-08 Martin Jambor <mjambor@suse.cz>
16905 * ipa-icf-gimple.h (func_checker): New members
16906 safe_for_total_scalarization_p, m_total_scalarization_limit_known_p
16907 and m_total_scalarization_limit.
16908 (func_checker::func_checker): Initialize new member variables.
16909 * ipa-icf-gimple.cc: Include tree-sra.h.
16910 (func_checker::func_checker): Initialize new member variables.
16911 (func_checker::safe_for_total_scalarization_p): New function.
16912 (func_checker::compare_operand): Use the new function.
16913 * tree-sra.h (sra_get_max_scalarization_size): Declare.
16914 (sra_total_scalarization_would_copy_same_data_p): Likewise.
16915 * tree-sra.cc (prepare_iteration_over_array_elts): New function.
16916 (class sra_padding_collecting): New.
16917 (sra_padding_collecting::record_padding): Likewise.
16918 (scalarizable_type_p): Rename to totally_scalarizable_type_p. Add
16919 ability to record padding when requested.
16920 (totally_scalarize_subtree): Split out gathering information necessary
16921 to iterate over array elements to prepare_iteration_over_array_elts.
16922 Fix errornous early exit.
16923 (analyze_all_variable_accesses): Adjust the call to
16924 totally_scalarizable_type_p. Move determining of total scalariation
16926 (sra_get_max_scalarization_size): ...here.
16927 (check_ts_and_push_padding_to_vec): New function.
16928 (sra_total_scalarization_would_copy_same_data_p): Likewise.
16930 2024-04-08 Martin Jambor <mjambor@suse.cz>
16933 * ipa-prop.h (class ipa_vr): Declare new overload of a member function
16935 (ipa_jump_functions_equivalent_p): Declare.
16936 * ipa-prop.cc (ipa_vr::equal_p): New function.
16937 (ipa_agg_pass_through_jf_equivalent_p): Likewise.
16938 (ipa_agg_jump_functions_equivalent_p): Likewise.
16939 (ipa_jump_functions_equivalent_p): Likewise.
16940 * ipa-cp.h (values_equal_for_ipcp_p): Declare.
16941 * ipa-cp.cc (values_equal_for_ipcp_p): Make function public.
16942 * ipa-icf-gimple.cc: Include alloc-pool.h, symbol-summary.h, sreal.h,
16943 ipa-cp.h and ipa-prop.h.
16944 (func_checker::compare_gimple_call): Comapre jump functions.
16946 2024-04-08 Richard Sandiford <richard.sandiford@arm.com>
16949 * config/aarch64/aarch64-sve-builtins-base.cc
16950 (svusdot_impl::expand): Fix botched attempt to swap the operands
16953 2024-04-08 Tatsuyuki Ishi <ishitatsuyuki@gmail.com>
16955 * config/riscv/riscv.opt: Add -mtls-dialect to configure TLS flavor.
16956 * config.gcc: Add --with-tls configuration option to change the
16957 default TLS flavor.
16958 * config/riscv/riscv.h: Add TARGET_TLSDESC determined from
16959 -mtls-dialect and with_tls defaults.
16960 * config/riscv/riscv-opts.h: Define enum riscv_tls_type for the
16962 * config/riscv/riscv-protos.h: Define SYMBOL_TLSDESC symbol type.
16963 * config/riscv/riscv.md: Add instruction sequence for TLSDESC.
16964 * config/riscv/riscv.cc (riscv_symbol_insns): Add instruction
16965 sequence length data for TLSDESC.
16966 (riscv_legitimize_tls_address): Add lowering of TLSDESC.
16967 * doc/install.texi: Document --with-tls for RISC-V.
16968 * doc/invoke.texi: Document -mtls-dialect for RISC-V.
16970 2024-04-08 Jakub Jelinek <jakub@redhat.com>
16973 * config/s390/s390.cc (s390_const_int_pool_entry_p): Punt
16974 if mem doesn't have MODE_INT mode, or pool constant doesn't
16975 have MODE_INT mode, or if pool constant mode is smaller than
16976 mem mode. If mem mode is different from pool constant mode,
16977 try to simplify subreg. If that doesn't work, punt, if it
16978 does, use the simplified constant instead of the constant pool
16980 * config/s390/s390.md (movdi from const pool peephole): If
16981 either low or high 32-bit part is zero, just emit move insn
16982 instead of move + ior.
16984 2024-04-08 Richard Biener <rguenther@suse.de>
16986 PR tree-optimization/114624
16987 * tree-scalar-evolution.cc (final_value_replacement_loop):
16988 Get at the PHI arg location before releasing the PHI node.
16990 2024-04-08 Pan Li <pan2.li@intel.com>
16992 * config/riscv/riscv-vector-builtins-shapes.cc (build_one): Pass
16993 required_ext arg when invoke add function.
16994 (build_th_loadstore): Ditto.
16995 (struct vcreate_def): Ditto.
16996 (struct read_vl_def): Ditto.
16997 (struct vlenb_def): Ditto.
16998 * config/riscv/riscv-vector-builtins.cc (function_builder::add_function):
16999 Introduce new arg required_ext to fill in the register func.
17000 (function_builder::add_unique_function): Ditto.
17001 (function_builder::add_overloaded_function): Ditto.
17002 (expand_builtin): Leverage required_extensions_specified to
17003 check if the required extension is provided.
17004 * config/riscv/riscv-vector-builtins.h (reqired_ext_to_isa_name): New
17005 func impl to convert the required_ext enum to the extension name.
17006 (required_extensions_specified): New func impl to predicate if
17007 the required extension is well feeded.
17009 2024-04-08 Iain Sandoe <iain@sandoe.co.uk>
17011 * config/darwin.h (LINK_COMMAND_SPEC_A): Update coverage
17014 2024-04-08 demin.han <demin.han@starfivetech.com>
17016 * config/riscv/riscv-vector-costs.cc: Use length()
17018 2024-04-08 Pan Li <pan2.li@intel.com>
17020 * config/riscv/riscv-c.cc (struct pragma_intrinsic_flags): New
17021 struct to hold all intrinisc related flags.
17022 (riscv_pragma_intrinsic_flags_pollute): New func to pollute
17023 the intrinsic flags and backup original flags.
17024 (riscv_pragma_intrinsic_flags_restore): New func to restore
17025 the flags from the backup intrinsic flags.
17026 (riscv_pragma_intrinsic): Pollute the flags and register all
17027 possible builtin types and functions, then restore and reinit.
17028 * config/riscv/riscv-protos.h (reinit_builtins): New func
17029 decl to reinit after flags pollution.
17030 (riscv_option_override): New extern func decl.
17031 * config/riscv/riscv-vector-builtins.cc (register_builtin_types_on_null):
17032 New func to register builtin types if null.
17033 (DEF_RVV_TYPE): Ditto.
17034 (DEF_RVV_TUPLE_TYPE): Ditto.
17035 (reinit_builtins): New func impl to reinit after flags pollution.
17036 (expand_builtin): Return
17037 target rtx after error_at.
17038 * config/riscv/riscv.cc (riscv_vector_int_type_p): New predicate
17039 func to tell one tree type is integer or not.
17040 (riscv_vector_float_type_p): New predicate func to tell one tree
17041 type is float or not.
17042 (riscv_vector_element_bitsize): New func to get the element bitsize
17043 of a vector tree type.
17044 (riscv_vector_required_min_vlen): New func to get the required min vlen
17045 of a vector tree type.
17046 (riscv_validate_vector_type): New func to validate the tree type
17048 (riscv_return_value_is_vector_type_p): Leverage the func
17049 riscv_validate_vector_type to do the tree type validation.
17050 (riscv_arguments_is_vector_type_p): Ditto.
17051 (riscv_override_options_internal): Ditto.
17053 2024-04-08 Lulu Cheng <chenglulu@loongson.cn>
17056 * config/loongarch/loongarch-def.cc (la664_align): Newly defined
17057 function that sets alignment rules under the LA664 microarchitecture.
17058 * config/loongarch/loongarch-opts.cc
17059 (loongarch_target_option_override): If not optimizing for size, set
17060 the default alignment to what the target wants.
17061 * config/loongarch/loongarch-tune.h (struct loongarch_align): Add
17062 new member variables jump and loop.
17064 2024-04-06 H.J. Lu <hjl.tools@gmail.com>
17067 * config/i386/i386.md (x86_64_shld): Use explicit shift count in
17069 (x86_64_shld_ndd): Likewise.
17070 (x86_shld): Likewise.
17071 (x86_shld_ndd): Likewise.
17072 (x86_64_shrd): Likewise.
17073 (x86_64_shrd_ndd): Likewise.
17074 (x86_shrd): Likewise.
17075 (x86_shrd_ndd): Likewise.
17077 2024-04-06 Jørgen Kvalsvik <j@lambda.is>
17079 PR middle-end/114599
17080 * tree-inline.cc (add_local_variables): Copy cond_uids mappings.
17082 2024-04-05 David Malcolm <dmalcolm@redhat.com>
17085 * diagnostic-color.cc (color_dict): Add "valid" and "invalid" as
17086 color capability names.
17087 * doc/invoke.texi: Document them in description of GCC_COLORS.
17088 * text-art/style.cc: Include "diagnostic-color.h".
17089 (text_art::get_style_from_color_cap_name): New.
17090 * text-art/types.h (get_style_from_color_cap_name): New decl.
17092 2024-04-05 Alex Coplan <alex.coplan@arm.com>
17094 * config/aarch64/aarch64-ldp-fusion.cc (struct alias_walker):
17095 Fix double space after const qualifier on valid ().
17097 2024-04-05 Martin Jambor <mjambor@suse.cz>
17100 * ipa-param-manipulation.cc (ipa_param_adjustments::modify_call):
17101 Force values obtined through pass-through maps to the expected
17104 2024-04-05 Mark Wielaard <mark@klomp.org>
17106 * common.opt.urls: Regenerate.
17108 2024-04-05 Richard Sandiford <richard.sandiford@arm.com>
17111 * config/aarch64/aarch64-sve.md (@aarch64_pred_cnot<mode>): Replace
17113 (@aarch64_ptrue_cnot<mode>): ...this, requiring operand 1 to be
17115 (*cnot<mode>): Require operand 1 to be a ptrue.
17116 * config/aarch64/aarch64-sve-builtins-base.cc (svcnot_impl::expand):
17117 Use aarch64_ptrue_cnot<mode> for _x operations that are predicated
17118 with a ptrue. Represent other _x operations as fully-defined _m
17121 2024-04-05 Jakub Jelinek <jakub@redhat.com>
17123 PR tree-optimization/114566
17124 * tree-vect-loop.cc (update_epilogue_loop_vinfo): Don't clear
17127 2024-04-05 Richard Biener <rguenther@suse.de>
17129 PR middle-end/114599
17130 PR gcov-profile/114115
17131 * symtab.cc (ifunc_ref_map): Do not use auto_bitmap.
17132 (is_caller_ifunc_resolver): Optimize bitmap_bit_p/bitmap_set_bit
17134 (symtab_node::check_ifunc_callee_symtab_nodes): Properly
17135 allocate ifunc_ref_map here.
17137 2024-04-04 Martin Jambor <mjambor@suse.cz>
17140 * ipa-param-manipulation.cc
17141 (ipa_param_body_adjustments::common_initialization): Avoid creating
17142 duplicate replacement entries.
17144 2024-04-04 Vladimir N. Makarov <vmakarov@redhat.com>
17146 PR rtl-optimization/114415
17147 * sched-deps.cc (add_insn_mem_dependence): Add memory check for mem argument.
17148 (sched_analyze_1): Treat stack pointer modification as memory read.
17149 (sched_analyze_2, sched_analyze_insn): Add memory guard for processing pending_read_mems.
17150 * sched-int.h (deps_desc): Add comment to pending_read_mems.
17152 2024-04-04 Tobias Burnus <tburnus@baylibre.com>
17154 * config/nvptx/mkoffload.cc (main): Call
17155 gcc_init_libintl and diagnostic_color_init.
17157 2024-04-04 H.J. Lu <hjl.tools@gmail.com>
17160 * config/i386/i386-c.cc (ix86_target_macros_internal): Define
17161 __APX_F__ when APX is enabled.
17163 2024-04-04 Jørgen Kvalsvik <j@lambda.is>
17165 * builtins.cc (expand_builtin_fork_or_exec): Check
17166 condition_coverage_flag.
17167 * collect2.cc (main): Add -fno-condition-coverage to OBSTACK.
17168 * common.opt: Add new options -fcondition-coverage and
17169 -Wcoverage-too-many-conditions.
17170 * doc/gcov.texi: Add --conditions documentation.
17171 * doc/invoke.texi: Add -fcondition-coverage documentation.
17172 * function.cc (free_after_compilation): Free cond_uids.
17173 * function.h (struct function): Add cond_uids.
17174 * gcc.cc: Link gcov on -fcondition-coverage.
17175 * gcov-counter.def (GCOV_COUNTER_CONDS): New.
17176 * gcov-dump.cc (tag_conditions): New.
17177 * gcov-io.h (GCOV_TAG_CONDS): New.
17178 (GCOV_TAG_CONDS_LENGTH): New.
17179 (GCOV_TAG_CONDS_NUM): New.
17180 * gcov.cc (class condition_info): New.
17181 (condition_info::condition_info): New.
17182 (condition_info::popcount): New.
17183 (struct coverage_info): New.
17184 (add_condition_counts): New.
17185 (output_conditions): New.
17186 (print_usage): Add -g, --conditions.
17187 (process_args): Likewise.
17188 (output_intermediate_json_line): Output conditions.
17189 (read_graph_file): Read condition counters.
17190 (read_count_file): Likewise.
17191 (file_summary): Print conditions.
17192 (accumulate_line_info): Accumulate conditions.
17193 (output_line_details): Print conditions.
17194 * gimplify.cc (next_cond_uid): New.
17195 (reset_cond_uid): New.
17196 (shortcut_cond_r): Set condition discriminator.
17197 (tag_shortcut_cond): New.
17198 (gimple_associate_condition_with_expr): New.
17199 (shortcut_cond_expr): Set condition discriminator.
17200 (gimplify_cond_expr): Likewise.
17201 (gimplify_function_tree): Call reset_cond_uid.
17202 * ipa-inline.cc (can_early_inline_edge_p): Check
17203 condition_coverage_flag.
17204 * ipa-split.cc (pass_split_functions::gate): Likewise.
17205 * passes.cc (finish_optimization_passes): Likewise.
17206 * profile.cc (struct condcov): New declaration.
17207 (cov_length): Likewise.
17208 (cov_blocks): Likewise.
17209 (cov_masks): Likewise.
17210 (cov_maps): Likewise.
17211 (cov_free): Likewise.
17212 (instrument_decisions): New.
17213 (read_thunk_profile): Control output to file.
17214 (branch_prob): Call find_conditions, instrument_decisions.
17215 (init_branch_prob): Add total_num_conds.
17216 (end_branch_prob): Likewise.
17217 * tree-core.h (struct tree_exp): Add condition_uid.
17218 * tree-profile.cc (struct conds_ctx): New.
17219 (CONDITIONS_MAX_TERMS): New.
17220 (EDGE_CONDITION): New.
17221 (topological_cmp): New.
17224 (single_edge): New.
17225 (contract_edge_up): New.
17226 (struct outcomes): New.
17227 (conditional_succs): New.
17228 (condition_index): New.
17229 (condition_uid): New.
17230 (masking_vectors): New.
17231 (emit_assign): New.
17232 (emit_bitwise_op): New.
17233 (make_top_index_visit): New.
17234 (make_top_index): New.
17235 (paths_between): New.
17236 (struct condcov): New.
17242 (find_conditions): New.
17243 (struct counters): New.
17244 (find_counters): New.
17245 (resolve_counter): New.
17246 (resolve_counters): New.
17247 (instrument_decisions): New.
17248 (tree_profiling): Check condition_coverage_flag.
17249 (pass_ipa_tree_profile::gate): Likewise.
17250 * tree.h (SET_EXPR_UID): New.
17251 (EXPR_COND_UID): New.
17253 2024-04-04 Richard Sandiford <richard.sandiford@arm.com>
17256 * config/aarch64/aarch64-sve-builtins.h (aarch64_sve::lookup_fndecl):
17258 * config/aarch64/aarch64-sve-builtins.cc (aarch64_sve::lookup_fndecl):
17260 * config/aarch64/aarch64-sve-builtins-base.cc (is_undef): Likewise.
17261 (svset_neonq_impl::expand): Optimise expansions whose first argument
17264 2024-04-04 Richard Biener <rguenther@suse.de>
17266 PR tree-optimization/114485
17267 * tree-vect-loop-manip.cc (vect_can_peel_nonlinear_iv_p):
17268 vect_step_op_neg isn't OK for partial vectors but only
17271 2024-04-04 Jakub Jelinek <jakub@redhat.com>
17274 * fold-const.cc (native_encode_initializer): Look through
17275 NON_LVALUE_EXPR if val is INTEGER_CST.
17277 2024-04-04 Jakub Jelinek <jakub@redhat.com>
17279 PR tree-optimization/114555
17280 * gimple-lower-bitint.cc (bitint_large_huge::handle_cast): For
17281 m_bitfld_load and save_cast_conditional add any needed PHIs
17282 and adjust t4 accordingly.
17284 2024-04-04 Richard Biener <rguenther@suse.de>
17286 PR tree-optimization/114551
17287 * tree-ssa-loop-split.cc (split_loop): If the guard is
17288 only conditionally evaluated rewrite computations with
17289 possibly undefined overflow to unsigned arithmetic.
17291 2024-04-04 Eugene Rozenfeld <erozen@microsoft.com>
17293 PR gcov-profile/113765
17294 * auto-profile.cc (afdo_annotate_cfg): Don't set full_profile to true
17296 2024-04-03 Mark Wielaard <mark@klomp.org>
17298 * config/i386/i386.opt.urls: Regenerate.
17300 2024-04-03 H.J. Lu <hjl.tools@gmail.com>
17302 PR tree-optimization/114115
17303 * cgraph.h (symtab_node): Add check_ifunc_callee_symtab_nodes.
17304 (cgraph_node): Add called_by_ifunc_resolver.
17305 * cgraphunit.cc (symbol_table::compile): Call
17306 symtab_node::check_ifunc_callee_symtab_nodes.
17307 * symtab.cc (check_ifunc_resolver): New.
17308 (ifunc_ref_map): Likewise.
17309 (is_caller_ifunc_resolver): Likewise.
17310 (symtab_node::check_ifunc_callee_symtab_nodes): Likewise.
17311 * tree-profile.cc (gimple_gen_ic_func_profiler): Disable indirect
17312 call profiling for IFUNC resolvers and their callees.
17314 2024-04-03 Tobias Burnus <tburnus@baylibre.com>
17316 * lto-wrapper.cc (compile_offload_image): Prefix 'offload_args'
17317 suffix by the target name.
17319 2024-04-03 Tobias Burnus <tburnus@baylibre.com>
17321 * doc/install.texi (amdgcn-*-amdhsa): Update Newlib recommendation
17322 and update wording for LLVM 18 release.
17324 2024-04-03 Tobias Burnus <tburnus@baylibre.com>
17327 * config/gcn/mkoffload.cc (get_arch): New; moved -march= flag
17329 (main): ... here; call it to handle --with-arch config option
17330 and -march= commandline.
17332 2024-04-03 Jakub Jelinek <jakub@redhat.com>
17334 PR middle-end/114552
17335 * expr.cc (emit_push_insn): Only use store_constructor for
17336 immediate_const_ctor_p if int_expr_size matches size.
17338 2024-04-03 Richard Biener <rguenther@suse.de>
17340 PR tree-optimization/114557
17341 PR tree-optimization/114480
17342 * tree-phinodes.cc (release_phi_node): Return PHIs from
17343 allocation buckets not covered by free_phinodes to GC.
17344 (remove_phi_node): Release the PHI LHS before freeing the
17346 * tree-vect-loop.cc (vectorizable_live_operation): Get PHI lhs
17347 before releasing it.
17349 2024-04-03 Jiahao Xu <xujiahao@loongson.cn>
17351 * config/loongarch/lasx.md: Remove unused code.
17352 * config/loongarch/loongarch-protos.h
17353 (loongarch_split_lsx_copy_d): Remove.
17354 (loongarch_split_lsx_insert_d): Ditto.
17355 (loongarch_split_lsx_fill_d): Ditto.
17356 * config/loongarch/loongarch.cc
17357 (loongarch_split_lsx_copy_d): Ditto.
17358 (loongarch_split_lsx_insert_d): Ditto.
17359 (loongarch_split_lsx_fill_d): Ditto.
17360 * config/loongarch/lsx.md (lsx_vpickve2gr_du): Remove splitter.
17361 (lsx_vpickve2gr_<lsxfmt_f>): Ditto.
17362 (abs<mode>2): Remove expander.
17363 (vabs<mode>2): Rename 2 abs<mode>2.
17365 2024-04-02 Christophe Lyon <christophe.lyon@linaro.org>
17367 * config/aarch64/aarch64-option-extensions.def: Fix comment.
17369 2024-04-02 Tom Tromey <tromey@adacore.com>
17371 * dwarf2out.cc (print_dw_val) <dw_val_class_loc>: Don't
17372 print newline when not recursing.
17374 2024-04-02 Iain Sandoe <iain@sandoe.co.uk>
17376 * config/darwin.cc (darwin_override_options): Update the
17377 clang major version value in the dsymutil check.
17379 2024-04-02 Iain Sandoe <iain@sandoe.co.uk>
17381 * config/darwin.cc (darwin_override_options): Reduce the debug
17382 level to 2 if dsymutil cannot handle .macinfo sections.
17384 2024-04-02 Yang Yujie <yangyujie@loongson.cn>
17386 * config/loongarch/t-loongarch: Add loongarch-def-arrays.h
17389 2024-04-02 mengqinggang <mengqinggang@loongson.cn>
17390 Lulu Cheng <chenglulu@loongson.cn>
17391 Xi Ruoyao <xry111@xry111.site>
17393 * config.gcc: Add --with-tls option to change TLS flavor.
17394 * config/loongarch/genopts/loongarch.opt.in: Add -mtls-dialect to
17395 configure TLS flavor.
17396 * config/loongarch/loongarch-def.h (struct loongarch_target): Add
17398 * config/loongarch/loongarch-driver.cc (la_driver_init): Add tls
17400 * config/loongarch/loongarch-opts.cc (loongarch_init_target): Add
17402 (loongarch_config_target): Ditto.
17403 (loongarch_update_gcc_opt_status): Ditto.
17404 * config/loongarch/loongarch-opts.h (loongarch_init_target): Ditto.
17405 (TARGET_TLS_DESC): New define.
17406 * config/loongarch/loongarch.cc (loongarch_symbol_insns): Add TLS
17407 DESC instructions sequence length.
17408 (loongarch_legitimize_tls_address): New TLS DESC instruction sequence.
17409 (loongarch_option_override_internal): Add la_opt_tls_dialect.
17410 (loongarch_option_restore): Add la_target.tls_dialect.
17411 * config/loongarch/loongarch.md (@got_load_tls_desc<mode>): Normal
17412 code model for TLS DESC.
17413 (got_load_tls_desc_off64): Extreme cmode model for TLS DESC.
17414 * config/loongarch/loongarch.opt: Regenerate.
17415 * config/loongarch/loongarch.opt.urls: Ditto.
17416 * doc/invoke.texi: Add a description of the compilation option
17417 '-mtls-dialect={trad,desc}'.
17419 2024-04-02 Lulu Cheng <chenglulu@loongson.cn>
17421 * config/loongarch/loongarch.opt.urls: Regenerate.
17423 2024-04-01 Yang Yujie <yangyujie@loongson.cn>
17425 * config/loongarch/genopts/loongarch.opt.in: Mark -m[no-]recip as
17426 aliases to -mrecip={all,none}, respectively.
17427 * config/loongarch/loongarch.opt: Regenerate.
17428 * config/loongarch/loongarch-def.h (ABI_FPU_64): Rename to...
17429 (ABI_FPU64_P): ...this.
17430 (ABI_FPU_32): Rename to...
17431 (ABI_FPU32_P): ...this.
17432 (ABI_FPU_NONE): Rename to...
17433 (ABI_NOFPU_P): ...this.
17434 (ABI_LP64_P): Define.
17435 * config/loongarch/loongarch.cc (loongarch_init_print_operand_punct):
17436 Merged into loongarch_global_init.
17437 (loongarch_cpu_option_override): Renamed to
17438 loongarch_target_option_override.
17439 (loongarch_option_override_internal): Move the work after
17440 loongarch_config_target into loongarch_target_option_override.
17441 (loongarch_global_init): Define.
17442 (INIT_TARGET_FLAG): Move to loongarch-opts.cc.
17443 (loongarch_option_override): Call loongarch_global_init
17445 * config/loongarch/loongarch-opts.cc (loongarch_parse_mrecip_scheme):
17446 Split the parsing of -mrecip=<string> from
17447 loongarch_option_override_internal.
17448 (loongarch_generate_mrecip_scheme): Define. Split from
17449 loongarch_option_override_internal.
17450 (loongarch_target_option_override): Define. Renamed from
17451 loongarch_cpu_option_override.
17452 (loongarch_init_misc_options): Define. Split from
17453 loongarch_option_override_internal.
17454 (INIT_TARGET_FLAG): Move from loongarch.cc.
17455 * config/loongarch/loongarch-opts.h (loongarch_target_option_override):
17457 (loongarch_parse_mrecip_scheme): New prototype.
17458 (loongarch_init_misc_options): New prototype.
17459 (TARGET_ABI_LP64): Simplify with ABI_LP64_P.
17460 * config/loongarch/loongarch.h (TARGET_RECIP_DIV): Simplify.
17461 Do not reference specific CPU architecture (LA664).
17462 (TARGET_RECIP_SQRT): Same.
17463 (TARGET_RECIP_RSQRT): Same.
17464 (TARGET_RECIP_VEC_DIV): Same.
17465 (TARGET_RECIP_VEC_SQRT): Same.
17466 (TARGET_RECIP_VEC_RSQRT): Same.
17468 2024-04-01 Lulu Cheng <chenglulu@loongson.cn>
17470 * doc/invoke.texi: Add descriptions for the compilation
17473 2024-03-31 Jeff Law <jlaw@ventanamicro.com>
17475 * config/riscv/xiangshan.md (xiangshan_jump): Add branch, jalr, ret
17478 2024-03-31 Pan Li <pan2.li@intel.com>
17480 * config/riscv/riscv-vector-builtins.cc (expand_builtin): Take
17481 the term built-in over builtin.
17483 2024-03-31 Pan Li <pan2.li@intel.com>
17485 * common/config/riscv/riscv-common.cc (riscv_subset_list::parse):
17486 Remove unused var decl.
17488 2024-03-30 Xi Ruoyao <xry111@xry111.site>
17491 * config/mips/mips.cc (mips_setup_incoming_varargs): Only skip
17492 mips_function_arg_advance for TYPE_NO_NAMED_ARGS_STDARG_P
17493 functions if arg.type is NULL.
17495 2024-03-29 Andrew Pinski <quic_apinski@quicinc.com>
17497 * lto-compress.cc (lto_end_uncompression): Use
17498 fatal_error instead of internal_error when ZSTD
17501 2024-03-28 Jeff Law <jlaw@ventanamicro.com>
17503 * config/h8300/extensions.md (zero_extendqihi*): Add output
17504 template for reg->reg case where the regs don't match.
17506 2024-03-28 Gaius Mulley <(no_default)>
17509 * doc/gm2.texi: Mention gm2 treats a # in the first column
17510 as a preprocessor directive unless -fno-cpp is supplied.
17512 2024-03-28 Jakub Jelinek <jakub@redhat.com>
17514 * predict.cc (estimate_bb_frequencies): Fix comment typo,
17515 scalling -> scaling.
17517 2024-03-28 Jakub Jelinek <jakub@redhat.com>
17519 PR tree-optimization/112303
17520 * profile-count.h (profile_count::operator+): Perform
17521 addition in uint64_t variable and set m_val to MIN of that
17523 (profile_count::operator+=): Likewise.
17524 (profile_count::operator-=): Formatting fix.
17525 (profile_count::apply_probability): Use safe_scale_64bit
17526 even in the int overload.
17528 2024-03-28 Jan Hubicka <jh@suse.cz>
17530 PR middle-end/113907
17531 * ipa-icf.cc (sem_function::init): Hash PHI operands
17532 (sem_function::compare_phi_node): Add argument about preserving order
17534 2024-03-28 Richard Biener <rguenther@suse.de>
17536 PR middle-end/114480
17537 * cfganal.cc (compute_idf): Use simpler bitmap iteration,
17538 touch work_set only when phi_insertion_points changed.
17540 2024-03-28 Palmer Dabbelt <palmer@rivosinc.com>
17542 * config/riscv/riscv.h (REGISTER_NAMES): Add vxsat.
17544 2024-03-27 Segher Boessenkool <segher@kernel.crashing.org>
17546 PR rtl-optimization/101523
17547 * combine.cc (try_combine): Don't do a 2-insn combination if
17548 it does not in fact change I2.
17550 2024-03-27 Jakub Jelinek <jakub@redhat.com>
17552 * doc/invoke.texi (Spec Files): Use @var{S} instead of S,
17553 @var{X} instead of X etc. for other placeholders.
17555 2024-03-27 Richard Biener <rguenther@suse.de>
17557 PR tree-optimization/114057
17558 * tree-vect-slp.cc (vect_bb_slp_mark_live_stmts): Mark
17559 BB reduction remain defs as scalar uses.
17561 2024-03-27 Victor Do Nascimento <victor.donascimento@arm.com>
17563 * config/aarch64/aarch64-option-extensions.def (rcpc3):
17564 Fix FEATURE_STRING field to "lrcpc3".
17566 2024-03-27 Victor Do Nascimento <victor.donascimento@arm.com>
17568 * config/aarch64/aarch64-option-extensions.def: Add LSE128
17569 AARCH64_OPT_EXTENSION, adding it as a dependency for the D128
17571 * doc/invoke.texi (AArch64 Options): Document +lse128.
17573 2024-03-26 Richard Sandiford <richard.sandiford@arm.com>
17575 * config/aarch64/aarch64-feature-deps.h: Use constexpr for
17576 out-of-line statics.
17578 2024-03-26 Cupertino Miranda <cupertino.miranda@oracle.com>
17581 * btfout.cc (get_name_for_datasec_entry): Add function.
17582 (btf_asm_datasec_entry): Print label when possible.
17584 2024-03-26 Richard Ball <richard.ball@arm.com>
17587 * config/aarch64/aarch64-cores.def (AARCH64_CORE):
17588 Change SCHEDULER_IDENT from cortexa55 to cortexa53
17589 for Cortex-A510 and Cortex-A520.
17591 2024-03-26 Jakub Jelinek <jakub@redhat.com>
17593 PR middle-end/111151
17594 * fold-const.cc (extract_muldiv_1) <case MAX_EXPR>: Punt for
17595 MULT_EXPR altogether, or for MAX_EXPR if c is -1.
17597 2024-03-26 Jakub Jelinek <jakub@redhat.com>
17599 PR sanitizer/111736
17600 * tsan.cc (instrument_expr): Punt on non-generic address space
17603 2024-03-26 Richard Biener <rguenther@suse.de>
17605 PR tree-optimization/114471
17606 * tree-vect-stmts.cc (vectorizable_operation): Verify operand
17607 types are compatible with the result type.
17609 2024-03-26 Richard Biener <rguenther@suse.de>
17611 PR tree-optimization/114464
17612 * tree-vect-loop.cc (vectorizable_recurr): Verify the latch
17613 vector type is compatible with what we chose for the recurrence.
17615 2024-03-26 Jakub Jelinek <jakub@redhat.com>
17617 * cfgloopmanip.cc (update_loop_exit_probability_scale_dom_bbs):
17618 Fix comment typo - multple -> multiple.
17619 * config/i386/x86-tune.def (X86_TUNE_ACCUMULATE_OUTGOING_ARGS):
17622 2024-03-26 YunQiang Su <syq@gcc.gnu.org>
17624 * config/mips/mips.h (TARGET_CPU_CPP_BUILTINS): Predefine
17625 __mips_strict_alignment if STRICT_ALIGNMENT.
17627 2024-03-25 Richard Biener <rguenther@suse.de>
17629 * config.gcc (amdgcn): Add gfx1036 entries.
17630 * config/gcn/gcn-hsa.h (NO_XNACK): Likewise.
17631 (gcn_local_sym_hash): Likewise.
17632 * config/gcn/gcn-opts.h (enum processor_type): Likewise.
17633 (TARGET_GFX1036): New macro.
17634 * config/gcn/gcn.cc (gcn_option_override): Handle gfx1036.
17635 (gcn_omp_device_kind_arch_isa): Likewise.
17636 (output_file_start): Likewise.
17637 * config/gcn/gcn.h (TARGET_CPU_CPP_BUILTINS): Add __gfx1036__.
17638 (TARGET_CPU_CPP_BUILTINS): Rename __gfx1030 to __gfx1030__.
17639 * config/gcn/gcn.opt: Add gfx1036.
17640 * config/gcn/mkoffload.cc (EF_AMDGPU_MACH_AMDGCN_GFX1036): New.
17641 (main): Handle gfx1036.
17642 * config/gcn/t-omp-device: Add gfx1036 isa.
17643 * doc/install.texi (amdgcn): Add gfx1036.
17644 * doc/invoke.texi (-march): Likewise.
17646 2024-03-25 Pan Li <pan2.li@intel.com>
17648 * config/riscv/riscv-c.cc (riscv_pragma_intrinsic): Remove error
17649 when V is disabled and init the RVV types and intrinic APIs.
17650 * config/riscv/riscv-vector-builtins.cc (expand_builtin): Report
17651 error if V ext is disabled.
17652 * config/riscv/riscv.cc (riscv_return_value_is_vector_type_p):
17654 (riscv_arguments_is_vector_type_p): Ditto.
17655 (riscv_vector_cc_function_p): Ditto.
17656 * config/riscv/riscv_vector.h: Remove error if V is disable.
17658 2024-03-23 John David Anglin <danglin@gcc.gnu.org>
17660 * config/pa/pa.cc (pa_output_global_address): Handle
17661 UNSPEC_DLTIND14R addresses.
17662 * config/pa/pa.h (PRINT_OPERAND_ADDRESS): Output "RT'" for
17663 UNSPEC_DLTIND14R address.
17665 2024-03-23 Jakub Jelinek <jakub@redhat.com>
17667 PR tree-optimization/114433
17668 * gimple-lower-bitint.cc (bitint_large_huge::handle_cast): For
17669 m_bitfld_load check save_first rather than m_first.
17671 2024-03-23 Jakub Jelinek <jakub@redhat.com>
17673 PR tree-optimization/114425
17674 * gimple-lower-bitint.cc (build_bitint_stmt_ssa_conflicts): Handle
17675 _Complex large/huge _BitInt types like the large/huge _BitInt types.
17677 2024-03-23 Jakub Jelinek <jakub@redhat.com>
17679 PR middle-end/111683
17680 * tree-predcom.cc (pcom_worker::suitable_component_p): If has_write
17681 and comp_step is RS_NONZERO, return false if any reference in the
17682 component doesn't have DR_STEP a multiple of access size.
17684 2024-03-23 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
17686 * config/xtensa/xtensa.md: Add new split pattern described above.
17688 2024-03-22 Georg-Johann Lay <avr@gjlay.de>
17690 * config/avr/avr.cc (avr_set_current_function): Adjust diagnostic
17691 for deprecated SIGNAL and INTERRUPT usage without respective header.
17693 2024-03-22 Andrew Stubbs <ams@baylibre.com>
17695 * config/gcn/gcn.md (*memory_barrier): Split into RDNA and !RDNA.
17696 (atomic_load<mode>): Adjust RDNA cache settings.
17697 (atomic_store<mode>): Likewise.
17698 (atomic_exchange<mode>): Likewise.
17700 2024-03-22 Andrew Stubbs <ams@baylibre.com>
17702 * config/gcn/gcn.cc (gcn_vectorize_preferred_simd_mode): Prefer V32 on
17705 2024-03-22 Andrew Stubbs <ams@baylibre.com>
17707 * config.gcc (amdgcn): Add gfx1103 entries.
17708 * config/gcn/gcn-hsa.h (NO_XNACK): Likewise.
17709 (gcn_local_sym_hash): Likewise.
17710 * config/gcn/gcn-opts.h (enum processor_type): Likewise.
17711 (TARGET_GFX1103): New macro.
17712 * config/gcn/gcn.cc (gcn_option_override): Handle gfx1103.
17713 (gcn_omp_device_kind_arch_isa): Likewise.
17714 (output_file_start): Likewise.
17715 (gcn_hsa_declare_function_name): Use TARGET_RDNA3, not just gfx1100.
17716 * config/gcn/gcn.h (TARGET_CPU_CPP_BUILTINS): Add __gfx1103__.
17717 * config/gcn/gcn.opt: Add gfx1103.
17718 * config/gcn/mkoffload.cc (EF_AMDGPU_MACH_AMDGCN_GFX1103): New.
17719 (main): Handle gfx1103.
17720 * config/gcn/t-omp-device: Add gfx1103 isa.
17721 * doc/install.texi (amdgcn): Add gfx1103.
17722 * doc/invoke.texi (-march): Likewise.
17724 2024-03-22 Andrew Stubbs <ams@baylibre.com>
17726 * dojump.cc (do_compare_rtx_and_jump): Clear excess bits in vector
17728 (do_compare_and_jump): Remove now-redundant similar code.
17729 * internal-fn.cc (expand_fn_using_insn): Clear excess bits in vector
17731 (add_mask_and_len_args): Likewise.
17733 2024-03-22 Pan Li <pan2.li@intel.com>
17735 * config/riscv/riscv-c.cc (riscv_cpu_cpp_builtins): Add pre-define
17736 macro __riscv_v_fixed_vlen when zvl.
17737 * config/riscv/riscv.cc (riscv_handle_rvv_vector_bits_attribute):
17738 New static func to take care of the RVV types decorated by
17741 2024-03-22 Andrew Pinski <quic_apinski@quicinc.com>
17744 * builtins.cc (fold_builtin_1): Use error_operand_p
17745 instead of checking against ERROR_MARK.
17746 (fold_builtin_2): Likewise.
17747 (fold_builtin_3): Likewise.
17749 2024-03-22 Jakub Jelinek <jakub@redhat.com>
17751 PR sanitizer/111736
17752 * ubsan.cc (ubsan_expand_null_ifn, instrument_mem_ref): Avoid
17753 SANITIZE_NULL instrumentation for non-generic address spaces
17754 for which targetm.addr_space.zero_address_valid (as) is true.
17756 2024-03-22 Jakub Jelinek <jakub@redhat.com>
17758 PR tree-optimization/114405
17759 * gimple-lower-bitint.cc (bitint_large_huge::lower_mergeable_stmt):
17760 Set rprec to limb_prec rather than 0 if tprec is divisible by
17761 limb_prec. In the last bf_cur handling, set rprec to (tprec + bo_bit)
17762 % limb_prec rather than tprec % limb_prec and use just rprec instead
17763 of rprec + bo_bit. For build_bit_field_ref offset, divide
17764 (tprec + bo_bit) by limb_prec rather than just tprec.
17766 2024-03-22 Christoph Müllner <christoph.muellner@vrull.eu>
17769 * config/riscv/vector-iterators.md: Split VI into VI_FRAC and VI_NOFRAC.
17770 Only include VI_NOFRAC in V_VLS without TARGET_XTHEADVECTOR.
17772 2024-03-22 Jeff Law <jlaw@ventanamicro.com>
17774 * config/riscv/riscv.cc (riscv_expand_prologue): Add missing stack
17775 tie for scalable and final stack adjustment if needed.
17776 Co-authored-by: Raphael Zinsly <rzinsly@ventanamicro.com>
17778 2024-03-22 Pan Li <pan2.li@intel.com>
17781 * common/config/riscv/riscv-common.cc (struct riscv_func_target_info):
17782 New struct for func decl and target name.
17783 (struct riscv_func_target_hasher): New hasher for hash table mapping
17784 from the fn_decl to fn_target_name.
17785 (riscv_func_decl_hash): New func to compute the hash for fn_decl.
17786 (riscv_func_target_hasher::hash): New func to impl hash interface.
17787 (riscv_func_target_hasher::equal): New func to impl equal interface.
17788 (riscv_cmdline_subset_list): New static var for cmdline subset list.
17789 (riscv_func_target_table_lazy_init): New func to lazy init the func
17791 (riscv_func_target_get): New func to get target name from hash table.
17792 (riscv_func_target_put): New func to put target name into hash table.
17793 (riscv_func_target_remove_and_destory): New func to remove target
17794 info from the hash table and destory it.
17795 (riscv_parse_arch_string): Set the static var cmdline_subset_list.
17796 * config/riscv/riscv-subset.h (riscv_cmdline_subset_list): New static
17797 var for cmdline subset list.
17798 (riscv_func_target_get): New func decl.
17799 (riscv_func_target_put): Ditto.
17800 (riscv_func_target_remove_and_destory): Ditto.
17801 * config/riscv/riscv-target-attr.cc (riscv_target_attr_parser::parse_arch):
17802 Take cmdline_subset_list instead of current_subset_list when clone.
17803 (riscv_process_target_attr): Record the func target info to hash table.
17804 (riscv_option_valid_attribute_p): Add new arg tree fndel.
17805 * config/riscv/riscv.cc (riscv_declare_function_name): Consume the
17806 func target info and print the arch message.
17808 2024-03-22 Pan Li <pan2.li@intel.com>
17811 * common/config/riscv/riscv-common.cc (riscv_subset_list::parse):
17812 Replace implied, combine and check to func finalize.
17813 (riscv_subset_list::finalize): New func impl to take care of
17814 implied, combine ext and related checks.
17815 * config/riscv/riscv-subset.h: Add func decl for finalize.
17816 * config/riscv/riscv-target-attr.cc (riscv_target_attr_parser::parse_arch):
17817 Finalize the ext before return succeed.
17818 * config/riscv/riscv.cc (riscv_set_current_function): Reinit the
17819 machine mode before when set cur function.
17821 2024-03-21 Andrew Stubbs <ams@baylibre.com>
17823 * config/gcn/gcn.cc (gcn_expand_builtin_1): Comment correction.
17825 2024-03-21 Andrew Stubbs <ams@baylibre.com>
17827 * config/gcn/gcn-hsa.h (ASM_SPEC): Pass -mattr=+cumode.
17829 2024-03-21 Andrew Stubbs <ams@baylibre.com>
17831 * config/gcn/gcn-run.cc (main): Add an hsa_memory_free calls for each
17832 device_malloc call.
17834 2024-03-21 liuhongt <hongtao.liu@intel.com>
17836 PR tree-optimization/114396
17837 * tree-vect-loop.cc (vect_peel_nonlinear_iv_init): Pass utype
17838 and true to wi::from_mpz.
17840 2024-03-21 Richard Biener <rguenther@suse.de>
17842 PR tree-optimization/111736
17843 * asan.cc (instrument_derefs): Do not instrument accesses
17844 to non-generic address-spaces.
17846 2024-03-21 Richard Biener <rguenther@suse.de>
17848 PR tree-optimization/113727
17849 * tree-sra.cc (analyze_access_subtree): Do not allow
17850 replacements in subtrees when grp_partial_lhs.
17852 2024-03-21 liuhongt <hongtao.liu@intel.com>
17854 PR middle-end/114347
17855 * doc/invoke.texi: Document -fexcess-precision=16.
17857 2024-03-20 Cupertino Miranda <cupertino.miranda@oracle.com>
17859 * config/bpf/core-builtins.cc (bpf_core_get_index): Check if
17860 field contains a DECL_NAME.
17862 2024-03-20 Cupertino Miranda <cupertino.miranda@oracle.com>
17864 * config/bpf/btfext-out.cc (cpf_core_reloc_add): Correct for new code.
17865 Add assert to validate the string is set.
17866 * config/bpf/core-builtins.cc (cr_final): Make string struct
17868 (process_enum_value): Correct for field type change.
17869 (process_type): Set access string to "0".
17871 2024-03-20 Cupertino Miranda <cupertino.miranda@oracle.com>
17873 * config/bpf/core-builtins.cc (core_field_info): Add
17874 support for POINTER_PLUS_EXPR in the root of the field expression.
17875 (bpf_core_get_index): Likewise.
17876 (pack_field_expr): Make the BTF type to point to the structure
17877 related node, instead of its pointer type.
17878 (make_core_safe_access_index): Correct to new code.
17880 2024-03-20 Xi Ruoyao <xry111@xry111.site>
17883 * config/loongarch/loongarch-opts.cc (loongarch_config_target):
17884 Fix typo in diagnostic message, enabing -> enabling.
17886 2024-03-20 Jakub Jelinek <jakub@redhat.com>
17889 * config/visium/visium.cc (visium_setup_incoming_varargs): Only skip
17890 TARGET_FUNCTION_ARG_ADVANCE for TYPE_NO_NAMED_ARGS_STDARG_P functions
17891 if arg.type is NULL.
17893 2024-03-20 Jakub Jelinek <jakub@redhat.com>
17896 * config/nios2/nios2.cc (nios2_setup_incoming_varargs): Only skip
17897 nios2_function_arg_advance for TYPE_NO_NAMED_ARGS_STDARG_P functions
17898 if arg.type is NULL.
17900 2024-03-20 Jakub Jelinek <jakub@redhat.com>
17903 * config/nds32/nds32.cc (nds32_setup_incoming_varargs): Only skip
17904 function arg advance for TYPE_NO_NAMED_ARGS_STDARG_P functions
17905 if arg.type is NULL.
17907 2024-03-20 Jakub Jelinek <jakub@redhat.com>
17910 * config/m32r/m32r.cc (m32r_setup_incoming_varargs): Only skip
17911 function arg advance for TYPE_NO_NAMED_ARGS_STDARG_P functions
17912 if arg.type is NULL.
17914 2024-03-20 Jakub Jelinek <jakub@redhat.com>
17917 * config/ft32/ft32.cc (ft32_setup_incoming_varargs): Only skip
17918 function arg advance for TYPE_NO_NAMED_ARGS_STDARG_P functions
17919 if arg.type is NULL.
17921 2024-03-20 Jakub Jelinek <jakub@redhat.com>
17924 * config/epiphany/epiphany.cc (epiphany_setup_incoming_varargs): Only
17925 skip function arg advance for TYPE_NO_NAMED_ARGS_STDARG_P functions
17926 if arg.type is NULL.
17928 2024-03-20 Jakub Jelinek <jakub@redhat.com>
17931 * config/csky/csky.cc (csky_setup_incoming_varargs): Only skip
17932 csky_function_arg_advance for TYPE_NO_NAMED_ARGS_STDARG_P functions
17933 if arg.type is NULL.
17935 2024-03-20 Yury Khrustalev <yury.khrustalev@arm.com>
17937 * config/aarch64/aarch64-sys-regs.def: Copy from Binutils.
17939 2024-03-20 Jakub Jelinek <jakub@redhat.com>
17941 PR tree-optimization/114365
17942 * gimple-lower-bitint.cc (bitint_large_huge::handle_load): When adding
17943 a PHI node, set iv2 to its result afterwards.
17945 2024-03-20 Jakub Jelinek <jakub@redhat.com>
17947 * tree-ssa-loop-ch.cc (update_profile_after_ch): Fix comment typo:
17948 probabbility -> probability.
17949 (ch_base::copy_headers): Fix comment typo: itrations -> iterations.
17951 2024-03-20 Jakub Jelinek <jakub@redhat.com>
17953 PR bootstrap/114369
17954 * system.h (vec_step): Define to vec_step_ when compiling
17955 with clang on PowerPC.
17957 2024-03-20 demin.han <demin.han@starfivetech.com>
17960 * config/riscv/riscv-opts.h (enum riscv_autovec_lmul_enum): Rename
17961 (enum rvv_max_lmul_enum): Ditto
17962 (TARGET_MAX_LMUL): Ditto
17963 * config/riscv/riscv-v.cc (preferred_simd_mode): Ditto
17964 * config/riscv/riscv-vector-costs.cc (costs::record_potential_unexpected_spills): Ditto
17965 (costs::better_main_loop_than_p): Ditto
17966 * config/riscv/riscv.opt: Replace -param=riscv-autovec-lmul with -mrvv-max-lmul
17968 2024-03-20 Richard Biener <rguenther@suse.de>
17970 PR middle-end/113396
17971 * tree-dfa.cc (get_ref_base_and_extent): Use index range
17972 bounds only if they fit within the address-range constraints
17975 2024-03-20 Chenghui Pan <panchenghui@loongson.cn>
17977 * config/loongarch/loongarch.cc
17978 (loongarch_hard_regno_mode_ok_uncached): Combine UNITS_PER_FP_REG and
17979 UNITS_PER_FPREG macros.
17980 (loongarch_hard_regno_nregs): Ditto.
17981 (loongarch_class_max_nregs): Ditto.
17982 (loongarch_get_separate_components): Ditto.
17983 (loongarch_process_components): Ditto.
17984 * config/loongarch/loongarch.h (UNITS_PER_FPREG): Ditto.
17985 (UNITS_PER_HWFPVALUE): Ditto.
17986 (UNITS_PER_FPVALUE): Ditto.
17988 2024-03-20 Chenghui Pan <panchenghui@loongson.cn>
17990 * config/loongarch/lasx.md (vec_cmp<mode><mode256_i>): Remove checking
17991 of loongarch_expand_vec_cmp()'s return value.
17992 (vec_cmpu<ILASX:mode><mode256_i>): Ditto.
17993 * config/loongarch/lsx.md (vec_cmp<mode><mode_i>): Ditto.
17994 (vec_cmpu<ILSX:mode><mode_i>): Ditto.
17995 * config/loongarch/loongarch-protos.h
17996 (loongarch_expand_vec_cmp): Change loongarch_expand_vec_cmp()'s return
17997 type from bool to void.
17998 * config/loongarch/loongarch.cc (loongarch_expand_vec_cmp): Ditto.
18000 2024-03-20 Chenghui Pan <panchenghui@loongson.cn>
18002 * config/loongarch/loongarch-protos.h
18003 (loongarch_cfun_has_cprestore_slot_p): Delete.
18004 (loongarch_adjust_insn_length): Delete.
18005 (current_section_name): Delete.
18006 (loongarch_split_symbol_type): Delete.
18007 * config/loongarch/loongarch.cc
18008 (loongarch_case_values_threshold): Delete.
18009 (loongarch_spill_class): Delete.
18010 (TARGET_OPTAB_SUPPORTED_P): Delete.
18011 (TARGET_CASE_VALUES_THRESHOLD): Delete.
18012 (TARGET_SPILL_CLASS): Delete.
18014 2024-03-20 Lewis Hyatt <lhyatt@gmail.com>
18017 * diagnostic-core.h (enum diagnostic_t): Add DK_ANY special flag.
18018 * diagnostic.cc (diagnostic_option_classifier::classify_diagnostic):
18019 Make use of DK_ANY to indicate a diagnostic was initially enabled.
18020 (diagnostic_context::diagnostic_enabled): Do not change the type of
18021 a diagnostic if the saved classification is type DK_ANY.
18023 2024-03-19 Martin Jambor <mjambor@suse.cz>
18027 * ipa-prop.cc (ipa_get_stmt_member_ptr_load_param): Fix case looking
18028 at COMPONENT_REFs directly from a PARM_DECL, also recognize loads from
18029 a pointer parameter.
18030 (ipa_analyze_indirect_call_uses): Also recognize loads from a pointer
18031 parameter, also recognize the case when pfn pointer is loaded in its
18034 2024-03-19 Vladimir N. Makarov <vmakarov@redhat.com>
18037 * lra-constraints.cc (lra_constraints): Prevent removing insn
18038 with reverse equivalence to memory if the memory was reloaded.
18040 2024-03-19 David Malcolm <dmalcolm@redhat.com>
18042 PR middle-end/114348
18043 * diagnostic-format-json.cc
18044 (json_stderr_output_format::machine_readable_stderr_p): New.
18045 (json_file_output_format::machine_readable_stderr_p): New.
18046 * diagnostic-format-sarif.cc
18047 (sarif_stream_output_format::machine_readable_stderr_p): New.
18048 (sarif_file_output_format::machine_readable_stderr_p): New.
18049 * diagnostic.cc (diagnostic_context::action_after_output): Move
18050 "fnotice" to before "finish" call, so that we still have the
18051 diagnostic_context.
18052 (fnotice): Bail out if the user requested one of the
18053 machine-readable diagnostic output formats on stderr.
18055 (diagnostic_output_format::machine_readable_stderr_p): New pure
18057 (diagnostic_text_output_format::machine_readable_stderr_p): New.
18058 (diagnostic_context::get_output_format): New accessor.
18060 2024-03-19 Edwin Lu <ewlu@rivosinc.com>
18063 * config/riscv/riscv.cc (riscv_setup_incoming_varargs): Only skip
18064 riscv_funciton_arg_advance for TYPE_NO_NAMED_ARGS_STDARG_P functions
18065 if arg.type is NULL
18067 2024-03-19 Jonathan Wakely <jwakely@redhat.com>
18069 * doc/install.texi (Prerequisites): Document use of autogen for
18072 2024-03-19 Richard Biener <rguenther@suse.de>
18074 PR tree-optimization/114151
18075 PR tree-optimization/114269
18076 PR tree-optimization/114322
18077 PR tree-optimization/114074
18078 * tree-chrec.cc (chrec_fold_multiply): Restrict the use of
18079 unsigned arithmetic when actual overflow on constant operands
18082 2024-03-19 Jakub Jelinek <jakub@redhat.com>
18085 * config/arc/arc.cc (arc_setup_incoming_varargs): Only skip
18086 arc_function_arg_advance for TYPE_NO_NAMED_ARGS_STDARG_P functions
18087 if arg.type is NULL.
18089 2024-03-19 Xi Ruoyao <xry111@xry111.site>
18092 * config/loongarch/loongarch.cc
18093 (loongarch_setup_incoming_varargs): Only skip
18094 loongarch_function_arg_advance for TYPE_NO_NAMED_ARGS_STDARG_P
18095 functions if arg.type is NULL.
18097 2024-03-19 Christophe Lyon <christophe.lyon@linaro.org>
18100 * config/arm/arm-mve-builtins.cc
18101 (function_instance::reads_global_state_p): Take CP_READ_MEMORY
18104 2024-03-19 Jakub Jelinek <jakub@redhat.com>
18107 * config/alpha/alpha.cc (alpha_setup_incoming_varargs): Only skip
18108 function_arg_advance for TYPE_NO_NAMED_ARGS_STDARG_P functions
18109 if arg.type is NULL.
18111 2024-03-19 Jakub Jelinek <jakub@redhat.com>
18114 * config/rs6000/rs6000-call.cc (setup_incoming_varargs): Only skip
18115 rs6000_function_arg_advance_1 for TYPE_NO_NAMED_ARGS_STDARG_P functions
18116 if arg.type is NULL.
18118 2024-03-19 Richard Biener <rguenther@suse.de>
18120 PR tree-optimization/114375
18121 * tree-vect-slp.cc (vect_build_slp_tree_2): Compute the
18122 load permutation for masked loads but reject it when any
18124 * tree-vect-stmts.cc (vectorizable_load): Reject masked
18125 VMAT_ELEMENTWISE and VMAT_STRIDED_SLP as those are not
18128 2024-03-19 Mary Bennett <mary.bennett@embecosm.com>
18130 * common/config/riscv/riscv-common.cc: Create XCVbi extension
18132 * config/riscv/riscv.opt: Likewise.
18133 * config/riscv/corev.md: Implement cv_branch<mode> pattern
18134 for cv.beqimm and cv.bneimm.
18135 * config/riscv/riscv.md: Add CORE-V branch immediate to RISC-V
18136 branch instruction pattern.
18137 * config/riscv/constraints.md: Implement constraints
18138 cv_bi_s5 - signed 5-bit immediate.
18139 * config/riscv/predicates.md: Implement predicate
18140 const_int5s_operand - signed 5 bit immediate.
18141 * doc/sourcebuild.texi: Add XCVbi documentation.
18143 2024-03-19 Chen Jiawei <jiawei@iscas.ac.cn>
18145 * config/riscv/riscv-cores.def (RISCV_TUNE): New def.
18146 (RISCV_CORE): Ditto.
18147 * config/riscv/riscv-opts.h (enum riscv_microarchitecture_type): New
18149 * config/riscv/riscv.cc: New def.
18150 * config/riscv/riscv.md: New include.
18151 * config/riscv/xiangshan.md: New file.
18153 2024-03-18 David Malcolm <dmalcolm@redhat.com>
18159 * selftest.h (ASSERT_NE_AT): New macro.
18161 2024-03-18 Uros Bizjak <ubizjak@gmail.com>
18164 * config/i386/i386-features.cc (smode_convert_cst): New function
18165 to handle SImode, DImode and TImode immediates, generalized from
18166 timode_convert_cst.
18167 (timode_convert_cst): Remove.
18168 (scalar_chain::convert_op): Unify from
18169 general_scalar_chain::convert_op and timode_scalar_chain::convert_op.
18170 (general_scalar_chain::convert_op): Remove.
18171 (timode_scalar_chain::convert_op): Remove.
18172 (timode_scalar_chain::convert_insn): Update the call to
18173 renamed timode_convert_cst.
18174 * config/i386/i386-features.h (class scalar_chain):
18175 Redeclare convert_op as protected class member.
18176 (class general_calar_chain): Remove convert_op.
18177 (class timode_scalar_chain): Ditto.
18179 2024-03-18 Jan Hubicka <jh@suse.cz>
18181 * config/i386/zn4zn5.md: Add file missed in the previous commit.
18183 2024-03-18 Jan Hubicka <jh@suse.cz>
18184 Karthiban Anbazhagan <Karthiban.Anbazhagan@amd.com>
18186 * common/config/i386/cpuinfo.h (get_amd_cpu): Recognize znver5.
18187 * common/config/i386/i386-common.cc (processor_names): Add znver5.
18188 (processor_alias_table): Likewise.
18189 * common/config/i386/i386-cpuinfo.h (processor_types): Add new zen
18191 (processor_subtypes): Add znver5.
18192 * config.gcc (x86_64-*-* |...): Likewise.
18193 * config/i386/driver-i386.cc (host_detect_local_cpu): Let
18194 march=native detect znver5 cpu's.
18195 * config/i386/i386-c.cc (ix86_target_macros_internal): Add
18197 * config/i386/i386-options.cc (m_ZNVER5): New definition
18198 (processor_cost_table): Add znver5.
18199 * config/i386/i386.cc (ix86_reassociation_width): Likewise.
18200 * config/i386/i386.h (processor_type): Add PROCESSOR_ZNVER5
18201 (PTA_ZNVER5): New definition.
18202 * config/i386/i386.md (define_attr "cpu"): Add znver5.
18203 (Scheduling descriptions) Add znver5.md.
18204 * config/i386/x86-tune-costs.h (znver5_cost): New definition.
18205 * config/i386/x86-tune-sched.cc (ix86_issue_rate): Add znver5.
18206 (ix86_adjust_cost): Likewise.
18207 * config/i386/x86-tune.def (avx512_move_by_pieces): Add m_ZNVER5.
18208 (avx512_store_by_pieces): Add m_ZNVER5.
18209 * doc/extend.texi: Add znver5.
18210 * doc/invoke.texi: Likewise.
18211 * config/i386/znver4.md: Rename to zn4zn5.md; combine znver4 and znver5 Scheduler.
18213 2024-03-18 Georg-Johann Lay <avr@gjlay.de>
18215 * config/avr/constraints.md (CX2, CX3, CX4): New constraints.
18216 * config/avr/avr-protos.h (avr_xor_noclobber_dconst): New proto.
18217 * config/avr/avr.cc (avr_xor_noclobber_dconst): New function.
18218 * config/avr/avr.md (xorhi3, *xorhi3): Add "d,0,CX2,X" alternative.
18219 (xorpsi3, *xorpsi3): Add "d,0,CX3,X" alternative.
18220 (xorsi3, *xorsi3): Add "d,0,CX4,X" alternative.
18222 2024-03-18 liuhongt <hongtao.liu@intel.com>
18225 * config/i386/i386.md (mode): Add new number V8BF,V16BF,V32BF.
18226 (MODEF248): New mode iterator.
18227 (ssevecmodesuffix): Hanlde BF and HF.
18228 * config/i386/sse.md (andnot<mode>3): Extend to HF/BF.
18229 (<code><mode>3): Ditto.
18231 2024-03-18 John David Anglin <danglin@gcc.gnu.org>
18233 PR rtl-optimization/112415
18234 * config/pa/pa.cc (pa_emit_move_sequence): Revise condition
18235 for symbolic memory operands.
18236 (pa_legitimate_address_p): Revise LO_SUM condition.
18237 * config/pa/pa.h (INT14_OK_STRICT): Revise define. Move
18238 comment about GNU linker to predicates.md.
18239 * config/pa/predicates.md (floating_point_store_memory_operand):
18240 Revise condition for symbolic memory operands. Update
18243 2024-03-17 John David Anglin <danglin@gcc.gnu.org>
18245 * config/pa/pa.cc (pa_delegitimize_address): Delegitimize UNSPEC_TP.
18247 2024-03-16 Jakub Jelinek <jakub@redhat.com>
18250 * config/i386/i386.cc (ix86_setup_incoming_varargs): Only skip
18251 ix86_function_arg_advance for TYPE_NO_NAMED_ARGS_STDARG_P functions
18252 if arg.type is NULL.
18254 2024-03-16 Jakub Jelinek <jakub@redhat.com>
18256 PR tree-optimization/114329
18257 * gimple-lower-bitint.cc (struct bitint_large_huge): Declare
18258 build_bit_field_ref method.
18259 (bitint_large_huge::build_bit_field_ref): New method.
18260 (bitint_large_huge::lower_mergeable_stmt): Use it.
18262 2024-03-15 YunQiang Su <syq@gcc.gnu.org>
18264 * config/riscv/riscv.opt.urls: Regenerated.
18265 * config/rs6000/sysv4.opt.urls: Likewise.
18266 * config/xtensa/xtensa.opt.urls: Likewise.
18268 2024-03-15 Jakub Jelinek <jakub@redhat.com>
18270 * lower-subreg.cc (resolve_simple_move): Fix comment typo,
18272 * edit-context.cc (class line_event): Fix comment typo,
18273 betweeen -> between.
18275 2024-03-15 Jakub Jelinek <jakub@redhat.com>
18278 * config/i386/i386-expand.cc (ix86_expand_int_sse_cmp) <case LE>: Fix
18279 a pasto, compare code against LE rather than GE.
18281 2024-03-15 Joe Ramsay <Joe.Ramsay@arm.com>
18283 * match.pd: Fix truncation pattern for -fno-signed-zeroes
18285 2024-03-15 Jakub Jelinek <jakub@redhat.com>
18287 PR middle-end/114332
18288 * expr.cc (expand_expr_real_1): EXTEND_BITINT also CALL_EXPR results.
18290 2024-03-15 Jakub Jelinek <jakub@redhat.com>
18292 PR tree-optimization/113466
18293 * gimple-lower-bitint.cc (bitint_large_huge): Add m_returns_twice_calls
18295 (bitint_large_huge::bitint_large_huge): Initialize it.
18296 (bitint_large_huge::~bitint_large_huge): Release it.
18297 (bitint_large_huge::lower_call): Remember ECF_RETURNS_TWICE call stmts
18298 before which at least one statement has been inserted.
18299 (gimple_lower_bitint): Move argument loads before ECF_RETURNS_TWICE
18300 calls to a different block and add corresponding PHIs.
18302 2024-03-15 YunQiang Su <syq@gcc.gnu.org>
18304 * config/mips/mips.opt: Support -mstrict-align, and use
18305 TARGET_STRICT_ALIGN as the flag; keep -m(no-)unaligned-access
18307 * config/mips/mips.h: Use TARGET_STRICT_ALIGN.
18308 * config/mips/mips.opt.urls: Regenerate.
18309 * doc/invoke.texi: Document -m(no-)strict-algin for MIPSr6.
18311 2024-03-15 Tejas Belagod <tejas.belagod@arm.com>
18313 PR middle-end/114108
18314 * tree-vect-patterns.cc (vect_recog_abd_pattern): Call
18315 vect_convert_output with the correct vecitype.
18317 2024-03-15 Chenghui Pan <panchenghui@loongson.cn>
18319 * config/loongarch/lasx.md (lasx_xvpermi_q_<LASX:mode>):
18320 Remove masking of operand 3.
18322 2024-03-14 Jason Merrill <jason@redhat.com>
18324 * tree-core.h (enum clobber_kind): Clarify CLOBBER_OBJECT_*
18327 2024-03-14 John David Anglin <danglin@gcc.gnu.org>
18330 * config/pa/pa.cc (pa_legitimate_address_p): Don't allow
18331 14-bit displacements before reload for modes that may use
18332 a floating-point load or store.
18334 2024-03-14 David Faust <david.faust@oracle.com>
18336 * config/bpf/bpf.h (INT8_TYPE): Change to signed char.
18338 2024-03-14 Max Filippov <jcmvbkbc@gmail.com>
18340 * config/xtensa/xtensa.md (movsi_internal): Move l32i and s32i
18341 patterns ahead of the l32i.n and s32i.n.
18343 2024-03-14 Jakub Jelinek <jakub@redhat.com>
18345 * config/gcn/gcn-hsa.h (ABI_VERSION_SPEC): Fix comment typo.
18347 2024-03-14 Jakub Jelinek <jakub@redhat.com>
18349 PR middle-end/113907
18350 * ipa-icf.cc (sem_item_optimizer::merge_classes): Reset
18351 SSA_NAME_RANGE_INFO and SSA_NAME_PTR_INFO on successfully ICF merged
18354 2024-03-14 Xi Ruoyao <xry111@xry111.site>
18356 * config/loongarch/loongarch.md (any_ge): Remove.
18357 (sge<u>_<X:mode><GPR:mode>): Remove.
18359 2024-03-14 Jakub Jelinek <jakub@redhat.com>
18362 * config/aarch64/aarch64.cc (aarch64_expand_compare_and_swap): For
18363 TImode force newval into a register.
18365 2024-03-14 Chung-Lin Tang <cltang@baylibre.com>
18367 * tree.h (OMP_CLAUSE_MAP_READONLY): New macro.
18368 (OMP_CLAUSE__CACHE__READONLY): New macro.
18369 * tree-core.h (struct GTY(()) tree_base): Adjust comments for new
18370 uses of readonly_flag bit in OMP_CLAUSE_MAP_READONLY and
18371 OMP_CLAUSE__CACHE__READONLY.
18372 * tree-pretty-print.cc (dump_omp_clause): Add support for printing
18373 OMP_CLAUSE_MAP_READONLY and OMP_CLAUSE__CACHE__READONLY.
18375 2024-03-14 Andreas Krebbel <krebbel@linux.ibm.com>
18377 * config/s390/s390.cc (s390_encode_section_info): Adjust the check
18378 for misaligned symbols.
18379 * config/s390/s390.opt: Improve documentation.
18381 2024-03-14 Jakub Jelinek <jakub@redhat.com>
18383 * gimple-iterator.cc (edge_before_returns_twice_call): Copy all
18384 flags and probability from ad_edge to e edge. If CDI_DOMINATORS
18385 are computed, recompute immediate dominator of other_edge->src
18386 and other_edge->dest.
18387 (gsi_safe_insert_before, gsi_safe_insert_seq_before): Update *iter
18388 for the returns_twice call case to the gsi_for_stmt (stmt) to deal
18389 with update it for bb splitting.
18391 2024-03-14 liuhongt <hongtao.liu@intel.com>
18393 * config/i386/i386-features.cc
18394 (general_scalar_chain::convert_op): Handle REG_EH_REGION note.
18395 (convert_scalars_to_vector): Ditto.
18396 * config/i386/i386-features.h (class scalar_chain): New
18397 memeber control_flow_insns.
18399 2024-03-13 Jakub Jelinek <jakub@redhat.com>
18401 PR middle-end/114319
18402 * gimple-ssa-store-merging.cc
18403 (imm_store_chain_info::try_coalesce_bswap): For 32-bit targets
18404 allow matching __builtin_bswap64 if there is bswapsi2 optab.
18406 2024-03-13 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
18408 * config/s390/s390.cc (s390_secondary_reload): Guard
18409 SYMBOL_FLAG_NOTALIGN2_P.
18411 2024-03-13 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
18413 * config/s390/s390-builtin-types.def: Update to reflect latest
18415 * config/s390/s390-builtins.def: Streamline vector builtins with
18418 2024-03-13 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
18420 * config/s390/s390-builtins.def (vec_permi): Deprecate.
18421 (vec_ctd): Deprecate.
18422 (vec_ctd_s64): Deprecate.
18423 (vec_ctd_u64): Deprecate.
18424 (vec_ctsl): Deprecate.
18425 (vec_ctul): Deprecate.
18426 (vec_ld2f): Deprecate.
18427 (vec_st2f): Deprecate.
18428 (vec_insert): Deprecate overloads with bool vectors.
18430 2024-03-13 Jakub Jelinek <jakub@redhat.com>
18432 PR middle-end/114313
18433 * gimple-lower-bitint.cc (bitint_large_huge::limb_access): Use
18434 TYPE_SIZE of TREE_TYPE (var) rather than TYPE_SIZE of type.
18435 (bitint_large_huge::handle_load): Pass NULL_TREE rather than
18436 rhs_type to limb_access for the bitfield load cases.
18437 (bitint_large_huge::lower_mergeable_stmt): Pass NULL_TREE rather than
18438 lhs_type to limb_access if nlhs is non-NULL.
18440 2024-03-13 Jakub Jelinek <jakub@redhat.com>
18442 PR sanitizer/112709
18443 * asan.cc (maybe_create_ssa_name, maybe_cast_to_ptrmode,
18444 build_check_stmt, maybe_instrument_call, asan_expand_mark_ifn): Use
18445 gsi_safe_insert_before instead of gsi_insert_before.
18447 2024-03-13 Jakub Jelinek <jakub@redhat.com>
18449 PR sanitizer/112709
18450 * gimple-iterator.h (gsi_safe_insert_before,
18451 gsi_safe_insert_seq_before): Declare.
18452 * gimple-iterator.cc: Include gimplify.h.
18453 (edge_before_returns_twice_call, adjust_before_returns_twice_call,
18454 gsi_safe_insert_before, gsi_safe_insert_seq_before): New functions.
18455 * ubsan.cc (instrument_mem_ref, instrument_pointer_overflow,
18456 instrument_nonnull_arg, instrument_nonnull_return): Use
18457 gsi_safe_insert_before instead of gsi_insert_before.
18458 (maybe_instrument_pointer_overflow): Use force_gimple_operand,
18459 gimple_seq_add_seq_without_update and gsi_safe_insert_seq_before
18460 instead of force_gimple_operand_gsi.
18461 (instrument_object_size): Likewise. Use gsi_safe_insert_before
18462 instead of gsi_insert_before.
18464 2024-03-12 Richard Biener <rguenther@suse.de>
18466 PR tree-optimization/114121
18467 * tree-chrec.cc (chrec_fold_plus_1): Guard recursion with
18468 converted operand properly.
18469 (chrec_fold_multiply): Likewise. Handle missed recursion.
18471 2024-03-12 Jakub Jelinek <jakub@redhat.com>
18473 PR sanitizer/112709
18474 * asan.cc (has_stmt_been_instrumented_p): Don't instrument call
18475 stores on the caller side unless it is a call to a builtin or
18476 internal function or function doesn't return by hidden reference.
18477 (maybe_instrument_call): Likewise.
18478 (instrument_derefs): Instrument stores to RESULT_DECL if
18479 returning by hidden reference.
18481 2024-03-12 Jakub Jelinek <jakub@redhat.com>
18483 PR tree-optimization/114293
18484 * tree-ssa-strlen.cc (strlen_pass::handle_builtin_strlen): If
18485 max is smaller than min, set max to ~(size_t)0.
18487 2024-03-12 Pan Li <pan2.li@intel.com>
18489 * config/riscv/riscv-c.cc (riscv_ext_version_value): Fix
18490 code style greater than 80 chars.
18491 (riscv_cpu_cpp_builtins): Fix useless empty line, indent
18492 with 3 space(s) and argument unalignment.
18494 2024-03-12 Richard Biener <rguenther@suse.de>
18496 PR tree-optimization/114297
18497 * tree-vect-loop.cc (vectorizable_live_operation): Pass in the
18498 live stmts SLP node to vect_create_epilog_for_reduction.
18500 2024-03-12 Andrew Pinski <quic_apinski@quicinc.com>
18503 * common.opt (fmultiflags): Add RejectNegative.
18505 2024-03-11 Szabolcs Nagy <szabolcs.nagy@arm.com>
18507 * config/aarch64/aarch64.md: Rename aarch_ to aarch64_.
18508 * config/aarch64/aarch64.opt: Likewise.
18509 * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins): Likewise.
18510 * config/aarch64/aarch64.cc (aarch64_expand_prologue): Likewise.
18511 (aarch64_expand_epilogue): Likewise.
18512 (aarch64_post_cfi_startproc): Likewise.
18513 (aarch64_handle_no_branch_protection): Copy and rename.
18514 (aarch64_handle_standard_branch_protection): Likewise.
18515 (aarch64_handle_pac_ret_protection): Likewise.
18516 (aarch64_handle_pac_ret_leaf): Likewise.
18517 (aarch64_handle_pac_ret_b_key): Likewise.
18518 (aarch64_handle_bti_protection): Likewise.
18519 (aarch64_override_options): Update branch protection validation.
18520 (aarch64_handle_attr_branch_protection): Likewise.
18521 * config/arm/aarch-common-protos.h (aarch_validate_mbranch_protection):
18522 Pass branch protection type description as argument.
18523 (struct aarch_branch_protect_type): Move from aarch-common.h.
18524 * config/arm/aarch-common.cc (aarch_handle_no_branch_protection):
18526 (aarch_handle_standard_branch_protection): Remove.
18527 (aarch_handle_pac_ret_protection): Remove.
18528 (aarch_handle_pac_ret_leaf): Remove.
18529 (aarch_handle_pac_ret_b_key): Remove.
18530 (aarch_handle_bti_protection): Remove.
18531 (aarch_validate_mbranch_protection): Pass branch protection type
18532 description as argument.
18533 * config/arm/aarch-common.h (enum aarch_key_type): Remove.
18534 (struct aarch_branch_protect_type): Remove.
18535 * config/arm/arm-c.cc (arm_cpu_builtins): Remove aarch_ra_sign_key.
18536 * config/arm/arm.cc (arm_handle_no_branch_protection): Copy and rename.
18537 (arm_handle_standard_branch_protection): Likewise.
18538 (arm_handle_pac_ret_protection): Likewise.
18539 (arm_handle_pac_ret_leaf): Likewise.
18540 (arm_handle_bti_protection): Likewise.
18541 (arm_configure_build_target): Update branch protection validation.
18542 * config/arm/arm.opt: Remove aarch_ra_sign_key.
18544 2024-03-11 Richard Biener <rguenther@suse.de>
18546 PR middle-end/114299
18547 * gimplify.cc (internal_get_tmp_var): When gimplification
18548 of VAL failed, return a decl.
18550 2024-03-11 Jakub Jelinek <jakub@redhat.com>
18552 PR tree-optimization/114278
18553 * tree-ssa.cc (maybe_optimize_var): If large/huge _BitInt vars are no
18554 longer addressable, set DECL_NOT_GIMPLE_REG_P on them.
18556 2024-03-11 Eric Botcazou <ebotcazou@adacore.com>
18560 * dwarf2out.cc (gen_enumeration_type_die): In the reverse case,
18561 generate the DIE with the same parent as in the regular case.
18563 2024-03-11 Andrew Pinski <quic_apinski@quicinc.com>
18565 PR middle-end/95351
18566 * fold-const.cc (merge_truthop_with_opposite_arm): Use
18567 the type of the operands of the comparison and not the type
18570 2024-03-10 jlaw <jeffreyalaw@gmail.com>
18572 PR tree-optimization/110199
18573 * tree-ssa-scopedtables.cc
18574 (avail_exprs_stack::simplify_binary_operation): Generalize handling
18575 of MIN_EXPR/MAX_EXPR to allow additional simplifications. Canonicalize
18576 comparison operands for other cases.
18578 2024-03-10 Pan Li <pan2.li@intel.com>
18580 * tree-vect-stmts.cc (vectorizable_store): Enable the assert
18581 during transform process.
18582 (vectorizable_load): Ditto.
18584 2024-03-10 jlaw <jeffreyalaw@gmail.com>
18587 * doc/install.texi: Document need for python when building
18590 2024-03-10 jlaw <jeffreyalaw@gmail.com>
18593 * mode-switching.cc (optimize_mode_switching): Only process
18596 2024-03-09 Georg-Johann Lay <avr@gjlay.de>
18598 * config/avr/avr.md: Fix typos in comment, indentation glitches
18599 and some other nits.
18601 2024-03-09 Jakub Jelinek <jakub@redhat.com>
18604 * fwprop.cc (try_fwprop_subst_pattern): Don't propagate
18605 src containing MEMs unless prop.likely_profitable_p ().
18607 2024-03-09 Xi Ruoyao <xry111@xry111.site>
18609 * config/loongarch/loongarch.cc (loongarch_print_operand_reloc):
18610 Support 'Q' for R_LARCH_RELAX for TLS IE.
18611 (loongarch_output_move): Use 'Q' to print R_LARCH_RELAX for TLS
18613 * config/loongarch/loongarch.md (ld_from_got<mode>): Likewise.
18615 2024-03-09 Georg-Johann Lay <avr@gjlay.de>
18617 * config/avr/avr.cc (avr_rtx_costs_1) [PLUS]: Determine cost for
18618 usum_widenqihi and add_zero_extend1.
18619 [MINUS]: Determine costs for udiff_widenqihi, sub+zero_extend,
18621 * config/avr/avr.md (*addhi3.sign_extend1, *subhi3.sign_extend2):
18622 Compute exact insn lengths.
18623 (*usum_widenqihi3): Allow input operands to commute.
18625 2024-03-09 Jakub Jelinek <jakub@redhat.com>
18627 * config/i386/i386.opt.urls: Regenerate.
18629 2024-03-09 Lulu Cheng <chenglulu@loongson.cn>
18631 * config/loongarch/sync.md (atomic_cas_value_strong<mode>):
18632 In loongarch64, a sign extension operation is added when
18633 operands[2] is a register operand and the mode is SImode.
18635 2024-03-08 Martin Jambor <mjambor@suse.cz>
18638 * tree-inline.cc (redirect_all_calls): Remove code adding SSAs to
18639 id->killed_new_ssa_names.
18641 2024-03-08 Vladimir N. Makarov <vmakarov@redhat.com>
18644 * lra-assigns.cc (assign_by_spills): Set up all_spilled_pseudos
18645 for non-reload pseudo too.
18647 2024-03-08 David Faust <david.faust@oracle.com>
18649 * config/bpf/bpf.cc (bpf_expand_cpymem, bpf_expand_setmem): Do
18650 not attempt inline expansion if size is above threshold.
18651 * config/bpf/bpf.opt (-minline-memops-threshold): New option.
18652 * doc/invoke.texi (eBPF Options) <-minline-memops-threshold>:
18655 2024-03-08 Richard Biener <rguenther@suse.de>
18657 PR tree-optimization/114269
18658 PR tree-optimization/114074
18659 * tree-chrec.cc (chrec_fold_plus_1): Handle sign-conversions
18660 in the third CASE_CONVERT case as well.
18661 (chrec_fold_multiply): Handle sign-conversions from unsigned
18662 by performing the operation in the unsigned type.
18664 2024-03-08 Georg-Johann Lay <avr@gjlay.de>
18666 * config/avr/avr.md (*addhi3_zero_extend.ashift1): New pattern.
18667 * config/avr/avr.cc (avr_rtx_costs_1) [PLUS]: Compute its cost.
18669 2024-03-08 Jakub Jelinek <jakub@redhat.com>
18671 * bb-reorder.cc (fix_up_fall_thru_edges): Fix up checking assert,
18672 asm_noperands < 0 means it is not asm goto too.
18674 2024-03-08 Jakub Jelinek <jakub@redhat.com>
18677 * config/i386/i386.opt (mnoreturn-no-callee-saved-registers): New
18679 * config/i386/i386-options.cc (ix86_set_func_type): Don't use
18680 TYPE_NO_CALLEE_SAVED_REGISTERS_EXCEPT_BP unless
18681 ix86_noreturn_no_callee_saved_registers is enabled.
18682 * doc/invoke.texi (-mnoreturn-no-callee-saved-registers): Document.
18684 2024-03-08 Jakub Jelinek <jakub@redhat.com>
18687 * dwarf2out.cc (gen_field_die): Emit DW_AT_export_symbols
18688 on anonymous unions or structs for -gdwarf-5 or -gno-strict-dwarf.
18690 2024-03-08 demin.han <demin.han@starfivetech.com>
18693 * config/riscv/riscv-vector-costs.cc: Fix ICE
18695 2024-03-08 Haochen Gui <guihaoc@gcc.gnu.org>
18697 * fwprop.cc (forward_propagate_into): Return false for volatile set
18700 2024-03-07 Wilco Dijkstra <wilco.dijkstra@arm.com>
18703 * config/aarch64/aarch64.cc (aarch64_copy_one_block): Remove.
18704 (aarch64_expand_cpymem): Emit single load/store only.
18705 (aarch64_set_one_block): Emit single stores only.
18707 2024-03-07 Robin Dapp <rdapp@ventanamicro.com>
18709 PR middle-end/114196
18710 * tree-vect-loop-manip.cc (vect_can_peel_nonlinear_iv_p): Merge
18711 vectorization guards.
18713 2024-03-07 Jonathan Wakely <jwakely@redhat.com>
18715 * doc/cppopts.texi: Remove incorrect claim about -dD not
18716 outputting predefined macros.
18718 2024-03-07 Jeevitha Palanisamy <jeevitha@linux.ibm.com>
18721 * config/rs6000/vsx.md (vsx_splat_<mode>): Correct assignment to operand1
18722 and simplify else if with else.
18724 2024-03-07 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
18726 * system.h: Include safe-ctype.h after C++ standard headers.
18728 2024-03-07 Jakub Jelinek <jakub@redhat.com>
18730 PR rtl-optimization/110079
18731 * bb-reorder.cc (fix_crossing_unconditional_branches): Don't adjust
18734 2024-03-07 Jakub Jelinek <jakub@redhat.com>
18736 PR middle-end/105533
18737 * expmed.cc (choose_mult_variant): Only try the val - 1 variant
18738 if val is not HOST_WIDE_INT_MIN or if mode has exactly
18739 HOST_BITS_PER_WIDE_INT precision. Avoid triggering UB while computing
18742 2024-03-07 Jakub Jelinek <jakub@redhat.com>
18744 PR middle-end/105533
18745 * tree-ssa-sccvn.cc (ao_ref_init_from_vn_reference) <case ARRAY_REF>:
18746 Multiple op->off by BITS_PER_UNIT instead of shifting it left by
18747 LOG2_BITS_PER_UNIT.
18749 2024-03-07 Yang Yujie <yangyujie@loongson.cn>
18751 * config.gcc: Add a case for loongarch*-*-linux-musl*.
18752 * config/loongarch/linux.h: Disable the multilib-compatible
18753 treatment for *musl* targets.
18754 * config/loongarch/musl.h: New file.
18756 2024-03-07 Jakub Jelinek <jakub@redhat.com>
18758 PR tree-optimization/114009
18759 * genmatch.cc (decision_tree::gen): Emit ARG_UNUSED for captures
18760 argument even for GENERIC, not just for GIMPLE.
18761 * match.pd (a * !a -> 0): New simplifications.
18763 2024-03-07 demin.han <demin.han@starfivetech.com>
18765 * config/riscv/riscv-protos.h (expand_vec_cmp): Change proto
18766 * config/riscv/riscv-v.cc (expand_vec_cmp): Use default arguments
18767 (expand_vec_cmp_float): Adapt arguments
18769 2024-03-06 Uros Bizjak <ubizjak@gmail.com>
18772 * config/i386/mmx.md (negv2qi2): Enable for optimize_size instead
18773 of optimize_function_for_size_p. Explictily enable for TARGET_SSE2.
18774 (negv2qi SSE reg splitter): Enable for TARGET_SSE2 only.
18775 (<plusminus:insn>v2qi3): Enable for optimize_size instead
18776 of optimize_function_for_size_p. Explictily enable for TARGET_SSE2.
18777 (<plusminus:insn>v2qi SSE reg splitter): Enable for TARGET_SSE2 only.
18778 (<any_shift:insn>v2qi3): Enable for optimize_size instead
18779 of optimize_function_for_size_p.
18781 2024-03-06 Robin Dapp <rdapp@ventanamicro.com>
18785 * config/riscv/vector.md: Use vmv[1248]r.v instead of vmv.v.v.
18787 2024-03-06 Robin Dapp <rdapp@ventanamicro.com>
18789 * config/riscv/riscv-vector-costs.cc (adjust_stmt_cost): Move...
18790 (costs::adjust_stmt_cost): ... to here and add vec_load/vec_store
18792 (costs::add_stmt_cost): Also adjust cost for statements without
18794 * config/riscv/riscv-vector-costs.h: Define zero constant.
18796 2024-03-06 Wilco Dijkstra <wilco.dijkstra@arm.com>
18799 * config/arm/arm.md (NOCOND): Improve comment.
18800 (arm_rev*) Add predicable.
18801 * config/arm/arm.cc (arm_final_prescan_insn): Add check for
18804 2024-03-06 Jeff Law <jlaw@ventanamicro.com>
18808 * config/riscv/riscv.cc (expand_conditional_move): Do not swap
18809 operands when the comparison operand is the same as the false
18812 2024-03-06 Uros Bizjak <ubizjak@gmail.com>
18814 * config/i386/i386-expand.cc (ix86_expand_move) [TARGET_MACHO]:
18815 Eliminate common code and use generic code instead.
18817 2024-03-06 Georg-Johann Lay <avr@gjlay.de>
18819 * config/avr/avr.cc (avr_rtx_costs_1) [PLUS+ZERO_EXTEND]: Adjust
18822 2024-03-06 Richard Biener <rguenther@suse.de>
18824 PR tree-optimization/114239
18825 * tree-vect-loop.cc (vect_get_vect_def): Remove.
18826 (vect_create_epilog_for_reduction): The passed in stmt_info
18827 should now be the live stmt that produces the scalar reduction
18828 result. Revert PR114192 fix. Base reduction info off
18829 info_for_reduction. Remove special handling of
18830 early-break/peeled, restore original vector def gathering.
18831 Make sure to pick the correct exit PHIs.
18832 (vectorizable_live_operation): Pass in the proper stmt_info
18833 for early break exits.
18835 2024-03-06 Richard Sandiford <richard.sandiford@arm.com>
18837 * config/aarch64/aarch64-feature-deps.h (feature_deps::info): Add
18838 out-of-class definitions of static constants.
18840 2024-03-06 Richard Biener <rguenther@suse.de>
18842 PR tree-optimization/114249
18843 * tree-vect-slp.cc (vect_build_slp_instance): Move making
18844 a BB reduction lane number even ...
18845 (vect_slp_check_for_roots): ... here to avoid leaking
18848 2024-03-06 Richard Biener <rguenther@suse.de>
18850 PR tree-optimization/114246
18851 * tree-ssa-dse.cc (increment_start_addr): Strip useless
18852 type conversions from the adjusted address.
18854 2024-03-06 Jakub Jelinek <jakub@redhat.com>
18856 PR rtl-optimization/114190
18857 * config/i386/i386-features.cc (rest_of_handle_insert_vzeroupper):
18858 Call df_remove_problem for df_note before calling df_analyze.
18860 2024-03-05 Cupertino Miranda <cupertino.miranda@oracle.com>
18861 Indu Bhagat <indu.bhagat@oracle.com>
18864 * dwarf2ctf.cc (gen_ctf_array_type): Invoke the ctf_add_array ()
18865 in the correct order of the dimensions.
18866 (gen_ctf_subrange_type): Refactor out handling of
18867 DW_TAG_subrange_type DIE to here.
18869 2024-03-05 Richard Sandiford <richard.sandiford@arm.com>
18872 * asan.cc (asan_expand_mark_ifn): Allow the length to be a poly_int.
18874 2024-03-05 Richard Sandiford <richard.sandiford@arm.com>
18876 * config/aarch64/aarch64.md (stride_type): Remove luti_consecutive
18878 * config/aarch64/aarch64-sme.md
18879 (@aarch64_sme_lut<LUTI_BITS><mode>): Remove stride_type attribute.
18880 (@aarch64_sme_lut<LUTI_BITS><mode>_strided2): Delete.
18881 (@aarch64_sme_lut<LUTI_BITS><mode>_strided4): Likewise.
18882 * config/aarch64/aarch64-early-ra.cc (is_stride_candidate)
18883 (early_ra::maybe_convert_to_strided_access): Remove support for
18884 strided LUTI2 and LUTI4.
18886 2024-03-05 Richard Earnshaw <rearnsha@arm.com>
18889 * config/arm/thumb1.md (peephole2 to fuse mov imm/add SP): Use
18890 low_register_operand.
18892 2024-03-05 Georg-Johann Lay <avr@gjlay.de>
18894 * config/avr/avr.md: Add two RTL peepholes for PLUS, IOR and AND
18895 in HI, PSI, SI that swap operation order from "X = CST, X o= Y"
18896 to "X = Y, X o= CST".
18898 2024-03-05 Xi Ruoyao <xry111@xry111.site>
18900 * config/loongarch/loongarch.h (ADDITIONAL_REGISTER_NAMES): Add
18901 s9 as an alias of r22.
18903 2024-03-05 Roger Sayle <roger@nextmovesoftware.com>
18905 * config/avr/avr-protos.h (avr_out_insv): New proto.
18906 * config/avr/avr.cc (avr_out_insv): New function.
18907 (avr_adjust_insn_length) [ADJUST_LEN_INSV]: Handle case.
18908 (avr_cbranch_cost) [ZERO_EXTRACT]: Adjust rtx costs.
18909 * config/avr/avr.md (define_attr "adjust_len") Add insv.
18910 (andhi3, *andhi3, andpsi3, *andpsi3, andsi3, *andsi3):
18911 Add constraint alternative where the 3rd operand is a power
18912 of 2, and the source register may differ from the destination.
18913 (*insv.any_shift.<mode>_split): Call avr_out_insv to output
18914 instructions. Set attr "length" to "insv".
18915 * config/avr/constraints.md (Cb2, Cb3, Cb4): New constraints.
18917 2024-03-05 Richard Biener <rguenther@suse.de>
18919 PR tree-optimization/114231
18920 * tree-vect-slp.cc (vect_analyze_slp): Lookup patterns when
18921 processing a BB SLP root.
18923 2024-03-05 Jakub Jelinek <jakub@redhat.com>
18925 PR rtl-optimization/114211
18926 * lower-subreg.cc (resolve_simple_move): For double-word
18927 rotates by BITS_PER_WORD if there is overlap between source
18928 and destination use a temporary.
18930 2024-03-05 Jakub Jelinek <jakub@redhat.com>
18932 PR middle-end/114157
18933 * gimple-lower-bitint.cc: Include stor-layout.h.
18934 (mergeable_op): Return true for BIT_FIELD_REF.
18935 (struct bitint_large_huge): Declare handle_bit_field_ref method.
18936 (bitint_large_huge::handle_bit_field_ref): New method.
18937 (bitint_large_huge::handle_stmt): Use it for BIT_FIELD_REF.
18939 2024-03-05 Jakub Jelinek <jakub@redhat.com>
18942 * config/i386/i386.h (enum call_saved_registers_type): Add
18943 TYPE_NO_CALLEE_SAVED_REGISTERS_EXCEPT_BP enumerator.
18944 * config/i386/i386-options.cc (ix86_set_func_type): Remove
18945 has_no_callee_saved_registers variable, add no_callee_saved_registers
18946 instead, initialize it depending on whether it is
18947 no_callee_saved_registers function or not. Don't set it if
18948 no_caller_saved_registers attribute is present. Adjust users.
18949 * config/i386/i386.cc (ix86_function_ok_for_sibcall): Handle
18950 TYPE_NO_CALLEE_SAVED_REGISTERS_EXCEPT_BP like
18951 TYPE_NO_CALLEE_SAVED_REGISTERS.
18952 (ix86_save_reg): Handle TYPE_NO_CALLEE_SAVED_REGISTERS_EXCEPT_BP.
18954 2024-03-05 Pan Li <pan2.li@intel.com>
18956 * config/riscv/riscv.cc (riscv_v_adjust_bytesize): Cleanup unused
18957 mode_size related code.
18959 2024-03-05 Patrick Palka <ppalka@redhat.com>
18961 * doc/invoke.texi (-Wno-global-module): Document.
18963 2024-03-04 David Faust <david.faust@oracle.com>
18965 * config/bpf/bpf-protos.h (bpf_expand_setmem): New prototype.
18966 * config/bpf/bpf.cc (bpf_expand_setmem): New.
18967 * config/bpf/bpf.md (setmemdi): New define_expand.
18969 2024-03-04 Jakub Jelinek <jakub@redhat.com>
18971 PR rtl-optimization/113010
18972 * combine.cc (simplify_comparison): Guard the
18973 WORD_REGISTER_OPERATIONS check on scalar_int_mode of SUBREG_REG
18974 and initialize inner_mode.
18976 2024-03-04 Andre Vieira <andre.simoesdiasvieira@arm.com>
18978 * config/arm/iterators.md (supf): Remove VMLALDAVXQ_U, VMLALDAVXQ_P_U,
18979 VMLALDAVAXQ_U cases.
18980 (VMLALDAVXQ): Remove iterator.
18981 (VMLALDAVXQ_P): Likewise.
18982 (VMLALDAVAXQ): Likewise.
18983 * config/arm/mve.md (mve_vstrwq_p_fv4sf): Replace use of <MVE_VPRED>
18984 mode iterator attribute with V4BI mode.
18985 * config/arm/unspecs.md (VMLALDAVXQ_U, VMLALDAVXQ_P_U,
18986 VMLALDAVAXQ_U): Remove unused unspecs.
18988 2024-03-04 Andre Vieira <andre.simoesdiasvieira@arm.com>
18990 * config/arm/arm.md (mve_safe_imp_xlane_pred): New attribute.
18991 * config/arm/iterators.md (mve_vmaxmin_safe_imp): New iterator
18993 * config/arm/mve.md (vaddvq_s, vaddvq_u, vaddlvq_s, vaddlvq_u,
18994 vaddvaq_s, vaddvaq_u, vmaxavq_s, vmaxvq_u, vmladavq_s, vmladavq_u,
18995 vmladavxq_s, vmlsdavq_s, vmlsdavxq_s, vaddlvaq_s, vaddlvaq_u,
18996 vmlaldavq_u, vmlaldavq_s, vmlaldavq_u, vmlaldavxq_s, vmlsldavq_s,
18997 vmlsldavxq_s, vrmlaldavhq_u, vrmlaldavhq_s, vrmlaldavhxq_s,
18998 vrmlsldavhq_s, vrmlsldavhxq_s, vrmlaldavhaq_s, vrmlaldavhaq_u,
18999 vrmlaldavhaxq_s, vrmlsldavhaq_s, vrmlsldavhaxq_s, vabavq_s, vabavq_u,
19000 vmladavaq_u, vmladavaq_s, vmladavaxq_s, vmlsdavaq_s, vmlsdavaxq_s,
19001 vmlaldavaq_s, vmlaldavaq_u, vmlaldavaxq_s, vmlsldavaq_s,
19002 vmlsldavaxq_s): Added mve_safe_imp_xlane_pred.
19004 2024-03-04 Stam Markianos-Wright <stam.markianos-wright@arm.com>
19006 * config/arm/arm.md (mve_unpredicated_insn): New attribute.
19007 * config/arm/arm.h (MVE_VPT_PREDICATED_INSN_P): New define.
19008 (MVE_VPT_UNPREDICATED_INSN_P): Likewise.
19009 (MVE_VPT_PREDICABLE_INSN_P): Likewise.
19010 * config/arm/vec-common.md (mve_vshlq_<supf><mode>): Add attribute.
19011 * config/arm/mve.md (arm_vcx1q<a>_p_v16qi): Add attribute.
19012 (arm_vcx1q<a>v16qi): Likewise.
19013 (arm_vcx1qav16qi): Likewise.
19014 (arm_vcx1qv16qi): Likewise.
19015 (arm_vcx2q<a>_p_v16qi): Likewise.
19016 (arm_vcx2q<a>v16qi): Likewise.
19017 (arm_vcx2qav16qi): Likewise.
19018 (arm_vcx2qv16qi): Likewise.
19019 (arm_vcx3q<a>_p_v16qi): Likewise.
19020 (arm_vcx3q<a>v16qi): Likewise.
19021 (arm_vcx3qav16qi): Likewise.
19022 (arm_vcx3qv16qi): Likewise.
19023 (@mve_<mve_insn>q_<supf><mode>): Likewise.
19024 (@mve_<mve_insn>q_int_<supf><mode>): Likewise.
19025 (@mve_<mve_insn>q_<supf>v4si): Likewise.
19026 (@mve_<mve_insn>q_n_<supf><mode>): Likewise.
19027 (@mve_<mve_insn>q_r_<supf><mode>): Likewise.
19028 (@mve_<mve_insn>q_f<mode>): Likewise.
19029 (@mve_<mve_insn>q_m_<supf><mode>): Likewise.
19030 (@mve_<mve_insn>q_m_n_<supf><mode>): Likewise.
19031 (@mve_<mve_insn>q_m_r_<supf><mode>): Likewise.
19032 (@mve_<mve_insn>q_m_f<mode>): Likewise.
19033 (@mve_<mve_insn>q_int_m_<supf><mode>): Likewise.
19034 (@mve_<mve_insn>q_p_<supf>v4si): Likewise.
19035 (@mve_<mve_insn>q_p_<supf><mode>): Likewise.
19036 (@mve_<mve_insn>q<mve_rot>_<supf><mode>): Likewise.
19037 (@mve_<mve_insn>q<mve_rot>_f<mode>): Likewise.
19038 (@mve_<mve_insn>q<mve_rot>_m_<supf><mode>): Likewise.
19039 (@mve_<mve_insn>q<mve_rot>_m_f<mode>): Likewise.
19040 (mve_v<absneg_str>q_f<mode>): Likewise.
19041 (mve_<mve_addsubmul>q<mode>): Likewise.
19042 (mve_<mve_addsubmul>q_f<mode>): Likewise.
19043 (mve_vadciq_<supf>v4si): Likewise.
19044 (mve_vadciq_m_<supf>v4si): Likewise.
19045 (mve_vadcq_<supf>v4si): Likewise.
19046 (mve_vadcq_m_<supf>v4si): Likewise.
19047 (mve_vandq_<supf><mode>): Likewise.
19048 (mve_vandq_f<mode>): Likewise.
19049 (mve_vandq_m_<supf><mode>): Likewise.
19050 (mve_vandq_m_f<mode>): Likewise.
19051 (mve_vandq_s<mode>): Likewise.
19052 (mve_vandq_u<mode>): Likewise.
19053 (mve_vbicq_<supf><mode>): Likewise.
19054 (mve_vbicq_f<mode>): Likewise.
19055 (mve_vbicq_m_<supf><mode>): Likewise.
19056 (mve_vbicq_m_f<mode>): Likewise.
19057 (mve_vbicq_m_n_<supf><mode>): Likewise.
19058 (mve_vbicq_n_<supf><mode>): Likewise.
19059 (mve_vbicq_s<mode>): Likewise.
19060 (mve_vbicq_u<mode>): Likewise.
19061 (@mve_vclzq_s<mode>): Likewise.
19062 (mve_vclzq_u<mode>): Likewise.
19063 (@mve_vcmp_<mve_cmp_op>q_<mode>): Likewise.
19064 (@mve_vcmp_<mve_cmp_op>q_n_<mode>): Likewise.
19065 (@mve_vcmp_<mve_cmp_op>q_f<mode>): Likewise.
19066 (@mve_vcmp_<mve_cmp_op>q_n_f<mode>): Likewise.
19067 (@mve_vcmp_<mve_cmp_op1>q_m_f<mode>): Likewise.
19068 (@mve_vcmp_<mve_cmp_op1>q_m_n_<supf><mode>): Likewise.
19069 (@mve_vcmp_<mve_cmp_op1>q_m_<supf><mode>): Likewise.
19070 (@mve_vcmp_<mve_cmp_op1>q_m_n_f<mode>): Likewise.
19071 (mve_vctp<MVE_vctp>q<MVE_vpred>): Likewise.
19072 (mve_vctp<MVE_vctp>q_m<MVE_vpred>): Likewise.
19073 (mve_vcvtaq_<supf><mode>): Likewise.
19074 (mve_vcvtaq_m_<supf><mode>): Likewise.
19075 (mve_vcvtbq_f16_f32v8hf): Likewise.
19076 (mve_vcvtbq_f32_f16v4sf): Likewise.
19077 (mve_vcvtbq_m_f16_f32v8hf): Likewise.
19078 (mve_vcvtbq_m_f32_f16v4sf): Likewise.
19079 (mve_vcvtmq_<supf><mode>): Likewise.
19080 (mve_vcvtmq_m_<supf><mode>): Likewise.
19081 (mve_vcvtnq_<supf><mode>): Likewise.
19082 (mve_vcvtnq_m_<supf><mode>): Likewise.
19083 (mve_vcvtpq_<supf><mode>): Likewise.
19084 (mve_vcvtpq_m_<supf><mode>): Likewise.
19085 (mve_vcvtq_from_f_<supf><mode>): Likewise.
19086 (mve_vcvtq_m_from_f_<supf><mode>): Likewise.
19087 (mve_vcvtq_m_n_from_f_<supf><mode>): Likewise.
19088 (mve_vcvtq_m_n_to_f_<supf><mode>): Likewise.
19089 (mve_vcvtq_m_to_f_<supf><mode>): Likewise.
19090 (mve_vcvtq_n_from_f_<supf><mode>): Likewise.
19091 (mve_vcvtq_n_to_f_<supf><mode>): Likewise.
19092 (mve_vcvtq_to_f_<supf><mode>): Likewise.
19093 (mve_vcvttq_f16_f32v8hf): Likewise.
19094 (mve_vcvttq_f32_f16v4sf): Likewise.
19095 (mve_vcvttq_m_f16_f32v8hf): Likewise.
19096 (mve_vcvttq_m_f32_f16v4sf): Likewise.
19097 (mve_vdwdupq_m_wb_u<mode>_insn): Likewise.
19098 (mve_vdwdupq_wb_u<mode>_insn): Likewise.
19099 (mve_veorq_s><mode>): Likewise.
19100 (mve_veorq_u><mode>): Likewise.
19101 (mve_veorq_f<mode>): Likewise.
19102 (mve_vidupq_m_wb_u<mode>_insn): Likewise.
19103 (mve_vidupq_u<mode>_insn): Likewise.
19104 (mve_viwdupq_m_wb_u<mode>_insn): Likewise.
19105 (mve_viwdupq_wb_u<mode>_insn): Likewise.
19106 (mve_vldrbq_<supf><mode>): Likewise.
19107 (mve_vldrbq_gather_offset_<supf><mode>): Likewise.
19108 (mve_vldrbq_gather_offset_z_<supf><mode>): Likewise.
19109 (mve_vldrbq_z_<supf><mode>): Likewise.
19110 (mve_vldrdq_gather_base_<supf>v2di): Likewise.
19111 (mve_vldrdq_gather_base_wb_<supf>v2di_insn): Likewise.
19112 (mve_vldrdq_gather_base_wb_z_<supf>v2di_insn): Likewise.
19113 (mve_vldrdq_gather_base_z_<supf>v2di): Likewise.
19114 (mve_vldrdq_gather_offset_<supf>v2di): Likewise.
19115 (mve_vldrdq_gather_offset_z_<supf>v2di): Likewise.
19116 (mve_vldrdq_gather_shifted_offset_<supf>v2di): Likewise.
19117 (mve_vldrdq_gather_shifted_offset_z_<supf>v2di): Likewise.
19118 (mve_vldrhq_<supf><mode>): Likewise.
19119 (mve_vldrhq_fv8hf): Likewise.
19120 (mve_vldrhq_gather_offset_<supf><mode>): Likewise.
19121 (mve_vldrhq_gather_offset_fv8hf): Likewise.
19122 (mve_vldrhq_gather_offset_z_<supf><mode>): Likewise.
19123 (mve_vldrhq_gather_offset_z_fv8hf): Likewise.
19124 (mve_vldrhq_gather_shifted_offset_<supf><mode>): Likewise.
19125 (mve_vldrhq_gather_shifted_offset_fv8hf): Likewise.
19126 (mve_vldrhq_gather_shifted_offset_z_<supf><mode>): Likewise.
19127 (mve_vldrhq_gather_shifted_offset_z_fv8hf): Likewise.
19128 (mve_vldrhq_z_<supf><mode>): Likewise.
19129 (mve_vldrhq_z_fv8hf): Likewise.
19130 (mve_vldrwq_<supf>v4si): Likewise.
19131 (mve_vldrwq_fv4sf): Likewise.
19132 (mve_vldrwq_gather_base_<supf>v4si): Likewise.
19133 (mve_vldrwq_gather_base_fv4sf): Likewise.
19134 (mve_vldrwq_gather_base_wb_<supf>v4si_insn): Likewise.
19135 (mve_vldrwq_gather_base_wb_fv4sf_insn): Likewise.
19136 (mve_vldrwq_gather_base_wb_z_<supf>v4si_insn): Likewise.
19137 (mve_vldrwq_gather_base_wb_z_fv4sf_insn): Likewise.
19138 (mve_vldrwq_gather_base_z_<supf>v4si): Likewise.
19139 (mve_vldrwq_gather_base_z_fv4sf): Likewise.
19140 (mve_vldrwq_gather_offset_<supf>v4si): Likewise.
19141 (mve_vldrwq_gather_offset_fv4sf): Likewise.
19142 (mve_vldrwq_gather_offset_z_<supf>v4si): Likewise.
19143 (mve_vldrwq_gather_offset_z_fv4sf): Likewise.
19144 (mve_vldrwq_gather_shifted_offset_<supf>v4si): Likewise.
19145 (mve_vldrwq_gather_shifted_offset_fv4sf): Likewise.
19146 (mve_vldrwq_gather_shifted_offset_z_<supf>v4si): Likewise.
19147 (mve_vldrwq_gather_shifted_offset_z_fv4sf): Likewise.
19148 (mve_vldrwq_z_<supf>v4si): Likewise.
19149 (mve_vldrwq_z_fv4sf): Likewise.
19150 (mve_vmvnq_s<mode>): Likewise.
19151 (mve_vmvnq_u<mode>): Likewise.
19152 (mve_vornq_<supf><mode>): Likewise.
19153 (mve_vornq_f<mode>): Likewise.
19154 (mve_vornq_m_<supf><mode>): Likewise.
19155 (mve_vornq_m_f<mode>): Likewise.
19156 (mve_vornq_s<mode>): Likewise.
19157 (mve_vornq_u<mode>): Likewise.
19158 (mve_vorrq_<supf><mode>): Likewise.
19159 (mve_vorrq_f<mode>): Likewise.
19160 (mve_vorrq_m_<supf><mode>): Likewise.
19161 (mve_vorrq_m_f<mode>): Likewise.
19162 (mve_vorrq_m_n_<supf><mode>): Likewise.
19163 (mve_vorrq_n_<supf><mode>): Likewise.
19164 (mve_vorrq_s<mode>): Likewise.
19165 (mve_vorrq_s<mode>): Likewise.
19166 (mve_vsbciq_<supf>v4si): Likewise.
19167 (mve_vsbciq_m_<supf>v4si): Likewise.
19168 (mve_vsbcq_<supf>v4si): Likewise.
19169 (mve_vsbcq_m_<supf>v4si): Likewise.
19170 (mve_vshlcq_<supf><mode>): Likewise.
19171 (mve_vshlcq_m_<supf><mode>): Likewise.
19172 (mve_vshrq_m_n_<supf><mode>): Likewise.
19173 (mve_vshrq_n_<supf><mode>): Likewise.
19174 (mve_vstrbq_<supf><mode>): Likewise.
19175 (mve_vstrbq_p_<supf><mode>): Likewise.
19176 (mve_vstrbq_scatter_offset_<supf><mode>_insn): Likewise.
19177 (mve_vstrbq_scatter_offset_p_<supf><mode>_insn): Likewise.
19178 (mve_vstrdq_scatter_base_<supf>v2di): Likewise.
19179 (mve_vstrdq_scatter_base_p_<supf>v2di): Likewise.
19180 (mve_vstrdq_scatter_base_wb_<supf>v2di): Likewise.
19181 (mve_vstrdq_scatter_base_wb_p_<supf>v2di): Likewise.
19182 (mve_vstrdq_scatter_offset_<supf>v2di_insn): Likewise.
19183 (mve_vstrdq_scatter_offset_p_<supf>v2di_insn): Likewise.
19184 (mve_vstrdq_scatter_shifted_offset_<supf>v2di_insn): Likewise.
19185 (mve_vstrdq_scatter_shifted_offset_p_<supf>v2di_insn): Likewise.
19186 (mve_vstrhq_<supf><mode>): Likewise.
19187 (mve_vstrhq_fv8hf): Likewise.
19188 (mve_vstrhq_p_<supf><mode>): Likewise.
19189 (mve_vstrhq_p_fv8hf): Likewise.
19190 (mve_vstrhq_scatter_offset_<supf><mode>_insn): Likewise.
19191 (mve_vstrhq_scatter_offset_fv8hf_insn): Likewise.
19192 (mve_vstrhq_scatter_offset_p_<supf><mode>_insn): Likewise.
19193 (mve_vstrhq_scatter_offset_p_fv8hf_insn): Likewise.
19194 (mve_vstrhq_scatter_shifted_offset_<supf><mode>_insn): Likewise.
19195 (mve_vstrhq_scatter_shifted_offset_fv8hf_insn): Likewise.
19196 (mve_vstrhq_scatter_shifted_offset_p_<supf><mode>_insn): Likewise.
19197 (mve_vstrhq_scatter_shifted_offset_p_fv8hf_insn): Likewise.
19198 (mve_vstrwq_<supf>v4si): Likewise.
19199 (mve_vstrwq_fv4sf): Likewise.
19200 (mve_vstrwq_p_<supf>v4si): Likewise.
19201 (mve_vstrwq_p_fv4sf): Likewise.
19202 (mve_vstrwq_scatter_base_<supf>v4si): Likewise.
19203 (mve_vstrwq_scatter_base_fv4sf): Likewise.
19204 (mve_vstrwq_scatter_base_p_<supf>v4si): Likewise.
19205 (mve_vstrwq_scatter_base_p_fv4sf): Likewise.
19206 (mve_vstrwq_scatter_base_wb_<supf>v4si): Likewise.
19207 (mve_vstrwq_scatter_base_wb_fv4sf): Likewise.
19208 (mve_vstrwq_scatter_base_wb_p_<supf>v4si): Likewise.
19209 (mve_vstrwq_scatter_base_wb_p_fv4sf): Likewise.
19210 (mve_vstrwq_scatter_offset_<supf>v4si_insn): Likewise.
19211 (mve_vstrwq_scatter_offset_fv4sf_insn): Likewise.
19212 (mve_vstrwq_scatter_offset_p_<supf>v4si_insn): Likewise.
19213 (mve_vstrwq_scatter_offset_p_fv4sf_insn): Likewise.
19214 (mve_vstrwq_scatter_shifted_offset_<supf>v4si_insn): Likewise.
19215 (mve_vstrwq_scatter_shifted_offset_fv4sf_insn): Likewise.
19216 (mve_vstrwq_scatter_shifted_offset_p_<supf>v4si_insn): Likewise.
19217 (mve_vstrwq_scatter_shifted_offset_p_fv4sf_insn): Likewise.
19219 2024-03-04 Marek Polacek <polacek@redhat.com>
19221 * doc/extend.texi: Update [[gnu::no_dangling]].
19223 2024-03-04 Andrew Stubbs <ams@baylibre.com>
19225 * dojump.cc (do_compare_and_jump): Use full-width integers for shifts.
19226 * expr.cc (store_constructor): Likewise.
19227 (do_store_flag): Likewise.
19229 2024-03-04 Mark Wielaard <mark@klomp.org>
19231 * common.opt.urls: Regenerate.
19232 * config/avr/avr.opt.urls: Likewise.
19233 * config/i386/i386.opt.urls: Likewise.
19234 * config/pru/pru.opt.urls: Likewise.
19235 * config/riscv/riscv.opt.urls: Likewise.
19236 * config/rs6000/rs6000.opt.urls: Likewise.
19238 2024-03-04 Richard Biener <rguenther@suse.de>
19240 PR tree-optimization/114197
19241 * tree-if-conv.cc (bitfields_to_lower_p): Do not lower if
19242 there are volatile bitfield accesses.
19243 (pass_if_conversion::execute): Throw away result if the
19244 if-converted and original loops are not nested as expected.
19246 2024-03-04 Richard Biener <rguenther@suse.de>
19248 PR tree-optimization/114164
19249 * tree-vect-stmts.cc (vectorizable_simd_clone_call): Fail if
19250 the code generated for mask argument setup is not supported.
19252 2024-03-04 Richard Biener <rguenther@suse.de>
19254 PR tree-optimization/114203
19255 * tree-ssa-loop-niter.cc (build_cltz_expr): Apply CTZ->CLZ
19256 adjustment before making the result defined at zero.
19258 2024-03-04 Richard Biener <rguenther@suse.de>
19260 PR tree-optimization/114192
19261 * tree-vect-loop.cc (vect_create_epilog_for_reduction): Use the
19262 appropriate def for the live out stmt in case of an alternate
19265 2024-03-04 Jakub Jelinek <jakub@redhat.com>
19267 PR middle-end/114209
19268 * gimple-lower-bitint.cc (bitint_large_huge::limb_access): Call
19269 unshare_expr when creating a MEM_REF from MEM_REF.
19270 (bitint_large_huge::lower_stmt): Call unshare_expr.
19272 2024-03-04 Jakub Jelinek <jakub@redhat.com>
19275 * config/i386/i386-expand.cc (ix86_expand_move): If XFmode op1
19276 is SUBREG of CONSTANT_P, force the SUBREG_REG into memory or
19279 2024-03-04 Roger Sayle <roger@nextmovesoftware.com>
19282 * simplify-rtx.cc (simplify_context::simplify_subreg): Call
19283 lowpart_subreg to perform type conversion, to avoid confusion
19284 over the offset to use in the call to simplify_reg_subreg.
19286 2024-03-03 Greg McGary <gkm@rivosinc.com>
19288 PR rtl-optimization/113010
19289 * combine.cc (simplify_comparison): Simplify a SUBREG on
19290 WORD_REGISTER_OPERATIONS targets only if it is a zero-extending
19293 2024-03-03 Georg-Johann Lay <avr@gjlay.de>
19295 * config/avr/avr.cc: Resolve ATTRIBUTE_UNUSED.
19296 Use bool in place of int for boolean logic (if possible).
19297 Move declarations to definitions (if possible).
19298 * config/avr/avr.md: Use C++ comments. Fix some indentation glitches.
19299 * config/avr/avr-dimode.md: Same.
19300 * config/avr/constraints.md: Same.
19301 * config/avr/predicates.md: Same.
19303 2024-03-03 Uros Bizjak <ubizjak@gmail.com>
19306 * config/alpha/alpha.md (umuldi3_highpart): Remove expander.
19307 (*umuldi3_highpart_reg): Rename to umuldi3_highpart and
19308 simplify insn RTX using UMUL_HIGHPART rtx_code.
19309 (*umuldi3_highpart_const): Remove.
19311 2024-03-03 Georg-Johann Lay <avr@gjlay.de>
19314 * config/avr/avr-protos.h (_reg_unused_after): Remove proto.
19315 * config/avr/avr.cc (_reg_unused_after): Make static. And
19316 add 3rd argument to skip the current insn.
19317 (reg_unused_after): Adjust call of reg_unused_after.
19318 (avr_out_plus_1) [AVR_TINY && -mfuse-add >= 2]: Don't output
19319 unneeded frame pointer adjustments.
19321 2024-03-03 Georg-Johann Lay <avr@gjlay.de>
19324 * config/avr/avr.md (define_attr "cc"): Remove.
19325 * config/avr/avr-protos.h (avr_out_plus): Remove pcc argument
19327 * config/avr/avr.cc (avr_out_plus_1): Remove pcc argument and
19328 its uses. Add insn argument.
19329 (avr_out_plus_symbol): Remove pcc argument and its uses.
19330 (avr_out_plus): Remove pcc argument and its uses.
19331 Adjust calls of avr_out_plus_symbol and avr_out_plus_1.
19332 (avr_out_round): Adjust call of avr_out_plus.
19334 2024-03-03 Georg-Johann Lay <avr@gjlay.de>
19336 * config/avr/avr.cc (avr_init_cumulative_args): Fix a typo
19339 2024-03-03 Oleg Endo <olegendo@gcc.gnu.org>
19342 * config/sh/sh.cc (sh_is_nott_insn): Handle case where the input
19343 is not an insn, but e.g. a code label.
19345 2024-03-02 Georg-Johann Lay <avr@gjlay.de>
19347 * config/avr/avr.md (REG_0, ... REG_36): New define_constants.
19348 * config/avr/avr.cc: Use them instead of magic numbers when it
19349 means a register number.
19351 2024-03-02 Georg-Johann Lay <avr@gjlay.de>
19353 * config/avr/avr.cc: Adjust some comments.
19355 2024-03-02 Georg-Johann Lay <avr@gjlay.de>
19358 * config/avr/avr.cc (avr_out_plus_1) [-mtiny-stack]: Only adjust
19359 the low part of the frame pointer with 8-bit stack pointer.
19361 2024-03-01 Patrick Palka <ppalka@redhat.com>
19365 * tree-inline.cc (remap_decl): Handle copy_decl returning the
19367 (remap_decls): Handle remap_decl returning the original decl.
19368 (copy_fn): Adjust copy_decl callback to skip TYPE_DECL and
19371 2024-03-01 Jeff Law <jlaw@ventanamicro.com>
19373 * config/riscv/riscv.md (zero_extendqi<SUPERQI:mode>2_internal): Fix
19375 (extendsidi2_internal, movhf_hardfloat, movhf_softfloat): Likewise.
19376 (movdi_32bit, movdi_64bit, movsi_internal): Likewise.
19377 (movhi_internal, movqi_internal): Likewise.
19378 (movsf_softfloat, movsf_hardfloat): Likewise.
19379 (movdf_hardfloat_rv32, movdf_hardfloat_rv64): Likewise.
19380 (movdf_softfloat): Likewise.
19382 2024-03-01 Marek Polacek <polacek@redhat.com>
19386 * doc/extend.texi: Document gnu::no_dangling.
19387 * doc/invoke.texi: Mention that gnu::no_dangling disables
19388 -Wdangling-reference.
19390 2024-03-01 Georg-Johann Lay <avr@gjlay.de>
19392 * config/avr/avr.opt: Overhaul help screen.
19394 2024-03-01 Jakub Jelinek <jakub@redhat.com>
19395 Tobias Burnus <tburnus@baylibre.com>
19398 * gimplify.cc (omp_notice_variable): Fix 'shared' arg to
19399 lang_hooks.decls.omp_disregard_value_expr for
19400 (first)private in target regions.
19402 2024-03-01 Jakub Jelinek <jakub@redhat.com>
19404 PR middle-end/114136
19405 * calls.cc (expand_call): For TYPE_NO_NAMED_ARGS_STDARG_P set
19406 n_named_args initially before INIT_CUMULATIVE_ARGS to
19407 structure_value_addr_parm rather than 0, after it don't modify
19408 it if strict_argument_naming and clear only if
19409 !pretend_outgoing_varargs_named.
19411 2024-03-01 Jakub Jelinek <jakub@redhat.com>
19414 * dwarf2out.cc (should_move_die_to_comdat): Return false for
19415 aggregates without DW_AT_byte_size attribute or with non-constant
19418 2024-03-01 Georg-Johann Lay <avr@gjlay.de>
19420 * doc/invoke.texi (AVR Options) <-mfuse-add=level>: Document
19421 valid values for level.
19423 2024-03-01 Richard Biener <rguenther@suse.de>
19425 PR middle-end/114070
19426 * match.pd ((c ? a : b) op d --> c ? (a op d) : (b op d)):
19427 Allow the folding if before lowering and the current IL
19428 isn't supported with vcond_mask.
19430 2024-03-01 xuli <xuli1@eswincomputing.com>
19432 * config/riscv/riscv.cc (TARGET_GNU_ATTRIBUTES): Add riscv_vector_cc
19433 attribute to riscv_attribute_table.
19434 (riscv_vector_cc_function_p): Return true if FUNC is a riscv_vector_cc function.
19435 (riscv_fntype_abi): Add riscv_vector_cc attribute check.
19436 * doc/extend.texi: Add riscv_vector_cc attribute description.
19438 2024-03-01 Pan Li <pan2.li@intel.com>
19441 * config/riscv/riscv-avlprop.cc (pass_avlprop::execute): Replace
19442 RVV_FIXED_VLMAX to RVV_VECTOR_BITS_ZVL.
19443 * config/riscv/riscv-opts.h (enum riscv_autovec_preference_enum): Remove.
19444 (enum rvv_vector_bits_enum): New enum for different RVV vector bits.
19445 * config/riscv/riscv-selftests.cc (riscv_run_selftests): Update
19446 comments for option replacement.
19447 * config/riscv/riscv-v.cc (autovec_use_vlmax_p): Replace enum of
19448 riscv_autovec_preference to rvv_vector_bits.
19449 (vls_mode_valid_p): Ditto.
19450 (estimated_poly_value): Ditto.
19451 * config/riscv/riscv.cc (riscv_convert_vector_chunks): Rename to
19452 vector chunks and honor new option mrvv-vector-bits.
19453 (riscv_override_options_internal): Update comments and rename the
19455 * config/riscv/riscv.opt: Add option mrvv-vector-bits and remove
19456 internal option param=riscv-autovec-preference.
19458 2024-03-01 Jakub Jelinek <jakub@redhat.com>
19460 * function.cc (assign_parms): Only call assign_parms_setup_varargs
19461 early for TYPE_NO_NAMED_ARGS_STDARG_P functions if fnargs is empty.
19463 2024-03-01 Jakub Jelinek <jakub@redhat.com>
19465 PR middle-end/114156
19466 * gimple-lower-bitint.cc (bitint_large_huge::lower_stmt): Allow
19467 rhs1 of a VCE to have no underlying variable if it is a load and
19470 2024-02-29 David Malcolm <dmalcolm@redhat.com>
19473 * function.cc (function_name): Make param const.
19474 * function.h (function_name): Likewise.
19476 2024-02-29 Georg-Johann Lay <avr@gjlay.de>
19479 * doc/invoke.texi (AVR Options) <-mfuse-add>: Document.
19480 * config/avr/avr.opt (-mfuse-add=): New target option.
19481 * common/config/avr/avr-common.cc (avr_option_optimization_table)
19482 [OPT_LEVELS_1_PLUS]: Set -mfuse-add=1.
19483 [OPT_LEVELS_2_PLUS]: Set -mfuse-add=2.
19484 * config/avr/avr-passes.def (avr_pass_fuse_add): Insert new pass.
19485 * config/avr/avr-protos.h (avr_split_tiny_move)
19486 (make_avr_pass_fuse_add): New protos.
19487 * config/avr/avr.md [AVR_TINY]: New post-reload splitter uses
19488 avr_split_tiny_move to split indirect memory accesses.
19489 (gen_move_clobbercc): New define_expand helper.
19490 * config/avr/avr.cc (avr_pass_data_fuse_add): New pass data.
19491 (avr_pass_fuse_add): New class from rtl_opt_pass.
19492 (make_avr_pass_fuse_add, avr_split_tiny_move): New functions.
19493 (reg_seen_between_p, emit_move_ccc, emit_move_ccc_after): New functions.
19494 (avr_legitimate_address_p) [AVR_TINY]: Don't restrict offsets
19495 of PLUS addressing for AVR_TINY.
19496 (avr_regno_mode_code_ok_for_base_p) [AVR_TINY]: Ignore -mstrict-X.
19497 (avr_out_plus_1) [AVR_TINY]: Tweak ++Y and --Y.
19498 (avr_mode_code_base_reg_class) [AVR_TINY]: Always return POINTER_REGS.
19500 2024-02-29 Georg-Johann Lay <avr@gjlay.de>
19503 * config/avr/avr.h (CUMULATIVE_ARGS) <has_stack_args>: New field.
19504 * config/avr/avr.cc (avr_init_cumulative_args): Initialize it.
19505 (avr_function_arg): Set it.
19506 (avr_frame_pointer_required_p): Use it instead of .nregs.
19508 2024-02-29 Andrew Pinski <quic_apinski@quicinc.com>
19511 * config/aarch64/aarch64-builtins.cc (aarch64_memtag_builtin_data): Make
19512 static and mark with GTY.
19514 2024-02-29 Xi Ruoyao <xry111@xry111.site>
19516 * config/loongarch/loongarch.md
19517 (loongarch_<crc>_w_<size>_w_extended): New define_insn.
19519 2024-02-29 Xi Ruoyao <xry111@xry111.site>
19521 * config/loongarch/loongarch.md (CRC): New define_int_iterator.
19522 (crc): New define_int_attr.
19523 (loongarch_crc_w_<size>_w, loongarch_crcc_w_<size>_w): Unify
19525 (loongarch_<crc>_w_<size>_w): ... here.
19527 2024-02-29 Kito Cheng <kito.cheng@sifive.com>
19530 * config/riscv/sync.md (atomic_compare_and_swap<mode>): Sign
19531 extend the expected value if needed.
19533 2024-02-28 Cupertino Miranda <cupertino.miranda@oracle.com>
19535 * config.gcc (target_gtfiles): Change coreout to btfext-out.
19536 (extra_objs): Change coreout to btfext-out.
19537 * config/bpf/coreout.cc: Rename to btfext-out.cc.
19538 * config/bpf/btfext-out.cc: Add.
19539 * config/bpf/coreout.h: Rename to btfext-out.h.
19540 * config/bpf/btfext-out.h: Add.
19541 * config/bpf/core-builtins.cc: Change include.
19542 * config/bpf/core-builtins.h: Change include.
19543 * config/bpf/t-bpf: Accomodate renamed files.
19545 2024-02-28 Cupertino Miranda <cupertino.miranda@oracle.com>
19548 * config/bpf/bpf.cc (bpf_function_prologue): Define target
19550 * config/bpf/coreout.cc (brf_ext_info_section)
19551 (btf_ext_info): Move from coreout.h
19552 (btf_ext_funcinfo, btf_ext_lineinfo): Add struct.
19553 (bpf_core_reloc): Rename to btf_ext_core_reloc.
19554 (btf_ext): Add static variable.
19555 (btfext_info_sec_find_or_add, SEARCH_NODE_AND_RETURN)
19556 (bpf_create_or_find_funcinfo, bpt_create_core_reloc)
19557 (btf_ext_add_string, btf_funcinfo_type_callback)
19558 (btf_add_func_info_for, btf_validate_funcinfo)
19559 (btf_ext_info_len, output_btfext_func_info): Add function.
19560 (output_btfext_header, bpf_core_reloc_add)
19561 (output_btfext_core_relocs, btf_ext_init, btf_ext_output):
19562 Change to support new structs.
19563 * config/bpf/coreout.h (btf_ext_funcinfo, btf_ext_lineinfo):
19564 Move and change in coreout.cc.
19565 (btf_add_func_info_for, btf_ext_add_string): Add prototypes.
19567 2024-02-28 Cupertino Miranda <cupertino.miranda@oracle.com>
19569 * config/bpf/bpf.cc (bpf_option_override): Make .BTF.ext
19570 enabled by default for BPF.
19571 (bpf_file_end): Call BTF deallocation.
19572 (bpf_asm_init_sections): Correct condition.
19573 * dwarf2ctf.cc (ctf_debug_finalize): Conditionally execute BTF
19575 (ctf_debuf_finish): Correct condition for calling
19576 ctf_debug_finalize.
19578 2024-02-28 Cupertino Miranda <cupertino.miranda@oracle.com>
19580 * btfout.cc (output_btf_func_types): Use FOR_EACH_VEC_ELT.
19581 (traverse_btf_func_types): Define function.
19582 * ctfc.h (funcs_traverse_callback): Typedef for function
19584 (traverse_btf_func_types): Add prototype.
19586 2024-02-28 Cupertino Miranda <cupertino.miranda@oracle.com>
19588 * btfout.cc (btf_collect_dataset): Corrects BTF type id.
19590 2024-02-28 Richard Biener <rguenther@suse.de>
19592 PR tree-optimization/113831
19593 PR tree-optimization/108355
19594 * tree-ssa-sccvn.cc (copy_reference_ops_from_ref): Revert
19597 2024-02-28 Richard Biener <rguenther@suse.de>
19599 PR tree-optimization/114121
19600 * tree-ssa-sccvn.h (vn_reference_s::offset,
19601 vn_reference_s::max_size): New fields.
19602 (vn_reference_insert_pieces): Adjust prototype.
19603 * tree-ssa-pre.cc (phi_translate_1): Preserve offset/max_size.
19604 * tree-ssa-sccvn.cc (vn_reference_eq): Compare offset and
19605 size, allow using "don't know" state.
19606 (vn_walk_cb_data::finish): Pass along offset/max_size.
19607 (vn_reference_lookup_or_insert_for_pieces): Take offset and
19608 max_size as argument and use it.
19609 (vn_reference_lookup_3): Properly adjust offset and max_size
19610 according to the adjusted ao_ref.
19611 (vn_reference_lookup_pieces): Initialize offset and max_size.
19612 (vn_reference_lookup): Likewise.
19613 (vn_reference_lookup_call): Likewise.
19614 (vn_reference_insert): Likewise.
19615 (visit_reference_op_call): Likewise.
19616 (vn_reference_insert_pieces): Take offset and max_size
19617 as argument and use it.
19619 2024-02-28 Juergen Christ <jchrist@linux.ibm.com>
19621 PR tree-optimization/114075
19622 * tree-vect-stmts.cc (vectorizable_operation): Don't emulate floating
19625 2024-02-28 Jakub Jelinek <jakub@redhat.com>
19627 PR tree-optimization/114041
19628 * graphite-sese-to-poly.cc (add_conditions_to_domain): Check for
19629 INTEGRAL_TYPE_P check rather than INTEGER_TYPE.
19631 2024-02-28 Jakub Jelinek <jakub@redhat.com>
19633 PR tree-optimization/113988
19634 * stor-layout.h (bitwise_mode_for_size): Declare.
19635 * stor-layout.cc (bitwise_mode_for_size): New function.
19636 * gimple-fold.cc (gimple_fold_builtin_memory_op): Use it.
19637 Use bitwise_type_for_mode instead of build_nonstandard_integer_type.
19638 Use BITS_PER_UNIT instead of 8.
19640 2024-02-27 Uros Bizjak <ubizjak@gmail.com>
19643 * config/i386/mmx.md (V248FI): Add V2BF mode.
19646 2024-02-27 Eric Botcazou <ebotcazou@adacore.com>
19648 * tree-ssa-dse.cc (compute_trims): Fix description. Return early
19649 if either ref->offset is not byte aligned or ref->size is not known
19650 to be equal to ref->max_size.
19651 (maybe_trim_complex_store): Fix description.
19652 (maybe_trim_constructor_store): Likewise.
19653 (maybe_trim_partially_dead_store): Likewise.
19655 2024-02-27 Richard Earnshaw <rearnsha@arm.com>
19657 * config/arm/mmintrin.h: Warn if this header is included without
19658 defining __ENABLE_DEPRECATED_IWMMXT.
19660 2024-02-27 Richard Biener <rguenther@suse.de>
19662 PR tree-optimization/114074
19663 * tree-chrec.h (chrec_convert_rhs): Default at_stmt arg to NULL.
19664 * tree-chrec.cc (chrec_fold_multiply): Canonicalize inputs.
19665 Handle poly vs. non-poly multiplication correctly with respect
19666 to undefined behavior on overflow.
19668 2024-02-27 Jakub Jelinek <jakub@redhat.com>
19670 PR rtl-optimization/114044
19671 * internal-fn.def (CLRSB, CLZ, CTZ, FFS, PARITY): Use
19672 DEF_INTERNAL_INT_EXT_FN macro rather than DEF_INTERNAL_INT_FN.
19673 * internal-fn.h (expand_CLRSB, expand_CLZ, expand_CTZ, expand_FFS,
19674 expand_PARITY): Declare.
19675 * internal-fn.cc (expand_bitquery, expand_CLRSB, expand_CLZ,
19676 expand_CTZ, expand_FFS, expand_PARITY): New functions.
19677 (expand_POPCOUNT): Use expand_bitquery.
19679 2024-02-27 Richard Biener <rguenther@suse.de>
19681 PR tree-optimization/114081
19682 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
19683 Perform manual dominator update for prologue peeling.
19684 (vect_do_peeling): Properly update dominators after adding the
19685 prologue-around guard.
19687 2024-02-26 Georg-Johann Lay <avr@gjlay.de>
19689 * config/avr/avr.opt (mcall-prologues, mrelax, maccumulate-args)
19690 (mstrict-X): Tag as "Optimization".
19692 2024-02-26 Georg-Johann Lay <avr@gjlay.de>
19694 * config/avr/avr.cc (avr_out_compare) [AVR_TINY]: Remove code in
19695 an "if avr_adiw_reg_p()" block that's dead for AVR_TINY.
19697 2024-02-26 Jakub Jelinek <jakub@redhat.com>
19698 H.J. Lu <hjl.tools@gmail.com>
19700 PR rtl-optimization/113617
19701 * varasm.cc (default_elf_select_rtx_section): For
19702 references to private symbols in comdat sections
19703 use .data.relro.local.pool.<comdat>, .data.relro.pool.<comdat>
19704 or .rodata.<comdat> comdat sections.
19706 2024-02-26 Richard Biener <rguenther@suse.de>
19708 PR tree-optimization/114099
19709 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
19710 Create and fill in a needed virtual LC PHI for the alternate
19711 exits. Remove code dealing with that missing.
19713 2024-02-26 Richard Biener <rguenther@suse.de>
19715 PR tree-optimization/114068
19716 * tree-vect-loop-manip.cc (get_live_virtual_operand_on_edge):
19718 (slpeel_tree_duplicate_loop_to_edge_cfg): Add a virtual LC PHI
19719 on the main exit if needed. Remove band-aid for the case
19722 2024-02-26 H.J. Lu <hjl.tools@gmail.com>
19725 * config/i386/i386-options.cc (ix86_set_func_type): Check
19726 interrupt instead of noreturn attribute.
19728 2024-02-26 Jakub Jelinek <jakub@redhat.com>
19730 * config/i386/i386.cc (ix86_bitint_type_info): Add support for
19733 2024-02-26 Jakub Jelinek <jakub@redhat.com>
19735 PR tree-optimization/114090
19736 * match.pd ((x >= 0 ? x : 0) + (x <= 0 ? -x : 0) -> abs x):
19737 Restrict pattern to ANY_INTEGRAL_TYPE_P and TYPE_OVERFLOW_UNDEFINED
19739 ((x <= 0 ? -x : 0) -> max(-x, 0)): Likewise.
19741 2024-02-26 Jakub Jelinek <jakub@redhat.com>
19743 PR middle-end/114084
19744 * fold-const.cc (fold_binary_loc): Avoid the final associate_trees
19745 if all subtrees of var0 come from one of the op0 or op1 operands
19746 and all subtrees of con0 come from the other one. Don't clear
19747 variables which are never used afterwards.
19749 2024-02-26 Richard Biener <rguenther@suse.de>
19751 PR middle-end/114070
19752 * genmatch.cc (parser::parse_c_expr): Do not record operand
19753 lists but only mark operators used.
19754 * match.pd ((c ? a : b) op (c ? d : e) --> c ? (a op d) : (b op e)):
19755 Properly guard the case of tcc_comparison changing the VEC_COND
19756 value operand type.
19758 2024-02-26 Jakub Jelinek <jakub@redhat.com>
19761 * config/i386/i386.cc (x86_function_profiler): Add missing new-line
19762 to printed instruction.
19764 2024-02-26 H.J. Lu <hjl.tools@gmail.com>
19767 * config/i386/amxtileintrin.h (_tile_loadconfig): Use
19768 __builtin_ia32_ldtilecfg.
19769 (_tile_storeconfig): Use __builtin_ia32_sttilecfg.
19770 * config/i386/i386-builtin.def (BDESC): Add
19771 __builtin_ia32_ldtilecfg and __builtin_ia32_sttilecfg.
19772 * config/i386/i386-expand.cc (ix86_expand_builtin): Handle
19773 IX86_BUILTIN_LDTILECFG and IX86_BUILTIN_STTILECFG.
19774 * config/i386/i386.md (ldtilecfg): New pattern.
19775 (sttilecfg): Likewise.
19777 2024-02-24 Richard Sandiford <richard.sandiford@arm.com>
19779 PR tree-optimization/113205
19780 * tree-vect-slp.cc (vect_optimize_slp_pass::forward_cost): Reject
19781 the proposed layout if it does not allow a source partition with
19782 layout 2 to keep that layout.
19784 2024-02-24 Jakub Jelinek <jakub@redhat.com>
19786 * builtins.cc (fold_builtin_isascii): Use HOST_WIDE_INT_UC macro.
19787 * combine.cc (make_field_assignment): Use HOST_WIDE_INT_1U macro.
19788 * double-int.cc (double_int::mask): Use HOST_WIDE_INT_UC macros.
19789 * genattrtab.cc (attr_alt_complement): Use HOST_WIDE_INT_1 macro.
19790 (mk_attr_alt): Use HOST_WIDE_INT_0 macro.
19791 * genautomata.cc (bitmap_set_bit, CLEAR_BIT): Use HOST_WIDE_INT_1
19793 * ipa-strub.cc (can_strub_internally_p): Use HOST_WIDE_INT_1 macro.
19794 * loop-iv.cc (implies_p): Use HOST_WIDE_INT_1U macro.
19795 * pretty-print.cc (test_pp_format): Use HOST_WIDE_INT_C and
19796 HOST_WIDE_INT_UC macros.
19797 * rtlanal.cc (nonzero_bits1): Use HOST_WIDE_INT_UC macro.
19798 * tree.cc (build_replicated_int_cst): Use HOST_WIDE_INT_1U macro.
19799 * tree.h (DECL_OFFSET_ALIGN): Use HOST_WIDE_INT_1U macro.
19800 * tree-ssa-structalias.cc (dump_varinfo): Use ~HOST_WIDE_INT_0U
19802 * wide-int.cc (divmod_internal_2): Use HOST_WIDE_INT_1U macro.
19803 * config/i386/constraints.md (define_constraint "L"): Use
19804 HOST_WIDE_INT_C macro.
19805 * config/i386/i386.md (movabsq split peephole2): Use HOST_WIDE_INT_C
19807 (movl + movb peephole2): Likewise.
19808 * config/i386/predicates.md (x86_64_zext_immediate_operand): Likewise.
19809 (const_32bit_mask): Likewise.
19811 2024-02-24 Jakub Jelinek <jakub@redhat.com>
19813 PR middle-end/114073
19814 * gimple-lower-bitint.cc (bitint_large_huge::lower_stmt): Handle
19815 VIEW_CONVERT_EXPRs between large/huge _BitInt and non-integer/pointer
19816 types like vector or complex types.
19817 (gimple_lower_bitint): Don't merge VIEW_CONVERT_EXPRs to non-integral
19818 types. Fix up VIEW_CONVERT_EXPR handling. Allow merging
19819 VIEW_CONVERT_EXPR from non-integral/pointer types with a store.
19821 2024-02-23 Robin Dapp <rdapp@ventanamicro.com>
19824 * config/riscv/riscv-v.cc (rvv_builder::can_duplicate_repeating_sequence_p):
19825 Return false if inner mode is already Pmode.
19826 (rvv_builder::is_all_same_sequence): New function.
19827 (expand_vec_init): Emit broadcast if sequence is all same.
19829 2024-02-23 Richard Sandiford <richard.sandiford@arm.com>
19832 * config/aarch64/aarch64-early-ra.cc
19833 (early_ra::m_current_region): New member variable.
19834 (early_ra::m_fpr_recency): Likewise.
19835 (early_ra::start_new_region): Bump m_current_region.
19836 (early_ra::allocate_colors): Prefer less recently used registers
19837 in the event of a tie. Add a comment to explain why we prefer(ed)
19838 higher-numbered registers.
19839 (early_ra::find_oldest_color): Prefer less recently used registers
19841 (early_ra::finalize_allocation): Update recency information for
19842 allocated registers.
19843 (early_ra::process_blocks): Initialize m_current_region and
19846 2024-02-23 Richard Sandiford <richard.sandiford@arm.com>
19849 * config/aarch64/aarch64-early-ra.cc
19850 (early_ra::test_strictness): New enum.
19851 (early_ra::is_chain_candidate): Add a strictness parameter to
19852 control whether only correctness matters, or whether both correctness
19853 and heuristics should be used. Handle multiple levels of equivalence.
19854 (early_ra::find_related_start): Update call accordingly.
19855 (early_ra::strided_polarity_pref): Likewise.
19856 (early_ra::form_chains): Likewise.
19857 (early_ra::try_to_chain_allocnos): Use is_chain_candidate in
19858 correctness mode rather than trying to inline the test.
19860 2024-02-23 Richard Sandiford <richard.sandiford@arm.com>
19863 * config/aarch64/aarch64-early-ra.cc
19864 (early_ra::find_related_start): Account for definitions by shared
19865 registers when testing for a single register definition.
19866 (early_ra::accumulate_defs): New function.
19867 (early_ra::record_copy): If A shares B's register, fold A's
19868 definition information into B's. Fold A's use information into B's.
19870 2024-02-23 H.J. Lu <hjl.tools@gmail.com>
19872 * configure.ac (HAVE_AS_R_X86_64_CODE_6_GOTTPOFF): Defined as 1
19873 if R_X86_64_CODE_6_GOTTPOFF is supported.
19874 * config.in: Regenerated.
19875 * configure: Likewise.
19876 * config/i386/predicates.md (apx_ndd_add_memory_operand): Allow
19877 UNSPEC_GOTNTPOFF if R_X86_64_CODE_6_GOTTPOFF is supported.
19879 2024-02-23 Richard Earnshaw <rearnsha@arm.com>
19882 * config/arm/neon.md (div<VCVTF:mode>3): Rename from div<mode>3.
19883 Gate with ARM_HAVE_NEON_<MODE>_ARITH.
19885 2024-02-23 Jakub Jelinek <jakub@redhat.com>
19887 PR rtl-optimization/114054
19888 * expr.cc (expand_expr_real_2) <case MULT_EXPR>: Use
19889 temp variable instead of target parameter for result.
19891 2024-02-23 Jakub Jelinek <jakub@redhat.com>
19893 PR tree-optimization/114040
19894 * gimple-lower-bitint.cc (bitint_large_huge::lower_addsub_overflow):
19895 Use EQ_EXPR rather than LT_EXPR for g2 condition and change its
19896 probability from likely to unlikely. When handling the true true
19897 store, first cast to limb_access_type and then to l's type.
19899 2024-02-23 Richard Biener <rguenther@suse.de>
19902 * config.gcc: Add ia64*-*-* to the list of obsoleted targets.
19904 2024-02-23 Palmer Dabbelt <palmer@rivosinc.com>
19907 * config/riscv/arch-canonicalize: Move to python3
19908 * config/riscv/multilib-generator: Likewise
19910 2024-02-23 Palmer Dabbelt <palmer@rivosinc.com>
19912 * doc/invoke.texi: Document -mcpu.
19914 2024-02-23 Lulu Cheng <chenglulu@loongson.cn>
19916 * configure: Regenerate.
19917 * configure.ac: Add parameter "--fatal-warnings" to assemble
19918 when checking whether the assemble support conditional branch
19921 2024-02-22 Jakub Jelinek <jakub@redhat.com>
19924 * doc/extend.texi: (__extension__): Remove comments about scope
19925 tokens vs. two colons.
19927 2024-02-22 Andrew Pinski <quic_apinski@quicinc.com>
19929 PR tree-optimization/109804
19930 * gimple-ssa-warn-access.cc (new_delete_mismatch_p): Handle
19931 DEMANGLE_COMPONENT_UNNAMED_TYPE.
19933 2024-02-22 Richard Biener <rguenther@suse.de>
19935 PR tree-optimization/114048
19936 * tree-ssa-sccvn.cc (copy_reference_ops_from_ref): MEM_REF
19937 can also produce -1 off.
19939 2024-02-22 Richard Biener <rguenther@suse.de>
19941 PR tree-optimization/114027
19942 * tree-vect-loop.cc (vecctorizable_reduction): Use optimized
19943 condition reduction classification only for single-element
19946 2024-02-22 Jakub Jelinek <jakub@redhat.com>
19949 * profile-count.h (profile_count::dump): Remove overload with
19950 char * first argument.
19951 * profile-count.cc (profile_count::dump): Change overload with char *
19952 first argument which uses sprintf into the overfload with FILE *
19953 first argument and use fprintf instead. Remove overload which wrapped
19956 2024-02-22 Jakub Jelinek <jakub@redhat.com>
19958 PR tree-optimization/113993
19959 * tree-call-cdce.cc (get_no_error_domain): Handle
19960 BUILT_IN_{COSH,SINH,EXP{,M1,2}}{F32X,F64X}. Handle
19961 BUILT_IN_{COSH,SINH,EXP{,M1,2}}L for
19962 REAL_MODE_FORMAT (TYPE_MODE (long_double_type_node))->emax == 16384
19963 the as the F128 suffixed cases, otherwise as non-suffixed ones.
19964 Handle BUILT_IN_{EXP,POW}10L for
19965 REAL_MODE_FORMAT (TYPE_MODE (long_double_type_node))->emax == 16384
19968 2024-02-22 Jakub Jelinek <jakub@redhat.com>
19970 PR tree-optimization/114038
19971 * gimple-lower-bitint.cc (bitint_large_huge::lower_mul_overflow): Fix
19972 loop exit condition if end is divisible by limb_prec.
19974 2024-02-22 YunQiang Su <syq@gcc.gnu.org>
19976 * doc/invoke.texi(MIPS Options): Fix skipping UrlSuffix
19977 problem of mabi=, mno-flush-func, mexplicit-relocs;
19978 add missing leading - of mbranch-cost option.
19979 * config/mips/mips.opt.urls: Regenerate.
19981 2024-02-22 Kewen Lin <linkw@linux.ibm.com>
19984 * config/rs6000/constraints.md (we): Update internal doc without
19985 referring to option -mpower9-vector.
19986 * config/rs6000/driver-rs6000.cc (asm_names): Remove mpower9-vector
19988 * config/rs6000/rs6000-cpus.def (OTHER_P9_VECTOR_MASKS,
19989 OTHER_P8_VECTOR_MASKS): Merge to ...
19990 (OTHER_VSX_VECTOR_MASKS): ... here.
19991 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Remove
19992 some error message handlings and explicit option mask adjustments on
19993 explicit option power{8,9}-vector conflicting with other options.
19994 (rs6000_print_isa_options): Update comments.
19995 (rs6000_disable_incompatible_switches): Remove power{8,9}-vector
19996 related array items and handlings.
19997 * config/rs6000/rs6000.h (ASM_CPU_SPEC): Remove mpower9-vector
19999 * config/rs6000/rs6000.opt: Make option power{8,9}-vector as
20001 * doc/extend.texi: Remove documentation referring to option
20003 * doc/invoke.texi: Remove documentation for option
20004 -mpower{8,9}-vector and adjust some documentation referring to them.
20005 * doc/md.texi: Update documentation for constraint we.
20006 * doc/sourcebuild.texi: Remove documentation for powerpc_p8vector_ok.
20008 2024-02-22 Pan Li <pan2.li@intel.com>
20011 * config/riscv/riscv-c.cc (riscv_cpu_cpp_builtins): Upgrade
20012 the version to 0.12.
20014 2024-02-21 Edwin Lu <ewlu@rivosinc.com>
20016 * config/riscv/riscv.cc (riscv_sched_variable_issue): Enable assert
20018 2024-02-21 Edwin Lu <ewlu@rivosinc.com>
20019 Robin Dapp <rdapp.gcc@gmail.com>
20021 * config/riscv/generic-ooo.md (generic_ooo): Move reservation
20022 (generic_ooo_vec_load): Ditto
20023 (generic_ooo_vec_store): Ditto
20024 (generic_ooo_vec_loadstore_seg): Ditto
20025 (generic_ooo_vec_alu): Ditto
20026 (generic_ooo_vec_fcmp): Ditto
20027 (generic_ooo_vec_imul): Ditto
20028 (generic_ooo_vec_fadd): Ditto
20029 (generic_ooo_vec_fmul): Ditto
20030 (generic_ooo_crypto): Ditto
20031 (generic_ooo_perm): Ditto
20032 (generic_ooo_vec_reduction): Ditto
20033 (generic_ooo_vec_ordered_reduction): Ditto
20034 (generic_ooo_vec_idiv): Ditto
20035 (generic_ooo_vec_float_divsqrt): Ditto
20036 (generic_ooo_vec_mask): Ditto
20037 (generic_ooo_vec_vesetvl): Ditto
20038 (generic_ooo_vec_setrm): Ditto
20039 (generic_ooo_vec_readlen): Ditto
20040 * config/riscv/riscv.md: Include generic-vector-ooo
20041 * config/riscv/generic-vector-ooo.md: New file. To here
20043 2024-02-21 Edwin Lu <ewlu@rivosinc.com>
20045 * config/riscv/generic-ooo.md (generic_ooo_sfb_alu): Add reservation
20046 (generic_ooo_branch): Ditto
20047 * config/riscv/generic.md (generic_sfb_alu): Ditto
20048 (generic_fmul_half): Ditto
20049 * config/riscv/riscv.md: Remove cbo, pushpop, and rdfrm types
20050 * config/riscv/sifive-7.md (sifive_7_hfma): Add reservation
20051 (sifive_7_popcount): Ditto
20052 * config/riscv/sifive-p400.md (sifive_p400_clmul): Ditto
20053 * config/riscv/sifive-p600.md (sifive_p600_clmul): Ditto
20054 * config/riscv/vector.md: Change rdfrm to fmove
20055 * config/riscv/zc.md: Change pushpop to load/store
20057 2024-02-21 Jonathan Wakely <jwakely@redhat.com>
20059 * doc/invoke.texi (Warning Options): Fix typos.
20061 2024-02-21 David Faust <david.faust@oracle.com>
20063 * config/bpf/bpf-protos.h (bpf_expand_cpymem): New.
20064 * config/bpf/bpf.cc: (emit_move_loop, bpf_expand_cpymem): New.
20065 * config/bpf/bpf.md: (cpymemdi, movmemdi): New define_expands.
20067 2024-02-21 Martin Jambor <mjambor@suse.cz>
20070 * ipa-prop.h (ipa_node_params): Convert lattices to a vector, adjust
20071 initializers in the contructor.
20072 (ipa_node_params::~ipa_node_params): Release lattices as a vector.
20073 * ipa-cp.h: New file.
20074 * ipa-cp.cc: Include sreal.h and ipa-cp.h.
20075 (ipcp_value_source): Move to ipa-cp.h.
20076 (ipcp_value_base): Likewise.
20077 (ipcp_value): Likewise.
20078 (ipcp_lattice): Likewise.
20079 (ipcp_agg_lattice): Likewise.
20080 (ipcp_bits_lattice): Likewise.
20081 (ipcp_vr_lattice): Likewise.
20082 (ipcp_param_lattices): Likewise.
20083 (ipa_get_parm_lattices): Remove assert latticess is non-NULL.
20084 (ipa_value_from_jfunc): Adjust a check for empty lattices.
20085 (ipa_context_from_jfunc): Likewise.
20086 (ipa_agg_value_from_jfunc): Likewise.
20087 (merge_agg_lats_step): Do not memset new aggregate lattices to zero.
20088 (ipcp_propagate_stage): Allocate lattices in a vector as opposed to
20089 just in contiguous memory.
20090 (ipcp_store_vr_results): Adjust a check for empty lattices.
20091 * auto-profile.cc: Include sreal.h and ipa-cp.h.
20092 * cgraph.cc: Likewise.
20093 * cgraphclones.cc: Likewise.
20094 * cgraphunit.cc: Likewise.
20095 * config/aarch64/aarch64.cc: Likewise.
20096 * config/i386/i386-builtins.cc: Likewise.
20097 * config/i386/i386-expand.cc: Likewise.
20098 * config/i386/i386-features.cc: Likewise.
20099 * config/i386/i386-options.cc: Likewise.
20100 * config/i386/i386.cc: Likewise.
20101 * config/rs6000/rs6000.cc: Likewise.
20102 * config/s390/s390.cc: Likewise.
20103 * gengtype.cc (open_base_files): Added sreal.h and ipa-cp.h to the
20104 files to be included in gtype-desc.cc.
20105 * gimple-range-fold.cc: Include sreal.h and ipa-cp.h.
20106 * ipa-devirt.cc: Likewise.
20107 * ipa-fnsummary.cc: Likewise.
20108 * ipa-icf.cc: Likewise.
20109 * ipa-inline-analysis.cc: Likewise.
20110 * ipa-inline-transform.cc: Likewise.
20111 * ipa-inline.cc: Include ipa-cp.h, move inclusion of sreal.h higher.
20112 * ipa-modref.cc: Include sreal.h and ipa-cp.h.
20113 * ipa-param-manipulation.cc: Likewise.
20114 * ipa-predicate.cc: Likewise.
20115 * ipa-profile.cc: Likewise.
20116 * ipa-prop.cc: Likewise.
20117 (ipa_node_params_t::duplicate): Assert new lattices remain empty
20118 instead of setting them to NULL.
20119 * ipa-pure-const.cc: Include sreal.h and ipa-cp.h.
20120 * ipa-split.cc: Likewise.
20121 * ipa-sra.cc: Likewise.
20122 * ipa-strub.cc: Likewise.
20123 * ipa-utils.cc: Likewise.
20124 * ipa.cc: Likewise.
20125 * toplev.cc: Likewise.
20126 * tree-ssa-ccp.cc: Likewise.
20127 * tree-ssa-sccvn.cc: Likewise.
20128 * tree-vrp.cc: Likewise.
20130 2024-02-21 Tamar Christina <tamar.christina@arm.com>
20132 * config/aarch64/aarch64-arches.def (AARCH64_ARCH): Remove LS64 from
20135 2024-02-21 Richard Sandiford <richard.sandiford@arm.com>
20137 * config/aarch64/aarch64.cc (aarch64_mode_emit_local_sme_state):
20138 Use aarch64_gen_compare_zero_and_branch rather than emitting
20141 2024-02-21 Richard Sandiford <richard.sandiford@arm.com>
20143 * config/aarch64/aarch64.cc (aarch64_option_valid_attribute_p):
20144 Remove duplicated call.
20146 2024-02-21 Richard Sandiford <richard.sandiford@arm.com>
20148 * config/aarch64/aarch64.cc (aarch64_function_ok_for_sibcall):
20149 Check that each individual piece of state is shared in the same
20150 way, rather than using an aggregate check for PSTATE.ZA.
20152 2024-02-21 Richard Sandiford <richard.sandiford@arm.com>
20154 * config/aarch64/aarch64.cc (aarch64_mode_emit_local_sme_state):
20155 In the code that commits a lazy save, only zero ZA if the function
20156 has ZA state. Similarly zero ZT0 if the function has ZT0 state.
20158 2024-02-21 Richard Sandiford <richard.sandiford@arm.com>
20160 * config/aarch64/aarch64-sme.md (aarch64_commit_lazy_save): Remove,
20161 directly inserting the associated sequence
20162 * config/aarch64/aarch64.cc (aarch64_mode_emit_local_sme_state):
20165 2024-02-21 Richard Sandiford <richard.sandiford@arm.com>
20168 * config/aarch64/aarch64.cc (aarch64_expand_prologue): Don't
20169 fold the SVE allocation into the initial allocation if the
20170 initial allocation includes a VG save.
20172 2024-02-21 Richard Sandiford <richard.sandiford@arm.com>
20175 * cfgrtl.cc (commit_one_edge_insertion): Handle sequences that
20176 contain jumps even if called after initial RTL expansion.
20177 * mode-switching.cc: Include cfgbuild.h.
20178 (optimize_mode_switching): Allow the sequence returned by the
20179 emit hook to contain internal jumps. Record which blocks
20180 contain such jumps and split the blocks at the end.
20181 * config/aarch64/aarch64.cc (aarch64_mode_emit): Check for
20182 non-debug insns when scanning the sequence.
20184 2024-02-21 Tobias Burnus <tburnus@baylibre.com>
20186 * config/nvptx/gen-omp-device-properties.sh: Add 'nvptx64' to arch.
20187 * config/nvptx/nvptx.cc (nvptx_omp_device_kind_arch_isa): Likewise.
20189 2024-02-21 Dimitar Dimitrov <dimitar@dinux.eu>
20191 * doc/invoke.texi (-mmcu): Add information about MCU specs.
20193 2024-02-21 Dimitar Dimitrov <dimitar@dinux.eu>
20195 * doc/invoke.texi (-minrt): Clarify that main
20196 must take no arguments.
20198 2024-02-20 Georg-Johann Lay <avr@gjlay.de>
20200 * config/avr/builtins.def: Use function prototypes of given size
20202 * config/avr/avr.cc (avr_init_builtins): Adjust types required
20204 * doc/extend.texi (AVR Built-in Functions): Adjust accordingly.
20206 2024-02-20 Georg-Johann Lay <avr@gjlay.de>
20208 * doc/extend.texi (AVR Built-in Functions): Use @defbuiltin
20211 2024-02-20 Will Hawkins <hawkinsw@obs.cr>
20213 * config/bpf/bpf.opt: Add help information for -mcpu.
20215 2024-02-20 Richard Sandiford <richard.sandiford@arm.com>
20218 * config/aarch64/aarch64-passes.def (pass_late_track_speculation):
20220 * config/aarch64/aarch64-protos.h (make_pass_late_track_speculation):
20222 * config/aarch64/aarch64.md (is_call): New attribute.
20223 (*and<mode>3nr_compare0): Rename to...
20224 (@aarch64_and<mode>3nr_compare0): ...this.
20225 * config/aarch64/aarch64-sme.md (aarch64_get_sme_state)
20226 (aarch64_tpidr2_save, aarch64_tpidr2_restore): Add is_call attributes.
20227 * config/aarch64/aarch64-speculation.cc: Update file comment to
20228 describe the new late pass.
20229 (aarch64_do_track_speculation): Handle is_call insns like other calls.
20230 (pass_track_speculation): Add an is_late member variable.
20231 (pass_track_speculation::gate): Run the late pass for streaming-
20232 compatible functions and the early pass for other functions.
20233 (make_pass_track_speculation): Update accordingly.
20234 (make_pass_late_track_speculation): New function.
20235 * config/aarch64/aarch64.cc (aarch64_gen_test_and_branch): New
20237 (aarch64_guard_switch_pstate_sm): Use it.
20239 2024-02-19 Iain Sandoe <iain@sandoe.co.uk>
20241 * config/aarch64/aarch64-builtins.cc (aarch64_init_rng_builtins):
20242 Register these builtins with a pointer to uint64_t rather than unsigned
20245 2024-02-19 Thomas Schwinge <tschwinge@baylibre.com>
20248 * config/gcn/gcn-valu.md (define_expand "reduc_<fexpander>_scal_<mode>"):
20249 Conditionalize on '!TARGET_RDNA2_PLUS'.
20250 * config/gcn/gcn.cc (gcn_expand_dpp_shr_insn)
20251 (gcn_expand_reduc_scalar):
20252 'gcc_checking_assert (!TARGET_RDNA2_PLUS);'.
20254 2024-02-19 Thomas Schwinge <tschwinge@baylibre.com>
20256 * config/gcn/gcn.h (TARGET_CPU_CPP_BUILTINS): Restore lost
20257 '__gfx90a__' target CPU definition. Add some safeguards for the future.
20259 2024-02-19 Richard Biener <rguenther@suse.de>
20261 PR rtl-optimization/54052
20262 * rtl-ssa/blocks.cc (function_info::place_phis): Filter
20263 local defs by LR_OUT.
20265 2024-02-19 Jakub Jelinek <jakub@redhat.com>
20267 PR tree-optimization/113967
20268 * match.pd (bit_insert @0 (BIT_FIELD_REF @1 ..) ..): Require
20269 in condition that @rpos is multiple of vector element size.
20271 2024-02-19 Juzhe-Zhong <juzhe.zhong@rivai.ai>
20274 * config/riscv/riscv-vsetvl.cc (pre_vsetvl::earliest_fuse_vsetvl_info):
20275 Suppress vsetvl fusion.
20277 2024-02-18 H.J. Lu <hjl.tools@gmail.com>
20280 * config/i386/i386.cc (ix86_can_use_push2pop2): New.
20281 (ix86_pro_and_epilogue_can_use_push2pop2): Use it.
20282 (ix86_emit_save_regs): Don't generate push2 if
20283 ix86_can_use_push2pop2 return false.
20284 (ix86_expand_epilogue): Don't generate pop2 if
20285 ix86_can_use_push2pop2 return false.
20287 2024-02-18 Georg-Johann Lay <avr@gjlay.de>
20289 * doc/invoke.texi (AVR Options) <-mmcu>: Remove "Atmel".
20290 Note on complete device support.
20292 2024-02-18 Georg-Johann Lay <avr@gjlay.de>
20294 * doc/extend.texi (AVR Function Attributes): Fuse description
20295 of "signal" and "interrupt" attribute. Link pseudo instruction.
20297 2024-02-18 Lulu Cheng <chenglulu@loongson.cn>
20299 * config/loongarch/larchintrin.h (__movgr2fcsr): Remove redundant
20300 symbol type conversions.
20301 (__cacop_d): Likewise.
20302 (__cpucfg): Likewise.
20303 (__asrtle_d): Likewise.
20304 (__asrtgt_d): Likewise.
20305 (__lddir_d): Likewise.
20306 (__ldpte_d): Likewise.
20307 (__crc_w_b_w): Likewise.
20308 (__crc_w_h_w): Likewise.
20309 (__crc_w_w_w): Likewise.
20310 (__crc_w_d_w): Likewise.
20311 (__crcc_w_b_w): Likewise.
20312 (__crcc_w_h_w): Likewise.
20313 (__crcc_w_w_w): Likewise.
20314 (__crcc_w_d_w): Likewise.
20315 (__csrrd_w): Likewise.
20316 (__csrwr_w): Likewise.
20317 (__csrxchg_w): Likewise.
20318 (__csrrd_d): Likewise.
20319 (__csrwr_d): Likewise.
20320 (__csrxchg_d): Likewise.
20321 (__iocsrrd_b): Likewise.
20322 (__iocsrrd_h): Likewise.
20323 (__iocsrrd_w): Likewise.
20324 (__iocsrrd_d): Likewise.
20325 (__iocsrwr_b): Likewise.
20326 (__iocsrwr_h): Likewise.
20327 (__iocsrwr_w): Likewise.
20328 (__iocsrwr_d): Likewise.
20329 (__frecipe_s): Likewise.
20330 (__frecipe_d): Likewise.
20331 (__frsqrte_s): Likewise.
20332 (__frsqrte_d): Likewise.
20334 2024-02-18 Lulu Cheng <chenglulu@loongson.cn>
20336 * config/loongarch/larchintrin.h (__iocsrrd_h): Modify the
20337 function return value type to unsigned short.
20339 2024-02-16 Edwin Lu <ewlu@rivosinc.com>
20341 * doc/sourcebuild.texi: add scan-assembler-bound
20343 2024-02-16 Jason Merrill <jason@redhat.com>
20345 * gdbhooks.py: Fix regex syntax.
20347 2024-02-16 Richard Biener <rguenther@suse.de>
20349 PR tree-optimization/113895
20350 * tree-ssa-sccvn.cc (copy_reference_ops_from_ref): Disable
20351 consistency checking when there are out-of-bound array
20352 accesses. Allow -1 off when from an array reference with
20355 2024-02-16 Kito Cheng <kito.cheng@sifive.com>
20358 * config/riscv/riscv.md (*sge<u>_<X:mode><GPR:mode>): Fix asm
20361 2024-02-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
20363 * doc/sourcebuild.texi (Effective-Target Keywords, Other
20364 attribugs): Document linker_plugin.
20365 (Require Support): Document dg-require-linker-plugin.
20367 2024-02-16 Kito Cheng <kito.cheng@sifive.com>
20370 * common/config/riscv/riscv-common.cc (riscv_arch_help): New.
20371 * config/riscv/riscv-protos.h (RISCV_MAJOR_VERSION_BASE): New.
20372 (RISCV_MINOR_VERSION_BASE): Ditto.
20373 (RISCV_REVISION_VERSION_BASE): Ditto.
20374 * config/riscv/riscv-c.cc (riscv_ext_version_value): Use enum
20375 rather than magic number.
20376 * config/riscv/riscv.h (riscv_arch_help): New.
20377 (EXTRA_SPEC_FUNCTIONS): Add riscv_arch_help.
20378 (DRIVER_SELF_SPECS): Handle -march=help, -print-supported-extensions and
20379 --print-supported-extensions.
20380 * config/riscv/riscv.opt (march=help): New.
20381 (print-supported-extensions): New.
20382 (-print-supported-extensions): New.
20383 * doc/invoke.texi (RISC-V Options): Document -march=help.
20385 2024-02-16 Tejas Belagod <tejas.belagod@arm.com>
20388 * config/arm/arm.cc (arm_function_ok_for_sibcall): Don't allow tailcalls
20389 for indirect calls with 4 or more arguments in pac-enabled functions.
20391 2024-02-15 David Faust <david.faust@oracle.com>
20393 * config/bpf/bpf.md (zero_extendqidi2): Correct asm template to
20394 use ldxb instead of ldxh.
20396 2024-02-15 Jakub Jelinek <jakub@redhat.com>
20398 PR middle-end/113921
20399 * cfgrtl.h (prepend_insn_to_edge): New declaration.
20400 * cfgrtl.cc (insert_insn_on_edge): Clarify behavior in function
20402 (prepend_insn_to_edge): New function.
20403 * cfgexpand.cc (expand_asm_stmt): Use prepend_insn_to_edge instead of
20404 insert_insn_on_edge.
20406 2024-02-15 Richard Biener <rguenther@suse.de>
20408 PR tree-optimization/111156
20409 * tree-vect-loop.cc (vect_dissolve_slp_only_groups): Look
20410 at the pattern stmt if any.
20412 2024-02-15 Georg-Johann Lay <avr@gjlay.de>
20415 * config/avr/avr.h (AVR_HAVE_ADIW): New macro.
20416 * config/avr/avr-protos.h (avr_adiw_reg_p): New proto.
20417 * config/avr/avr.cc (avr_adiw_reg_p): New function.
20418 (avr_conditional_register_usage) [AVR_TINY]: Don't clear ADDW_REGS.
20419 Replace test_hard_reg_class (ADDW_REGS, ...) with calls to
20420 * config/avr/avr.md: Same.
20421 (attr "isa") <tiny, no_tiny>: Remove.
20422 <adiw, no_adiw>: Add.
20423 (define_insn, define_insn_and_split): When an alternative has
20424 constraint "w", then set attribute "isa" to "adiw".
20425 * config/avr/avr-c.cc (avr_cpu_cpp_builtins) [AVR_HAVE_ADIW]:
20426 Built-in define __AVR_HAVE_ADIW__.
20427 * doc/invoke.texi (AVR Options): Document it.
20429 2024-02-15 Andrew Stubbs <ams@baylibre.com>
20431 * config/gcn/gcn-valu.md
20432 (vec_extract<V_MOV:mode><V_MOV_ALT:mode>): Add conditions for RDNA.
20433 * config/gcn/gcn.cc (gcn_vectorize_vec_perm_const): Check permutation
20434 details are supported on RDNA devices.
20436 2024-02-15 Andrew Pinski <quic_apinski@quicinc.com>
20438 PR middle-end/113508
20439 * doc/md.texi (sdot_prod@var{m}, udot_prod@var{m},
20440 usdot_prod@var{m}, ssad@var{m}, usad@var{m}, widen_usum@var{m}3,
20441 smulhs@var{m}3, umulhs@var{m}3, smulhrs@var{m}3, umulhrs@var{m}3):
20442 Add sentence about what the mode m is.
20444 2024-02-15 Andrew Pinski <quic_apinski@quicinc.com>
20446 * doc/md.texi (widen_ssum, widen_usum, smulhs, umulhs,
20447 smulhrs, umulhrs, sdiv_pow2): Move the 3 outside of the
20450 2024-02-15 Richard Biener <rguenther@suse.de>
20452 * tree-ssa-tail-merge.cc (same_succ_hash): Skip debug
20455 2024-02-15 Jakub Jelinek <jakub@redhat.com>
20457 PR tree-optimization/113567
20458 * gimple-lower-bitint.cc (gimple_lower_bitint): For large/huge
20459 _BitInt multiplication, division or modulo with
20460 SSA_NAME_OCCURS_IN_ABNORMAL_PHI lhs and at least one of rhs1 and rhs2
20461 force the affected inputs into a new SSA_NAME.
20463 2024-02-14 Uros Bizjak <ubizjak@gmail.com>
20466 * config/i386/mmx.md (V248FI): New mode iterator.
20468 (vec_shl_<V248FI:mode>): New expander.
20469 (vec_shl_<V24FI_32:mode>): Ditto.
20470 (vec_shr_<V248FI:mode>): Ditto.
20471 (vec_shr_<V24FI_32:mode>): Ditto.
20472 * config/i386/sse.md (vec_shl_<V_128:mode>): Simplify expander.
20473 (vec_shr_<V248FI:mode>): Ditto.
20475 2024-02-14 Jan Hubicka <jh@suse.cz>
20477 PR tree-optimization/111054
20478 * tree-ssa-loop-split.cc (split_loop): Check for profile being present.
20480 2024-02-14 Tamar Christina <tamar.christina@arm.com>
20482 * tree-cfg.cc (replace_loop_annotate): Inspect loop edges for annotations.
20484 2024-02-14 Richard Biener <rguenther@suse.de>
20486 PR tree-optimization/113910
20487 * bitmap.cc (bitmap_hash): Mix the full element "hash" to
20488 the hashval_t hash.
20490 2024-02-14 Jakub Jelinek <jakub@redhat.com>
20492 * pretty-print.cc (PTRDIFF_MAX): Define if not yet defined.
20493 (pp_integer_with_precision): For unsigned ptrdiff_t printing
20494 with u, o or x print ptrdiff_t argument converted to
20495 unsigned long long and masked with 2ULL * PTRDIFF_MAX + 1.
20497 2024-02-14 Richard Biener <rguenther@suse.de>
20499 PR middle-end/113576
20500 * expr.cc (do_store_flag): For vector bool compares of vectors
20501 with padding zero that.
20502 * dojump.cc (do_compare_and_jump): Likewise.
20504 2024-02-14 Gerald Pfeifer <gerald@pfeifer.com>
20506 * doc/install.texi (Prerequisites): Update gettext link.
20508 2024-02-13 H.J. Lu <hjl.tools@gmail.com>
20511 * config/i386/i386.cc (ix86_pro_and_epilogue_can_use_push2pop2):
20512 Return false if the incoming stack isn't 16-byte aligned.
20514 2024-02-13 Tobias Burnus <tburnus@baylibre.com>
20516 PR middle-end/113904
20517 * omp-general.cc (struct omp_ts_info): Update for splitting of
20518 OMP_TRAIT_PROPERTY_EXPR into OMP_TRAIT_PROPERTY_{DEV_NUM,BOOL}_EXPR.
20519 * omp-selectors.h (enum omp_tp_type): Replace
20520 OMP_TRAIT_PROPERTY_EXPR by OMP_TRAIT_PROPERTY_{DEV_NUM,BOOL}_EXPR.
20522 2024-02-13 Monk Chiang <monk.chiang@sifive.com>
20525 * config/riscv/riscv.cc (riscv_macro_fusion_pair_p): Fix
20526 recognizes UNSPEC_AUIPC for RISCV_FUSE_LUI_ADDI.
20528 2024-02-13 Richard Biener <rguenther@suse.de>
20530 PR tree-optimization/113895
20531 * tree-ssa-sccvn.cc (copy_reference_ops_from_ref): Track
20532 offset to discover constant array indices in bits, handle
20533 COMPONENT_REF to bitfields.
20535 2024-02-13 Richard Biener <rguenther@suse.de>
20537 PR tree-optimization/113831
20538 * tree-ssa-sccvn.cc (ao_ref_init_from_vn_reference): Fix
20541 2024-02-13 Richard Biener <rguenther@suse.de>
20543 PR tree-optimization/113902
20544 * tree-vect-loop.cc (move_early_exit_stmts): Track
20545 last_seen_vuse for VUSE updating.
20547 2024-02-13 Tamar Christina <tamar.christina@arm.com>
20549 PR tree-optimization/113734
20550 * tree-vect-loop.cc (vect_transform_loop): Treat the final iteration of
20551 an early break loop as partial.
20553 2024-02-13 Richard Biener <rguenther@suse.de>
20555 PR tree-optimization/113898
20556 * tree-ssa-sccvn.cc (copy_reference_ops_from_ref): Add
20557 missing accumulated off adjustment.
20559 2024-02-13 Jakub Jelinek <jakub@redhat.com>
20561 * hwint.h (GCC_PRISZ, fmt_size_t): Fix preprocessor conditions,
20562 instead of comparing SIZE_MAX against INT_MAX and LONG_MAX compare
20563 it against UINT_MAX and ULONG_MAX.
20565 2024-02-13 David Malcolm <dmalcolm@redhat.com>
20567 * diagnostic-core.h (emit_diagnostic_valist): Rename overload
20569 (emit_diagnostic_valist_meta): ...this.
20570 * diagnostic.cc (emit_diagnostic_valist): Likewise, to...
20571 (emit_diagnostic_valist_meta): ...this.
20573 2024-02-12 Jakub Jelinek <jakub@redhat.com>
20575 PR tree-optimization/113849
20576 * gimple-lower-bitint.cc (bitint_large_huge::handle_cast): Don't use
20577 fast path for widening casts where !m_upwards_2limb and lhs_type
20578 has precision which is a multiple of limb_prec.
20580 2024-02-12 Jakub Jelinek <jakub@redhat.com>
20583 * attribs.cc (extract_attribute_substring): Remove.
20584 (lookup_scoped_attribute_spec): Don't call it.
20586 2024-02-12 Jakub Jelinek <jakub@redhat.com>
20588 * gengtype.cc (adjust_field_rtx_def): Use HOST_SIZE_T_PRINT_UNSIGNED
20589 and cast to fmt_size_t instead of %lu and cast to unsigned long.
20591 2024-02-12 Christophe Lyon <christophe.lyon@linaro.org>
20593 * Makefile.in: Add no-info dependency.
20594 * configure.ac: Set BUILD_INFO=no-info if makeinfo is not
20596 * configure: Regenerate.
20598 2024-02-12 Iain Sandoe <iain@sandoe.co.uk>
20601 * config/i386/darwin.h (DARWIN_HEAP_T_LIB): Moved to be
20602 available to all sub-targets.
20603 * config/i386/darwin32-biarch.h (DARWIN_HEAP_T_LIB): Delete.
20604 * config/i386/darwin64-biarch.h (DARWIN_HEAP_T_LIB): Delete.
20606 2024-02-12 Richard Biener <rguenther@suse.de>
20608 PR tree-optimization/113831
20609 PR tree-optimization/108355
20610 * tree-ssa-sccvn.cc (copy_reference_ops_from_ref): When
20611 we see variable array indices and get_ref_base_and_extent
20612 can resolve those to constants fix up the ops to constants
20614 (ao_ref_init_from_vn_reference): Use 'off' member for
20615 ARRAY_REF and ARRAY_RANGE_REF instead of recomputing it.
20616 (valueize_refs_1): Also fixup 'off' of ARRAY_RANGE_REF.
20618 2024-02-12 Pan Li <pan2.li@intel.com>
20620 * config/riscv/riscv-vector-builtins.cc (resolve_overloaded_builtin):
20621 Replace args to arguments for misspelled term.
20623 2024-02-12 Georg-Johann Lay <avr@gjlay.de>
20626 * config/avr/gen-avr-mmcu-specs.cc (print_mcu) [have_flmap]:
20627 <*link_rodata_in_ram>: Spec undefs symbol __do_flmap_init
20628 when not linked with -mrodata-in-ram.
20630 2024-02-12 Richard Biener <rguenther@suse.de>
20632 PR tree-optimization/113863
20633 * tree-vect-data-refs.cc (vect_analyze_early_break_dependences):
20634 Record crossed virtual PHIs.
20635 * tree-vect-loop.cc (move_early_exit_stmts): Elide crossed
20638 2024-02-10 Marek Polacek <polacek@redhat.com>
20643 * doc/invoke.texi: Document -Wtemplate-id-cdtor.
20645 2024-02-10 Jakub Jelinek <jakub@redhat.com>
20647 * gimple-lower-bitint.cc (itint_large_huge::lower_addsub_overflow): Fix
20648 computation of idx for i == 4 of bitint_prec_huge.
20650 2024-02-10 Jakub Jelinek <jakub@redhat.com>
20652 PR middle-end/110754
20653 * gimple-low.cc (assumption_copy_decl): For TREE_THIS_VOLATILE
20654 decls create PARM_DECL with pointer to original type, set
20655 TREE_READONLY and keep TREE_THIS_VOLATILE, TREE_ADDRESSABLE,
20656 DECL_NOT_GIMPLE_REG_P and DECL_BY_REFERENCE cleared.
20657 (adjust_assumption_stmt_op): For remapped TREE_THIS_VOLATILE decls
20658 wrap PARM_DECL into a simple TREE_THIS_NO_TRAP MEM_REF.
20659 (lower_assumption): For TREE_THIS_VOLATILE vars pass ADDR_EXPR
20660 of the var as argument.
20662 2024-02-10 Jakub Jelinek <jakub@redhat.com>
20664 * pretty-print.cc (pp_integer_with_precision): Handle precision 3 for
20665 size_t and precision 4 for ptrdiff_t. Formatting fix.
20666 (pp_format): Document %{t,z}{d,i,u,o,x}. Implement t and z modifiers.
20668 (test_pp_format): Test t and z modifiers.
20669 * gcc.cc (read_specs): Use %td instead of %ld and casts to long.
20671 2024-02-10 Jakub Jelinek <jakub@redhat.com>
20673 * ipa-icf.cc (sem_item_optimizer::process_cong_reduction,
20674 sem_item_optimizer::dump_cong_classes): Use HOST_SIZE_T_PRINT_UNSIGNED
20675 and casts to fmt_size_t instead of "%lu" and casts to unsigned long.
20676 * tree.cc (print_debug_expr_statistics): Use HOST_SIZE_T_PRINT_DEC
20677 and casts to fmt_size_t instead of "%ld" and casts to long.
20678 (print_value_expr_statistics, print_type_hash_statistics): Likewise.
20679 * dwarf2out.cc (output_macinfo_op): Use HOST_WIDE_INT_PRINT_UNSIGNED
20680 instead of "%lu" and casts to unsigned long.
20681 * gcov-dump.cc (dump_gcov_file): Use %u instead of %lu and casts to
20683 * tree-ssa-dom.cc (htab_statistics): Use HOST_SIZE_T_PRINT_DEC
20684 and casts to fmt_size_t instead of "%ld" and casts to long.
20685 * cfgexpand.cc (dump_stack_var_partition): Use
20686 HOST_SIZE_T_PRINT_UNSIGNED and casts to fmt_size_t instead of "%lu"
20687 and casts to unsigned long.
20688 * gengtype.cc (adjust_field_rtx_def): Likewise.
20689 * tree-into-ssa.cc (htab_statistics): Use HOST_SIZE_T_PRINT_DEC
20690 and casts to fmt_size_t instead of "%ld" and casts to long.
20691 * postreload-gcse.cc (dump_hash_table): Likewise.
20692 * ggc-page.cc (alloc_page): Use HOST_SIZE_T_PRINT_UNSIGNED
20693 and casts to fmt_size_t instead of "%lu" and casts to unsigned long.
20694 (ggc_internal_alloc, ggc_free): Likewise.
20695 * genpreds.cc (write_lookup_constraint_1): Likewise.
20696 (write_insn_constraint_len): Likewise.
20697 * tree-dfa.cc (dump_dfa_stats): Use HOST_SIZE_T_PRINT_DEC
20698 and casts to fmt_size_t instead of "%ld" and casts to long.
20699 * varasm.cc (output_constant_pool_contents): Use
20700 HOST_WIDE_INT_PRINT_DEC instead of "%ld" and casts to long.
20701 * var-tracking.cc (dump_var): Likewise.
20703 2024-02-09 Jakub Jelinek <jakub@redhat.com>
20705 PR tree-optimization/113783
20706 * gimple-lower-bitint.cc (bitint_large_huge::lower_stmt): Look
20707 through VIEW_CONVERT_EXPR for final cast checks. Handle
20708 VIEW_CONVERT_EXPRs from large/huge _BitInt to > MAX_FIXED_MODE_SIZE
20710 (gimple_lower_bitint): Don't merge mergeable operations or other
20711 casts with VIEW_CONVERT_EXPRs to > MAX_FIXED_MODE_SIZE INTEGER_TYPEs.
20712 * expr.cc (expand_expr_real_1): Don't use convert_modes if either
20715 2024-02-09 Jakub Jelinek <jakub@redhat.com>
20717 * hwint.h (GCC_PRISZ, fmt_size_t, HOST_SIZE_T_PRINT_DEC,
20718 HOST_SIZE_T_PRINT_UNSIGNED, HOST_SIZE_T_PRINT_HEX,
20719 HOST_SIZE_T_PRINT_HEX_PURE): Define.
20720 * ira-conflicts.cc (build_conflict_bit_table): Use it. Formatting
20723 2024-02-09 Jakub Jelinek <jakub@redhat.com>
20725 PR middle-end/113415
20726 * cfgexpand.cc (expand_asm_stmt): For asm goto, use
20727 duplicate_insn_chain to duplicate after_rtl_seq sequence instead
20728 of hand written loop with emit_insn of copy_insn and emit original
20729 after_rtl_seq on the last edge.
20731 2024-02-09 Jakub Jelinek <jakub@redhat.com>
20733 PR tree-optimization/113818
20734 * gimple-lower-bitint.cc (add_eh_edge): New function.
20735 (bitint_large_huge::handle_load,
20736 bitint_large_huge::lower_mergeable_stmt,
20737 bitint_large_huge::lower_muldiv_stmt): Use it.
20739 2024-02-09 Jakub Jelinek <jakub@redhat.com>
20741 PR tree-optimization/113774
20742 * gimple-lower-bitint.cc (bitint_large_huge::handle_cast): Don't
20743 emit any comparison if m_first and low + 1 is equal to
20744 m_upwards_2limb, simplify condition for that. If not
20745 single_comparison, not m_first and we can prove that the idx <= low
20746 comparison will be always true, emit instead of idx <= low
20747 comparison low <= low such that cfg cleanup will optimize it at
20748 the end of the pass.
20750 2024-02-08 Aldy Hernandez <aldyh@redhat.com>
20752 PR tree-optimization/113735
20753 * value-relation.cc (equiv_oracle::add_equiv_to_block): Call
20756 2024-02-08 Georg-Johann Lay <avr@gjlay.de>
20758 * config/avr/gen-avr-mmcu-specs.cc (struct McuInfo): New.
20759 (main, print_mcu, diagnose_mrodata_in_ram): Pass it down.
20761 2024-02-08 H.J. Lu <hjl.tools@gmail.com>
20765 * config/i386/constraints.md: List all constraints with j prefix.
20766 (j>): Change auto-dec to auto-inc in documentation.
20767 (je): Changed to a memory constraint with APX NDD TLS operand
20769 (jM): New memory constraint for APX NDD instructions.
20771 * config/i386/i386-protos.h (x86_poff_operand_p): Removed.
20772 * config/i386/i386.cc (x86_poff_operand_p): Likewise.
20773 * config/i386/i386.md (*add<dwi>3_doubleword): Use rjO.
20774 (*add<mode>_1[SWI48]): Use je and jM.
20775 (addsi_1_zext): Use jM.
20776 (*addv<dwi>4_doubleword_1[DWI]): Likewise.
20777 (*sub<mode>_1[SWI]): Use jM.
20778 (@add<mode>3_cc_overflow_1[SWI]): Likewise.
20779 (*add<dwi>3_doubleword_cc_overflow_1): Use rjO.
20780 (*and<dwi>3_doubleword): Likewise.
20781 (*anddi_1): Use jM.
20782 (*andsi_1_zext): Likewise.
20783 (*and<mode>_1[SWI24]): Likewise.
20784 (*<code><dwi>3_doubleword[any_or]): Use rjO
20785 (*code<mode>_1[any_or SWI248]): Use jM.
20786 (*<code>si_1_zext[zero_extend + any_or]): Likewise.
20787 * config/i386/predicates.md (apx_ndd_memory_operand): New.
20788 (apx_ndd_add_memory_operand): Likewise.
20790 2024-02-08 Georg-Johann Lay <avr@gjlay.de>
20793 * config/avr/avr-mcus.def (ata5797): Move from avr5 to avr4.
20794 * doc/avr-mmcu.texi: Rebuild.
20796 2024-02-08 Tamar Christina <tamar.christina@arm.com>
20798 PR tree-optimization/113808
20799 * tree-vect-loop.cc (vectorizable_live_operation): Don't cache the
20800 value cross iterations.
20802 2024-02-08 Georg-Johann Lay <avr@gjlay.de>
20804 * config/avr/gen-avr-mmcu-specs.cc (print_mcu) <*cpp_mcu>: Spec always
20805 defines __AVR_PM_BASE_ADDRESS__ if the core has it.
20807 2024-02-08 Richard Biener <rguenther@suse.de>
20809 * tree-vect-data-refs.cc (vect_analyze_early_break_dependences):
20810 Revert last change to dr_may_alias_p.
20812 2024-02-08 Georg-Johann Lay <avr@gjlay.de>
20814 * config/avr/gen-avr-mmcu-specs.cc: Rename spec cc1_misc to
20815 cc1_rodata_in_ram. Rename spec link_misc to link_rodata_in_ram.
20816 Remove spec asm_misc.
20817 * config/avr/specs.h: Same.
20819 2024-02-08 Pan Li <pan2.li@intel.com>
20822 * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_def): Make
20823 sure the c.arg_num is >= 2 before checking.
20824 (struct build_frm_base): Ditto.
20825 (struct narrow_alu_def): Ditto.
20827 2024-02-07 Richard Biener <rguenther@suse.de>
20829 PR tree-optimization/113796
20830 * tree-if-conv.cc (combine_blocks): Wipe range-info before
20831 replacing PHIs and inserting predicates.
20833 2024-02-07 Roger Sayle <roger@nextmovesoftware.com>
20834 Uros Bizjak <ubizjak@gmail.com>
20837 * config/i386/i386-features.cc (timode_convert_cst): New helper
20838 function to convert a TImode CONST_SCALAR_INT_P to a V1TImode
20840 (timode_scalar_chain::convert_op): Use timode_convert_cst.
20841 (timode_scalar_chain::convert_insn): Delete REG_EQUAL notes.
20842 Use timode_convert_cst.
20844 2024-02-07 Victor Do Nascimento <victor.donascimento@arm.com>
20846 * config/aarch64/aarch64-sys-regs.def: Copy from Binutils.
20847 * config/aarch64/aarch64.h (AARCH64_FL_AIE): New.
20848 (AARCH64_FL_DEBUGv8p9): Likewise.
20849 (AARCH64_FL_FGT2): Likewise.Likewise.
20850 (AARCH64_FL_ITE): Likewise.
20851 (AARCH64_FL_PFAR): Likewise.
20852 (AARCH64_FL_PMUv3_ICNTR): Likewise.
20853 (AARCH64_FL_PMUv3_SS): Likewise.
20854 (AARCH64_FL_PMUv3p9): Likewise.
20855 (AARCH64_FL_RASv2): Likewise.
20856 (AARCH64_FL_S1PIE): Likewise.
20857 (AARCH64_FL_S1POE): Likewise.
20858 (AARCH64_FL_S2PIE): Likewise.
20859 (AARCH64_FL_S2POE): Likewise.
20860 (AARCH64_FL_SCTLR2): Likewise.
20861 (AARCH64_FL_SEBEP): Likewise.
20862 (AARCH64_FL_SPE_FDS): Likewise.
20863 (AARCH64_FL_TCR2): Likewise.
20865 2024-02-07 Richard Biener <rguenther@suse.de>
20867 * tree-vect-data-refs.cc (vect_analyze_early_break_dependences):
20868 Only check whether reads are in-bound in places that are not safe.
20869 Fix dependence check. Add missing newline. Clarify comments.
20871 2024-02-07 Tamar Christina <tamar.christina@arm.com>
20873 PR tree-optimization/113750
20874 * tree-vect-data-refs.cc (vect_analyze_early_break_dependences): Check
20875 for single predecessor when doing early break vect.
20876 * tree-vect-loop.cc (move_early_exit_stmts): Get gsi at the start but
20879 2024-02-07 Tamar Christina <tamar.christina@arm.com>
20881 PR tree-optimization/113731
20882 * gimple-iterator.cc (gsi_move_before): Take new parameter for update
20884 * gimple-iterator.h (gsi_move_before): Default new param to
20886 * tree-vect-loop.cc (move_early_exit_stmts): Call gsi_move_before with
20889 2024-02-07 Jakub Jelinek <jakub@redhat.com>
20891 PR tree-optimization/113756
20892 * range-op.cc (update_known_bitmask): For GIMPLE_UNARY_RHS,
20893 use TYPE_SIGN (lh.type ()) instead of sign for widest_int::from
20894 of lh_bits value and mask.
20896 2024-02-07 Jakub Jelinek <jakub@redhat.com>
20898 PR tree-optimization/113753
20899 * wide-int.cc (wi::mul_internal): Unpack op1val and op2val with
20900 UNSIGNED rather than SIGNED. If high or needs_overflow and prec is
20901 not a multiple of HOST_BITS_PER_WIDE_INT, shift left bits above prec
20902 so that they start with r[half_blocks_needed] lowest bit. Fix up
20903 computation of top mask for SIGNED.
20905 2024-02-07 Pan Li <pan2.li@intel.com>
20908 * config/riscv/riscv-protos.h (resolve_overloaded_builtin): Adjust
20909 the signature of func.
20910 * config/riscv/riscv-c.cc (riscv_resolve_overloaded_builtin): Ditto.
20911 * config/riscv/riscv-vector-builtins.cc (resolve_overloaded_builtin): Make
20912 overloaded func with empty args error.
20914 2024-02-06 H.J. Lu <hjl.tools@gmail.com>
20917 * config/i386/i386.cc (x86_64_select_profile_regnum): Return
20918 R10_REG after sorry.
20920 2024-02-06 Andrew Carlotti <andrew.carlotti@arm.com>
20922 * config/aarch64/aarch64.cc (aarch64_mangle_decl_assembler_name):
20923 Move before new caller, and add ".default" suffix.
20924 (get_suffixed_assembler_name): New.
20925 (make_resolver_func): Use get_suffixed_assembler_name.
20926 (aarch64_generate_version_dispatcher_body): Redo name mangling.
20928 2024-02-06 Jakub Jelinek <jakub@redhat.com>
20931 * config/aarch64/aarch64.cc (aarch64_output_sme_zero_za): Change tiles
20932 element from std::pair<unsigned int, char> to an unnamed struct.
20933 Adjust uses of tile range variable.
20935 2024-02-06 Juzhe-Zhong <juzhe.zhong@rivai.ai>
20937 * config/riscv/riscv-vsetvl.cc (pre_vsetvl::emit_vsetvl): Fix inifinite compilation.
20938 (pre_vsetvl::remove_vsetvl_pre_insns): Ditto.
20940 2024-02-06 Jakub Jelinek <jakub@redhat.com>
20942 PR sanitizer/110676
20943 * gimple-fold.cc (gimple_fold_builtin_strlen): For -fsanitize=address
20944 reset maxlen to sizetype maximum.
20946 2024-02-06 Jakub Jelinek <jakub@redhat.com>
20948 PR tree-optimization/113736
20949 * gimple-lower-bitint.cc (bitint_large_huge::limb_access): Use
20950 var's address space for MEM_REF or VIEW_CONVERT_EXPRs.
20952 2024-02-06 Jakub Jelinek <jakub@redhat.com>
20954 PR tree-optimization/113759
20955 * tree-ssa-math-opts.cc (convert_mult_to_widen): If actual_precision
20956 or from_unsignedN differs from properties of typeN, update typeN
20957 to build_nonstandard_integer_type. If TREE_TYPE (rhsN) is not
20958 uselessly convertible to typeN, convert it using fold_convert or
20959 build_and_insert_cast depending on if rhsN is INTEGER_CST or not.
20960 (convert_plusminus_to_widen): Likewise.
20962 2024-02-06 Tejas Belagod <tejas.belagod@arm.com>
20965 * config/aarch64/aarch64.cc (aarch64_class_max_nregs): Handle 64-bit
20966 vector structure modes correctly.
20968 2024-02-05 Christoph Müllner <christoph.muellner@vrull.eu>
20970 * config/riscv/thead.cc (th_print_operand_address): Fix compiler
20973 2024-02-05 H.J. Lu <hjl.tools@gmail.com>
20976 * config/i386/i386.cc (x86_64_select_profile_regnum): New.
20977 (x86_function_profiler): Call x86_64_select_profile_regnum to
20978 get a scratch register for large model profiling.
20980 2024-02-05 Richard Ball <richard.ball@arm.com>
20982 * config/arm/arm.cc (arm_output_mi_thunk): Emit
20983 insn for bti_c when bti is enabled.
20985 2024-02-05 Xi Ruoyao <xry111@xry111.site>
20987 * config/mips/mips-msa.md (neg<mode:MSA>2): Add missing mode for
20990 2024-02-05 Xi Ruoyao <xry111@xry111.site>
20992 * config/mips/mips-msa.md (elmsgnbit): New define_mode_attr.
20993 (neg<mode>2): Change the mode iterator from MSA to IMSA because
20994 in FP arithmetic we cannot use (0 - x) for -x.
20995 (neg<mode>2): New define_insn to implement FP vector negation,
20996 using a bnegi instruction to negate the sign bit.
20998 2024-02-05 Richard Biener <rguenther@suse.de>
21000 PR tree-optimization/113707
21001 * tree-ssa-sccvn.cc (rpo_elim::eliminate_avail): After
21002 checking the avail set treat out-of-region defines as
21005 2024-02-05 Richard Biener <rguenther@suse.de>
21007 * tree-vect-data-refs.cc (vect_create_data_ref_ptr): Use
21008 the default mode when building a pointer.
21010 2024-02-05 Jakub Jelinek <jakub@redhat.com>
21012 PR tree-optimization/113737
21013 * gimple-lower-bitint.cc (gimple_lower_bitint): If GIMPLE_SWITCH
21014 has just a single label, remove it and make single successor edge
21017 2024-02-05 Jakub Jelinek <jakub@redhat.com>
21020 * config/i386/i386-features.cc (rest_of_handle_insert_vzeroupper):
21021 Remove REG_DEAD/REG_UNUSED notes at the end of the pass before
21024 2024-02-05 Richard Biener <rguenther@suse.de>
21027 * config/i386/i386-expand.cc
21028 (expand_set_or_cpymem_prologue_epilogue_by_misaligned_moves):
21029 Use a new pseudo for the skipped number of bytes.
21031 2024-02-05 Monk Chiang <monk.chiang@sifive.com>
21033 * config/riscv/riscv-cores.def: Add sifive-p450, sifive-p670.
21034 * doc/invoke.texi (RISC-V Options): Add sifive-p450,
21037 2024-02-05 Monk Chiang <monk.chiang@sifive.com>
21039 * config/riscv/riscv.md: Include sifive-p400.md.
21040 * config/riscv/sifive-p400.md: New file.
21041 * config/riscv/riscv-cores.def (RISCV_TUNE): Add parameter.
21042 * config/riscv/riscv-opts.h (enum riscv_microarchitecture_type):
21044 * config/riscv/riscv.cc (sifive_p400_tune_info): New.
21045 * config/riscv/riscv.h (TARGET_SFB_ALU): Update.
21046 * doc/invoke.texi (RISC-V Options): Add sifive-p400-series
21048 2024-02-04 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
21050 * config/xtensa/xtensa.md (*eqne_zero_masked_bits):
21051 Add missing ":SI" to the match_operator.
21053 2024-02-04 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
21055 * config/xtensa/xtensa.md (SHI): New mode iterator.
21056 (2 split patterns related to constsynth):
21057 Change to also accept HImode operands.
21059 2024-02-04 Jeff Law <jlaw@ventanamicro.com>
21061 * config/riscv/riscv.cc (riscv_rtx_costs): Handle SUBREG and REG
21064 2024-02-04 Xi Ruoyao <xry111@xry111.site>
21066 * config/loongarch/lsx.md (neg<mode:FLSX>2): Remove the
21068 * config/loongarch/simd.md (simdfmt_as_i): New define_mode_attr.
21069 (elmsgnbit): Likewise.
21070 (neg<mode:FVEC>2): New define_insn.
21071 * config/loongarch/lasx.md (negv4df2, negv8sf2): Remove as they
21072 are now instantiated in simd.md.
21074 2024-02-04 Xi Ruoyao <xry111@xry111.site>
21076 * config/loongarch/loongarch.cc (loongarch_symbol_insns): Do not
21077 use LSX_SUPPORTED_MODE_P or LASX_SUPPORTED_MODE_P if mode is
21080 2024-02-04 Li Wei <liwei@loongson.cn>
21082 * config/loongarch/loongarch.cc (loongarch_expand_vselect): Adjust.
21083 (loongarch_expand_vselect_vconcat): Ditto.
21084 (loongarch_try_expand_lsx_vshuf_const): New, use vshuf to implement
21085 all 128-bit constant permutation situations.
21086 (loongarch_expand_lsx_shuffle): Adjust and rename function name.
21087 (loongarch_is_imm_set_shuffle): Renamed function name.
21088 (loongarch_expand_vec_perm_even_odd): Function forward declaration.
21089 (loongarch_expand_vec_perm_even_odd_1): Add implement for 128-bit
21090 extract-even and extract-odd permutations.
21091 (loongarch_is_odd_extraction): Delete.
21092 (loongarch_is_even_extraction): Ditto.
21093 (loongarch_expand_vec_perm_const): Adjust.
21095 2024-02-03 Jakub Jelinek <jakub@redhat.com>
21097 PR middle-end/113722
21098 * wide-int.cc (wi::bswap_large): Rename third argument from
21099 len to xlen and adjust use in safe_uhwi. Add len variable, set
21100 it to BLOCKS_NEEDED (precision) and use it for clearing of val
21101 and as canonize argument. Clear val using memset instead of
21104 2024-02-03 Jakub Jelinek <jakub@redhat.com>
21106 * ggc-common.cc (gt_pch_save): Allow addr to be equal to
21107 mmi.preferred_base + mmi.size - sizeof (void *).
21109 2024-02-03 Xi Ruoyao <xry111@xry111.site>
21111 * config/loongarch/loongarch-def.h (abi_minimal_isa): Declare.
21112 * config/loongarch/loongarch-opts.cc (abi_minimal_isa): Remove
21113 the ODR-violating locale declaration.
21115 2024-02-02 Tamar Christina <tamar.christina@arm.com>
21117 PR tree-optimization/113588
21118 PR tree-optimization/113467
21119 * tree-vect-data-refs.cc
21120 (vect_analyze_data_ref_dependence): Choose correct dest and fix checks.
21121 (vect_analyze_early_break_dependences): Update comments.
21123 2024-02-02 John David Anglin <danglin@gcc.gnu.org>
21126 * config/pa/pa.cc (enum pa_builtins): Add PA_BUILTIN_GET_FPSR
21127 and PA_BUILTIN_SET_FPSR builtins.
21128 * (pa_builtins_icode): Declare.
21129 * (def_builtin, pa_fpu_init_builtins): New.
21130 * (pa_init_builtins): Initialize FPU builtins.
21131 * (pa_builtin_decl, pa_expand_builtin_1): New.
21132 * (pa_expand_builtin): Handle PA_BUILTIN_GET_FPSR and
21133 PA_BUILTIN_SET_FPSR builtins.
21134 * (pa_atomic_assign_expand_fenv): New.
21135 * config/pa/pa.md (UNSPECV_GET_FPSR, UNSPECV_SET_FPSR): New
21137 (get_fpsr, put_fpsr): New expanders.
21138 (get_fpsr_32, get_fpsr_64, set_fpsr_32, set_fpsr_64): New
21141 2024-02-02 Juzhe-Zhong <juzhe.zhong@rivai.ai>
21144 * config/riscv/riscv-v.cc (expand_reduction): Pass VLMAX avl to scalar move.
21146 2024-02-02 Jonathan Wakely <jwakely@redhat.com>
21148 * doc/extend.texi (Common Type Attributes): Fix typo in
21149 description of hardbool.
21151 2024-02-02 Jakub Jelinek <jakub@redhat.com>
21153 PR tree-optimization/113692
21154 * gimple-lower-bitint.cc (bitint_large_huge::lower_stmt): Handle casts
21155 from large/huge BITINT_TYPEs to POINTER_TYPE/REFERENCE_TYPE as
21158 2024-02-02 Jakub Jelinek <jakub@redhat.com>
21160 PR middle-end/113699
21161 * gimple-lower-bitint.cc (bitint_large_huge::lower_asm): Handle
21162 uninitialized large/huge _BitInt SSA_NAME inputs.
21164 2024-02-02 Jakub Jelinek <jakub@redhat.com>
21166 PR middle-end/113705
21167 * tree-ssa-math-opts.cc (is_widening_mult_rhs_p): Use wide_int_from
21168 around wi::to_wide in order to compare value in prec precision.
21170 2024-02-02 Lehua Ding <lehua.ding@rivai.ai>
21173 2024-02-02 Juzhe-Zhong <juzhe.zhong@rivai.ai>
21175 * config/riscv/riscv.cc (riscv_legitimize_move): Fix poly_int dest generation.
21177 2024-02-02 Juzhe-Zhong <juzhe.zhong@rivai.ai>
21179 * config/riscv/riscv.cc (riscv_legitimize_move): Fix poly_int dest generation.
21181 2024-02-02 Pan Li <pan2.li@intel.com>
21183 * config/riscv/riscv.cc (riscv_get_arg_info): Cleanup comments.
21184 (riscv_pass_by_reference): Ditto.
21185 (riscv_fntype_abi): Ditto.
21187 2024-02-02 Juzhe-Zhong <juzhe.zhong@rivai.ai>
21189 * config/riscv/riscv-vsetvl.cc (vsetvl_pre_insn_p): New function.
21190 (pre_vsetvl::cleaup): Remove vsetvl_pre.
21191 (pre_vsetvl::remove_vsetvl_pre_insns): New function.
21193 2024-02-02 Jiahao Xu <xujiahao@loongson.cn>
21195 * config/loongarch/larchintrin.h
21196 (__frecipe_s): Update function return type.
21197 (__frecipe_d): Ditto.
21198 (__frsqrte_s): Ditto.
21199 (__frsqrte_d): Ditto.
21201 2024-02-02 Li Wei <liwei@loongson.cn>
21203 * config/loongarch/loongarch.cc (loongarch_multiply_add_p): New.
21204 (loongarch_vector_costs::add_stmt_cost): Adjust.
21206 2024-02-02 Xi Ruoyao <xry111@xry111.site>
21208 * config/loongarch/loongarch.md (unspec): Add
21209 UNSPEC_LA_PCREL_64_PART1 and UNSPEC_LA_PCREL_64_PART2.
21210 (la_pcrel64_two_parts): New define_insn.
21211 * config/loongarch/loongarch.cc (loongarch_tls_symbol): Fix a
21212 typo in the comment.
21213 (loongarch_call_tls_get_addr): If -mcmodel=extreme
21214 -mexplicit-relocs={always,auto}, use la_pcrel64_two_parts for
21215 addressing the TLS symbol and __tls_get_addr. Emit an REG_EQUAL
21216 note to allow CSE addressing __tls_get_addr.
21217 (loongarch_legitimize_tls_address): If -mcmodel=extreme
21218 -mexplicit-relocs={always,auto}, address TLS IE symbols with
21219 la_pcrel64_two_parts.
21220 (loongarch_split_symbol): If -mcmodel=extreme
21221 -mexplicit-relocs={always,auto}, address symbols with
21222 la_pcrel64_two_parts.
21223 (loongarch_output_mi_thunk): Clean up unreachable code. If
21224 -mcmodel=extreme -mexplicit-relocs={always,auto}, address the MI
21225 thunks with la_pcrel64_two_parts.
21227 2024-02-02 Lulu Cheng <chenglulu@loongson.cn>
21229 * config/loongarch/loongarch.cc (loongarch_call_tls_get_addr):
21230 Add support for call36.
21232 2024-02-02 Lulu Cheng <chenglulu@loongson.cn>
21234 * config/loongarch/loongarch.cc (loongarch_explicit_relocs_p):
21235 When the code model of the symbol is extreme and -mexplicit-relocs=auto,
21236 the macro instruction loading symbol address is not applicable.
21237 (loongarch_call_tls_get_addr): Adjust code.
21238 (loongarch_legitimize_tls_address): Likewise.
21240 2024-02-02 Lulu Cheng <chenglulu@loongson.cn>
21242 * config/loongarch/loongarch-protos.h (loongarch_symbol_extreme_p):
21243 Add function declaration.
21244 * config/loongarch/loongarch.cc (loongarch_symbolic_constant_p):
21245 For SYMBOL_PCREL64, non-zero addend of "la.local $rd,$rt,sym+addend"
21247 (loongarch_load_tls): Added macro support in extreme mode.
21248 (loongarch_call_tls_get_addr): Likewise.
21249 (loongarch_legitimize_tls_address): Likewise.
21250 (loongarch_force_address): Likewise.
21251 (loongarch_legitimize_move): Likewise.
21252 (loongarch_output_mi_thunk): Likewise.
21253 (loongarch_option_override_internal): Remove the code that detects
21254 explicit relocs status.
21255 (loongarch_handle_model_attribute): Likewise.
21256 * config/loongarch/loongarch.md (movdi_symbolic_off64): New template.
21257 * config/loongarch/predicates.md (symbolic_off64_operand): New predicate.
21258 (symbolic_off64_or_reg_operand): Likewise.
21260 2024-02-02 Lulu Cheng <chenglulu@loongson.cn>
21262 * config/loongarch/loongarch.cc (loongarch_load_tls):
21263 Load all types of tls symbols through one function.
21264 (loongarch_got_load_tls_gd): Delete.
21265 (loongarch_got_load_tls_ld): Delete.
21266 (loongarch_got_load_tls_ie): Delete.
21267 (loongarch_got_load_tls_le): Delete.
21268 (loongarch_call_tls_get_addr): Modify the called function name.
21269 (loongarch_legitimize_tls_address): Likewise.
21270 * config/loongarch/loongarch.md (@got_load_tls_gd<mode>): Delete.
21271 (@load_tls<mode>): New template.
21272 (@got_load_tls_ld<mode>): Delete.
21273 (@got_load_tls_le<mode>): Delete.
21274 (@got_load_tls_ie<mode>): Delete.
21276 2024-02-02 Lulu Cheng <chenglulu@loongson.cn>
21278 * config/loongarch/loongarch.cc (mem_shadd_or_shadd_rtx_p): New function.
21279 (loongarch_legitimize_address): Add logical transformation code.
21281 2024-02-01 Marek Polacek <polacek@redhat.com>
21283 * doc/invoke.texi: Update -Wdangling-reference documentation.
21285 2024-02-01 Uros Bizjak <ubizjak@gmail.com>
21288 * config/i386/i386.md (*cmp<dwi>_doubleword):
21289 Do not force SUBREG pieces to pseudos.
21291 2024-02-01 John David Anglin <danglin@gcc.gnu.org>
21293 * config/pa/pa.md (atomic_storedi_1): Fix bug in
21296 2024-02-01 Georg-Johann Lay <avr@gjlay.de>
21298 * config/avr/avr.cc: Tabify.
21300 2024-02-01 Richard Ball <richard.ball@arm.com>
21302 PR tree-optimization/111268
21303 * tree-vect-slp.cc (vectorizable_slp_permutation_1):
21304 Add variable-length check for vector input arguments
21307 2024-02-01 Thomas Schwinge <tschwinge@baylibre.com>
21309 * config/gcn/gcn.cc (gcn_hsa_declare_function_name): Don't
21310 hard-code number of SGPR/VGPR/AVGPR registers.
21311 * config/gcn/gcn.h: Add a 'STATIC_ASSERT's for number of
21312 SGPR/VGPR/AVGPR registers.
21314 2024-02-01 Monk Chiang <monk.chiang@sifive.com>
21316 * config/riscv/riscv.md: Add "fcvt_i2f", "fcvt_f2i" type
21317 attribute, and include sifive-p600.md.
21318 * config/riscv/generic-ooo.md: Update type attribute.
21319 * config/riscv/generic.md: Update type attribute.
21320 * config/riscv/sifive-7.md: Update type attribute.
21321 * config/riscv/sifive-p600.md: New file.
21322 * config/riscv/riscv-cores.def (RISCV_TUNE): Add parameter.
21323 * config/riscv/riscv-opts.h (enum riscv_microarchitecture_type):
21325 * config/riscv/riscv.cc (sifive_p600_tune_info): New.
21326 * config/riscv/riscv.h (TARGET_SFB_ALU): Update.
21327 * doc/invoke.texi (RISC-V Options): Add sifive-p600-series
21329 2024-02-01 Monk Chiang <monk.chiang@sifive.com>
21331 * common/config/riscv/riscv-common.cc: Add Za64rs, Za128rs,
21332 Ziccif, Ziccrse, Ziccamoa, Zicclsm, Zic64b items.
21333 * config/riscv/riscv.opt: New macro for 7 new unprivileged
21335 * doc/invoke.texi (RISC-V Options): Add Za64rs, Za128rs,
21336 Ziccif, Ziccrse, Ziccamoa, Zicclsm, Zic64b extensions.
21338 2024-02-01 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
21340 * config/sol2.h (LIBASAN_EARLY_SPEC): Add -z now unless
21341 -static-libasan. Add missing whitespace.
21343 2024-02-01 Thomas Schwinge <tschwinge@baylibre.com>
21345 * config/gcn/gcn.md (FIRST_SGPR_REG, LAST_SGPR_REG)
21346 (FIRST_VGPR_REG, LAST_VGPR_REG, FIRST_AVGPR_REG, LAST_AVGPR_REG):
21347 Don't 'define_constants'.
21349 2024-02-01 Thomas Schwinge <tschwinge@baylibre.com>
21351 * config/gcn/gcn.h (SGPR_OR_VGPR_REGNO_P): Remove.
21353 2024-02-01 Thomas Schwinge <tschwinge@baylibre.com>
21355 * config/gcn/gcn.md (sync_compare_and_swap<mode>_lds_insn)
21356 [TARGET_RDNA3]: Adjust.
21358 2024-02-01 Richard Biener <rguenther@suse.de>
21360 PR tree-optimization/113693
21361 * tree-ssa-sccvn.cc (rpo_elim::eliminate_avail): Honor avail
21362 data when available.
21364 2024-02-01 Jakub Jelinek <jakub@redhat.com>
21365 Jason Merrill <jason@redhat.com>
21368 * gimple-low.cc (lower_stmt): Remove .ASAN_MARK calls
21369 on variables which were promoted to TREE_STATIC.
21371 2024-02-01 Roger Sayle <roger@nextmovesoftware.com>
21372 Richard Biener <rguenther@suse.de>
21375 * tree-ssa-math-opts.cc (is_widening_mult_rhs_p): Use range
21376 information via tree_non_zero_bits to check if this operand
21377 is suitably extended for a widening (or highpart) multiplication.
21378 (convert_mult_to_widen): Insert explicit casts if the RHS or LHS
21379 isn't already of the claimed type.
21381 2024-02-01 Edwin Lu <ewlu@rivosinc.com>
21384 2024-02-01 Edwin Lu <ewlu@rivosinc.com>
21386 * config/riscv/generic-ooo.md (generic_ooo_sfb_alu): Add reservation
21387 (generic_ooo_branch): ditto
21388 * config/riscv/generic.md (generic_sfb_alu): ditto
21389 (generic_fmul_half): ditto
21390 * config/riscv/riscv.md: Remove cbo, pushpop, and rdfrm types
21391 * config/riscv/sifive-7.md (sifive_7_hfma):Add reservation
21392 (sifive_7_popcount): ditto
21393 * config/riscv/vector.md: change rdfrm to fmove
21394 * config/riscv/zc.md: change pushpop to load/store
21396 2024-02-01 Edwin Lu <ewlu@rivosinc.com>
21399 2024-02-01 Edwin Lu <ewlu@rivosinc.com>
21400 Robin Dapp <rdapp.gcc@gmail.com>
21402 * config/riscv/generic-ooo.md (generic_ooo): Move reservation
21403 (generic_ooo_vec_load): ditto
21404 (generic_ooo_vec_store): ditto
21405 (generic_ooo_vec_loadstore_seg): ditto
21406 (generic_ooo_vec_alu): ditto
21407 (generic_ooo_vec_fcmp): ditto
21408 (generic_ooo_vec_imul): ditto
21409 (generic_ooo_vec_fadd): ditto
21410 (generic_ooo_vec_fmul): ditto
21411 (generic_ooo_crypto): ditto
21412 (generic_ooo_perm): ditto
21413 (generic_ooo_vec_reduction): ditto
21414 (generic_ooo_vec_ordered_reduction): ditto
21415 (generic_ooo_vec_idiv): ditto
21416 (generic_ooo_vec_float_divsqrt): ditto
21417 (generic_ooo_vec_mask): ditto
21418 (generic_ooo_vec_vesetvl): ditto
21419 (generic_ooo_vec_setrm): ditto
21420 (generic_ooo_vec_readlen): ditto
21421 * config/riscv/riscv.md: include generic-vector-ooo
21422 * config/riscv/generic-vector-ooo.md: New file. to here
21424 2024-02-01 Edwin Lu <ewlu@rivosinc.com>
21427 2024-02-01 Edwin Lu <ewlu@rivosinc.com>
21429 * config/riscv/riscv.cc (riscv_sched_variable_issue): enable assert
21431 2024-02-01 Edwin Lu <ewlu@rivosinc.com>
21433 * config/riscv/riscv.cc (riscv_sched_variable_issue): enable assert
21435 2024-02-01 Edwin Lu <ewlu@rivosinc.com>
21436 Robin Dapp <rdapp.gcc@gmail.com>
21438 * config/riscv/generic-ooo.md (generic_ooo): Move reservation
21439 (generic_ooo_vec_load): ditto
21440 (generic_ooo_vec_store): ditto
21441 (generic_ooo_vec_loadstore_seg): ditto
21442 (generic_ooo_vec_alu): ditto
21443 (generic_ooo_vec_fcmp): ditto
21444 (generic_ooo_vec_imul): ditto
21445 (generic_ooo_vec_fadd): ditto
21446 (generic_ooo_vec_fmul): ditto
21447 (generic_ooo_crypto): ditto
21448 (generic_ooo_perm): ditto
21449 (generic_ooo_vec_reduction): ditto
21450 (generic_ooo_vec_ordered_reduction): ditto
21451 (generic_ooo_vec_idiv): ditto
21452 (generic_ooo_vec_float_divsqrt): ditto
21453 (generic_ooo_vec_mask): ditto
21454 (generic_ooo_vec_vesetvl): ditto
21455 (generic_ooo_vec_setrm): ditto
21456 (generic_ooo_vec_readlen): ditto
21457 * config/riscv/riscv.md: include generic-vector-ooo
21458 * config/riscv/generic-vector-ooo.md: New file. to here
21460 2024-02-01 Edwin Lu <ewlu@rivosinc.com>
21462 * config/riscv/generic-ooo.md (generic_ooo_sfb_alu): Add reservation
21463 (generic_ooo_branch): ditto
21464 * config/riscv/generic.md (generic_sfb_alu): ditto
21465 (generic_fmul_half): ditto
21466 * config/riscv/riscv.md: Remove cbo, pushpop, and rdfrm types
21467 * config/riscv/sifive-7.md (sifive_7_hfma):Add reservation
21468 (sifive_7_popcount): ditto
21469 * config/riscv/vector.md: change rdfrm to fmove
21470 * config/riscv/zc.md: change pushpop to load/store
21472 2024-02-01 Andrew Pinski <quic_apinski@quicinc.com>
21475 * config/aarch64/aarch64-simd.md (split for movv8di):
21476 For strict aligned mode, use DImode instead of TImode.
21478 2024-01-31 Robin Dapp <rdapp@ventanamicro.com>
21480 PR middle-end/113607
21481 * match.pd: Make sure else values match when folding a
21482 vec_cond into a conditional operation.
21484 2024-01-31 Marek Polacek <polacek@redhat.com>
21486 * doc/invoke.texi: Mention that -fconcepts-ts was deprecated in GCC 14.
21488 2024-01-31 Tamar Christina <tamar.christina@arm.com>
21489 Matthew Malcomson <matthew.malcomson@arm.com>
21491 PR sanitizer/112644
21492 * asan.h (asan_intercepted_p): Incercept memset, memmove, memcpy and
21494 * builtins.cc (expand_builtin): Include HWASAN when checking for
21497 2024-01-31 Richard Biener <rguenther@suse.de>
21499 PR middle-end/110176
21500 * match.pd (zext (bool) <= (int) 4294967295u): Make sure
21501 to match INTEGER_CST only without outstanding conversion.
21503 2024-01-31 Alex Coplan <alex.coplan@arm.com>
21506 * config/aarch64/aarch64.cc (aarch64_reg_save_mode): Use
21507 V16QImode for the full 16-byte FPR saves in the vector PCS case.
21509 2024-01-31 Richard Biener <rguenther@suse.de>
21511 PR tree-optimization/111444
21512 * tree-ssa-sccvn.cc (vn_reference_lookup_3): Do not use
21513 vn_reference_lookup_2 when optimistically skipping may-defs.
21515 2024-01-31 Richard Biener <rguenther@suse.de>
21517 PR tree-optimization/113630
21518 * tree-ssa-pre.cc (compute_avail): Avoid registering a
21519 reference with a representation with not matching base
21522 2024-01-31 Jakub Jelinek <jakub@redhat.com>
21524 PR rtl-optimization/113656
21525 * simplify-rtx.cc (simplify_context::simplify_unary_operation_1)
21526 <case FLOAT_TRUNCATE>: Fix up last argument to simplify_gen_unary.
21528 2024-01-31 Jakub Jelinek <jakub@redhat.com>
21531 * dwarf2out.cc (loc_list_from_tree_1): Assume integral types
21532 with BLKmode are larger than DWARF2_ADDR_SIZE.
21534 2024-01-31 Jakub Jelinek <jakub@redhat.com>
21536 PR tree-optimization/113639
21537 * gimple-lower-bitint.cc (bitint_large_huge::handle_operand_addr):
21538 For VIEW_CONVERT_EXPR set rhs1 to its operand.
21540 2024-01-31 Richard Biener <rguenther@suse.de>
21542 PR tree-optimization/113670
21543 * tree-vect-data-refs.cc (vect_check_gather_scatter):
21544 Make sure we can take the address of the reference base.
21546 2024-01-31 Georg-Johann Lay <avr@gjlay.de>
21548 * config/avr/avr-mcus.def: Add AVR64DU28, AVR64DU32, ATA5787,
21549 ATA5835, ATtiny64AUTO, ATA5700M322.
21550 * doc/avr-mmcu.texi: Rebuild.
21552 2024-01-31 Alexandre Oliva <oliva@adacore.com>
21555 * ipa-strub.cc (build_ref_type_for): Drop nonaliased. Adjust
21558 2024-01-31 Alexandre Oliva <oliva@adacore.com>
21560 PR middle-end/112917
21561 PR middle-end/113100
21562 * builtins.cc (expand_builtin_stack_address): Use
21563 STACK_ADDRESS_OFFSET.
21564 * doc/extend.texi (__builtin_stack_address): Adjust.
21565 * config/sparc/sparc.h (STACK_ADDRESS_OFFSET): Define.
21566 * doc/tm.texi.in (STACK_ADDRESS_OFFSET): Document.
21567 * doc/tm.texi: Rebuilt.
21569 2024-01-31 Juzhe-Zhong <juzhe.zhong@rivai.ai>
21572 * config/riscv/riscv-vsetvl.cc (extract_single_source): Remove.
21573 (pre_vsetvl::compute_vsetvl_def_data): Fix compile time issue.
21574 (pre_vsetvl::compute_transparent): New function.
21575 (pre_vsetvl::compute_lcm_local_properties): Fix compile time time issue.
21577 2024-01-30 Fangrui Song <maskray@google.com>
21580 * config/i386/constraints.md: Define constraint "Ws".
21581 * doc/md.texi: Document it.
21583 2024-01-30 Marek Polacek <polacek@redhat.com>
21587 * doc/invoke.texi: Update -Wdangling-reference description.
21589 2024-01-30 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
21591 * config/xtensa/constraints.md (R, T, U):
21592 Change define_constraint to define_memory_constraint.
21593 * config/xtensa/predicates.md (move_operand): Don't check that a
21594 constant pool operand size is a multiple of UNITS_PER_WORD.
21595 * config/xtensa/xtensa.cc
21596 (xtensa_lra_p, TARGET_LRA_P): Remove.
21597 (xtensa_emit_move_sequence): Remove "if (reload_in_progress)"
21598 clause as it can no longer be true.
21599 (fixup_subreg_mem): Drop function.
21600 (xtensa_output_integer_literal_parts): Consider 16-bit wide
21602 (xtensa_legitimate_constant_p): Add short-circuit path for
21603 integer load instructions. Don't check that mode size is
21604 at least UNITS_PER_WORD.
21605 * config/xtensa/xtensa.md (movsf): Use can_create_pseudo_p()
21606 rather reload_in_progress and reload_completed.
21607 (doloop_end): Drop operand 2.
21608 (movhi_internal): Add alternative loading constant from a
21610 (define_split for DI register_operand): Don't limit to
21611 !TARGET_AUTO_LITPOOLS.
21612 * config/xtensa/xtensa.opt (mlra): Change to no effect.
21614 2024-01-30 Pan Li <pan2.li@intel.com>
21616 * config/riscv/riscv.cc (riscv_v_vls_mode_aggregate_gpr_count): New function to
21617 calculate the gpr count required by vls mode.
21618 (riscv_v_vls_to_gpr_mode): New function convert vls mode to gpr mode.
21619 (riscv_pass_vls_aggregate_in_gpr): New function to return the rtx of gpr
21621 (riscv_get_arg_info): Add vls mode handling.
21622 (riscv_pass_by_reference): Return false if arg info has no zero gpr count.
21624 2024-01-30 Richard Biener <rguenther@suse.de>
21626 PR tree-optimization/113659
21627 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
21628 Handle main exit without virtual use.
21630 2024-01-30 Christoph Müllner <christoph.muellner@vrull.eu>
21632 * config/riscv/riscv.md: Move UNSPEC_XTHEADFMV* to unspec enum.
21634 2024-01-30 Iain Sandoe <iain@sandoe.co.uk>
21637 * config/darwin.h (DARWIN_SHARED_WEAK_ADDS, DARWIN_WEAK_CRTS): New.
21638 (REAL_LIBGCC_SPEC): Move weak CRT handling to separate spec.
21639 * config/i386/darwin.h (DARWIN_HEAP_T_LIB): New.
21640 * config/i386/darwin32-biarch.h (DARWIN_HEAP_T_LIB): New.
21641 * config/i386/darwin64-biarch.h (DARWIN_HEAP_T_LIB): New.
21642 * config/rs6000/darwin.h (DARWIN_HEAP_T_LIB): New.
21644 2024-01-30 Richard Sandiford <richard.sandiford@arm.com>
21647 * config/aarch64/aarch64-early-ra.cc (early_ra::preprocess_insns):
21648 Mark all registers that occur in addresses as needing a GPR.
21650 2024-01-30 Richard Sandiford <richard.sandiford@arm.com>
21653 * config/aarch64/aarch64-early-ra.cc (early_ra::replace_regs): Take
21654 the containing insn as an extra parameter. Reset debug instructions
21655 if they reference a register that is no longer used by real insns.
21656 (early_ra::apply_allocation): Update calls accordingly.
21658 2024-01-30 Jakub Jelinek <jakub@redhat.com>
21660 PR tree-optimization/113603
21661 * tree-ssa-strlen.cc (strlen_pass::handle_store): After
21662 count_nonzero_bytes call refetch si using get_strinfo in case it
21663 has been unshared in the meantime.
21665 2024-01-30 Jakub Jelinek <jakub@redhat.com>
21667 PR middle-end/101195
21668 * except.cc (expand_builtin_eh_return_data_regno): If which doesn't
21669 fit into unsigned HOST_WIDE_INT, return constm1_rtx.
21671 2024-01-30 Jin Ma <jinma@linux.alibaba.com>
21673 * config/riscv/thead.cc (th_print_operand_address): Change %ld
21676 2024-01-29 Manos Anagnostakis <manos.anagnostakis@vrull.eu>
21677 Manolis Tsamis <manolis.tsamis@vrull.eu>
21678 Philipp Tomsich <philipp.tomsich@vrull.eu>
21680 * config/aarch64/aarch64-ldpstp.md: Remove unused mode.
21681 * config/aarch64/aarch64-protos.h (aarch64_operands_ok_for_ldpstp):
21683 * config/aarch64/aarch64.cc (aarch64_operands_ok_for_ldpstp):
21684 Call on framework moved later.
21686 2024-01-29 Jose E. Marchesi <jose.marchesi@oracle.com>
21688 * config/bpf/bpf.cc (bpf_expand_epilogue): Do not emit a return
21689 instruction in naked function epilogues.
21691 2024-01-29 YunQiang Su <syq@gcc.gnu.org>
21694 * configure.ac: Fix typo gcc_cv_as_mips_explicit should be
21695 gcc_cv_as_mips_explicit_relocs.
21696 * configure: Regnerated.
21698 2024-01-29 Matthieu Longo <matthieu.longo@arm.com>
21701 * config/arm/arm.md (arm_rev16si2): Convert to define_insn.
21702 Correct generated RTL.
21703 (arm_rev16si2_alt1): Correctly handle conditional execution.
21704 (arm_rev16si2_alt2): Likewise.
21706 2024-01-29 Richard Biener <rguenther@suse.de>
21708 PR middle-end/113622
21709 * expr.cc (expand_assignment): Spill hard registers if
21710 we index them with a variable offset.
21712 2024-01-29 Richard Biener <rguenther@suse.de>
21714 PR middle-end/113622
21715 * gimple-isel.cc (gimple_expand_vec_set_extract_expr):
21716 Also allow DECL_HARD_REGISTER variables.
21718 2024-01-29 Alex Coplan <alex.coplan@arm.com>
21721 * config/aarch64/aarch64-ldp-fusion.cc (fixup_debug_uses_trailing_add):
21722 Use iterate_safely when iterating over debug uses.
21723 (fixup_debug_uses): Likewise.
21724 (ldp_bb_info::cleanup_tombstones): Use iterate_safely to iterate
21725 over nondebug insns instead of manually maintaining the next insn.
21726 * iterator-utils.h (class safe_iterator): New.
21727 (iterate_safely): New.
21729 2024-01-29 H.J. Lu <hjl.tools@gmail.com>
21732 * config/i386/i386-options.cc (ix86_set_func_type): Save
21733 callee-saved registers in noreturn functions for -O0/-Og.
21735 2024-01-29 Tobias Burnus <tburnus@baylibre.com>
21738 * config/gcn/gcn-valu.md (fold_left_plus_<mode>): Only
21739 define for !TARGET_RDNA2_PLUS.
21741 2024-01-29 Richard Sandiford <richard.sandiford@arm.com>
21744 * tree-vect-patterns.cc (vect_recog_over_widening_pattern): Remove
21745 workaround for right shifts.
21746 (vect_truncatable_operation_p): Handle NEGATE_EXPR and BIT_NOT_EXPR.
21747 (vect_determine_precisions_from_range): Be more selective about
21748 which codes can be narrowed based on their input and output ranges.
21749 For shifts, require at least one more bit of precision than the
21750 maximum shift amount.
21752 2024-01-29 Tobias Burnus <tburnus@baylibre.com>
21754 * config/nvptx/nvptx.opt (march-map=): Add sm_89 and sm_90a.
21756 2024-01-29 Tobias Burnus <tburnus@baylibre.com>
21758 * doc/install.texi (amdgcn): Recommend LLVM 15+ and newlib 4.4+,
21759 but keep requiring only newlib 4.3+ and, if gfx1100 is disabled,
21762 2024-01-29 Tobias Burnus <tburnus@baylibre.com>
21765 * config/gcn/mkoffload.cc (SET_XNACK_UNSET, TEST_SRAM_ECC_UNSET): New.
21766 (SET_SRAM_ECC_UNSUPPORTED): Renamed to ...
21767 (SET_SRAM_ECC_UNSET): ... this.
21768 (copy_early_debug_info): Remove gfx900 special case, now handled as
21769 part of the generic handling.
21770 (main): Update SRAM_ECC and XNACK for the -march as done in gcn-hsa.h.
21772 2024-01-29 Jakub Jelinek <jakub@redhat.com>
21774 PR tree-optimization/110603
21775 * tree-ssa-strlen.cc (get_range_strlen_dynamic): Remove incorrect
21776 setting of pdata->maxlen to vr.upper_bound (which is unconditionally
21777 overwritten anyway). Avoid creating invalid range with minlen
21778 larger than maxlen. Formatting fix.
21780 2024-01-29 Richard Biener <rguenther@suse.de>
21783 * tree-inline.cc (initialize_inlined_parameters): Reverse
21784 the decl chain of inlined parameters.
21786 2024-01-28 Iain Sandoe <iain@sandoe.co.uk>
21788 * config/darwin.cc (darwin_build_constant_cfstring): Prevent over-
21789 alignment of CFString constants by setting DECL_USER_ALIGN.
21791 2024-01-28 Iain Sandoe <iain@sandoe.co.uk>
21792 Jakub Jelinek <jakub@redhat.com>
21795 * builtins.cc (expand_builtin): Handle BUILT_IN_GCC_NESTED_PTR_CREATED
21796 and BUILT_IN_GCC_NESTED_PTR_DELETED.
21797 * builtins.def (BUILT_IN_GCC_NESTED_PTR_CREATED,
21798 BUILT_IN_GCC_NESTED_PTR_DELETED): Make these builtins LIB-EXT and
21799 rename the library fallbacks to __gcc_nested_func_ptr_created and
21800 __gcc_nested_func_ptr_deleted.
21801 * doc/invoke.texi: Rename these to __gcc_nested_func_ptr_created
21802 and __gcc_nested_func_ptr_deleted.
21803 * tree-nested.cc (finalize_nesting_tree_1): Use builtin_explicit for
21804 BUILT_IN_GCC_NESTED_PTR_CREATED and BUILT_IN_GCC_NESTED_PTR_DELETED.
21805 * tree.cc (build_common_builtin_nodes): Build the
21806 BUILT_IN_GCC_NESTED_PTR_CREATED and BUILT_IN_GCC_NESTED_PTR_DELETED local
21807 builtins only for non-explicit.
21809 2024-01-28 YunQiang Su <syq@gcc.gnu.org>
21811 * doc/invoke.texi: Remove duplicate MIPS explicit-relocs option.
21813 2024-01-27 H.J. Lu <hjl.tools@gmail.com>
21816 * config/i386/i386-options.cc (ix86_set_func_type): Don't
21817 save and restore callee saved registers for a noreturn function
21818 with nothrow or compiled with -fno-exceptions.
21820 2024-01-27 H.J. Lu <hjl.tools@gmail.com>
21824 * config/i386/i386-expand.cc (ix86_expand_call): Replace
21825 no_caller_saved_registers check with call_saved_registers check.
21826 Clobber all registers that are not used by the callee with
21827 no_callee_saved_registers attribute.
21828 * config/i386/i386-options.cc (ix86_set_func_type): Set
21829 call_saved_registers to TYPE_NO_CALLEE_SAVED_REGISTERS for
21830 noreturn function. Disallow no_callee_saved_registers with
21831 interrupt or no_caller_saved_registers attributes together.
21832 (ix86_set_current_function): Replace no_caller_saved_registers
21833 check with call_saved_registers check.
21834 (ix86_handle_no_caller_saved_registers_attribute): Renamed to ...
21835 (ix86_handle_call_saved_registers_attribute): This.
21836 (ix86_gnu_attributes): Add
21837 ix86_handle_call_saved_registers_attribute.
21838 * config/i386/i386.cc (ix86_conditional_register_usage): Replace
21839 no_caller_saved_registers check with call_saved_registers check.
21840 (ix86_function_ok_for_sibcall): Don't allow callee with
21841 no_callee_saved_registers attribute when the calling function
21842 has callee-saved registers.
21843 (ix86_comp_type_attributes): Also check
21844 no_callee_saved_registers.
21845 (ix86_epilogue_uses): Replace no_caller_saved_registers check
21846 with call_saved_registers check.
21847 (ix86_hard_regno_scratch_ok): Likewise.
21848 (ix86_save_reg): Replace no_caller_saved_registers check with
21849 call_saved_registers check. Don't save any registers for
21850 TYPE_NO_CALLEE_SAVED_REGISTERS. Save all registers with
21851 TYPE_DEFAULT_CALL_SAVED_REGISTERS if function with
21852 no_callee_saved_registers attribute is called.
21853 (find_drap_reg): Replace no_caller_saved_registers check with
21854 call_saved_registers check.
21855 * config/i386/i386.h (call_saved_registers_type): New enum.
21856 (machine_function): Replace no_caller_saved_registers with
21857 call_saved_registers.
21858 * doc/extend.texi: Document no_callee_saved_registers attribute.
21860 2024-01-27 Jakub Jelinek <jakub@redhat.com>
21862 PR tree-optimization/113614
21863 * gimple-lower-bitint.cc (gimple_lower_bitint): Don't merge
21864 widening casts from signed to unsigned types with TRUNC_DIV_EXPR,
21865 TRUNC_MOD_EXPR or FLOAT_EXPR uses.
21867 2024-01-27 Jakub Jelinek <jakub@redhat.com>
21869 PR tree-optimization/113568
21870 * gimple-lower-bitint.cc (bitint_large_huge::lower_mergeable_stmt):
21871 For VIEW_CONVERT_EXPR use first operand of rhs1 instead of rhs1
21872 in the widening extension checks.
21874 2024-01-27 Jakub Jelinek <jakub@redhat.com>
21876 * gimple-lower-bitint.cc (gimple_lower_bitint): For
21877 TDF_DETAILS dump mapping of SSA_NAMEs to decls.
21879 2024-01-26 Hans-Peter Nilsson <hp@axis.com>
21881 * cgraphunit.cc (process_function_and_variable_attributes): Tweak
21882 the warning for an attribute-always_inline without inline declaration.
21884 2024-01-26 Robin Dapp <rdapp@ventanamicro.com>
21887 * genopinit.cc (main): Split init_all_optabs into functions
21888 of 1000 patterns each.
21890 2024-01-26 Tobias Burnus <tburnus@baylibre.com>
21892 * config.gcc (amdgcn-*-*): Add gfx1030 and gfx1100 to
21893 TM_MULTILIB_CONFIG.
21894 * doc/install.texi (Configuration amdgcn-*-*): Mention gfx1030/gfx1100.
21895 * doc/invoke.texi (AMD GCN Options): Add gfx1030 and gfx1100 to
21898 2024-01-26 Andrew Stubbs <ams@baylibre.com>
21900 * config/gcn/gcn-opts.h (TARGET_PACKED_WORK_ITEMS): Add TARGET_RDNA3.
21901 * config/gcn/gcn-valu.md (all_convert): New iterator.
21902 (<convop><V_INT_1REG_ALT:mode><V_INT_1REG:mode>2<exec>): New
21903 define_expand, and rename the old one to ...
21904 (*<convop><V_INT_1REG_ALT:mode><V_INT_1REG:mode>_sdwa<exec>): ... this.
21905 (extend<V_INT_1REG_ALT:mode><V_INT_1REG:mode>2<exec>): Likewise, to ...
21906 (extend<V_INT_1REG_ALT:mode><V_INT_1REG:mode>_sdwa<exec>): .. this.
21907 (*<convop><V_INT_1REG_ALT:mode><V_INT_1REG:mode>_shift<exec>): New.
21908 * config/gcn/gcn.cc (gcn_global_address_p): Use "offsetbits" correctly.
21909 (gcn_hsa_declare_function_name): Update the vgpr counting for gfx1100.
21910 * config/gcn/gcn.md (<u>mulhisi3): Disable on RDNA3.
21911 (<u>mulqihi3_scalar): Likewise.
21913 2024-01-26 Richard Biener <rguenther@suse.de>
21915 PR tree-optimization/113602
21916 * tree-data-ref.cc (dr_analyze_innermost): Fail when
21917 the base object isn't addressable.
21919 2024-01-26 Tobias Burnus <tburnus@baylibre.com>
21921 * config/gcn/gcn-hsa.h (ABI_VERSION_SPEC): New; creates the
21922 "--amdhsa-code-object-version=" argument.
21923 (ASM_SPEC): Use it; replace previous version of it.
21925 2024-01-26 Juzhe-Zhong <juzhe.zhong@rivai.ai>
21927 * config/riscv/riscv-vsetvl.cc (pre_vsetvl::earliest_fuse_vsetvl_info): Refine some codes.
21928 (pre_vsetvl::emit_vsetvl): Ditto.
21930 2024-01-26 Jiahao Xu <xujiahao@loongson.cn>
21932 * config/loongarch/lasx.md (vec_extract<mode>_0):
21933 New define_insn_and_split patten.
21935 2024-01-26 Jiahao Xu <xujiahao@loongson.cn>
21937 * config/loongarch/loongarch.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
21939 2024-01-26 Li Wei <liwei@loongson.cn>
21941 * config/loongarch/loongarch.cc (loongarch_emit_swdivsf): Adjust.
21943 2024-01-26 Juzhe-Zhong <juzhe.zhong@rivai.ai>
21946 * config/riscv/riscv-vsetvl.cc (pre_vsetvl::compute_lcm_local_properties): Fix bug.
21948 2024-01-26 Andrew Pinski <quic_apinski@quicinc.com>
21951 * config/aarch64/aarch64.cc (aarch64_classify_index): Avoid
21952 undefined shift after the call to exact_log2.
21954 2024-01-25 Andrew Pinski <quic_apinski@quicinc.com>
21957 * config/aarch64/constraints.md (J): Cast to `unsigned HOST_WIDE_INT`
21958 before taking the negative of it.
21960 2024-01-25 Vladimir N. Makarov <vmakarov@redhat.com>
21963 * lra-constraints.cc (curr_insn_transform): Change class even for
21964 spilled pseudo successfully matched with with NO_REGS.
21966 2024-01-25 Georg-Johann Lay <avr@gjlay.de>
21969 * config/avr/avr-mcus.def (atmega3208, atmega3209): Fix data_section_start.
21971 2024-01-25 Szabolcs Nagy <szabolcs.nagy@arm.com>
21974 * config/aarch64/aarch64.cc (aarch64_gen_compare_zero_and_branch): New.
21975 (aarch64_expand_epilogue): Use the new function.
21976 (aarch64_split_compare_and_swap): Likewise.
21977 (aarch64_split_atomic_op): Likewise.
21979 2024-01-25 Robin Dapp <rdapp.gcc@gmail.com>
21981 PR middle-end/112971
21982 * fold-const.cc (simplify_const_binop): New function for binop
21983 simplification of two constant vectors when element-wise
21984 handling is not necessary.
21985 (const_binop): Call new function.
21987 2024-01-25 Mary Bennett <mary.bennett@embecosm.com>
21989 * common/config/riscv/riscv-common.cc: Add XCVbitmanip.
21990 * config/riscv/constraints.md: Likewise.
21991 * config/riscv/corev.def: Likewise.
21992 * config/riscv/corev.md: Likewise.
21993 * config/riscv/predicates.md: Likewise.
21994 * config/riscv/riscv-builtins.cc (AVAIL): Likewise.
21995 * config/riscv/riscv-ftypes.def: Likewise.
21996 * config/riscv/riscv.opt: Likewise.
21997 * config/riscv/riscv.cc (riscv_print_operand): Add new operand 'Y'.
21998 * doc/extend.texi: Add XCVbitmanip builtin documentation.
21999 * doc/sourcebuild.texi: Likewise.
22001 2024-01-25 Tobias Burnus <tburnus@baylibre.com>
22003 * config/gcn/gcn-hsa.h (ASM_SPEC): Add space after -mxnack= argument.
22005 2024-01-25 Yanzhang Wang <yanzhang.wang@intel.com>
22008 * config/riscv/riscv.cc (riscv_get_arg_info): Remove the flag.
22009 (riscv_fntype_abi): Ditto.
22010 * config/riscv/riscv.opt: Ditto.
22012 2024-01-25 Jakub Jelinek <jakub@redhat.com>
22014 PR middle-end/113574
22015 * convert.cc (convert_to_integer_1) <case LSHIFT_EXPR>: Compare shift
22016 count against TYPE_PRECISION rather than TYPE_SIZE.
22018 2024-01-25 Richard Sandiford <richard.sandiford@arm.com>
22021 * config/aarch64/aarch64-sve-builtins.cc (vector_cst_all_same):
22022 Check VECTOR_CST_ELT instead of VECTOR_CST_ENCODED_ELT
22024 2024-01-25 Richard Sandiford <richard.sandiford@arm.com>
22027 * config/aarch64/aarch64-simd.md: In the movv8di splitter, check
22028 whether each split instruction is a load that clobbers the source
22029 address. Emit that instruction last if so.
22031 2024-01-25 Richard Sandiford <richard.sandiford@arm.com>
22034 * config/aarch64/aarch64-simd.md (aarch64_zip1<mode>_low): New
22036 (<optab><Vnarrowq><mode>2): Use it instead of generating a
22037 paradoxical subreg for the input.
22039 2024-01-25 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22041 * config/riscv/riscv-vsetvl.cc (get_all_predecessors): New function.
22042 (pre_vsetvl::pre_global_vsetvl_info): Add LCM delete block all
22043 predecessors dump information.
22045 2024-01-25 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22047 * config/riscv/riscv-vsetvl.cc (pre_vsetvl::compute_vsetvl_def_data): Remove
22048 redundant full available computation.
22049 (pre_vsetvl::pre_global_vsetvl_info): Ditto.
22051 2024-01-25 Jakub Jelinek <jakub@redhat.com>
22053 * doc/generic.texi (VECTOR_CST): Fix typo - petterns -> patterns.
22054 * doc/rtl.texi (CONST_VECTOR): Likewise.
22056 2024-01-25 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22058 * config/riscv/riscv-opts.h (enum vsetvl_strategy_enum): Add optim-no-fusion option.
22059 * config/riscv/riscv-vsetvl.cc (pass_vsetvl::lazy_vsetvl): Ditto.
22060 (pass_vsetvl::execute): Ditto.
22061 * config/riscv/riscv.opt: Ditto.
22063 2024-01-25 Jiahao Xu <xujiahao@loongson.cn>
22065 * config/loongarch/lasx.md (@vec_concatz<mode>): Remove this define_insn pattern.
22066 * config/loongarch/loongarch.cc (loongarch_expand_vector_group_init): Use vec_concat<mode>.
22068 2024-01-25 Richard Biener <rguenther@suse.de>
22070 PR tree-optimization/113576
22071 * tree-vect-loop.cc (vec_init_loop_exit_info): Only allow
22072 exits with may_be_zero niters when its the last one.
22074 2024-01-25 Lulu Cheng <chenglulu@loongson.cn>
22076 * config/loongarch/loongarch.cc (loongarch_symbolic_constant_p):
22077 For symbols of type tls, non-zero Offset is not generated.
22079 2024-01-25 Haochen Gui <guihaoc@gcc.gnu.org>
22081 * config/rs6000/rs6000-string.cc (expand_block_compare): Enable
22082 P9 with m32 and mpowerpc64.
22084 2024-01-25 liuhongt <hongtao.liu@intel.com>
22086 * config/i386/i386-options.cc (ix86_option_override_internal):
22087 Enable -mlam=u57 by default when compiled with
22088 -fsanitize=hwaddress.
22090 2024-01-25 Palmer Dabbelt <palmer@rivosinc.com>
22092 * common/config/riscv/riscv-common.cc (riscv_implied_info):
22093 Remove {"ztso", "a"}.
22095 2024-01-24 Martin Jambor <mjambor@suse.cz>
22099 * cgraph.h (cgraph_edge): Add a parameter to
22100 redirect_call_stmt_to_callee.
22101 * ipa-param-manipulation.h (ipa_param_adjustments): Add a
22102 parameter to modify_call.
22103 (ipa_release_ssas_in_hash): Declare.
22104 * cgraph.cc (cgraph_edge::redirect_call_stmt_to_callee): New
22105 parameter killed_ssas, pass it to padjs->modify_call.
22106 * ipa-param-manipulation.cc (purge_all_uses): New function.
22107 (ipa_param_adjustments::modify_call): New parameter killed_ssas.
22108 Instead of substituting uses, invoke purge_all_uses. If
22109 hash of killed SSAs has not been provided, create a temporary one
22110 and release SSAs that have been added to it.
22111 (compare_ssa_versions): New function.
22112 (ipa_release_ssas_in_hash): Likewise.
22113 * tree-inline.cc (redirect_all_calls): Create
22114 id->killed_new_ssa_names earlier, pass it to edge redirection,
22116 (copy_body): Release SSAs in id->killed_new_ssa_names.
22118 2024-01-24 Andrew Pinski <quic_apinski@quicinc.com>
22121 * config/aarch64/aarch64.cc (aarch64_get_reg_raw_mode): For
22122 TARGET_GENERAL_REGS_ONLY, return VOIDmode for non-GP_REGNUM_P regno.
22124 2024-01-24 Monk Chiang <monk.chiang@sifive.com>
22127 * config/riscv/sfb.md: New splitters to rewrite single bit
22128 sign extension as the condition to SFB instructions.
22130 2024-01-24 Jan Hubicka <jh@suse.cz>
22132 PR middle-end/88345
22133 * common.opt: (flimit-function-alignment): Reorder alphabeticaly
22134 (fmin-function-alignment): New parameter.
22135 * doc/invoke.texi: (-fmin-function-alignment): Document.
22136 (-falign-functions,-falign-loops,-falign-labels): Mention that
22137 aglinments are ignored in cold code.
22138 * varasm.cc (assemble_start_function): Handle min-function-alignment.
22140 2024-01-24 Tamar Christina <tamar.christina@arm.com>
22143 * config/aarch64/aarch64-simd.md (<su_optab>div<mode>3,
22145 * config/aarch64/iterators.md (VQDIV): Remove.
22146 (SVE_FULL_SDI_SIMD, SVE_FULL_HSDI_SIMD_DI,
22147 SVE_I_SIMD_DI): New.
22148 (VPRED, sve_lane_con): Add V4SI and V2DI.
22149 * config/aarch64/aarch64-sve.md (<optab><mode>3,
22150 @aarch64_pred_<optab><mode>): Support Advanced SIMD types.
22151 (mul<mode>3): New, split from <optab><mode>3.
22152 (@aarch64_pred_<optab><mode>, *post_ra_<optab><mode>3): New.
22153 * config/aarch64/aarch64-sve2.md (@aarch64_mul_lane_<mode>,
22154 *aarch64_mul_unpredicated_<mode>): Change SVE_FULL_HSDI to
22155 SVE_FULL_HSDI_SIMD_DI.
22157 2024-01-24 Tamar Christina <tamar.christina@arm.com>
22159 PR tree-optimization/113552
22160 * config/aarch64/aarch64.cc
22161 (aarch64_simd_clone_compute_vecsize_and_simdlen): Block simdlen 1.
22163 2024-01-24 Martin Jambor <mjambor@suse.cz>
22166 * ipa-cp.cc (ipcp_lattice<valtype>::add_value): Bail out if value
22167 count is equal or greater than the limit. Use the limit from the
22170 2024-01-24 YunQiang Su <syq@gcc.gnu.org>
22172 * configure.ac: Detect the explicit relocs support for
22173 mips, and define C macro MIPS_EXPLICIT_RELOCS.
22174 * config.in: Regenerated.
22175 * configure: Regenerated.
22176 * doc/invoke.texi(MIPS Options): Add -mexplicit-relocs.
22177 * config/mips/mips-opts.h: Define enum mips_explicit_relocs.
22178 * config/mips/mips.cc(mips_set_compression_mode): Sorry if
22179 !TARGET_EXPLICIT_RELOCS instead of just set it.
22180 * config/mips/mips.h: Define TARGET_EXPLICIT_RELOCS and
22181 TARGET_EXPLICIT_RELOCS_PCREL with mips_opt_explicit_relocs.
22182 * config/mips/mips.opt: Introduce -mexplicit-relocs= option
22183 and define -m(no-)explicit-relocs as aliases.
22185 2024-01-24 Alex Coplan <alex.coplan@arm.com>
22187 * config/aarch64/aarch64.opt (-mearly-ldp-fusion): Set default
22189 (-mlate-ldp-fusion): Likewise.
22191 2024-01-24 Tamar Christina <tamar.christina@arm.com>
22193 * tree-vect-loop.cc (vect_get_vect_def,
22194 vect_create_epilog_for_reduction): Rename main_exit_p to
22197 2024-01-24 Tamar Christina <tamar.christina@arm.com>
22199 PR tree-optimization/113364
22200 * tree-vect-loop.cc (vect_create_epilog_for_reduction): If all exits all
22201 early exits then we must reduce from the first offset for all of them.
22203 2024-01-24 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22206 * config/riscv/riscv-vsetvl.cc (get_expr_id): Remove.
22207 (get_regno): Ditto.
22208 (get_bb_index): Ditto.
22209 (pre_vsetvl::compute_avl_def_data): Ditto.
22210 (pre_vsetvl::earliest_fuse_vsetvl_info): Fix large memory usage.
22211 (pre_vsetvl::pre_global_vsetvl_info): Ditto.
22213 2024-01-23 Andrew Pinski <quic_apinski@quicinc.com>
22214 Richard Sandiford <richard.sandiford@arm.com>
22217 * ccmp.cc (ccmp_candidate_p): Add outer argument.
22218 Allow if the outer is true and the lhs is used more
22220 (expand_ccmp_expr): Update call to ccmp_candidate_p.
22221 * expr.h (expand_expr_real_gassign): Declare.
22222 * expr.cc (expand_expr_real_gassign): New function, split out from...
22223 (expand_expr_real_1): ...here.
22224 * cfgexpand.cc (expand_gimple_stmt_1): Use expand_expr_real_gassign.
22226 2024-01-23 Alex Coplan <alex.coplan@arm.com>
22229 * config/aarch64/aarch64-ldp-fusion.cc (reset_debug_use): New.
22230 (fixup_debug_use): New.
22231 (fixup_debug_uses_trailing_add): New.
22232 (fixup_debug_uses): New. Use it ...
22233 (ldp_bb_info::fuse_pair): ... here.
22234 (try_promote_writeback): Call fixup_debug_uses_trailing_add to
22235 fix up debug uses of the base register that are affected by
22236 folding in the trailing add insn.
22238 2024-01-23 Alex Coplan <alex.coplan@arm.com>
22241 * config/aarch64/aarch64-ldp-fusion.cc (ldp_bb_info::fuse_pair):
22242 Update trailing nondebug uses of the base register in the case
22243 of cancelling writeback.
22245 2024-01-23 Alex Coplan <alex.coplan@arm.com>
22248 * rtl-ssa/accesses.h (use_info::next_debug_insn_use): New.
22249 (debug_insn_use_iterator): New.
22250 (set_info::first_debug_insn_use): New.
22251 (set_info::debug_insn_uses): New.
22252 * rtl-ssa/member-fns.inl (use_info::next_debug_insn_use): New.
22253 (set_info::first_debug_insn_use): New.
22254 (set_info::debug_insn_uses): New.
22256 2024-01-23 Alex Coplan <alex.coplan@arm.com>
22259 * config/aarch64/aarch64-ldp-fusion.cc (ldp_bb_info::try_fuse_pair):
22260 Don't record hazards against the opposite insn in the pair.
22262 2024-01-23 Alex Coplan <alex.coplan@arm.com>
22265 * config/aarch64/aarch64-ldp-fusion.cc
22266 (struct stp_change_builder): New.
22267 (decide_stp_strategy): Reanme to ...
22268 (try_repurpose_store): ... this.
22269 (ldp_bb_info::fuse_pair): Refactor to use stp_change_builder to
22270 construct stp changes. Fix up uses when inserting new stp insns.
22272 2024-01-23 Alex Coplan <alex.coplan@arm.com>
22275 * rtl-ssa.h: Include hash-set.h.
22276 * rtl-ssa/changes.cc (function_info::finalize_new_accesses): Add
22277 new_sets parameter and use it to keep track of new user-created sets.
22278 (function_info::apply_changes_to_insn): Also call add_def on new sets.
22279 (function_info::change_insns): Add hash_set to keep track of new
22280 user-created defs. Plumb it through.
22281 * rtl-ssa/functions.h: Add hash_set parameter to finalize_new_accesses and
22282 apply_changes_to_insn.
22284 2024-01-23 Alex Coplan <alex.coplan@arm.com>
22287 * rtl-ssa/accesses.cc (function_info::create_use): New.
22288 * rtl-ssa/changes.cc (function_info::finalize_new_accesses):
22289 Ensure new uses end up referring to permanent defs.
22290 * rtl-ssa/functions.h (function_info::create_use): Declare.
22292 2024-01-23 Alex Coplan <alex.coplan@arm.com>
22295 * rtl-ssa/changes.cc (function_info::change_insns): Split out the call
22296 to finalize_new_accesses from the backwards placement loop, run it
22297 forwards in a separate loop.
22299 2024-01-23 Richard Biener <rguenther@suse.de>
22301 PR tree-optimization/113552
22302 * tree-vect-stmts.cc (vectorizable_simd_clone_call): Use
22303 floor_log2 instead of exact_log2 on the number of calls.
22305 2024-01-23 Jeff Law <jlaw@ventanamicro.com>
22306 Jakub Jelinek <jakub@redhat.com>
22308 * config/ia64/ia64.cc (ia64_start_function): Add ATTRIBUTE_UNUSED to
22311 2024-01-23 Richard Biener <rguenther@suse.de>
22313 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
22314 Separate single and multi-exit case when creating PHIs between
22315 the main and epilogue.
22317 2024-01-23 Richard Sandiford <richard.sandiford@arm.com>
22320 * config/aarch64/aarch64-sve-builtins-shapes.cc (build_one): Skip
22321 MODE_single variants of functions that don't take tuple arguments.
22323 2024-01-23 Alex Coplan <alex.coplan@arm.com>
22326 * config/aarch64/aarch64-ldp-fusion.cc (try_promote_writeback):
22327 Don't assert recog success, just punt if the writeback pair
22330 2024-01-23 Jakub Jelinek <jakub@redhat.com>
22332 * config/gcn/gcn.cc (gcn_hsa_declare_function_name): Add
22333 ATTRIBUTE_UNUSED to decl.
22335 2024-01-23 Richard Biener <rguenther@suse.de>
22338 * dwarf2out.cc (dwarf2out_die_ref_for_decl): Gracefully
22339 handle unexpected but bogus DIE contexts when not checking
22342 2024-01-23 Jakub Jelinek <jakub@redhat.com>
22344 PR tree-optimization/113462
22345 * fold-const.cc (native_interpret_int): Don't punt if total_bytes
22346 is larger than HOST_BITS_PER_DOUBLE_INT / BITS_PER_UNIT.
22347 (fold_view_convert_expr): Use XALLOCAVEC buffers for types with
22348 sizes between 129 and 8192 bytes.
22350 2024-01-23 Xi Ruoyao <xry111@xry111.site>
22352 * config/loongarch/loongarch.cc (loongarch_explicit_relocs_p):
22353 If la_opt_explicit_relocs is EXPLICIT_RELOCS_AUTO, return false
22354 for SYMBOL_TLS_LDM and SYMBOL_TLS_GD.
22355 (loongarch_call_tls_get_addr): Do not split symbols of
22356 SYMBOL_TLS_LDM or SYMBOL_TLS_GD if la_opt_explicit_relocs is
22357 EXPLICIT_RELOCS_AUTO.
22359 2024-01-23 Richard Biener <rguenther@suse.de>
22361 * alias.cc (known_base_value_p): Remove.
22362 (find_base_value): Remove PLUS/MINUS handling
22363 when both operands are not CONST_INT_P.
22365 2024-01-23 Richard Biener <rguenther@suse.de>
22367 PR rtl-optimization/113255
22368 * alias.cc (find_base_term): Remove PLUS/MINUS handling
22369 when both operands are not CONST_INT_P.
22371 2024-01-23 Richard Biener <rguenther@suse.de>
22374 * dwarf2out.cc (dwarf2out_finish): Reset all type units
22375 for the fat part of an LTO compile.
22377 2024-01-23 chenxiaolong <chenxiaolong@loongson.cn>
22379 * doc/sourcebuild.texi: Add attributes for keywords.
22381 2024-01-23 Sandra Loosemore <sandra@codesourcery.com>
22384 * doc/invoke.texi (Warning Options): Correct lists of options
22385 enabled by -Wall and -Wextra by checking against common.opt
22386 and c-family/c.opt.
22388 2024-01-22 Andrew Pinski <quic_apinski@quicinc.com>
22391 * config/arm/parsecpu.awk (check_cpu): Use cpu_opt_alias
22392 instead of cpu_optaliases.
22393 (check_arch): Use arch_opt_alias instead of arch_optaliases.
22395 2024-01-22 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22397 * config/riscv/riscv-protos.h (splat_to_scalar_move_p): New function.
22398 * config/riscv/riscv-v.cc (splat_to_scalar_move_p): Ditto.
22399 * config/riscv/vector.md: Simplify vmv.v.x. into vmv.s.x.
22401 2024-01-22 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22404 * config/riscv/riscv.md: Use reg instead of subreg.
22406 2024-01-22 Tobias Burnus <tburnus@baylibre.com>
22409 * config/gcn/mkoffload.cc (elf_arch): Change default to gfx900
22410 to match the compiler default.
22411 (simple_object_copy_lto_debug_sections): Never unlink the outfile
22412 on error as the caller does so.
22413 (maybe_unlink, compile_native): Use %<...%> and %qs in fatal_error.
22414 (main): Likewise. Fix 'mkoffload.dbg.o' cleanup.
22416 2024-01-22 Richard Biener <rguenther@suse.de>
22418 PR tree-optimization/113373
22419 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
22420 Create LC PHIs in the exit blocks where necessary.
22421 * tree-vect-loop.cc (vectorizable_live_operation): Do not try
22422 to handle missing LC PHIs.
22423 (find_connected_edge): Remove.
22424 (vect_create_epilog_for_reduction): Cleanup use of auto_vec.
22426 2024-01-22 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22428 * config/riscv/vector.md: Fix vfirst/vmsbf/vmsof ratio attributes.
22430 2024-01-22 xuli <xuli1@eswincomputing.com>
22433 * config/riscv/riscv-vector-builtins.cc (has_vxrm_or_frm_p):remove.
22434 (registered_function::overloaded_hash):refactor.
22435 (resolve_overloaded_builtin):avoid internal ICE.
22437 2024-01-21 Mikael Pettersson <mikpelinux@gmail.com>
22441 * calls.cc (emit_library_call_value_1): Pass valid TYPE
22443 * expr.cc (emit_push_insn): Likewise.
22445 2024-01-21 Jeff Law <jlaw@ventanamicro.com>
22447 * config/riscv/riscv.cc (riscv_init_cumulative_args): Install
22448 correcction version of last change.
22450 2024-01-21 Jeff Law <jlaw@ventanamicro.com>
22452 * config/riscv/riscv.cc (riscv_init_cumulative_args): Update and
22453 fix bugs in signature.
22455 2024-01-21 Roger Sayle <roger@nextmovesoftware.com>
22456 Richard Biener <rguenther@suse.de>
22458 PR rtl-optimization/111267
22459 * fwprop.cc (fwprop_propagation::profitabe_p): Rename
22460 profitable_p method to likely_profitable_p.
22461 (try_fwprop_subst_node): Update call to likely_profitable_p.
22462 Only bail-out early when !prop.likely_profitable_p for instructions
22463 that are not single sets. When comparing costs, bail-out if the
22464 cost is unchanged and !prop.likely_profitable_p.
22466 2024-01-21 Sandra Loosemore <sandra@codesourcery.com>
22469 * doc/invoke.texi (Warning Options): Document that -Wunused-parameter
22470 isn't enabled by -Wunused unless -Wextra is provided, and that
22471 -Wunused does enable -Wunused-const-variable=1 for C. Clarify that
22472 -Wunused doesn't enable -Wunused-* options documented as behaving
22473 otherwise, and list them explicitly.
22475 2024-01-21 Sandra Loosemore <sandra@codesourcery.com>
22478 * doc/invoke.texi (Warning Options): Fix broken example and
22479 clean up/reorganize the others. Also describe what the short-form
22482 2024-01-20 Sandra Loosemore <sandra@codesourcery.com>
22485 * doc/invoke.texi (Option Summary): Add -Warray-parameter.
22486 (Warning Options): Correct/edit discussion of -Warray-parameter
22487 to make the first example less confusing, and fill in missing info.
22489 2024-01-20 Jakub Jelinek <jakub@redhat.com>
22491 PR tree-optimization/113462
22492 * gimple-lower-bitint.cc (bitint_large_huge::handle_cast):
22493 Handle rhs1 INTEGER_CST like SSA_NAME.
22495 2024-01-20 Jakub Jelinek <jakub@redhat.com>
22497 PR tree-optimization/113491
22498 * tree-switch-conversion.cc (switch_conversion::build_constructors):
22499 If elt.index has precision higher than sizetype, fold_convert it to
22501 (switch_conversion::array_value_type): Return type if type is
22502 BITINT_TYPE with precision above MAX_FIXED_MODE_SIZE or with BLKmode.
22503 (switch_conversion::build_arrays): Use unsigned_type_for rather than
22504 lang_hooks.types.type_for_mode if utype is BITINT_TYPE with precision
22505 above MAX_FIXED_MODE_SIZE or with BLKmode. If utype has precision
22506 higher than sizetype, use sizetype as tidx type and fold_convert the
22507 subtraction to sizetype.
22509 2024-01-20 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22511 * config/riscv/riscv.cc (riscv_init_cumulative_args): Suppress warning.
22512 (riscv_vector_mode_supported_any_target_p): Ditto.
22514 2024-01-19 Mikael Pettersson <mikpelinux@gmail.com>
22517 * config/m68k/m68k.cc (m68k_zero_call_used_regs): New function.
22518 (TARGET_ZERO_CALL_USED_REGS): Define.
22520 2024-01-19 Mikael Pettersson <mikpelinux@gmail.com>
22523 * config/m68k/m68k.cc (output_andsi3): Use QImode for
22524 address adjusted for 1-byte RMW access.
22525 (output_iorsi3): Likewise.
22526 (output_xorsi3): Likewise.
22528 2024-01-19 Kito Cheng <kito.cheng@sifive.com>
22530 * doc/invoke.texi (RISC-V Options): Add list of supported
22533 2024-01-19 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22536 * config/riscv/riscv-protos.h (RVV_VLMAX): Change to regno_reg_rtx[X0_REGNUM].
22537 (RVV_VUNDEF): Ditto.
22538 * config/riscv/riscv-vsetvl.cc: Add timevar.
22540 2024-01-19 Richard Biener <rguenther@suse.de>
22543 * lto-streamer-in.cc (lto_read_tree_1): When there isn't
22544 an early DIE but there should be, do not pretend there is.
22546 2024-01-19 Richard Biener <rguenther@suse.de>
22548 PR tree-optimization/113494
22549 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
22550 Handle endless loop on exit. Handle re-allocated PHI.
22552 2024-01-19 Jakub Jelinek <jakub@redhat.com>
22554 PR tree-optimization/113464
22555 * gimple-lower-bitint.cc (gimple_lower_bitint): Don't try to
22556 optimize loads into GIMPLE_ASM stmts.
22558 2024-01-19 Jakub Jelinek <jakub@redhat.com>
22560 PR tree-optimization/113463
22561 * gimple-ssa-warn-restrict.cc (builtin_memref::extend_offset_range):
22562 Only look through NOP_EXPRs if rhs1 doesn't have wider type than
22565 2024-01-19 Jakub Jelinek <jakub@redhat.com>
22567 PR tree-optimization/113459
22568 * tree-ssa-sccvn.cc (vn_walk_cb_data::push_partial_def): Use
22569 TREE_INT_CST_LOW of TYPE_SIZE_UNIT rather than GET_MODE_SIZE
22570 of SCALAR_INT_TYPE_MODE if type has BLKmode.
22571 (vn_reference_lookup_3): Likewise. Formatting fix.
22573 2024-01-19 Jakub Jelinek <jakub@redhat.com>
22574 Richard Biener <rguenther@suse.de>
22576 * cfgexpand.cc (discover_nonconstant_array_refs_r): Force non-BLKmode
22577 VAR_DECLs referenced in BLKmode VIEW_CONVERT_EXPRs into memory.
22578 * expr.cc (expand_expr_real_1) <case VIEW_CONVERT_EXPR>: Do nothing
22579 but adjust_address also for BLKmode mode and MEM op0.
22581 2024-01-19 Palmer Dabbelt <palmer@rivosinc.com>
22583 * common/config/riscv/riscv-common.cc: Add Zihpm and Zicnttr
22586 2024-01-19 Kito Cheng <kito.cheng@sifive.com>
22588 * doc/invoke.texi (RISC-V Options): Document the syntax of -march.
22590 2024-01-19 Kito Cheng <kito.cheng@sifive.com>
22592 * common/config/riscv/riscv-common.cc
22593 (riscv_subset_list::parse_std_ext): Remove.
22594 (riscv_subset_list::parse_multiletter_ext): Remove.
22595 * config/riscv/riscv-subset.h
22596 (riscv_subset_list::parse_std_ext): Remove.
22597 (riscv_subset_list::parse_multiletter_ext): Remove.
22599 2024-01-19 Kito Cheng <kito.cheng@sifive.com>
22601 * common/config/riscv/riscv-common.cc
22602 (riscv_subset_list::parse_single_std_ext): New parameter.
22603 (riscv_subset_list::parse_single_multiletter_ext): Ditto.
22604 (riscv_subset_list::parse_single_ext): Ditto.
22605 (riscv_subset_list::parse): Relax the order for the input of ISA
22607 * config/riscv/riscv-subset.h
22608 (riscv_subset_list::parse_single_std_ext): New parameter.
22609 (riscv_subset_list::parse_single_multiletter_ext): Ditto.
22610 (riscv_subset_list::parse_single_ext): Ditto.
22612 2024-01-19 Kito Cheng <kito.cheng@sifive.com>
22614 * common/config/riscv/riscv-common.cc
22615 (riscv_subset_list::parse_base_ext): New.
22616 (riscv_subset_list::parse): Extract part of logic into
22617 riscv_subset_list::parse_base_ext.
22618 * config/riscv/riscv-subset.h (riscv_subset_list::parse_base_ext):
22621 2024-01-19 Kito Cheng <kito.cheng@sifive.com>
22623 * config/riscv/riscv.cc (riscv_override_options_internal): Tweak
22626 2024-01-19 Kuan-Lin Chen <rufus@andestech.com>
22628 * config/riscv/vector-crypto.md (UNSPEC_CLMUL): Rename to
22631 2024-01-19 Sandra Loosemore <sandra@codesourcery.com>
22634 * doc/extend.texi (Common Variable Attributes): Explain what
22635 happens when multiple variables with cleanups are in the same scope.
22637 2024-01-18 Sandra Loosemore <sandra@codesourcery.com>
22640 * doc/extend.texi (Common Function Attributes): Document that
22641 noinline also disables some interprocedural optimizations and
22642 improve flow to the part about using inline asm instead to
22643 disable calls from being optimized away completely. Remove the
22644 sentence that says noipa is mainly for internal compiler testing.
22646 2024-01-18 John David Anglin <danglin@gcc.gnu.org>
22648 PR tree-optimization/69807
22649 * config/pa/pa.cc (pa_option_override): Set flag_pie on TARGET_64BIT.
22651 2024-01-18 Brian Inglis <Brian.Inglis@Shaw.ca>
22654 * doc/invoke.texi (Option Summary): Remove -mcygwin and -mno-cygwin
22655 from x86 Windows Options.
22657 2024-01-18 Sandra Loosemore <sandra@codesourcery.com>
22660 * doc/extend.texi (C Extensions): Add new section to menu.
22661 (Function Attributes): Move dangling index entries to....
22662 (Const and Volatile Functions): New section.
22664 2024-01-18 David Malcolm <dmalcolm@redhat.com>
22666 PR middle-end/112684
22667 * toplev.cc (toplev::main): Don't ICE in
22668 -fdiagnostics-generate-patch when exiting after options,
22669 since no edit context will have been created.
22671 2024-01-18 Richard Biener <rguenther@suse.de>
22673 * tree-vect-stmts.cc (vectorizable_store): Do not pre-allocate
22676 2024-01-18 Iain Sandoe <iain@sandoe.co.uk>
22678 * Makefile.in: Emit ENABLE_DARWIN_AT_RPATH into site.exp
22679 when ENABLE_DARWIN_AT_RPATH_TRUE is not '#'.
22681 2024-01-18 Jun Sha (Joshua) <cooper.joshua@linux.alibaba.com>
22682 Jin Ma <jinma@linux.alibaba.com>
22683 Xianmiao Qu <cooper.qu@linux.alibaba.com>
22684 Christoph Müllner <christoph.muellner@vrull.eu>
22686 * config/riscv/thead.cc
22687 (th_asm_output_opcode): Rewrite some instructions.
22689 2024-01-18 Jun Sha (Joshua) <cooper.joshua@linux.alibaba.com>
22690 Jin Ma <jinma@linux.alibaba.com>
22691 Xianmiao Qu <cooper.qu@linux.alibaba.com>
22692 Christoph Müllner <christoph.muellner@vrull.eu>
22694 * config/riscv/riscv.md (none,thv,rvv): New attribute.
22695 (no,yes): Add an attribute to disable alternative
22696 for xtheadvector or RVV1.0.
22697 * config/riscv/vector.md:
22698 Disable alternatives that destination register overlaps
22699 source register group for xtheadvector.
22701 2024-01-18 Jun Sha (Joshua) <cooper.joshua@linux.alibaba.com>
22702 Jin Ma <jinma@linux.alibaba.com>
22703 Xianmiao Qu <cooper.qu@linux.alibaba.com>
22704 Christoph Müllner <christoph.muellner@vrull.eu>
22706 * config/riscv/riscv-vector-builtins-bases.cc
22707 (class th_loadstore_width): Define new builtin bases.
22708 (class th_extract): Define new builtin bases.
22709 (BASE): Define new builtin bases.
22710 * config/riscv/riscv-vector-builtins-bases.h:
22711 Define new builtin class.
22712 * config/riscv/riscv-vector-builtins-shapes.cc
22713 (struct th_loadstore_width_def): Define new builtin shapes.
22714 (struct th_indexed_loadstore_width_def):
22715 Define new builtin shapes.
22716 (struct th_extract_def): Define new builtin shapes.
22717 (SHAPE): Define new builtin shapes.
22718 * config/riscv/riscv-vector-builtins-shapes.h:
22719 Define new builtin shapes.
22720 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_FUNCTION):
22721 Redefine DEF_RVV_FUNCTION for XTheadVector special intrinsics.
22722 * config/riscv/riscv-vector-builtins.h
22723 (enum required_ext): Add new XTheadVector member.
22724 (struct function_group_info): Likewise.
22725 * config/riscv/t-riscv:
22726 Add thead-vector-builtins-functions.def
22727 * config/riscv/thead-vector.md
22728 (@pred_mov_width<vlmem_op_attr><mode>): Add new patterns.
22729 (*pred_mov_width<vlmem_op_attr><mode>): Likewise.
22730 (@pred_store_width<vlmem_op_attr><mode>): Likewise.
22731 (@pred_strided_load_width<vlmem_op_attr><mode>): Likewise.
22732 (@pred_strided_store_width<vlmem_op_attr><mode>): Likewise.
22733 (@pred_indexed_load_width<vlmem_op_attr><mode>): Likewise.
22734 (@pred_th_extract<mode>): Likewise.
22735 (*pred_th_extract<mode>): Likewise.
22736 * config/riscv/thead-vector-builtins-functions.def: New file.
22738 2024-01-18 Jun Sha (Joshua) <cooper.joshua@linux.alibaba.com>
22739 Jin Ma <jinma@linux.alibaba.com>
22740 Xianmiao Qu <cooper.qu@linux.alibaba.com>
22741 Christoph Müllner <christoph.muellner@vrull.eu>
22743 * config.gcc: Add files for XTheadVector intrinsics.
22744 * config/riscv/autovec.md: Guard XTheadVector.
22745 * config/riscv/predicates.md: Disable immediate vl
22747 * config/riscv/riscv-c.cc (riscv_pragma_intrinsic):
22748 Add pragma for XTheadVector.
22749 * config/riscv/riscv-string.cc (riscv_expand_block_move):
22750 Guard XTheadVector.
22751 * config/riscv/riscv-v.cc (vls_mode_valid_p):
22753 * config/riscv/riscv-vector-builtins-bases.cc:
22754 Do not normalize vsetvl instructions for XTheadVector.
22755 * config/riscv/riscv-vector-builtins-shapes.cc (check_type):
22756 New check type function.
22757 (build_one): Adjust for XTheadVector.
22758 * config/riscv/riscv-vector-switch.def (ENTRY):
22759 Disable fractional mode for the XTheadVector extension.
22760 (TUPLE_ENTRY): Likewise.
22761 * config/riscv/riscv.cc (riscv_v_adjust_bytesize):
22762 Guard XTheadVector.
22763 (riscv_preferred_simd_mode): Likewsie.
22764 (riscv_autovectorize_vector_modes): Likewise.
22765 (riscv_vector_mode_supported_any_target_p): Likewise.
22766 (TARGET_VECTOR_MODE_SUPPORTED_ANY_TARGET_P): Likewise.
22767 * config/riscv/thead.cc (th_asm_output_opcode):
22768 Rewrite vsetvl instructions.
22769 * config/riscv/vector.md:
22770 Include thead-vector.md and change fractional LMUL
22772 * config/riscv/riscv_th_vector.h: New file.
22773 * config/riscv/thead-vector.md: New file.
22775 2024-01-18 Jun Sha (Joshua) <cooper.joshua@linux.alibaba.com>
22776 Jin Ma <jinma@linux.alibaba.com>
22777 Xianmiao Qu <cooper.qu@linux.alibaba.com>
22778 Christoph Müllner <christoph.muellner@vrull.eu>
22780 * config/riscv/riscv-protos.h (riscv_asm_output_opcode):
22781 Add new function to add assembler insn code prefix/suffix.
22782 (th_asm_output_opcode):
22783 Add Thead function to add assembler insn code prefix/suffix.
22784 * config/riscv/riscv.cc (riscv_asm_output_opcode):
22785 Implement function to add assembler insn code prefix/suffix.
22786 * config/riscv/riscv.h (ASM_OUTPUT_OPCODE):
22787 Add new function to add assembler insn code prefix/suffix.
22788 * config/riscv/thead.cc (th_asm_output_opcode):
22789 Implement Thead function to add assembler insn code
22792 2024-01-18 Jun Sha (Joshua) <cooper.joshua@linux.alibaba.com>
22793 Jin Ma <jinma@linux.alibaba.com>
22794 Xianmiao Qu <cooper.qu@linux.alibaba.com>
22795 Christoph Müllner <christoph.muellner@vrull.eu>
22797 * common/config/riscv/riscv-common.cc
22798 (riscv_subset_list::parse): Add new vendor extension.
22799 * config/riscv/riscv-c.cc (riscv_cpu_cpp_builtins):
22801 * config/riscv/riscv.opt: Add new mask.
22803 2024-01-18 Iain Sandoe <iain@sandoe.co.uk>
22805 * config/darwin.h (DARWIN_RPATH_SPEC): Arrange for the %P spec
22806 to be conditional on macosx-version-min.
22808 2024-01-18 Iain Sandoe <iain@sandoe.co.uk>
22810 * config/darwin.cc (darwin_objc1_section): Use the correct
22811 meta-data version for constant strings.
22812 (machopic_select_section): Assert if we fail to handle CFString
22813 sections as Obejctive-C meta-data or drectly.
22815 2024-01-18 Iain Sandoe <iain@sandoe.co.uk>
22817 * lto-section-names.h (OFFLOAD_SECTION_NAME_PREFIX,
22818 OFFLOAD_VAR_TABLE_SECTION_NAME, OFFLOAD_FUNC_TABLE_SECTION_NAME,
22819 OFFLOAD_IND_FUNC_TABLE_SECTION_NAME): Provide Mach-O syntax
22820 versions when the object format is Mach-O.
22822 2024-01-18 Iain Sandoe <iain@sandoe.co.uk>
22825 * config/darwin.cc (machopic_select_section): Handle C and C++
22827 (darwin_rename_builtins): Move this out of the CFString code.
22828 (darwin_libc_has_function): Likewise.
22829 (darwin_build_constant_cfstring): Create an anonymous var to
22830 hold each CFString.
22831 * config/darwin.h (ASM_OUTPUT_LABELREF): Handle constant
22834 2024-01-18 Maxim Kuvyrkov <maxim.kuvyrkov@linaro.org>
22836 PR bootstrap/113445
22837 * haifa-sched.cc (dep_list_size): Make global.
22838 * sched-deps.cc (find_inc): Use instead of sd_lists_size().
22839 * sched-int.h (dep_list_size): Declare.
22841 2024-01-18 Martin Jambor <mjambor@suse.cz>
22843 PR tree-optimization/110422
22844 * tree-sra.cc (scan_function): Disqualify bases of operands of asm
22847 2024-01-18 Richard Biener <rguenther@suse.de>
22849 PR tree-optimization/113475
22850 * gimple-range-phi.h (phi_analyzer::m_phi_groups): New.
22851 * gimple-range-phi.cc (phi_analyzer::phi_analyzer): Initialize.
22852 (phi_analyzer::~phi_analyzer): Deallocate and free collected
22854 (phi_analyzer::process_phi): Record allocated phi_groups.
22856 2024-01-18 Richard Biener <rguenther@suse.de>
22858 * tree-vect-stmts.cc (vectorizable_store): Do not allocate
22859 storage for gvec_oprnds elements.
22861 2024-01-18 Richard Biener <rguenther@suse.de>
22863 * tree-vect-loop.cc (vec_init_loop_exit_info): Adjust comment,
22864 prefer all later exits we can handle.
22865 (vect_analyze_loop_form): Free the allocated loop body.
22868 2024-01-18 Georg-Johann Lay <avr@gjlay.de>
22870 * config/avr/avr-log.cc: Tabify.
22872 2024-01-18 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22874 * config/riscv/autovec.md: Support vi variant.
22876 2024-01-18 Georg-Johann Lay <avr@gjlay.de>
22878 * config/avr/avr-devices.cc: Tabify.
22880 2024-01-18 Georg-Johann Lay <avr@gjlay.de>
22882 * config/avr/avr-c.cc: Tabify.
22884 2024-01-18 Georg-Johann Lay <avr@gjlay.de>
22886 * config/avr/driver-avr.cc: Tabify.
22888 2024-01-18 Georg-Johann Lay <avr@gjlay.de>
22890 * config/avr/gen-avr-mmcu-texi.cc: Tabify.
22892 2024-01-18 Georg-Johann Lay <avr@gjlay.de>
22894 * config/avr/gen-avr-mmcu-specs.cc: Tabify.
22896 2024-01-18 Jakub Jelinek <jakub@redhat.com>
22898 * config/riscv/riscv.opt (mshorten-memrefs, mrelax, mcsr-check,
22899 minline-strcmp, minline-strncmp, minline-strlen,
22900 -param=riscv-vector-abi): Remove Bool keywords.
22902 2024-01-18 Jakub Jelinek <jakub@redhat.com>
22905 * config/i386/i386.cc (x86_function_profiler): Add -masm=intel
22906 support. Add missing space after , in emitted assembly in some
22907 cases. Formatting fixes.
22909 2024-01-18 Xi Ruoyao <xry111@xry111.site>
22911 * config/loongarch/loongarch.md (movsi_internal): Remove
22914 2024-01-18 Georg-Johann Lay <avr@gjlay.de>
22916 * config/avr/gen-avr-mmcu-specs.cc (diagnose_rodata_in_ram): Fix typo
22917 in the diagnostic, and capitalize the device name.
22918 (print_mcu): Generate specs such that:
22919 <*check_rodata_in_ram>: New.
22920 <*cc1_misc>: Use check_rodata_in_ram instead of cc1_rodata_in_ram.
22921 <*link_misc>: Use check_rodata_in_ram instead of link_rodata_in_ram.
22922 <*cc1_rodata_in_ram, *link_rodata_in_ram>: Remove.
22924 2024-01-18 Jakub Jelinek <jakub@redhat.com>
22927 * common.opt (ffold-mem-offsets): Remove Target and Bool keywords, add
22928 Common and Optimization.
22930 2024-01-18 Richard Biener <rguenther@suse.de>
22932 PR tree-optimization/113431
22933 * tree-vect-data-refs.cc (vect_preserves_scalar_order_p):
22934 When there is an invariant load we might not preserve
22937 2024-01-18 Richard Biener <rguenther@suse.de>
22939 PR tree-optimization/113374
22940 * tree-ssa-operands.h (SET_PHI_ARG_DEF_ON_EDGE): New.
22941 * tree-vect-loop.cc (move_early_exit_stmts): Update
22943 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
22944 Refactor. Preserve virtual LC PHIs on all exits.
22946 2024-01-18 Lulu Cheng <chenglulu@loongson.cn>
22948 * config/loongarch/loongarch.cc (loongarch_split_symbol):
22949 Assign the '/u' attribute to the mem.
22951 2024-01-18 Sandra Loosemore <sandra@codesourcery.com>
22953 PR middle-end/110847
22954 * doc/invoke.texi (Option Summary): Document negative forms of
22955 -Wtsan and -Wxor-used-as-pow.
22956 (Warning Options): Likewise.
22958 2024-01-18 Juzhe-Zhong <juzhe.zhong@rivai.ai>
22961 * config/riscv/riscv-vsetvl.cc (pre_vsetvl::earliest_fuse_vsetvl_info): Fix bug.
22963 2024-01-18 Sandra Loosemore <sandra@codesourcery.com>
22965 * doc/extend.texi (Common Function Attributes): Re-alphabetize
22967 (Common Variable Attributes): Likewise.
22968 (Common Type Attributes): Likewise.
22970 2024-01-17 Sandra Loosemore <sandra@codesourcery.com>
22972 PR middle-end/111659
22973 * doc/extend.texi (Common Variable Attributes): Fix long lines
22974 in documentation of strict_flex_array + other minor copy-editing.
22975 Add a cross-reference to -Wstrict-flex-arrays.
22976 * doc/invoke.texi (Option Summary): Fix whitespace in tables
22977 before -fstrict-flex-arrays and -Wstrict-flex-arrays.
22978 (C Dialect Options): Combine the docs for the two
22979 -fstrict-flex-arrays forms into a single entry. Note this option
22980 is for C/C++ only. Add a cross-reference to -Wstrict-flex-arrays.
22981 (Warning Options): Note -Wstrict-flex-arrays is for C/C++ only.
22982 Minor copy-editing. Add cross references to the strict_flex_array
22983 attribute and -fstrict-flex-arrays option. Add note that this
22984 option depends on -ftree-vrp.
22986 2024-01-17 Andrew Pinski <quic_apinski@quicinc.com>
22989 * config/aarch64/predicates.md (aarch64_ldp_reg_operand): For subreg,
22990 only allow REG operands instead of allowing all.
22992 2024-01-17 Vineet Gupta <vineetg@rivosinc.com>
22994 * config/riscv/riscv-vsetvl.cc (earliest_fuse_vsetvl_info):
22995 Remove redundant checks in else condition for readablity.
22996 (earliest_fuse_vsetvl_info) Print iteration count in debug
22998 (earliest_fuse_vsetvl_info) Fix misleading vsetvl info
22999 dump details in certain cases.
23001 2024-01-17 Vineet Gupta <vineetg@rivosinc.com>
23003 * config/riscv/riscv.opt: New -param=vsetvl-strategy.
23004 * config/riscv/riscv-opts.h: New enum vsetvl_strategy_enum.
23005 * config/riscv/riscv-vsetvl.cc
23006 (pre_vsetvl::pre_global_vsetvl_info): Use vsetvl_strategy.
23007 (pass_vsetvl::execute): Use vsetvl_strategy.
23009 2024-01-17 Jan Hubicka <jh@suse.cz>
23011 * ipa-polymorphic-call.cc (ipa_polymorphic_call_context::set_by_invariant): Remove
23012 accidental hack reseting offset.
23014 2024-01-17 Jan Hubicka <jh@suse.cz>
23016 * config/i386/i386-options.cc (ix86_option_override_internal): Fix
23017 handling of X86_TUNE_AVOID_512FMA_CHAINS.
23019 2024-01-17 Jan Hubicka <jh@suse.cz>
23020 Jakub Jelinek <jakub@redhat.com>
23022 PR tree-optimization/110852
23023 * predict.cc (expr_expected_value_1): Fix profile merging of PHI and
23025 (get_predictor_value): Handle PRED_COMBINED_VALUE_PREDICTIONS and
23026 PRED_COMBINED_VALUE_PREDICTIONS_PHI
23027 * predict.def (PRED_COMBINED_VALUE_PREDICTIONS): New predictor.
23028 (PRED_COMBINED_VALUE_PREDICTIONS_PHI): New predictor.
23030 2024-01-17 Jakub Jelinek <jakub@redhat.com>
23032 PR tree-optimization/113421
23033 * gimple-lower-bitint.cc (stmt_needs_operand_addr): Adjust function
23035 (bitint_dom_walker::before_dom_children): Add g temporary to simplify
23036 formatting. Start at vop rather than cvop even if stmt is a store
23037 and needs_operand_addr.
23039 2024-01-17 Jakub Jelinek <jakub@redhat.com>
23041 PR middle-end/113410
23042 * gimple-ssa-warn-access.cc (pass_waccess::maybe_check_access_sizes):
23043 If access_nelts is integral with larger precision than sizetype,
23044 fold_convert it to sizetype.
23046 2024-01-17 Jakub Jelinek <jakub@redhat.com>
23048 PR tree-optimization/113408
23049 * gimple-lower-bitint.cc (bitint_large_huge::handle_stmt): For
23050 VIEW_CONVERT_EXPR, pass TREE_OPERAND (rhs1, 0) rather than rhs1
23053 2024-01-17 Jakub Jelinek <jakub@redhat.com>
23055 PR middle-end/113406
23056 * ipa-strub.cc (pass_ipa_strub::execute): Check aggregate_value_p
23057 regardless of whether is_gimple_reg_type (restype) or not.
23059 2024-01-17 Jakub Jelinek <jakub@redhat.com>
23061 * tree-into-ssa.cc (pass_build_ssa::gate): Fix comment typo,
23062 funcions -> functions, and use were instead of was.
23063 * gengtype.cc (dump_typekind): Fix comment typos, funcion -> function
23064 and guaranteee -> guarantee.
23065 * attribs.h (struct attr_access): Fix comment typo funcion -> function.
23067 2024-01-17 Jakub Jelinek <jakub@redhat.com>
23069 PR middle-end/113409
23070 * omp-general.cc (omp_adjust_for_condition): Handle BITINT_TYPE like
23072 (omp_extract_for_data): Use build_bitint_type rather than
23073 build_nonstandard_integer_type if either iter_type or loop->v type
23075 * omp-expand.cc (expand_omp_for_generic,
23076 expand_omp_taskloop_for_outer, expand_omp_taskloop_for_inner): Handle
23077 BITINT_TYPE like INTEGER_TYPE.
23079 2024-01-17 Richard Biener <rguenther@suse.de>
23081 PR tree-optimization/113371
23082 * tree-vect-data-refs.cc (vect_enhance_data_refs_alignment):
23083 Do not peel when LOOP_VINFO_EARLY_BREAKS_VECT_PEELED.
23084 * tree-vect-loop-manip.cc (vect_do_peeling): Assert we do
23085 not perform prologue peeling when LOOP_VINFO_EARLY_BREAKS_VECT_PEELED.
23087 2024-01-17 Maxim Kuvyrkov <maxim.kuvyrkov@linaro.org>
23089 PR rtl-optimization/96388
23090 PR rtl-optimization/111554
23091 * sched-deps.cc (find_inc): Avoid exponential behavior.
23093 2024-01-17 Sandra Loosemore <sandra@codesourcery.com>
23096 * doc/invoke.texi (Option Summary): Move -Wuseless-cast
23097 from C++ Language Options to Warning Options. Add entry for
23099 (C++ Dialect Options): Move -Wuse-after-free and -Wuseless-cast
23101 (Warning Options): ...to here. Minor copy-editing to fix typo
23104 2024-01-17 YunQiang Su <syq@gcc.gnu.org>
23106 * config/mips/mips.cc (mips_compute_frame_info): If another
23107 register is used as global_pointer, mark $GP live false.
23109 2024-01-17 Sandra Loosemore <sandra@codesourcery.com>
23112 * doc/extend.texi (BPF Built-in Functions): Wrap long lines and
23113 give the section a light copy-editing pass.
23115 2024-01-16 Wilco Dijkstra <wilco.dijkstra@arm.com>
23117 * config/aarch64/aarch64-cores.def (AARCH64_CORE): Add 'cobalt-100' CPU.
23118 * config/aarch64/aarch64-tune.md: Regenerated.
23119 * doc/invoke.texi (-mcpu): Add cobalt-100 core.
23121 2024-01-16 Wilco Dijkstra <wilco.dijkstra@arm.com>
23124 * config/aarch64/aarch64.cc (aarch64_legitimize_address): Reassociate
23125 badly formed CONST expressions.
23127 2024-01-16 Daniel Cederman <cederman@gaisler.com>
23129 * config/sparc/sparc.cc (next_active_non_empty_insn): Length 0 treated as empty
23131 2024-01-16 Daniel Cederman <cederman@gaisler.com>
23133 * config/sparc/sparc.cc (atomic_insn_for_leon3_p): Treat membar_storeload as atomic
23134 * config/sparc/sync.md (membar_storeload): Turn into named insn
23135 and add GR712RC errata workaround.
23136 (membar_v8): Add GR712RC errata workaround.
23138 2024-01-16 Andreas Larsson <andreas@gaisler.com>
23140 * config/sparc/sync.md (*membar_storeload_leon3): Remove
23141 (*membar_storeload): Enable for LEON
23143 2024-01-16 Jakub Jelinek <jakub@redhat.com>
23145 PR tree-optimization/113372
23146 PR middle-end/90348
23147 PR middle-end/110115
23148 PR middle-end/111422
23149 * cfgexpand.cc (add_scope_conflicts_2): New function.
23150 (add_scope_conflicts_1): Use it.
23152 2024-01-16 Georg-Johann Lay <avr@gjlay.de>
23154 * config/avr/avr-mcus.def (avr16eb14, avr16eb20, avr16eb28, avr16eb32)
23155 (avr16ea28, avr16ea32, avr16ea48, avr32ea28, avr32ea32, avr32ea48): Add.
23156 * doc/avr-mmcu.texi: Regenerate.
23158 2024-01-16 Feng Xue <fxue@os.amperecomputing.com>
23160 PR tree-optimization/113091
23161 * tree-vect-slp.cc (vect_slp_has_scalar_use): New function.
23162 (vect_bb_slp_mark_live_stmts): New parameter scalar_use_map, check
23163 scalar use with new function.
23164 (vect_bb_slp_mark_live_stmts): New function as entry to existing
23165 overriden functions with same name.
23166 (vect_slp_analyze_operations): Call new entry function to mark
23169 2024-01-16 Juzhe-Zhong <juzhe.zhong@rivai.ai>
23172 * config/riscv/riscv.cc (riscv_override_options_internal): Report sorry
23173 for RVV in big-endian mode.
23175 2024-01-16 Yanzhang Wang <yanzhang.wang@intel.com>
23177 * config/riscv/riscv.cc (riscv_arg_has_vector): Delete.
23178 (riscv_pass_in_vector_p): Delete.
23179 (riscv_init_cumulative_args): Delete the checking.
23180 (riscv_get_arg_info): Delete the checking.
23181 (riscv_function_value): Delete the checking.
23182 * config/riscv/riscv.h: Delete the member for checking.
23184 2024-01-15 Georg-Johann Lay <avr@gjlay.de>
23186 * doc/invoke.texi (AVR Options) [-mskip-bug]: Add documentation.
23188 2024-01-15 Liao Shihua <shihua@iscas.ac.cn>
23190 * config.gcc: Include riscv_bitmanip.h.
23191 * config/riscv/bitmanip.md: Changed mode form X to GPR in orcb and clmul pattern.
23192 * config/riscv/crypto.md: Changed mode form X to GPR in brev8 pattern.
23193 * config/riscv/riscv-builtins.cc (AVAIL): Adding new bitmanip builtins.
23194 (RISCV_BUILTIN_NO_PREFIX): New helper macro.
23195 * config/riscv/riscv-cmo.def (RISCV_BUILTIN): Add '_32'/'_64' postfix to builtins.
23196 * config/riscv/riscv-ftypes.def (2): New ftypes.
23197 * config/riscv/riscv-scalar-crypto.def (RISCV_BUILTIN): New builtins.
23198 (RISCV_BUILTIN_NO_PREFIX): Likewise.
23199 * config/riscv/riscv_bitmanip.h: New file.
23201 2024-01-15 Liao Shihua <shihua@iscas.ac.cn>
23203 * config.gcc: Include riscv_crypto.h.
23204 * config/riscv/riscv_crypto.h: New file.
23206 2024-01-15 Vladimir N. Makarov <vmakarov@redhat.com>
23208 PR middle-end/113354
23209 * lra-constraints.cc (curr_insn_transform): Spill pseudo only used
23210 in the insn if the corresponding operand does not require hard
23213 2024-01-15 Georg-Johann Lay <avr@gjlay.de>
23216 * config/avr/avr.h (EXTRA_SPEC_FUNCTIONS): Add no-devlib, avr_no_devlib.
23217 * config/avr/driver-avr.cc (avr_no_devlib): New function.
23218 (avr_devicespecs_file): Use it to remove -nodevicelib from the
23219 options for cores only.
23220 * config/avr/avr-arch.h (avr_get_parch): New prototype.
23221 * config/avr/avr-devices.cc (avr_get_parch): New function.
23223 2024-01-15 Juzhe-Zhong <juzhe.zhong@rivai.ai>
23226 * config/riscv/riscv-protos.h (struct regmove_vector_cost): Add vector to scalar regmove.
23227 * config/riscv/riscv-vector-costs.cc (adjust_stmt_cost): Ditto.
23228 * config/riscv/riscv.cc (riscv_builtin_vectorization_cost): Adjust vec_construct cost.
23230 2024-01-15 Juzhe-Zhong <juzhe.zhong@rivai.ai>
23233 * config/riscv/riscv-vector-costs.cc (costs::adjust_vect_cost_per_loop): New function.
23234 (costs::finish_cost): Adjust cost for LOOP LEN with NITERS < VF.
23235 * config/riscv/riscv-vector-costs.h: New function.
23237 2024-01-15 Richard Biener <rguenther@suse.de>
23239 PR tree-optimization/113385
23240 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
23241 First redirect, then split the exit edge.
23243 2024-01-15 Juzhe-Zhong <juzhe.zhong@rivai.ai>
23245 * config/riscv/riscv-vector-costs.cc (costs::analyze_loop_vinfo):
23246 Remove m_num_vector_iterations.
23247 * config/riscv/riscv-vector-costs.h: Ditto.
23249 2024-01-15 Andrew Pinski <quic_apinski@quicinc.com>
23252 * config/avr/avr.opt (-mdouble, -mlong-double): Add "Save" flag.
23253 (-mbranch-cost): Set "Optimization" flag.
23255 2024-01-15 Jakub Jelinek <jakub@redhat.com>
23257 PR tree-optimization/113370
23258 * gimple-lower-bitint.cc (bitint_large_huge::handle_operand): Only
23259 set rem to prec % (2 * limb_prec) if m_upwards_2limb, otherwise
23260 set it to just prec % limb_prec.
23262 2024-01-15 Juzhe-Zhong <juzhe.zhong@rivai.ai>
23265 * config/riscv/vector.md: Fix ternary attributes.
23267 2024-01-14 Georg-Johann Lay <avr@gjlay.de>
23270 * configure.ac [target=avr]: Check availability of emulations
23271 avrxmega2_flmap and avrxmega4_flmap, resulting in new config vars
23272 HAVE_LD_AVR_AVRXMEGA2_FLMAP and HAVE_LD_AVR_AVRXMEGA4_FLMAP.
23273 * configure: Regenerate.
23274 * config.in: Regenerate.
23275 * doc/invoke.texi (AVR Options): Document -mflmap, -mrodata-in-ram,
23276 __AVR_HAVE_FLMAP__, __AVR_RODATA_IN_RAM__.
23277 * config/avr/avr.opt (-mflmap, -mrodata-in-ram): New options.
23278 * config/avr/avr-arch.h (enum avr_device_specific_features):
23280 * config/avr/avr-mcus.def (AVR_MCU) [avr64*, avr128*]: Set isa flag
23282 * config/avr/avr.cc (avr_arch_index, avr_has_rodata_p): New vars.
23283 (avr_set_core_architecture): Set avr_arch_index.
23284 (have_avrxmega2_flmap, have_avrxmega4_flmap)
23285 (have_avrxmega3_rodata_in_flash): Set new static const bool according
23286 to configure results.
23287 (avr_rodata_in_flash_p): New function using them.
23288 (avr_asm_init_sections): Let readonly_data_section->unnamed.callback
23289 track avr_need_copy_data_p only if not avr_rodata_in_flash_p().
23290 (avr_asm_named_section): Track avr_has_rodata_p.
23291 (avr_file_end): Emit __do_copy_data also when avr_has_rodata_p
23292 and not avr_rodata_in_flash_p ().
23293 * config/avr/specs.h (CC1_SPEC): Add %(cc1_rodata_in_ram).
23294 (LINK_SPEC): Add %(link_rodata_in_ram).
23295 (LINK_ARCH_SPEC): Remove.
23296 * config/avr/gen-avr-mmcu-specs.cc (have_avrxmega3_rodata_in_flash)
23297 (have_avrxmega2_flmap, have_avrxmega4_flmap): Set new static
23298 const bool according to configure results.
23299 (diagnose_mrodata_in_ram): New function.
23300 (print_mcu): Generate specs with the following changes:
23301 <*cc1_misc, *asm_misc, *link_misc>: New specs so that we don't
23302 need to extend avr/specs.h each time we add a new bell or whistle.
23303 <*cc1_rodata_in_ram, *link_rodata_in_ram>: New specs to diagnose
23304 -m[no-]rodata-in-ram.
23305 <*cpp_rodata_in_ram>: New. Does -D__AVR_RODATA_IN_RAM__=0/1.
23306 <*cpp_mcu>: Add -D__AVR_AVR_FLMAP__ if it applies.
23307 <*cpp>: Add %(cpp_rodata_in_ram).
23308 <*link_arch>: Use emulation avrxmega2_flmap, avrxmega4_flmap as
23310 <*self_spec>: Add -mflmap or %<mflmap as needed.
23312 2024-01-14 Jeff Law <jlaw@ventanamicro.com>
23314 * config/mips/mips.md (ior<mode>3_mips16_asmacro): Use SImode,
23315 not the GPR iterator. Adjust pattern name and mode attribute
23318 2024-01-13 Jakub Jelinek <jakub@redhat.com>
23320 PR tree-optimization/113361
23321 * gimple-lower-bitint.cc (bitint_large_huge::handle_operand_addr):
23322 Fix up determination of the type for > limb_prec constants.
23324 2024-01-12 Georg-Johann Lay <avr@gjlay.de>
23326 * doc/extend.texi (AVR Named Address Spaces, Limitations and Caveats):
23327 Add web-link to the avr-gcc wiki.
23329 2024-01-12 Georg-Johann Lay <avr@gjlay.de>
23331 * doc/extend.texi (AVR Variable Attributes) [address]: Remove
23332 documentation for a version without argument, which is not supported.
23334 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23336 * config/arm/arm_neon.h
23337 (vld1_u8_x4, vld1_u16_x4, vld1_u32_x4, vld1_u64_x4): New.
23338 (vld1_s8_x4, vld1_s16_x4, vld1_s32_x4, vld1_s64_x4): New.
23339 (vld1_f16_x4, vld1_f32_x4): New.
23340 (vld1_p8_x4, vld1_p16_x4, vld1_p64_x4): New.
23341 (vld1_bf16_x4): New.
23342 (vld1q_types_x4): Updated to use vld1q_x4
23343 from arm_neon_builtins.def
23344 * config/arm/arm_neon_builtins.def
23345 (vld1_x4): Updated entries.
23346 (vld1q_x4): New entries, but comes from the old vld1_x4
23347 * config/arm/neon.md
23348 (neon_vld1q_x4<mode>): Updated from neon_vld1_x4<mode>.
23350 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23352 * config/arm/arm_neon.h
23353 (vld1_u8_x3, vld1_u16_x3, vld1_u32_x3, vld1_u64_x3): New.
23354 (vld1_s8_x3, vld1_s16_x3, vld1_s32_x3, vld1_s64_x3): New.
23355 (vld1_f16_x3, vld1_f32_x3): New.
23356 (vld1_p8_x3, vld1_p16_x3, vld1_p64_x3): New.
23357 (vld1_bf16_x3): New.
23358 (vld1q_types_x3): Updated to use vld1q_x3 from
23359 arm_neon_builtins.def
23360 * config/arm/arm_neon_builtins.def
23361 (vld1_x3): Updated entries.
23362 (vld1q_x3): New entries, but comes from the old vld1_x2
23363 * config/arm/neon.md
23364 (neon_vld1q_x3<mode>): Updated from neon_vld1_x3<mode>.
23366 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23368 * config/arm/arm_neon.h
23369 (vld1_u8_x2, vld1_u16_x2, vld1_u32_x2, vld1_u64_x2): New.
23370 (vld1_s8_x2, vld1_s16_x2, vld1_s32_x2, vld1_s64_x2): New.
23371 (vld1_f16_x2, vld1_f32_x2): New.
23372 (vld1_p8_x2, vld1_p16_x2, vld1_p64_x2): New.
23373 (vld1_bf16_x2): New.
23374 (vld1q_types_x2): Updated to use vld1q_x2 from
23375 arm_neon_builtins.def
23376 * config/arm/arm_neon_builtins.def
23377 (vld1_x2): Updated entries.
23378 (vld1q_x2): New entries, but comes from the old vld1_x2
23379 * config/arm/neon.md
23380 (neon_vld1<VMEMX2_q>_x2<VDQX:mode>): Updated from
23381 neon_vld1_x2<mode>.
23383 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23385 * config/arm/arm_neon.h
23386 (vst1q_u8_x4, vst1q_u16_x4, vst1q_u32_x4, vst1q_u64_x4): New.
23387 (vst1q_s8_x4, vst1q_s16_x4, vst1q_s32_x4, vst1q_s64_x4): New.
23388 (vst1q_f16_x4, vst1q_f32_x4): New.
23389 (vst1q_p8_x4, vst1q_p16_x4, vst1q_p64_x4): New.
23390 (vst1q_bf16_x4): New.
23391 * config/arm/arm_neon_builtins.def (vst1q_x4): New entries.
23392 * config/arm/neon.md
23393 (neon_vst1q_x4<mode>): New.
23394 (neon_vst1x4qa<mode>, neon_vst1x4qb<mode>): New.
23395 * config/arm/unspecs.md
23396 (UNSPEC_VST1X4A, UNSPEC_VST1X4B): New.
23398 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23400 * config/arm/arm_neon.h
23401 (vst1q_u8_x3, vst1q_u16_x3, vst1q_u32_x3, vst1q_u64_x3): New.
23402 (vst1q_s8_x3, vst1q_s16_x3, vst1q_s32_x3, vst1q_s64_x3): New.
23403 (vst1q_f16_x3, vst1q_f32_x3): New.
23404 (vst1q_p8_x3, vst1q_p16_x3, vst1q_p64_x3): New.
23405 (vst1q_bf16_x3): New.
23406 * config/arm/arm_neon_builtins.def (vst1q_x3): New entries.
23407 * config/arm/neon.md
23408 (neon_vst1q_x3<mode>): New.
23409 (neon_vld1x3qa<mode>, neon_vst1x3qb<mode>): New.
23410 * config/arm/unspecs.md
23411 (UNSPEC_VST1X3A, UNSPEC_VST1X3B): New.
23413 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23415 * config/arm/arm_neon.h
23416 (vst1q_u8_x2, vst1q_u16_x2, vst1q_u32_x2, vst1q_u64_x2): New.
23417 (vst1q_s8_x2, vst1q_s16_x2, vst1q_s32_x2, vst1q_s64_x2): New.
23418 (vst1q_f16_x2, vst1q_f32_x2): New.
23419 (vst1q_p8_x2, vst1q_p16_x2, vst1q_p64_x2): New.
23420 (vst1q_bf16_x2): New.
23421 * config/arm/arm_neon_builtins.def (vst1<_x2): New entries.
23422 * config/arm/neon.md
23423 (neon_vst1<VMEMX2_q>_x2<VDQX:mode>): Updated from
23424 neon_vst1_x2<mode>.
23425 * config/arm/iterators.md
23426 (VMEMX2): New mode iterator.
23427 (VMEMX2_q): New mode attribute.
23429 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23431 * config/arm/arm_neon.h
23432 (vst1_u8_x4, vst1_u16_x4, vst1_u32_x4, vst1_u64_x4): New.
23433 (vst1_s8_x4, vst1_s16_x4, vst1_s32_x4, vst1_s64_x4): New.
23434 (vst1_f16_x4, vst1_f32_x4): New.
23435 (vst1_p8_x4, vst1_p16_x4, vst1_p64_x4): New.
23436 (vst1_bf16_x4): New.
23437 * config/arm/arm_neon_builtins.def (vst1_x4): New entries.
23438 * config/arm/neon.md (vst1_x4<mode>): New.
23440 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23442 * config/arm/arm_neon.h
23443 (vst1_u8_x3, vst1_u16_x3, vst1_u32_x3, vst1_u64_x3): New.
23444 (vst1_s8_x3, vst1_s16_x3, vst1_s32_x3, vst1_s64_x3): New.
23445 (vst1_f16_x3, vst1_f32_x3): New.
23446 (vst1_p8_x3, vst1_p16_x3, vst1_p64_x3): New.
23447 (vst1_bf16_x3): New.
23448 * config/arm/arm_neon_builtins.def (vst1_x3): New entries.
23449 * config/arm/neon.md (vst1_x3<mode>): New.
23451 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23453 * config/arm/arm_neon.h
23454 (vst1_u8_x2, vst1_u16_x2, vst1_u32_x2, vst1_u64_x2): New.
23455 (vst1_s8_x2, vst1_s16_x2, vst1_s32_x2, vst1_s64_x2): New.
23456 (vst1_f16_x2, vst1_f32_x2): New.
23457 (vst1_p8_x2, vst1_p16_x2, vst1_p64_x2): New.
23458 (vst1_bf16_x2): New.
23459 * config/arm/arm_neon_builtins.def (vst1_x2): New entries.
23460 * config/arm/neon.md (vst1_x2<mode>): New.
23462 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23464 * config/arm/arm_neon.h
23465 (vld1q_u8_x4, vld1q_u16_x4, vld1q_u32_x4, vld1q_u64_x4): New.
23466 (vld1q_s8_x4, vld1q_s16_x4, vld1q_s32_x4, vld1q_s64_x4): New.
23467 (vld1q_f16_x4, vld1q_f32_x4): New.
23468 (vld1q_p8_x4, vld1q_p16_x4, vld1q_p64_x4): New.
23469 (vld1q_bf16_x4): New.
23470 * config/arm/arm_neon_builtins.def (vld1_x4): New entries.
23471 * config/arm/neon.md
23472 (neon_vld1_x4<mode>): New.
23473 (neon_vld1x4qa<mode>, neon_vld1x4qb<mode>): New
23474 * config/arm/unspecs.md
23475 (UNSPEC_VLD1X4A, UNSPEC_VLD1X4B): New.
23477 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23479 * config/arm/arm_neon.h
23480 (vld1q_u8_x3, vld1q_u16_x3, vld1q_u32_x3, vld1q_u64_x3): New.
23481 (vld1q_s8_x3, vld1q_s16_x3, vld1q_s32_x3, vld1q_s64_x3): New.
23482 (vld1q_f16_x3, vld1q_f32_x3): New.
23483 (vld1q_p8_x3, vld1q_p16_x3, vld1q_p64_x3): New.
23484 (vld1q_bf16_x3): New.
23485 * config/arm/arm_neon_builtins.def (vld1_x3): New entries.
23486 * config/arm/neon.md
23487 (neon_vld1_x3<mode>): New.
23488 (neon_vld1x3qa<mode>, neon_vld1x3qb<mode>): New.
23489 * config/arm/unspecs.md
23490 (UNSPEC_VLD1X3A, UNSPEC_VLD1X3B): New.
23492 2024-01-12 Ezra Sitorus <ezra.sitorus@arm.com>
23494 * config/arm/arm_neon.h
23495 (vld1q_u8_x2, vld1q_u16_x2, vld1q_u32_x2, vld1q_u64_x2): New.
23496 (vld1q_s8_x2, vld1q_s16_x2, vld1q_s32_x2, vld1q_s64_x2): New.
23497 (vld1q_f16_x2, vld1q_f32_x2): New.
23498 (vld1q_p8_x2, vld1q_p16_x2, vld1q_p64_x2): New.
23499 (vld1q_bf16_x2): New.
23500 * config/arm/arm_neon_builtins.def (vld1_x2): New entries.
23501 * config/arm/neon.md (vld1_x2<mode>): New.
23503 2024-01-12 Tamar Christina <tamar.christina@arm.com>
23505 PR tree-optimization/113287
23506 * doc/sourcebuild.texi (check_effective_target_bitint65535): New.
23508 2024-01-12 Tamar Christina <tamar.christina@arm.com>
23510 * tree-vect-loop-manip.cc (vect_loop_versioning): Replace single_exit.
23511 * tree-vect-loop.cc (vect_transform_loop): Likewise.
23513 2024-01-12 Tamar Christina <tamar.christina@arm.com>
23515 PR tree-optimization/113178
23516 * tree-vect-loop.cc (vect_create_epilog_for_reduction): Fill in all
23519 2024-01-12 Tamar Christina <tamar.christina@arm.com>
23521 PR tree-optimization/113237
23522 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg): Use
23523 existing LCSSA variable for exit when all exits are early break.
23525 2024-01-12 Tamar Christina <tamar.christina@arm.com>
23527 PR tree-optimization/113137
23528 PR tree-optimization/113136
23529 PR tree-optimization/113172
23530 PR tree-optimization/113178
23531 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
23532 Maintain PHIs on inverted loops.
23533 (vect_do_peeling): Maintain virtual PHIs on inverted loops.
23534 * tree-vect-loop.cc (vec_init_loop_exit_info): Pick exit closes to
23536 (vect_create_loop_vinfo): Record all conds instead of only alt ones.
23538 2024-01-12 Tamar Christina <tamar.christina@arm.com>
23540 PR tree-optimization/113135
23541 * tree-vect-data-refs.cc (vect_analyze_early_break_dependences): Rework
23542 dependency analysis.
23544 2024-01-12 Iain Sandoe <iain@sandoe.co.uk>
23546 * config/rs6000/host-darwin.cc (segv_handler): Use the revised
23547 diagnostics class member name for abort of error.
23549 2024-01-12 Georg-Johann Lay <avr@gjlay.de>
23551 * config/avr/avr.cc (avr_handle_addr_attribute): Move "..." from
23552 format string to %s argument.
23554 2024-01-12 John David Anglin <danglin@gcc.gnu.org>
23555 Jakub Jelinek <jakub@redhat.com>
23557 PR middle-end/113182
23558 * varasm.cc (process_pending_assemble_externals,
23559 assemble_external_libcall): Use targetm.strip_name_encoding
23560 before calling get_identifier.
23562 2024-01-12 Richard Sandiford <richard.sandiford@arm.com>
23565 * config/aarch64/aarch64.h (machine_function::advsimd_zero_insn):
23566 New member variable.
23567 * config/aarch64/aarch64-protos.h (aarch64_split_simd_shift_p):
23569 * config/aarch64/iterators.md (Vnarrowq2): New mode attribute.
23570 * config/aarch64/aarch64-simd.md
23571 (vec_unpacku_hi_<mode>, vec_unpacks_hi_<mode>): Recombine into...
23572 (vec_unpack<su>_hi_<mode>): ...this. Move the generation of
23573 zip2 for zero-extends to...
23574 (aarch64_simd_vec_unpack<su>_hi_<mode>): ...a split of this
23575 instruction. Fix big-endian handling.
23576 (vec_unpacku_lo_<mode>, vec_unpacks_lo_<mode>): Recombine into...
23577 (vec_unpack<su>_lo_<mode>): ...this. Move the generation of
23578 zip1 for zero-extends to...
23579 (<optab><Vnarrowq><mode>2): ...a split of this instruction.
23580 Fix big-endian handling.
23581 (*aarch64_zip1_uxtl): New pattern.
23582 (aarch64_usubw<mode>_lo_zip, aarch64_uaddw<mode>_lo_zip): Delete
23583 (aarch64_usubw<mode>_hi_zip, aarch64_uaddw<mode>_hi_zip): Likewise.
23584 * config/aarch64/aarch64.cc (aarch64_get_shareable_reg): New function.
23585 (aarch64_gen_shareable_zero): Use it.
23586 (aarch64_split_simd_shift_p): New function.
23588 2024-01-12 Richard Sandiford <richard.sandiford@arm.com>
23590 * emit-rtl.h (rtl_data::x_function_beg_note): New member variable.
23591 (function_beg_insn): New macro.
23592 * function.cc (expand_function_start): Initialize function_beg_insn.
23594 2024-01-12 Richard Sandiford <richard.sandiford@arm.com>
23597 * config/aarch64/aarch64-sve-builtins.h
23598 (function_builder::m_overload_names): Replace with...
23599 * config/aarch64/aarch64-sve-builtins.cc (overload_names): ...this
23601 (add_overloaded_function): Update accordingly, using get_identifier
23602 to get a GGC-friendly record of the name.
23604 2024-01-12 Richard Sandiford <richard.sandiford@arm.com>
23607 * config/aarch64/aarch64-sve-builtins.def: Don't include
23608 aarch64-sve-builtins-sme.def.
23609 (DEF_SME_ZA_FUNCTION_GS, DEF_SME_ZA_FUNCTION): Move to...
23610 * config/aarch64/aarch64-sve-builtins-sme.def: ...here.
23611 (DEF_SME_FUNCTION): New macro. Use it and DEF_SME_FUNCTION_GS
23612 instead of DEF_SVE_*. Add AARCH64_FL_SME to anything that
23613 requires AARCH64_FL_SME2.
23614 * config/aarch64/aarch64-sve-builtins-sve2.def: Make same
23615 AARCH64_FL_SME adjustment here.
23616 * config/aarch64/aarch64-sve-builtins.cc (function_groups): Don't
23617 include SME intrinsics.
23618 (sme_function_groups): New array.
23619 (handle_arm_sve_h): Remove check for AARCH64_FL_SME.
23620 (handle_arm_sme_h): Use sme_function_groups instead of function_groups.
23622 2024-01-12 Juzhe-Zhong <juzhe.zhong@rivai.ai>
23625 * config/riscv/riscv-protos.h (struct regmove_vector_cost): New struct.
23626 (struct cpu_vector_cost): Add regmove struct.
23627 (get_vector_costs): Export as global.
23628 * config/riscv/riscv-vector-costs.cc (adjust_stmt_cost): Adjust scalar_to_vec cost.
23629 (costs::add_stmt_cost): Ditto.
23630 * config/riscv/riscv.cc (get_common_costs): Export global function.
23632 2024-01-12 Jakub Jelinek <jakub@redhat.com>
23634 PR tree-optimization/113334
23635 * gimple-lower-bitint.cc (bitint_large_huge::handle_operand): Use
23636 wi::neg_p (wi::to_wide (op)) instead of tree_int_cst_sgn (op) < 0
23637 to determine if number should be extended by all ones rather than zero
23640 2024-01-12 Jakub Jelinek <jakub@redhat.com>
23642 PR tree-optimization/113330
23643 * tree-sra.cc (create_access): Punt for BITINT_TYPE accesses with
23646 2024-01-12 Jakub Jelinek <jakub@redhat.com>
23648 PR tree-optimization/113323
23649 * gimple-lower-bitint.cc (bitint_dom_walker::before_dom_children): Fix
23650 check for lhs being large/huge _BitInt not in m_names.
23652 2024-01-12 Jakub Jelinek <jakub@redhat.com>
23654 PR tree-optimization/113316
23655 * gimple-lower-bitint.cc (bitint_large_huge::lower_call): Handle
23656 uninitialized large/huge _BitInt arguments to calls.
23658 2024-01-12 Jakub Jelinek <jakub@redhat.com>
23660 * gimple-lower-bitint.cc (mergeable_op): Instead of comparing
23661 TYPE_SIZE (t) of large/huge BITINT_TYPEs, compare
23662 CEIL (TYPE_PRECISION (t), limb_prec).
23663 (bitint_large_huge::handle_cast): Likewise.
23665 2024-01-12 Ilya Leoshkevich <iii@linux.ibm.com>
23667 PR sanitizer/113284
23668 * config/rs6000/rs6000.cc (rs6000_elf_declare_function_name):
23669 Use assemble_function_label_final () for Power ELF V1 ABI.
23670 * output.h (assemble_function_label_final): New function.
23671 * varasm.cc (assemble_function_label_raw): Use
23672 assemble_function_label_final ().
23673 (assemble_function_label_final): New function.
23675 2024-01-12 Richard Biener <rguenther@suse.de>
23677 PR middle-end/113344
23678 * match.pd ((double)float CMP (double)float -> float CMP float):
23679 Perform result type check only for vectors.
23680 * fold-const.cc (fold_binary_loc): Likewise.
23682 2024-01-12 Haochen Jiang <haochen.jiang@intel.com>
23684 * config/i386/sse.md (sdot_prod<mode>): Remove redundant SET.
23685 (usdot_prod<mode>): Ditto.
23686 (sdot_prod<mode>): Ditto.
23687 (udot_prod<mode>): Ditto.
23689 2024-01-12 Haochen Jiang <haochen.jiang@intel.com>
23692 * config/i386/i386-c.cc (ix86_target_macros_internal):
23693 Add __AVX10_1__, __AVX10_1_256__ and __AVX10_1_512__.
23695 2024-01-12 Richard Biener <rguenther@suse.de>
23698 * config/s390/s390.cc (expand_perm_as_a_vlbr_vstbr_candidate):
23699 Do not generate code when d.testing_p.
23701 2024-01-12 liuhongt <hongtao.liu@intel.com>
23704 * doc/invoke.texi (fcf-protection=): Update documents.
23706 2024-01-12 Pan Li <pan2.li@intel.com>
23708 * config/riscv/riscv.cc (riscv_v_ext_mode_p): Update the
23709 comments of predicate func riscv_v_ext_mode_p.
23711 2024-01-12 Feng Wang <wangfeng@eswincomputing.com>
23713 * config/riscv/riscv-vector-builtins.def (vfloat16m8_t):
23714 Modify ABI-name length of vfloat16m8_t
23716 2024-01-12 Li Wei <liwei@loongson.cn>
23718 * config/loongarch/loongarch.cc (loongarch_expand_conditional_move):
23721 2024-01-12 Li Wei <liwei@loongson.cn>
23723 * config/loongarch/loongarch.md (add<mode>3): Removed.
23727 (*addsi3_extended): Removed.
23728 (addsi3_extended): New.
23730 2024-01-11 Jin Ma <jinma@linux.alibaba.com>
23732 * config/riscv/thead.md: Add limits for splits.
23734 2024-01-11 Andrew Pinski <quic_apinski@quicinc.com>
23736 PR middle-end/113322
23737 * expr.cc (do_store_flag): Don't try single bit tests with
23738 comparison on vector types.
23740 2024-01-11 Andrew Pinski <quic_apinski@quicinc.com>
23742 PR tree-optimization/113301
23743 * match.pd (`1/x`): Delay signed case until late.
23745 2024-01-11 Georg-Johann Lay <avr@gjlay.de>
23747 * doc/invoke.texi (AVR Options): Move -mrmw, -mn-flash, -mshort-calls
23749 (AVR Internal Options): ...this new @subsubsection.
23751 2024-01-11 Vladimir N. Makarov <vmakarov@redhat.com>
23753 PR rtl-optimization/112918
23754 * lra-constraints.cc (SMALL_REGISTER_CLASS_P): Move before in_class_p.
23755 (in_class_p): Restrict condition for narrowing class in case of
23756 allow_all_reload_class_changes_p.
23757 (process_alt_operands): Try to match operand without and with
23758 narrowing reg class. Discourage narrowing the class. Finish insn
23759 matching only if there is no class narrowing.
23760 (curr_insn_transform): Pass true to in_class_p for reg operand win.
23762 2024-01-11 Richard Biener <rguenther@suse.de>
23764 PR tree-optimization/112505
23765 * tree-vect-loop.cc (vectorizable_induction): Reject
23766 bit-precision induction.
23768 2024-01-11 Richard Biener <rguenther@suse.de>
23770 PR tree-optimization/113126
23771 * match.pd ((double)float CMP (double)float -> float CMP float):
23772 Make sure the boolean type is the same.
23773 * fold-const.cc (fold_binary_loc): Likewise.
23775 2024-01-11 Richard Biener <rguenther@suse.de>
23777 PR tree-optimization/112636
23778 * tree-ssa-loop-ch.cc (ch_base::copy_headers): Call
23779 estimate_numbers_of_iterations before querying
23780 get_max_loop_iterations_int.
23781 (pass_ch::execute): Initialize SCEV and loops appropriately.
23783 2024-01-11 Georg-Johann Lay <avr@gjlay.de>
23785 * config/avr/avr-devices.cc (avr_texinfo): Adjust documentation for
23787 * config/avr/gen-avr-mmcu-texi.cc (main): Add @anchor for each core.
23788 * doc/extend.texi (AVR Variable Attributes): Improve documentation
23789 of io, io_low and address attributes.
23790 * doc/invoke.texi (AVR Options): Add some anchors for external refs.
23791 * doc/avr-mmcu.texi: Rebuild.
23793 2024-01-11 Yang Yujie <yangyujie@loongson.cn>
23796 * config/loongarch/genopts/loongarch.opt.in: Mark options with
23797 the "Save" property.
23798 * config/loongarch/loongarch.opt: Same.
23799 * config/loongarch/loongarch-opts.cc: Refresh -mcmodel= state
23800 according to la_target.
23801 * config/loongarch/loongarch.cc: Implement TARGET_OPTION_{SAVE,
23802 RESTORE} for the la_target structure; Rename option conditions
23803 to have the same "la_" prefix.
23804 * config/loongarch/loongarch.h: Same.
23806 2024-01-11 Pan Li <pan2.li@intel.com>
23808 * loop-unroll.cc (insert_var_expansion_initialization): Leverage
23809 MODE_HAS_SIGNED_ZEROS for expansion variable initialization.
23811 2024-01-11 Alex Coplan <alex.coplan@arm.com>
23814 * config/aarch64/aarch64-ldp-fusion.cc (filter_notes): Add
23815 fr_expr param to extract REG_FRAME_RELATED_EXPR notes.
23816 (combine_reg_notes): Handle REG_FRAME_RELATED_EXPR notes, and
23817 synthesize these if needed. Update caller ...
23818 (ldp_bb_info::fuse_pair): ... here.
23819 (ldp_bb_info::try_fuse_pair): Punt if either insn has writeback
23820 and either insn is frame-related.
23821 (find_trailing_add): Punt on frame-related insns.
23822 * config/aarch64/aarch64.cc (aarch64_save_callee_saves): Use
23823 REG_FRAME_RELATED_EXPR instead of REG_CFA_OFFSET.
23825 2024-01-11 YunQiang Su <syq@gcc.gnu.org>
23827 * config/mips/mips.cc (mips_start_function_definition):
23828 Add ATTRIBUTE_UNUSED.
23830 2024-01-11 Richard Biener <rguenther@suse.de>
23832 PR middle-end/112740
23833 * expr.cc (store_constructor): Check the integer vector
23834 mask has a single bit per element before using sign-extension
23835 to expand an uniform vector.
23837 2024-01-11 Juzhe-Zhong <juzhe.zhong@rivai.ai>
23839 * config/riscv/riscv-vector-costs.cc (costs::better_main_loop_than_p): VLA
23840 preempt VLS on unknown NITERS loop.
23842 2024-01-11 Haochen Jiang <haochen.jiang@intel.com>
23844 * doc/invoke.texi: Add -mevex512.
23846 2024-01-11 Lulu Cheng <chenglulu@loongson.cn>
23848 * config/loongarch/loongarch.md (one_cmpl<mode>2): Replace GPR with X.
23849 (*nor<mode>3): Likewise.
23850 (nor<mode>3): Likewise.
23851 (*negsi2_extended): New template.
23852 (*<optab>si3_internal): Likewise.
23853 (*one_cmplsi2_internal): Likewise.
23854 (*norsi3_internal): Likewise.
23855 (*<optab>nsi_internal): Likewise.
23856 (bytepick_w_<bytepick_imm>_extend): Modify this template according to the
23857 modified bit operation to make the optimization work.
23859 2024-01-11 liuhongt <hongtao.liu@intel.com>
23862 * match.pd (VEC_COND_EXPR: A < B ? A : B -> MIN_EXPR): New patten match.
23864 2024-01-10 Juzhe-Zhong <juzhe.zhong@rivai.ai>
23866 * config/riscv/riscv.cc (get_common_costs): Switch RVV cost model.
23867 (get_vector_costs): Ditto.
23868 (riscv_builtin_vectorization_cost): Ditto.
23870 2024-01-10 Juzhe-Zhong <juzhe.zhong@rivai.ai>
23872 * config/riscv/riscv-vector-costs.cc (costs::better_main_loop_than_p): Minior tweak.
23874 2024-01-10 Antoni Boucher <bouanto@zoho.com>
23877 * ipa-fnsummary.cc (ipa_fnsummary_cc_finalize): Call
23878 ipa_free_size_summary.
23879 * ipa-icf.cc (ipa_icf_cc_finalize): New function.
23880 * ipa-profile.cc (ipa_profile_cc_finalize): New function.
23881 * ipa-prop.cc (ipa_prop_cc_finalize): New function.
23882 * ipa-prop.h (ipa_prop_cc_finalize): New function.
23883 * ipa-sra.cc (ipa_sra_cc_finalize): New function.
23884 * ipa-utils.h (ipa_profile_cc_finalize, ipa_icf_cc_finalize,
23885 ipa_sra_cc_finalize): New functions.
23886 * toplev.cc (toplev::finalize): Call ipa_icf_cc_finalize,
23887 ipa_prop_cc_finalize, ipa_profile_cc_finalize and
23888 ipa_sra_cc_finalize
23889 Include ipa-utils.h.
23891 2024-01-10 Jin Ma <jinma@linux.alibaba.com>
23893 * config/riscv/riscv-protos.h (th_int_get_mask): New prototype.
23894 (th_int_get_save_adjustment): Likewise.
23895 (th_int_adjust_cfi_prologue): Likewise.
23896 * config/riscv/riscv.cc (BITSET_P): Moved away from here.
23897 (TH_INT_INTERRUPT): New macro.
23898 (riscv_expand_prologue): Add the processing of XTheadInt.
23899 (riscv_expand_epilogue): Likewise.
23900 * config/riscv/riscv.h (BITSET_P): Moved to here.
23901 * config/riscv/riscv.md: New unspec.
23902 * config/riscv/thead.cc (th_int_get_mask): New function.
23903 (th_int_get_save_adjustment): Likewise.
23904 (th_int_adjust_cfi_prologue): Likewise.
23905 * config/riscv/thead.md (th_int_push): New pattern.
23906 (th_int_pop): new pattern.
23908 2024-01-10 Tamar Christina <tamar.christina@arm.com>
23910 PR tree-optimization/112468
23911 * doc/sourcebuild.texi: Document ifn_copysign.
23912 * match.pd: Only apply transformation if target supports the IFN.
23914 2024-01-10 Andrew Pinski <quic_apinski@quicinc.com>
23916 PR tree-optimization/112581
23917 * gimple-if-to-switch.cc (pass_if_to_switch::execute): Call
23918 mark_ssa_maybe_undefs.
23919 * tree-ssa-reassoc.cc (can_reassociate_op_p): Uninitialized
23920 variables can not be reassociated.
23921 (init_range_entry): Check for uninitialized variables too.
23922 (init_reassoc): Call mark_ssa_maybe_undefs.
23924 2024-01-10 Maciej W. Rozycki <macro@embecosm.com>
23926 * config/riscv/riscv.cc (riscv_noce_conversion_profitable_p):
23927 Also handle sign extension.
23929 2024-01-10 Alex Coplan <alex.coplan@arm.com>
23931 * config/aarch64/aarch64.opt (-mearly-ldp-fusion): Set default
23933 (-mlate-ldp-fusion): Likewise.
23935 2024-01-10 Tamar Christina <tamar.christina@arm.com>
23937 PR tree-optimization/113287
23938 * tree-vect-stmts.cc (vectorizable_early_exit): Check the flags on edge
23939 instead of using BRANCH_EDGE to determine true edge.
23941 2024-01-10 Richard Biener <rguenther@suse.de>
23943 PR tree-optimization/113078
23944 * tree-vect-loop.cc (check_reduction_path): Canonicalize
23945 .COND_SUB to .COND_ADD.
23947 2024-01-10 David Malcolm <dmalcolm@redhat.com>
23949 * gcc-urlifier.cc (gcc_urlifier::get_url_suffix_for_option):
23950 Handle prefix mappings before calling find_opt.
23951 (selftest::gcc_urlifier_cc_tests): Add example of urlifying a
23952 "-fno-"-prefixed command-line option.
23953 * opts-common.cc (get_option_prefix_remapping): New.
23954 * opts.h (get_option_prefix_remapping): New decl.
23956 2024-01-10 David Malcolm <dmalcolm@redhat.com>
23958 * diagnostic.cc (diagnostic_context::report_diagnostic): Pass
23959 m_urlifier to pp_output_formatted_text.
23960 * pretty-print.cc: Add #define of INCLUDE_VECTOR.
23961 (obstack_append_string): New overload, taking a length.
23962 (urlify_quoted_string): Pass in an obstack ptr, rather than using
23963 that of the pp's buffer. Generalize to handle trailing text in
23964 the buffer beyond the run of quoted text.
23965 (class quoting_info): New.
23966 (on_begin_quote): New.
23967 (on_end_quote): New.
23968 (pp_format): Refactor phase 1 and phase 2 quoting support, moving
23969 it to calls to on_begin_quote and on_end_quote.
23970 (struct auto_obstack): New.
23971 (quoting_info::handle_phase_3): New.
23972 (pp_output_formatted_text): Add urlifier param. Use it if there
23973 is deferred urlification. Delete m_quotes.
23974 (selftest::pp_printf_with_urlifier): Pass urlifier to
23975 pp_output_formatted_text.
23976 (selftest::test_urlification): Update results for the existing
23977 case of quoted text stradding chunks; add more such test cases.
23978 * pretty-print.h (class quoting_info): New forward decl.
23979 (chunk_info::m_quotes): New field.
23980 (pp_output_formatted_text): Add optional urlifier param.
23982 2024-01-10 David Malcolm <dmalcolm@redhat.com>
23984 * pretty-print.cc (selftest::test_pp_format): Add selftest
23985 coverage for numbered args.
23987 2024-01-10 Tamar Christina <tamar.christina@arm.com>
23989 PR tree-optimization/113144
23990 PR tree-optimization/113145
23991 * tree-vect-loop-manip.cc (slpeel_tree_duplicate_loop_to_edge_cfg):
23992 Update all BB that the original exits dominated.
23994 2024-01-10 Eric Botcazou <ebotcazou@adacore.com>
23996 * dwarf2out.cc (modified_type_die): Extend the support of reverse
23997 storage order to enumeration types if -gstrict-dwarf is not passed.
23998 (gen_enumeration_type_die): Add REVERSE parameter and generate the
23999 DIE immediately after the existing one if it is true.
24000 (gen_tagged_type_die): Add REVERSE parameter and pass it in the
24001 call to gen_enumeration_type_die.
24002 (gen_type_die_with_usage): Add REVERSE parameter and pass it in the
24003 first recursive call as well as the call to gen_tagged_type_die.
24004 (gen_type_die): Add REVERSE parameter and pass it in the call to
24005 gen_type_die_with_usage.
24007 2024-01-10 Jakub Jelinek <jakub@redhat.com>
24009 PR tree-optimization/113120
24010 * tree-sra.cc (analyze_access_subtree): For BITINT_TYPE
24011 with root->size TYPE_PRECISION don't build anything new.
24012 Otherwise, if root->type is a BITINT_TYPE, use build_bitint_type
24013 rather than build_nonstandard_integer_type.
24015 2024-01-10 Hongyu Wang <hongyu.wang@intel.com>
24017 * config/i386/i386.opt: Adjust document.
24018 * doc/invoke.texi: Add description for
24019 -mapx-inline-asm-use-gpr32.
24021 2024-01-10 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24023 * config/riscv/autovec.md (<u>avg<v_double_trunc>3_floor): Remove.
24024 (avg<v_double_trunc>3_floor): New pattern.
24025 (<u>avg<v_double_trunc>3_ceil): Remove.
24026 (avg<v_double_trunc>3_ceil): New pattern.
24027 (uavg<mode>3_floor): Ditto.
24028 (uavg<mode>3_ceil): Ditto.
24029 * config/riscv/riscv-protos.h (enum insn_flags): Add for average addition.
24030 (enum insn_type): Ditto.
24031 * config/riscv/riscv-v.cc: Ditto.
24032 * config/riscv/vector-iterators.md (ashiftrt): Remove.
24034 * config/riscv/vector.md: Add VLS modes.
24036 2024-01-10 Kewen Lin <linkw@linux.ibm.com>
24039 * config/rs6000/vsx.md (VCZLSBB): New int iterator.
24040 (vczlsbb_char): New int attribute.
24041 (vclzlsbb_<mode>, vctzlsbb_<mode>): Merge to ...
24042 (vc<vczlsbb_char>zlsbb_<mode>): ... this.
24043 (*vctzlsbb_zext_<mode>): Rename to ...
24044 (*vc<vczlsbb_char>zlsbb_zext_<mode>): ... this, and extend it to
24047 2024-01-10 Kewen Lin <linkw@linux.ibm.com>
24050 * config/rs6000/rs6000.md (copysign<mode>3 IEEE128): Change predicate
24051 of the last argument from altivec_register_operand to any_operand. If
24052 operands[2] is CONST_DOUBLE, emit abs or neg abs depending on its sign
24053 otherwise if it doesn't satisfy altivec_register_operand, force it to
24054 REG using copy_to_mode_reg.
24056 2024-01-10 Kewen Lin <linkw@linux.ibm.com>
24058 PR middle-end/113100
24059 * builtins.cc (expand_builtin_stack_address): Guard stack point
24060 adjustment with SPARC_STACK_BOUNDARY_HACK.
24062 2024-01-10 Yang Yujie <yangyujie@loongson.cn>
24064 * config/loongarch/genopts/loongarch-strings: Remove explicit-reloc
24065 argument string definitions.
24066 * config/loongarch/loongarch-str.h: Same.
24067 * config/loongarch/genopts/loongarch.opt.in: Mark -m[no-]explicit-relocs
24068 as aliases to -mexplicit-relocs={always,none}
24069 * config/loongarch/loongarch.opt: Regenerate.
24070 * config/loongarch/loongarch.cc: Same.
24072 2024-01-10 Yang Yujie <yangyujie@loongson.cn>
24074 * config/loongarch/loongarch-def.h: Define constants with
24075 enums instead of Macros.
24077 2024-01-10 Yang Yujie <yangyujie@loongson.cn>
24079 * config/loongarch/genopts/loongarch-strings: Rename.
24080 * config/loongarch/genopts/loongarch.opt.in: Same.
24081 * config/loongarch/loongarch-cpu.cc: Same.
24082 * config/loongarch/loongarch-def.cc: Same.
24083 * config/loongarch/loongarch-def.h: Same.
24084 * config/loongarch/loongarch-opts.cc: Same.
24085 * config/loongarch/loongarch-opts.h: Same.
24086 * config/loongarch/loongarch-str.h: Same.
24087 * config/loongarch/loongarch.opt: Same.
24089 2024-01-10 Yang Yujie <yangyujie@loongson.cn>
24091 * config/loongarch/genopts/genstr.sh: Prepend the isa_evolution
24092 variable with the common la_ prefix.
24093 * config/loongarch/genopts/loongarch.opt.in: Mark ISA evolution
24094 flags as saved using TargetVariable.
24095 * config/loongarch/loongarch.opt: Same.
24096 * config/loongarch/loongarch-def.h: Define evolution_set to
24097 mark changes to the -march default.
24098 * config/loongarch/loongarch-driver.cc: Same.
24099 * config/loongarch/loongarch-opts.cc: Same.
24100 * config/loongarch/loongarch-opts.h: Define and use ISA evolution
24101 conditions around the la_target structure.
24102 * config/loongarch/loongarch.cc: Same.
24103 * config/loongarch/loongarch.md: Same.
24104 * config/loongarch/loongarch-builtins.cc: Same.
24105 * config/loongarch/loongarch-c.cc: Same.
24106 * config/loongarch/lasx.md: Same.
24107 * config/loongarch/lsx.md: Same.
24108 * config/loongarch/sync.md: Same.
24110 2024-01-09 Jeff Law <jlaw@ventanamicro.com>
24112 * config/epiphany/constraints.md (Car): Allow -1024..1023, no more,
24115 2024-01-09 Richard Sandiford <richard.sandiford@arm.com>
24117 * config/mn10300/mn10300.md (subdi3_degenerate): Add isa attribute.
24119 2024-01-09 Tamar Christina <tamar.christina@arm.com>
24121 * tree-vect-loop.cc (vectorizable_live_operation_1): Drop unused
24123 (vectorizable_live_operation): Likewise.
24125 2024-01-09 Tamar Christina <tamar.christina@arm.com>
24127 PR tree-optimization/113199
24128 * tree-vect-loop.cc (vectorizable_live_operation_1): Use
24131 2024-01-09 Jakub Jelinek <jakub@redhat.com>
24134 * config.gcc (aarch64*-*-*): Add aarch64-builtins.h to target_gtfiles.
24135 * config/aarch64/aarch64-builtins.cc (aarch64_simd_types): Add extern
24136 GTY(()) declaration before the definition, drop GTY(()) drom the
24139 2024-01-09 Richard Biener <rguenther@suse.de>
24141 PR tree-optimization/113026
24142 * tree-vect-loop-manip.cc (vect_do_peeling): Remove
24143 redundant and wrong niter bound setting. Move niter
24144 bound adjustment down.
24146 2024-01-09 Tamar Christina <tamar.christina@arm.com>
24148 PR middle-end/113163
24149 * tree-vect-loop-manip.cc (vect_can_peel_nonlinear_iv_p):
24150 Reject non-linear inductions that aren't supported.
24152 2024-01-09 Roger Sayle <roger@nextmovesoftware.com>
24154 * config/arc/arc.cc (arc_shift_alg): New enumerated type for
24155 left shift implementation strategies.
24156 (arc_shift_info): Type for each entry of the shift strategy table.
24157 (arc_shift_context_idx): Return a integer value for each code
24158 generation context, used as an index
24159 (arc_ashl_alg): Table indexed by context and shifted bit count.
24160 (arc_split_ashl): Use the arc_ashl_alg table to select SImode
24161 left shift implementation.
24162 (arc_rtx_costs) <case ASHIFT>: Use the arc_ashl_alg table to
24163 provide accurate costs, when optimizing for speed or size.
24165 2024-01-09 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24167 * config/riscv/riscv-vector-costs.cc (loop_invariant_op_p): Fix loop invariant check.
24169 2024-01-09 Julian Brown <julian@codesourcery.com>
24171 * gimplify.cc (gimplify_expr): Ensure OMP_ARRAY_SECTION has been
24172 processed out before gimplification.
24173 * tree-pretty-print.cc (dump_generic_node): Support OMP_ARRAY_SECTION.
24174 * tree.def (OMP_ARRAY_SECTION): New tree code.
24176 2024-01-09 Jakub Jelinek <jakub@redhat.com>
24178 PR tree-optimization/113210
24179 * tree-vect-loop.cc (vect_get_loop_niters): If non-INTEGER_CST
24180 value in *number_of_iterationsm1 PLUS_EXPR 1 is folded into
24181 INTEGER_CST, recompute *number_of_iterationsm1 as the INTEGER_CST
24184 2024-01-09 Eric Botcazou <ebotcazou@adacore.com>
24186 PR rtl-optimization/113140
24187 * reorg.cc (fill_slots_from_thread): If we are to branch after the
24188 last instruction of the function, create an end label.
24190 2024-01-09 Roger Sayle <roger@nextmovesoftware.com>
24191 Hongtao Liu <hongtao.liu@intel.com>
24194 * config/i386/i386-expand.cc
24195 (ix86_convert_const_wide_int_to_broadcast): Allow call to
24196 ix86_expand_vector_init_duplicate to fail, and return NULL_RTX.
24197 (ix86_broadcast_from_constant): Revert recent change; Return a
24198 suitable MEMREF independently of mode/target combinations.
24199 (ix86_expand_vector_move): Allow ix86_expand_vector_init_duplicate
24200 to decide whether expansion is possible/preferrable. Only try
24201 forcing DImode constants to memory (and trying again) if calling
24202 ix86_expand_vector_init_duplicate fails with an DImode immediate
24204 (ix86_expand_vector_init_duplicate) <case E_V2DImode>: Try using
24205 V4SImode for suitable immediate constants.
24206 <case E_V4DImode>: Try using V8SImode for suitable constants.
24207 <case E_V4HImode>: Fail for CONST_INT_P, i.e. use constant pool.
24208 <case E_V2HImode>: Likewise.
24209 <case E_V8HImode>: For CONST_INT_P try using V4SImode via widen.
24210 <case E_V16QImode>: For CONT_INT_P try using V8HImode via widen.
24211 <label widen>: Handle CONT_INTs via simplify_binary_operation.
24212 Allow recursive calls to ix86_expand_vector_init_duplicate to fail.
24213 <case E_V16HImode>: For CONST_INT_P try V8SImode via widen.
24214 <case E_V32QImode>: For CONST_INT_P try V16HImode via widen.
24215 (ix86_expand_vector_init): Move try using a broadcast for all_same
24216 with ix86_expand_vector_init_duplicate before using constant pool.
24218 2024-01-09 Chung-Ju Wu <jasonwucj@gmail.com>
24220 * doc/invoke.texi (Arm Options): Document Cortex-M52 options.
24222 2024-01-09 Chung-Ju Wu <jasonwucj@gmail.com>
24224 * config/arm/arm-cpus.in (cortex-m52): New cpu.
24225 * config/arm/arm-tables.opt: Regenerate.
24226 * config/arm/arm-tune.md: Regenerate.
24228 2024-01-09 Jiahao Xu <xujiahao@loongson.cn>
24230 * config/loongarch/lasx.md (vec_initv32qiv16qi): Rename to ..
24231 (vec_init<mode><lasxhalf>): .. this, and extend to mode.
24232 (@vec_concatz<mode>): New insn pattern.
24233 * config/loongarch/loongarch.cc (loongarch_expand_vector_group_init):
24234 Handle VALS containing two vectors.
24236 2024-01-09 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24238 * config/riscv/riscv-vector-builtins-functions.def (vleff): Move comments.
24239 (vundefined): Ditto.
24241 2024-01-09 Feng Wang <wangfeng@eswincomputing.com>
24243 * config/riscv/riscv-vector-builtins-bases.cc (class vandn):
24244 Add new function_base for crypto vector.
24245 (class bitmanip): Ditto.
24246 (class b_reverse):Ditto.
24247 (class vwsll): Ditto.
24248 (class clmul): Ditto.
24249 (class vg_nhab): Ditto.
24250 (class crypto_vv):Ditto.
24251 (class crypto_vi):Ditto.
24252 (class vaeskf2_vsm3c):Ditto.
24253 (class vsm3me): Ditto.
24254 (BASE): Add BASE declaration for crypto vector.
24255 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24256 * config/riscv/riscv-vector-builtins-functions.def (REQUIRED_EXTENSIONS):
24257 Add crypto vector intrinsic definition.
24285 * config/riscv/riscv-vector-builtins-shapes.cc (struct crypto_vv_def):
24286 Add new function_shape for crypto vector.
24287 (struct crypto_vi_def): Ditto.
24288 (struct crypto_vv_no_op_type_def): Ditto.
24289 (SHAPE): Add SHAPE declaration of crypto vector.
24290 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
24291 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_CRYPTO_SEW32_OPS):
24292 Add new data type for crypto vector.
24293 (DEF_RVV_CRYPTO_SEW64_OPS): Ditto.
24294 (vuint32mf2_t): Ditto.
24295 (vuint32m1_t): Ditto.
24296 (vuint32m2_t): Ditto.
24297 (vuint32m4_t): Ditto.
24298 (vuint32m8_t): Ditto.
24299 (vuint64m1_t): Ditto.
24300 (vuint64m2_t): Ditto.
24301 (vuint64m4_t): Ditto.
24302 (vuint64m8_t): Ditto.
24303 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_CRYPTO_SEW32_OPS):
24304 Add new data struct for crypto vector.
24305 (DEF_RVV_CRYPTO_SEW64_OPS): Ditto.
24306 (registered_function::overloaded_hash): Processing size_t uimm for C overloaded func.
24307 * config/riscv/riscv-vector-builtins.def (vi): Add vi OP_TYPE.
24309 2024-01-08 Ilya Leoshkevich <iii@linux.ibm.com>
24311 PR sanitizer/113251
24312 * varasm.cc (assemble_function_label_raw): Do not call
24313 asan_function_start () without the current function.
24315 2024-01-08 Cupertino Miranda <cupertino.miranda@oracle.com>
24318 * btfout.cc (btf_collect_datasec): Skip creating BTF info for
24319 extern and kernel_helper attributed function decls.
24321 2024-01-08 Cupertino Miranda <cupertino.miranda@oracle.com>
24323 * btfout.cc (output_btf_strs): Changed.
24325 2024-01-08 Tobias Burnus <tobias@codesourcery.com>
24327 * config/gcn/mkoffload.cc (main): Handle gfx1100
24328 when setting the default XNACK.
24330 2024-01-08 Tobias Burnus <tobias@codesourcery.com>
24332 * config.gcc (amdgcn-*-amdhsa): Accept --with-arch=gfx1100.
24333 * config/gcn/gcn-hsa.h (NO_XNACK): Add gfx1100:
24334 (ASM_SPEC): Handle gfx1100.
24335 * config/gcn/gcn-opts.h (enum processor_type): Add PROCESSOR_GFX1100.
24336 (enum gcn_isa): Add ISA_RDNA3.
24337 (TARGET_GFX1100, TARGET_RDNA2_PLUS, TARGET_RDNA3): Define.
24338 * config/gcn/gcn-valu.md: Change TARGET_RDNA2 to TARGET_RDNA2_PLUS.
24339 * config/gcn/gcn.cc (gcn_option_override,
24340 gcn_omp_device_kind_arch_isa, output_file_start): Handle gfx1100.
24341 (gcn_global_address_p, gcn_addr_space_legitimate_address_p): Change
24342 TARGET_RDNA2 to TARGET_RDNA2_PLUS.
24343 (gcn_hsa_declare_function_name): Don't use '.amdhsa_reserve_flat_scratch'
24345 * config/gcn/gcn.h (ASSEMBLER_DIALECT): Likewise.
24346 (TARGET_CPU_CPP_BUILTINS): Define __RDNA3__, __gfx1030__ and
24348 * config/gcn/gcn.md: Change TARGET_RDNA2 to TARGET_RDNA2_PLUS.
24349 * config/gcn/gcn.opt (Enum gpu_type): Add gfx1100.
24350 * config/gcn/mkoffload.cc (EF_AMDGPU_MACH_AMDGCN_GFX1100): Define.
24351 (isa_has_combined_avgprs, main): Handle gfx1100.
24352 * config/gcn/t-omp-device (isa): Add gfx1100.
24354 2024-01-08 Richard Biener <rguenther@suse.de>
24356 * doc/invoke.texi (-mmovbe): Clarify.
24358 2024-01-08 Richard Biener <rguenther@suse.de>
24360 PR tree-optimization/113026
24361 * tree-vect-loop.cc (vect_need_peeling_or_partial_vectors_p):
24362 Avoid an epilog in more cases.
24363 * tree-vect-loop-manip.cc (vect_do_peeling): Adjust the
24364 epilogues niter upper bounds and estimates.
24366 2024-01-08 Jakub Jelinek <jakub@redhat.com>
24368 PR tree-optimization/113228
24369 * gimplify.cc (recalculate_side_effects): Do nothing for SSA_NAMEs.
24371 2024-01-08 Jakub Jelinek <jakub@redhat.com>
24373 PR tree-optimization/113120
24374 * gimple-lower-bitint.cc (gimple_lower_bitint): Fix handling of very
24375 large _BitInt zero INTEGER_CST PHI argument.
24377 2024-01-08 Jakub Jelinek <jakub@redhat.com>
24379 PR tree-optimization/113119
24380 * gimple-lower-bitint.cc (optimizable_arith_overflow): Punt if
24381 both REALPART_EXPR and cast from IMAGPART_EXPR appear, but cast
24382 is before REALPART_EXPR.
24384 2024-01-08 Georg-Johann Lay <avr@gjlay.de>
24387 * config/avr/avr.cc (avr_handle_addr_attribute): Also print valid
24388 range when diagnosing attribute "io" and "io_low" are out of range.
24389 (avr_eval_addr_attrib): Don't ICE on empty address at that place.
24390 (avr_insert_attributes): Reject if attribute "address", "io" or "io_low"
24391 in contexts other than static storage.
24392 (avr_asm_output_aligned_decl_common): Move output of decls with
24393 attribute "address", "io", and "io_low" to...
24394 (avr_output_addr_attrib): ...this new function.
24395 (avr_asm_asm_output_aligned_bss): Remove output for decls with
24396 attribute "address", "io", and "io_low".
24397 (avr_encode_section_info): Rectify handling of decls with attribute
24398 "address", "io", and "io_low".
24400 2024-01-08 Andrew Stubbs <ams@codesourcery.com>
24402 * config/gcn/mkoffload.cc (TEST_XNACK_UNSET): New.
24403 (elf_flags): Remove XNACK from the default value.
24404 (main): Set a default XNACK according to the arch.
24406 2024-01-08 Andrew Stubbs <ams@codesourcery.com>
24408 * config/gcn/mkoffload.cc (isa_has_combined_avgprs): Delete.
24409 (process_asm): Don't count avgprs.
24411 2024-01-08 Hongyu Wang <hongyu.wang@intel.com>
24413 * config/i386/i386.opt: Add supported sub-features.
24414 * doc/extend.texi: Add description for target attribute.
24416 2024-01-08 Feng Wang <wangfeng@eswincomputing.com>
24418 * config/riscv/vector.md: Modify avl_type operand index of zvbc ins.
24420 2024-01-07 Roger Sayle <roger@nextmovesoftware.com>
24421 Uros Bizjak <ubizjak@gmail.com>
24424 * config/i386/i386-features.cc (compute_convert_gain): Include
24425 the overhead of explicit load and store (movd) instructions when
24426 converting non-store scalar operations with memory destinations.
24427 Various indentation whitespace fixes.
24429 2024-01-07 Tamar Christina <tamar.christina@arm.com>
24431 * config/arm/neon.md (cbranch<mode>4): New.
24433 2024-01-07 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24435 * config/riscv/riscv-vsetvl.cc: replace std::max by MAX.
24437 2024-01-06 Jiahao Xu <xujiahao@loongson.cn>
24439 * config/loongarch/lasx.md: Set the unused bits in operand[3] to 0.
24441 2024-01-06 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24444 * config/riscv/riscv-vsetvl.cc (pre_vsetvl::fuse_local_vsetvl_info):
24445 Update the MAX_SEW.
24447 2024-01-06 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24449 * config/riscv/riscv-vector-costs.cc (loop_invariant_op_p): New function.
24450 (variable_vectorized_p): Teach loop invariant.
24451 (has_unexpected_spills_p): Ditto.
24453 2024-01-06 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24455 * config/riscv/riscv-protos.h (whole_reg_to_reg_move_p): New function.
24456 * config/riscv/riscv-v.cc (whole_reg_to_reg_move_p): Ditto.
24457 * config/riscv/vector.md: Allow non-vlmax with len = NUNITS simplification.
24459 2024-01-05 Richard Sandiford <richard.sandiford@arm.com>
24462 * doc/invoke.texi (aarch64-sve-compare-costs): Replace with...
24463 (aarch64-vect-compare-costs): ...this.
24464 * config/aarch64/aarch64.opt (-param=aarch64-sve-compare-costs=):
24466 (-param=aarch64-vect-compare-costs=): ...this new param.
24467 * config/aarch64/aarch64.cc (aarch64_override_options_internal):
24468 Don't disable it when vectorizing for Advanced SIMD only.
24469 (aarch64_autovectorize_vector_modes): Apply VECT_COMPARE_COSTS
24470 whenever aarch64_vect_compare_costs is true.
24472 2024-01-05 Lulu Cheng <chenglulu@loongson.cn>
24474 * config/loongarch/lasx.md (lasx_mxld_<lasxfmt_f>):
24475 Modify the method of determining the memory offset of [x]vld/[x]vst.
24476 (lasx_mxst_<lasxfmt_f>): Likewise.
24477 * config/loongarch/loongarch.cc (loongarch_valid_offset_p): Delete.
24478 (loongarch_address_insns): Likewise.
24479 * config/loongarch/lsx.md (lsx_ld_<lsxfmt_f>): Likewise.
24480 (lsx_st_<lsxfmt_f>): Likewise.
24481 * config/loongarch/predicates.md (aq10b_operand): Likewise.
24482 (aq10h_operand): Likewise.
24483 (aq10w_operand): Likewise.
24484 (aq10d_operand): Likewise.
24486 2024-01-05 Alex Coplan <alex.coplan@arm.com>
24489 * config/aarch64/aarch64-ldp-fusion.cc
24490 (ldp_bb_info::try_fuse_pair): If the second access can throw,
24491 narrow the move range to exactly that insn.
24493 2024-01-05 Ilya Leoshkevich <iii@linux.ibm.com>
24495 * asan.cc (asan_function_start): Drop switch_to_section ().
24496 (asan_emit_stack_protection): Set .LASANPC alignment.
24497 * config/i386/i386.cc: Use assemble_function_label_raw ()
24498 instead of ASM_OUTPUT_LABEL ().
24499 * config/s390/s390.cc (s390_asm_output_function_label):
24501 * defaults.h (ASM_OUTPUT_FUNCTION_LABEL): Likewise.
24502 * final.cc (final_start_function_1): Drop
24503 asan_function_start ().
24504 * output.h (assemble_function_label_raw): New function.
24505 * varasm.cc (assemble_function_label_raw): Likewise.
24507 2024-01-05 Ilya Leoshkevich <iii@linux.ibm.com>
24509 * config/aarch64/aarch64.cc (aarch64_declare_function_name):
24510 Use ASM_OUTPUT_FUNCTION_LABEL ().
24511 * config/alpha/alpha.cc (alpha_start_function): Likewise.
24512 * config/arm/aout.h (ASM_DECLARE_FUNCTION_NAME): Likewise.
24513 * config/arm/arm.cc (arm_asm_declare_function_name): Likewise.
24514 * config/bfin/bfin.h (ASM_DECLARE_FUNCTION_NAME): Likewise.
24515 * config/c6x/c6x.h (ASM_DECLARE_FUNCTION_NAME): Likewise.
24516 * config/gcn/gcn.cc (gcn_hsa_declare_function_name): Likewise.
24517 * config/h8300/h8300.h (ASM_DECLARE_FUNCTION_NAME): Likewise.
24518 * config/ia64/ia64.cc (ia64_start_function): Likewise.
24519 * config/mcore/mcore-elf.h (ASM_DECLARE_FUNCTION_NAME):
24521 * config/microblaze/microblaze.cc (microblaze_function_prologue):
24523 * config/mips/mips.cc (mips_start_unique_function): Return the
24525 (mips_start_function_definition): Use
24526 ASM_OUTPUT_FUNCTION_LABEL ().
24527 (mips_finish_stub): Pass the tree to
24528 mips_start_function_definition ().
24529 (mips16_build_function_stub): Likewise.
24530 (mips16_build_call_stub): Likewise.
24531 (mips_output_function_prologue): Likewise.
24532 * config/pa/pa.cc (pa_output_function_label): Use
24533 ASM_OUTPUT_FUNCTION_LABEL ().
24534 * config/riscv/riscv.cc (riscv_declare_function_name): Likewise.
24535 * config/rs6000/rs6000.cc (rs6000_elf_declare_function_name):
24537 (rs6000_xcoff_declare_function_name): Likewise.
24539 2024-01-05 Jakub Jelinek <jakub@redhat.com>
24541 PR tree-optimization/113201
24542 * tree-scalar-evolution.cc (final_value_replacement_loop): Don't call
24543 replace_uses_by on SSA_NAME_OCCURS_IN_ABNORMAL_PHI rslt.
24545 2024-01-05 Jakub Jelinek <jakub@redhat.com>
24547 PR tree-optimization/90693
24548 * tree-ssa-math-opts.cc (match_single_bit_test): If
24549 tree_expr_nonzero_p (arg), remember it in the second argument to
24550 IFN_POPCOUNT or lower it as arg & (arg - 1) == 0 rather than
24551 arg ^ (arg - 1) > arg - 1.
24552 * internal-fn.cc (expand_POPCOUNT): If second argument to
24553 IFN_POPCOUNT suggests arg is non-zero, try to expand it as
24554 arg & (arg - 1) == 0 rather than arg ^ (arg - 1) > arg - 1.
24556 2024-01-05 Kito Cheng <kito.cheng@sifive.com>
24558 * config/riscv/riscv-v.cc (expand_load_store):
24560 (expand_cond_len_op): Ditto.
24561 (expand_gather_scatter): Ditto.
24562 (expand_lanes_load_store): Ditto.
24563 (expand_fold_extract_last): Ditto.
24565 2024-01-05 Pan Li <pan2.li@intel.com>
24568 2024-01-05 Feng Wang <wangfeng@eswincomputing.com>
24570 * config/riscv/riscv-vector-builtins-bases.cc (class vandn):
24571 Add new function_base for crypto vector.
24572 (class bitmanip): Ditto.
24573 (class b_reverse):Ditto.
24574 (class vwsll): Ditto.
24575 (class clmul): Ditto.
24576 (class vg_nhab): Ditto.
24577 (class crypto_vv):Ditto.
24578 (class crypto_vi):Ditto.
24579 (class vaeskf2_vsm3c):Ditto.
24580 (class vsm3me): Ditto.
24581 (BASE): Add BASE declaration for crypto vector.
24582 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24583 * config/riscv/riscv-vector-builtins-functions.def (REQUIRED_EXTENSIONS):
24584 Add crypto vector intrinsic definition.
24612 * config/riscv/riscv-vector-builtins-shapes.cc (struct crypto_vv_def):
24613 Add new function_shape for crypto vector.
24614 (struct crypto_vi_def): Ditto.
24615 (struct crypto_vv_no_op_type_def): Ditto.
24616 (SHAPE): Add SHAPE declaration of crypto vector.
24617 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
24618 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_CRYPTO_SEW32_OPS):
24619 Add new data type for crypto vector.
24620 (DEF_RVV_CRYPTO_SEW64_OPS): Ditto.
24621 (vuint32mf2_t): Ditto.
24622 (vuint32m1_t): Ditto.
24623 (vuint32m2_t): Ditto.
24624 (vuint32m4_t): Ditto.
24625 (vuint32m8_t): Ditto.
24626 (vuint64m1_t): Ditto.
24627 (vuint64m2_t): Ditto.
24628 (vuint64m4_t): Ditto.
24629 (vuint64m8_t): Ditto.
24630 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_CRYPTO_SEW32_OPS):
24631 Add new data struct for crypto vector.
24632 (DEF_RVV_CRYPTO_SEW64_OPS): Ditto.
24633 (registered_function::overloaded_hash): Processing size_t uimm for C overloaded func.
24634 * config/riscv/riscv-vector-builtins.def (vi): Add vi OP_TYPE.
24636 2024-01-05 Feng Wang <wangfeng@eswincomputing.com>
24638 * config/riscv/riscv-vector-builtins-bases.cc (class vandn):
24639 Add new function_base for crypto vector.
24640 (class bitmanip): Ditto.
24641 (class b_reverse):Ditto.
24642 (class vwsll): Ditto.
24643 (class clmul): Ditto.
24644 (class vg_nhab): Ditto.
24645 (class crypto_vv):Ditto.
24646 (class crypto_vi):Ditto.
24647 (class vaeskf2_vsm3c):Ditto.
24648 (class vsm3me): Ditto.
24649 (BASE): Add BASE declaration for crypto vector.
24650 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
24651 * config/riscv/riscv-vector-builtins-functions.def (REQUIRED_EXTENSIONS):
24652 Add crypto vector intrinsic definition.
24680 * config/riscv/riscv-vector-builtins-shapes.cc (struct crypto_vv_def):
24681 Add new function_shape for crypto vector.
24682 (struct crypto_vi_def): Ditto.
24683 (struct crypto_vv_no_op_type_def): Ditto.
24684 (SHAPE): Add SHAPE declaration of crypto vector.
24685 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
24686 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_CRYPTO_SEW32_OPS):
24687 Add new data type for crypto vector.
24688 (DEF_RVV_CRYPTO_SEW64_OPS): Ditto.
24689 (vuint32mf2_t): Ditto.
24690 (vuint32m1_t): Ditto.
24691 (vuint32m2_t): Ditto.
24692 (vuint32m4_t): Ditto.
24693 (vuint32m8_t): Ditto.
24694 (vuint64m1_t): Ditto.
24695 (vuint64m2_t): Ditto.
24696 (vuint64m4_t): Ditto.
24697 (vuint64m8_t): Ditto.
24698 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_CRYPTO_SEW32_OPS):
24699 Add new data struct for crypto vector.
24700 (DEF_RVV_CRYPTO_SEW64_OPS): Ditto.
24701 (registered_function::overloaded_hash): Processing size_t uimm for C overloaded func.
24702 * config/riscv/riscv-vector-builtins.def (vi): Add vi OP_TYPE.
24704 2024-01-04 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24706 * config/riscv/riscv-vector-costs.cc (variable_vectorized_p): Teach vi variant.
24708 2024-01-04 Andrew Pinski <quic_apinski@quicinc.com>
24710 PR tree-optimization/113186
24711 * gimple-match-head.cc (gimple_bitwise_inverted_equal_p):
24712 Match `^` with the `==` for 1bit integral types.
24713 * match.pd (maybe_cmp): Allow for bit_xor for 1bit
24716 2024-01-04 David Malcolm <dmalcolm@redhat.com>
24718 * toplev.cc (general_init): Pass lang_mask to urlifier.
24720 2024-01-04 David Malcolm <dmalcolm@redhat.com>
24722 * diagnostic.h (diagnostic_make_option_url_cb): Add lang_mask
24724 (diagnostic_context::make_option_url): Update for lang_mask param.
24725 * gcc-urlifier.cc: Include "opts.h" and "options.h".
24726 (gcc_urlifier::gcc_urlifier): Add lang_mask param.
24727 (gcc_urlifier::m_lang_mask): New field.
24728 (doc_urls): Make static.
24729 (gcc_urlifier::get_url_for_quoted_text): Use label_text.
24730 (gcc_urlifier::get_url_suffix_for_quoted_text): Use label_text.
24731 Look for an option by name before trying a binary search in
24733 (gcc_urlifier::get_url_suffix_for_quoted_text): Use label_text.
24734 (gcc_urlifier::get_url_suffix_for_option): New.
24735 (make_gcc_urlifier): Add lang_mask param.
24736 (selftest::gcc_urlifier_cc_tests): Update for above changes.
24737 Verify that a URL is found for "-fpack-struct".
24738 * gcc-urlifier.def: Drop options "--version" and "-fpack-struct".
24739 * gcc-urlifier.h (make_gcc_urlifier): Add lang_mask param.
24740 * gcc.cc (driver::global_initializations): Pass 0 for lang_mask
24741 to make_gcc_urlifier.
24742 * opts-diagnostic.h (get_option_url): Add lang_mask param.
24743 * opts.cc (get_option_html_page): Remove special-casing for
24745 (get_option_url_suffix): New.
24746 (get_option_url): Reimplement.
24747 (selftest::test_get_option_html_page): Rename to...
24748 (selftest::test_get_option_url_suffix): ...this and update for
24750 (selftest::opts_cc_tests): Update for renaming.
24751 * opts.h: Include "rich-location.h".
24752 (get_option_url_suffix): New decl.
24754 2024-01-04 David Malcolm <dmalcolm@redhat.com>
24756 * Makefile.in (ALL_OPT_URL_FILES): New.
24757 (GCC_OBJS): Add options-urls.o.
24759 (OBJS-libcommon): Likewise.
24760 (s-options): Depend on $(ALL_OPT_URL_FILES), and add this to
24761 inputs to opt-gather.awk.
24762 (options-urls.cc): New Makefile target.
24763 * opt-functions.awk (url_suffix): New function.
24764 (lang_url_suffix): New function.
24765 * options-urls-cc-gen.awk: New file.
24766 * opts.h (get_opt_url_suffix): New decl.
24768 2024-01-04 David Malcolm <dmalcolm@redhat.com>
24770 * params.opt.urls: New file, autogenerated by
24771 regenerate-opt-urls.py.
24773 2024-01-04 David Malcolm <dmalcolm@redhat.com>
24775 * common.opt.urls: New file, autogenerated by
24776 regenerate-opt-urls.py.
24777 * config/aarch64/aarch64.opt.urls: Likewise.
24778 * config/alpha/alpha.opt.urls: Likewise.
24779 * config/alpha/elf.opt.urls: Likewise.
24780 * config/arc/arc-tables.opt.urls: Likewise.
24781 * config/arc/arc.opt.urls: Likewise.
24782 * config/arm/arm-tables.opt.urls: Likewise.
24783 * config/arm/arm.opt.urls: Likewise.
24784 * config/arm/vxworks.opt.urls: Likewise.
24785 * config/avr/avr.opt.urls: Likewise.
24786 * config/bpf/bpf.opt.urls: Likewise.
24787 * config/c6x/c6x-tables.opt.urls: Likewise.
24788 * config/c6x/c6x.opt.urls: Likewise.
24789 * config/cris/cris.opt.urls: Likewise.
24790 * config/cris/elf.opt.urls: Likewise.
24791 * config/csky/csky.opt.urls: Likewise.
24792 * config/csky/csky_tables.opt.urls: Likewise.
24793 * config/darwin.opt.urls: Likewise.
24794 * config/dragonfly.opt.urls: Likewise.
24795 * config/epiphany/epiphany.opt.urls: Likewise.
24796 * config/fr30/fr30.opt.urls: Likewise.
24797 * config/freebsd.opt.urls: Likewise.
24798 * config/frv/frv.opt.urls: Likewise.
24799 * config/ft32/ft32.opt.urls: Likewise.
24800 * config/fused-madd.opt.urls: Likewise.
24801 * config/g.opt.urls: Likewise.
24802 * config/gcn/gcn.opt.urls: Likewise.
24803 * config/gnu-user.opt.urls: Likewise.
24804 * config/h8300/h8300.opt.urls: Likewise.
24805 * config/hpux11.opt.urls: Likewise.
24806 * config/i386/cygming.opt.urls: Likewise.
24807 * config/i386/cygwin.opt.urls: Likewise.
24808 * config/i386/djgpp.opt.urls: Likewise.
24809 * config/i386/i386.opt.urls: Likewise.
24810 * config/i386/mingw-w64.opt.urls: Likewise.
24811 * config/i386/mingw.opt.urls: Likewise.
24812 * config/i386/nto.opt.urls: Likewise.
24813 * config/ia64/ia64.opt.urls: Likewise.
24814 * config/ia64/ilp32.opt.urls: Likewise.
24815 * config/ia64/vms.opt.urls: Likewise.
24816 * config/iq2000/iq2000.opt.urls: Likewise.
24817 * config/linux-android.opt.urls: Likewise.
24818 * config/linux.opt.urls: Likewise.
24819 * config/lm32/lm32.opt.urls: Likewise.
24820 * config/loongarch/loongarch.opt.urls: Likewise.
24821 * config/lynx.opt.urls: Likewise.
24822 * config/m32c/m32c.opt.urls: Likewise.
24823 * config/m32r/m32r.opt.urls: Likewise.
24824 * config/m68k/ieee.opt.urls: Likewise.
24825 * config/m68k/m68k-tables.opt.urls: Likewise.
24826 * config/m68k/m68k.opt.urls: Likewise.
24827 * config/m68k/uclinux.opt.urls: Likewise.
24828 * config/mcore/mcore.opt.urls: Likewise.
24829 * config/microblaze/microblaze.opt.urls: Likewise.
24830 * config/mips/mips-tables.opt.urls: Likewise.
24831 * config/mips/mips.opt.urls: Likewise.
24832 * config/mips/sde.opt.urls: Likewise.
24833 * config/mmix/mmix.opt.urls: Likewise.
24834 * config/mn10300/mn10300.opt.urls: Likewise.
24835 * config/moxie/moxie.opt.urls: Likewise.
24836 * config/msp430/msp430.opt.urls: Likewise.
24837 * config/nds32/nds32-elf.opt.urls: Likewise.
24838 * config/nds32/nds32-linux.opt.urls: Likewise.
24839 * config/nds32/nds32.opt.urls: Likewise.
24840 * config/netbsd-elf.opt.urls: Likewise.
24841 * config/netbsd.opt.urls: Likewise.
24842 * config/nios2/elf.opt.urls: Likewise.
24843 * config/nios2/nios2.opt.urls: Likewise.
24844 * config/nvptx/nvptx-gen.opt.urls: Likewise.
24845 * config/nvptx/nvptx.opt.urls: Likewise.
24846 * config/openbsd.opt.urls: Likewise.
24847 * config/or1k/elf.opt.urls: Likewise.
24848 * config/or1k/or1k.opt.urls: Likewise.
24849 * config/pa/pa-hpux.opt.urls: Likewise.
24850 * config/pa/pa-hpux1010.opt.urls: Likewise.
24851 * config/pa/pa-hpux1111.opt.urls: Likewise.
24852 * config/pa/pa-hpux1131.opt.urls: Likewise.
24853 * config/pa/pa.opt.urls: Likewise.
24854 * config/pa/pa64-hpux.opt.urls: Likewise.
24855 * config/pdp11/pdp11.opt.urls: Likewise.
24856 * config/pru/pru.opt.urls: Likewise.
24857 * config/riscv/riscv.opt.urls: Likewise.
24858 * config/rl78/rl78.opt.urls: Likewise.
24859 * config/rpath.opt.urls: Likewise.
24860 * config/rs6000/476.opt.urls: Likewise.
24861 * config/rs6000/aix64.opt.urls: Likewise.
24862 * config/rs6000/darwin.opt.urls: Likewise.
24863 * config/rs6000/linux64.opt.urls: Likewise.
24864 * config/rs6000/rs6000-tables.opt.urls: Likewise.
24865 * config/rs6000/rs6000.opt.urls: Likewise.
24866 * config/rs6000/sysv4.opt.urls: Likewise.
24867 * config/rtems.opt.urls: Likewise.
24868 * config/rx/elf.opt.urls: Likewise.
24869 * config/rx/rx.opt.urls: Likewise.
24870 * config/s390/s390.opt.urls: Likewise.
24871 * config/s390/tpf.opt.urls: Likewise.
24872 * config/sh/sh.opt.urls: Likewise.
24873 * config/sh/superh.opt.urls: Likewise.
24874 * config/sol2.opt.urls: Likewise.
24875 * config/sparc/long-double-switch.opt.urls: Likewise.
24876 * config/sparc/sparc.opt.urls: Likewise.
24877 * config/stormy16/stormy16.opt.urls: Likewise.
24878 * config/v850/v850.opt.urls: Likewise.
24879 * config/vax/elf.opt.urls: Likewise.
24880 * config/vax/vax.opt.urls: Likewise.
24881 * config/visium/visium.opt.urls: Likewise.
24882 * config/vms/vms.opt.urls: Likewise.
24883 * config/vxworks-smp.opt.urls: Likewise.
24884 * config/vxworks.opt.urls: Likewise.
24885 * config/xtensa/elf.opt.urls: Likewise.
24886 * config/xtensa/uclinux.opt.urls: Likewise.
24887 * config/xtensa/xtensa.opt.urls: Likewise.
24888 * config/bfin/bfin.opt.urls: New file.
24890 2024-01-04 David Malcolm <dmalcolm@redhat.com>
24892 * Makefile.in (OPT_URLS_HTML_DEPS): New.
24893 (regenerate-opt-urls): New target.
24894 (regenerate-opt-urls-unit-test): New target.
24895 * doc/options.texi (Option properties): Add UrlSuffix and
24896 description of regenerate-opt-urls.py. Add LangUrlSuffix_*.
24897 * doc/sourcebuild.texi (Anatomy of a Language Front End): Add
24898 reference to regenerate-opt-urls.py's PER_LANGUAGE_OPTION_INDEXES
24899 and Makefile.in's OPT_URLS_HTML_DEPS.
24900 (Anatomy of a Target Back End): Add
24901 reference to regenerate-opt-urls.py's TARGET_SPECIFIC_PAGES.
24902 * regenerate-opt-urls.py: New file.
24904 2024-01-04 David Malcolm <dmalcolm@redhat.com>
24906 * diagnostic-format-sarif.cc
24907 (sarif_builder::make_logical_location_object): Convert to...
24908 (make_sarif_logical_location_object): ...this.
24909 (sarif_builder::set_any_logical_locs_arr): Update for above
24911 (sarif_builder::make_thread_flow_location_object): Call
24912 maybe_add_sarif_properties on each diagnostic_event.
24913 * diagnostic-format-sarif.h (class logical_location): New forward
24915 (make_sarif_logical_location_object): New decl.
24916 * diagnostic-path.h (class sarif_object): New forward decl.
24917 (diagnostic_event::maybe_add_sarif_properties): New vfunc.
24919 2024-01-04 Kuan-Lin Chen <rufus@andestech.com>
24920 Patrick Lin <patrick@andestech.com>
24921 Rufus Chen <rufus@andestech.com>
24922 Monk Chiang <monk.chiang@sifive.com>
24924 * config/riscv/riscv.cc (riscv_legitimize_move): Expand movfh
24925 with Nan-boxing value.
24926 * config/riscv/riscv.md (*movhf_softfloat_unspec): New pattern.
24928 2024-01-04 Roger Sayle <roger@nextmovesoftware.com>
24929 Jeff Law <jlaw@ventanamicro.com>
24931 PR rtl-optimization/104914
24932 * expr.cc (expand_assignment): When target is SUBREG_PROMOTED_VAR_P
24933 a sign or zero extension is only required if the modified field
24934 overlaps the SUBREG's most significant bit. On MODE_REP_EXTENDED
24935 targets, don't refer to the temporarily incorrectly extended value
24936 using a SUBREG, but instead generate an explicit TRUNCATE rtx.
24938 2024-01-04 Pan Li <pan2.li@intel.com>
24941 2024-01-04 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24943 * config/riscv/riscv-vector-costs.cc (variable_vectorized_p): Teach vi variant.
24945 2024-01-04 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24947 * config/riscv/riscv-vector-costs.cc (variable_vectorized_p): Teach vi variant.
24949 2024-01-04 Kito Cheng <kito.cheng@sifive.com>
24951 * config/riscv/riscv.cc (riscv_for_each_saved_reg): Adjust the
24954 2024-01-04 Juzhe-Zhong <juzhe.zhong@rivai.ai>
24956 * config/riscv/riscv-vector-costs.cc (variable_vectorized_p): New function.
24957 (compute_nregs_for_mode): Refine LMUL.
24958 (max_number_of_live_regs): Ditto.
24959 (compute_estimated_lmul): Ditto.
24960 (has_unexpected_spills_p): Ditto.
24962 2024-01-04 Li Wei <liwei@loongson.cn>
24964 * config/loongarch/loongarch.cc (loongarch_is_odd_extraction):
24965 Remove useless forward declaration.
24966 (loongarch_is_even_extraction): Remove useless forward declaration.
24967 (loongarch_try_expand_lsx_vshuf_const): Removed.
24968 (loongarch_expand_vec_perm_const_1): Merged.
24969 (loongarch_is_double_duplicate): Removed.
24970 (loongarch_is_center_extraction): Ditto.
24971 (loongarch_is_reversing_permutation): Ditto.
24972 (loongarch_is_di_misalign_extract): Ditto.
24973 (loongarch_is_si_misalign_extract): Ditto.
24974 (loongarch_is_lasx_lowpart_extract): Ditto.
24975 (loongarch_is_op_reverse_perm): Ditto.
24976 (loongarch_is_single_op_perm): Ditto.
24977 (loongarch_is_divisible_perm): Ditto.
24978 (loongarch_is_triple_stride_extract): Ditto.
24979 (loongarch_expand_vec_perm_const_2): Merged.
24980 (loongarch_expand_vec_perm_const): New.
24981 (loongarch_vectorize_vec_perm_const): Adjust.
24983 2024-01-04 Sandra Loosemore <sandra@codesourcery.com>
24985 * omp-general.cc: Fix comment typos and misplaced/confusing
24986 comments. Delete redundant include of omp-general.h.
24988 2024-01-04 YunQiang Su <syq@gcc.gnu.org>
24990 PR rtl-optimization/104914
24991 * config/mips/mips.md (insqisi_extended): New patterns.
24992 (inshisi_extended): Ditto.
24994 2024-01-04 YunQiang Su <syq@gcc.gnu.org>
24996 * config/mips/mips.cc (mips_insn_cost): New function.
24998 2024-01-04 YunQiang Su <syq@gcc.gnu.org>
25000 * config/mips/mips.md (perf_ratio): New attribute.
25002 2024-01-04 Juzhe-Zhong <juzhe.zhong@rivai.ai>
25006 * config/riscv/riscv-vsetvl.cc (invalid_opt_bb_p): New function.
25007 (pre_vsetvl::compute_lcm_local_properties): Disable earliest fusion on
25008 blocks belong to infinite loop.
25009 (pre_vsetvl::emit_vsetvl): Remove fake edges.
25010 * config/riscv/t-riscv: Add a new include file.
25012 2024-01-04 Juzhe-Zhong <juzhe.zhong@rivai.ai>
25014 * config/riscv/vector.md: Fix indent.
25016 2024-01-03 Kwok Cheung Yeung <kcy@codesourcery.com>
25018 * tree-core.h (enum omp_clause_code): Move OMP_CLAUSE_INDIRECT to before
25019 OMP_CLAUSE__SIMDUID_.
25020 * tree.cc (omp_clause_num_ops): Update position of entry for
25021 OMP_CLAUSE_INDIRECT to correspond with omp_clause_code.
25022 (omp_clause_code_name): Likewise.
25024 2024-01-03 Kwok Cheung Yeung <kcy@codesourcery.com>
25026 * config/nvptx/nvptx.cc (nvptx_record_offload_symbol): Restucture
25027 printing of FUNC_MAP/IND_FUNC_MAP labels.
25029 2024-01-03 Jakub Jelinek <jakub@redhat.com>
25031 * gcc.cc (process_command): Update copyright notice dates.
25032 * gcov-dump.cc (print_version): Ditto.
25033 * gcov.cc (print_version): Ditto.
25034 * gcov-tool.cc (print_version): Ditto.
25035 * gengtype.cc (create_file): Ditto.
25036 * doc/cpp.texi: Bump @copying's copyright year.
25037 * doc/cppinternals.texi: Ditto.
25038 * doc/gcc.texi: Ditto.
25039 * doc/gccint.texi: Ditto.
25040 * doc/gcov.texi: Ditto.
25041 * doc/install.texi: Ditto.
25042 * doc/invoke.texi: Ditto.
25044 2024-01-03 Xi Ruoyao <xry111@xry111.site>
25046 * config/loongarch/simd.md (fmax<mode>3): New define_insn.
25047 (fmin<mode>3): Likewise.
25048 (reduc_fmax_scal_<mode>3): New define_expand.
25049 (reduc_fmin_scal_<mode>3): Likewise.
25051 2024-01-03 Juzhe-Zhong <juzhe.zhong@rivai.ai>
25054 * config/riscv/riscv-vector-costs.cc (compute_nregs_for_mode): Add rgroup info.
25055 (max_number_of_live_regs): Ditto.
25056 (has_unexpected_spills_p): Ditto.
25058 2024-01-02 Jun Sha (Joshua) <cooper.joshua@linux.alibaba.com>
25059 Jin Ma <jinma@linux.alibaba.com>
25060 Xianmiao Qu <cooper.qu@linux.alibaba.com>
25061 Christoph Müllner <christoph.muellner@vrull.eu>
25063 * config/riscv/vector.md:
25064 Use vector_length_operand for vsetvl patterns.
25066 2024-01-02 Juzhe-Zhong <juzhe.zhong@rivai.ai>
25068 * config/riscv/riscv-v.cc (is_vlmax_len_p): Remove satisfies_constraint_K.
25069 (expand_cond_len_op): Add simplification of dummy len and dummy mask.
25071 2024-01-02 Di Zhao <dizhao@os.amperecomputing.com>
25073 * config/aarch64/aarch64-tuning-flags.def
25074 (AARCH64_EXTRA_TUNING_OPTION): New tuning option
25075 AARCH64_EXTRA_TUNE_FULLY_PIPELINED_FMA.
25076 * config/aarch64/aarch64.cc
25077 (aarch64_override_options_internal): Set
25078 param_fully_pipelined_fma according to tuning option.
25079 * config/aarch64/tuning_models/ampere1.h: Add
25080 AARCH64_EXTRA_TUNE_FULLY_PIPELINED_FMA to tune_flags.
25081 * config/aarch64/tuning_models/ampere1a.h: Likewise.
25082 * config/aarch64/tuning_models/ampere1b.h: Likewise.
25084 2024-01-02 Feng Wang <wangfeng@eswincomputing.com>
25086 * config/riscv/vector-crypto.md: Modify copyright year.
25088 2024-01-02 Juzhe-Zhong <juzhe.zhong@rivai.ai>
25090 * config/riscv/riscv-vector-costs.cc: Move STMT_VINFO_TYPE (...) to local.
25092 2024-01-02 Lulu Cheng <chenglulu@loongson.cn>
25094 * config.in: Regenerate.
25095 * config/loongarch/loongarch-opts.h (HAVE_AS_TLS_LE_RELAXATION): Define.
25096 * config/loongarch/loongarch.cc (loongarch_legitimize_tls_address):
25097 Added TLS Le Relax support.
25098 (loongarch_print_operand_reloc): Add the output string of TLS Le Relax.
25099 * config/loongarch/loongarch.md (@add_tls_le_relax<mode>): New template.
25100 * configure: Regenerate.
25101 * configure.ac: Check if binutils supports TLS le relax.
25103 2024-01-02 Feng Wang <wangfeng@eswincomputing.com>
25105 * config/riscv/iterators.md: Add rotate insn name.
25106 * config/riscv/riscv.md: Add new insns name for crypto vector.
25107 * config/riscv/vector-iterators.md: Add new iterators for crypto vector.
25108 * config/riscv/vector.md: Add the corresponding attr for crypto vector.
25109 * config/riscv/vector-crypto.md: New file.The machine descriptions for crypto vector.
25111 2024-01-02 Juzhe-Zhong <juzhe.zhong@rivai.ai>
25114 * config/riscv/riscv-vector-costs.cc (compute_nregs_for_mode): Fix
25115 pointer type liveness count.
25117 Copyright (C) 2024 Free Software Foundation, Inc.
25119 Copying and distribution of this file, with or without modification,
25120 are permitted in any medium without royalty provided the copyright
25121 notice and this notice are preserved.