1 2023-03-30 Andrew MacLeod <amacleod@redhat.com>
3 PR tree-optimization/109154
4 * gimple-range-gori.cc (gori_compute::may_recompute_p): Add depth limit.
5 * gimple-range-gori.h (may_recompute_p): Add depth param.
6 * params.opt (ranger-recompute-depth): New param.
8 2023-03-30 Jason Merrill <jason@redhat.com>
12 * cgraph.h: Move reset() from cgraph_node to symtab_node.
13 * cgraphunit.cc (symtab_node::reset): Adjust. Also call
14 remove_from_same_comdat_group.
16 2023-03-30 Richard Biener <rguenther@suse.de>
18 PR tree-optimization/107561
19 * gimple-ssa-warn-access.cc (get_size_range): Add flags
20 argument and pass it on.
21 (check_access): When querying for the size range pass
22 SR_ALLOW_ZERO when the known destination size is zero.
24 2023-03-30 Richard Biener <rguenther@suse.de>
26 PR tree-optimization/109342
27 * tree-ssa-sccvn.cc (vn_nary_op_get_predicated_value): New
28 overload for edge. When that edge is a backedge use
29 dominated_by_p directly.
31 2023-03-30 liuhongt <hongtao.liu@intel.com>
33 * config/i386/i386-expand.cc (expand_vec_perm_blend): Generate
34 vpblendd instead of vpblendw for V4SI under avx2.
36 2023-03-29 Hans-Peter Nilsson <hp@axis.com>
38 * config/cris/cris.cc (cris_rtx_costs) [CONST_INT]: Return 0
39 for many quick operands, for register-sized modes.
41 2023-03-29 Jiawei <jiawei@iscas.ac.cn>
43 * common/config/riscv/riscv-common.cc (riscv_subset_list::parse):
46 2023-03-29 Martin Liska <mliska@suse.cz>
49 * configure.ac: Emit a warning for deprecated option
51 * configure: Regenerate.
53 2023-03-29 Richard Biener <rguenther@suse.de>
55 PR tree-optimization/109331
56 * tree-ssa-forwprop.cc (pass_forwprop::execute): When we
57 discover a taken edge make sure to cleanup the CFG.
59 2023-03-29 Richard Biener <rguenther@suse.de>
61 PR tree-optimization/109327
62 * tree-ssa-forwprop.cc (pass_forwprop::execute): Deal with
63 already removed stmts when draining to_remove.
65 2023-03-29 Richard Biener <rguenther@suse.de>
68 * dwarf2out.cc (lookup_type_die): Reset TREE_ASM_WRITTEN
69 so we can re-create the DIE for the type if required.
71 2023-03-29 Jakub Jelinek <jakub@redhat.com>
72 Richard Biener <rguenther@suse.de>
74 PR tree-optimization/109301
75 * tree-ssa-math-opts.cc (pass_data_cse_sincos): Change
76 properties_provided from PROP_gimple_opt_math to 0.
77 (pass_data_expand_powcabs): Change properties_provided from 0 to
80 2023-03-29 Richard Biener <rguenther@suse.de>
82 PR tree-optimization/109154
83 * tree-if-conv.cc (gen_phi_arg_condition): Handle single
84 inverted condition specially by inverting at the caller.
85 (gen_phi_arg_condition): Swap COND_EXPR arms if requested.
87 2023-03-28 David Malcolm <dmalcolm@redhat.com>
90 * diagnostic-show-locus.cc (column_range::column_range): Factor
91 out assertion conditional into...
92 (column_range::valid_p): ...this new function.
93 (line_corrections::add_hint): Don't attempt to consolidate hints
94 if it would lead to invalid column_range instances.
96 2023-03-28 Kito Cheng <kito.cheng@sifive.com>
99 * config/riscv/riscv-c.cc (riscv_ext_version_value): New.
100 (riscv_cpu_cpp_builtins): Define __riscv_v_intrinsic and
103 2023-03-28 Alexander Monakov <amonakov@ispras.ru>
105 PR rtl-optimization/109187
106 * haifa-sched.cc (autopref_rank_for_schedule): Avoid use of overflowing
107 subtraction in three-way comparison.
109 2023-03-28 Andrew MacLeod <amacleod@redhat.com>
111 PR tree-optimization/109265
112 PR tree-optimization/109274
113 * gimple-range-gori.cc (gori_compute::compute_operand_range): Do
114 not create a relation record is op1 and op2 are the same symbol.
115 (gori_compute::compute_operand1_range): Pass op1 == op2 to the
116 handler for this stmt, but create a new record only if this statement
117 generates a relation based on the ranges.
118 (gori_compute::compute_operand2_range): Ditto.
119 * value-relation.h (value_relation::set_relation): Always create the
120 record that is requested.
122 2023-03-28 Richard Biener <rguenther@suse.de>
124 PR tree-optimization/107087
125 * tree-ssa-forwprop.cc (pass_forwprop::execute): Track
126 executable regions to avoid useless work and to better
127 propagate degenerate PHIs.
129 2023-03-28 Costas Argyris <costas.argyris@gmail.com>
131 * config/i386/x-mingw32-utf8: update comments.
133 2023-03-28 Richard Sandiford <richard.sandiford@arm.com>
136 * config/aarch64/aarch64-protos.h (aarch64_vector_load_decl): Declare.
137 * config/aarch64/aarch64.h (machine_function::vector_load_decls): New
139 * config/aarch64/aarch64-builtins.cc (aarch64_record_vector_load_arg):
141 (aarch64_general_gimple_fold_builtin): Delay folding of vld1 until
142 after inlining. Record which decls are loaded from. Fix handling
143 of vops for loads and stores.
144 * config/aarch64/aarch64.cc (aarch64_vector_load_decl): New function.
145 (aarch64_accesses_vector_load_decl_p): Likewise.
146 (aarch64_vector_costs::m_stores_to_vector_load_decl): New member
148 (aarch64_vector_costs::add_stmt_cost): If the function has a vld1
149 that loads from a decl, treat vector stores to those decls as
151 (aarch64_vector_costs::finish_cost): ...and in that case,
152 if the vector code does nothing more than a store, give the
153 prologue a zero cost as well.
155 2023-03-28 Richard Biener <rguenther@suse.de>
158 PR tree-optimization/108129
159 * genmatch.cc (lower_for): For (match ...) delay
160 substituting into the match operator if possible.
161 (dt_operand::gen_gimple_expr): For user_id look at the
162 first substitute for determining how to access operands.
163 (dt_operand::gen_generic_expr): Likewise.
164 (dt_node::gen_kids): Properly sort user_ids according
165 to their substitutes.
166 (dt_node::gen_kids_1): Code-generate user_id matching.
168 2023-03-28 Jakub Jelinek <jakub@redhat.com>
169 Jonathan Wakely <jwakely@redhat.com>
171 * gcov-tool.cc (do_merge, do_merge_stream, do_rewrite, do_overlap):
172 Use subcommand rather than sub-command in function comments.
174 2023-03-28 Jakub Jelinek <jakub@redhat.com>
176 PR tree-optimization/109154
177 * value-range.h (frange::flush_denormals_to_zero): Make it public
179 * value-range.cc (frange::set): Don't call flush_denormals_to_zero
181 * range-op-float.cc (range_operator_float::fold_range): Call
182 flush_denormals_to_zero.
184 2023-03-28 Jakub Jelinek <jakub@redhat.com>
187 * sanopt.cc (pass_sanopt::execute): Return TODO_cleanup_cfg if any
188 of the IFN_{UB,HWA,A}SAN_* internal fns are lowered.
190 2023-03-28 Jakub Jelinek <jakub@redhat.com>
192 * range-op-float.cc (float_widen_lhs_range): Use pass get_nan_state
193 as 4th argument to set to avoid clear_nan and union_ calls.
195 2023-03-28 Jakub Jelinek <jakub@redhat.com>
198 * config/i386/i386.cc (assign_386_stack_local): For DImode
199 with SLOT_FLOATxFDI_387 and -m32 -mpreferred-stack-boundary=2 pass
200 align 32 rather than 0 to assign_stack_local.
202 2023-03-28 Eric Botcazou <ebotcazou@adacore.com>
205 * config/sparc/sparc.cc (sparc_expand_vcond): Call signed_condition
206 on operand #3 to get the final condition code. Use std::swap.
207 * config/sparc/sparc.md (vcondv8qiv8qi): New VIS 4 expander.
208 (fucmp<gcond:code>8<P:mode>_vis): Move around.
209 (fpcmpu<gcond:code><GCM:gcm_name><P:mode>_vis): Likewise.
210 (vcondu<GCM:mode><GCM:mode>): New VIS 4 expander.
212 2023-03-28 Eric Botcazou <ebotcazou@adacore.com>
214 * doc/gm2.texi: Add missing Next, Previous and Top fields to most
217 2023-03-28 Costas Argyris <costas.argyris@gmail.com>
219 * config.host: Pull in i386/x-mingw32-utf8 Makefile
220 fragment and reference utf8rc-mingw32.o explicitly
222 * config/i386/sym-mingw32.cc: prevent name mangling of
224 * config/i386/x-mingw32-utf8: Make utf8rc-mingw32.o
225 depend on manifest file explicitly.
227 2023-03-28 Richard Biener <rguenther@suse.de>
230 2023-03-27 Richard Biener <rguenther@suse.de>
232 PR rtl-optimization/109237
233 * cfgcleanup.cc (bb_is_just_return): Walk insns backwards.
235 2023-03-28 Richard Biener <rguenther@suse.de>
237 * common.opt (gdwarf): Remove Negative(gdwarf-).
239 2023-03-28 Richard Biener <rguenther@suse.de>
241 * common.opt (gdwarf): Add RejectNegative.
246 2023-03-28 Hans-Peter Nilsson <hp@axis.com>
248 * config/cris/constraints.md ("T"): Correct to
249 define_memory_constraint.
251 2023-03-28 Hans-Peter Nilsson <hp@axis.com>
253 * config/cris/cris.md (BW2): New mode-iterator.
254 (lra_szext_decomposed, lra_szext_decomposed_indirect_with_offset): New
257 2023-03-28 Hans-Peter Nilsson <hp@axis.com>
259 * config/cris/cris.md ("*add<mode>3_addi"): Improve to bail only
260 for possible eliminable compares.
262 2023-03-28 Hans-Peter Nilsson <hp@axis.com>
264 * config/cris/constraints.md ("R"): Remove unused constraint.
266 2023-03-27 Jonathan Wakely <jwakely@redhat.com>
268 PR gcov-profile/109297
269 * gcov-tool.cc (merge_usage): Fix "subcomand" typo.
270 (merge_stream_usage): Likewise.
271 (overlap_usage): Likewise.
273 2023-03-27 Christoph Müllner <christoph.muellner@vrull.eu>
276 * config/riscv/thead.md: Add missing mode specifiers.
278 2023-03-27 Philipp Tomsich <philipp.tomsich@vrull.eu>
279 Jiangning Liu <jiangning.liu@amperecomputing.com>
280 Manolis Tsamis <manolis.tsamis@vrull.eu>
282 * config/aarch64/aarch64.cc: Update vector costs for ampere1.
284 2023-03-27 Richard Biener <rguenther@suse.de>
286 PR rtl-optimization/109237
287 * cfgcleanup.cc (bb_is_just_return): Walk insns backwards.
289 2023-03-27 Richard Biener <rguenther@suse.de>
292 * lto-wrapper.cc (run_gcc): Parse alternate debug options
293 as well, they always enable debug.
295 2023-03-27 Kewen Lin <linkw@linux.ibm.com>
298 * config/rs6000/emmintrin.h (_mm_bslli_si128): Move the implementation
300 (_mm_slli_si128): ... here. Change to call _mm_bslli_si128 directly.
302 2023-03-27 Kewen Lin <linkw@linux.ibm.com>
305 * config/rs6000/emmintrin.h (_mm_bslli_si128): Check __N is not less
306 than zero when calling vec_sld.
307 (_mm_bsrli_si128): Return __A if __N is zero, check __N is bigger than
308 zero when calling vec_sld.
309 (_mm_slli_si128): Return __A if _imm5 is zero, check _imm5 is bigger
310 than zero when calling vec_sld.
312 2023-03-27 Sandra Loosemore <sandra@codesourcery.com>
314 * doc/generic.texi (OpenMP): Document OMP_SIMD, OMP_DISTRIBUTE,
315 OMP_TASKLOOP, and OMP_LOOP with OMP_FOR. Document how collapsed
316 loops are represented and which fields are vectors. Add
317 documentation for OMP_FOR_PRE_BODY field. Document internal
318 form of non-rectangular loops and OMP_FOR_NON_RECTANGULAR.
319 * tree.def (OMP_FOR): Make documentation consistent with the
320 Texinfo manual, to fill some gaps and correct errors.
322 2023-03-26 Andreas Schwab <schwab@linux-m68k.org>
325 * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Define.
326 * config/m68k/m68k.cc (m68k_final_prescan_insn): Define.
327 (handle_move_double): Call it before handle_movsi.
328 * config/m68k/m68k-protos.h: Declare it.
330 2023-03-26 Jakub Jelinek <jakub@redhat.com>
332 PR tree-optimization/109230
333 * match.pd (fneg/fadd simplify): Verify also odd permutation indexes.
335 2023-03-26 Jakub Jelinek <jakub@redhat.com>
338 * predict.cc (compute_function_frequency): Don't call
339 warn_function_cold if function already has cold attribute.
341 2023-03-26 Gerald Pfeifer <gerald@pfeifer.com>
343 * doc/install.texi: Remove anachronistic note
344 related to languages built and separate source tarballs.
346 2023-03-25 David Malcolm <dmalcolm@redhat.com>
349 * diagnostic-format-sarif.cc (read_until_eof): Delete.
350 (maybe_read_file): Delete.
351 (sarif_builder::maybe_make_artifact_content_object): Use
352 get_source_file_content rather than maybe_read_file.
353 Reject it if it's not valid UTF-8.
354 * input.cc (file_cache_slot::get_full_file_content): New.
355 (get_source_file_content): New.
356 (selftest::check_cpp_valid_utf8_p): New.
357 (selftest::test_cpp_valid_utf8_p): New.
358 (selftest::input_cc_tests): Call selftest::test_cpp_valid_utf8_p.
359 * input.h (get_source_file_content): New prototype.
361 2023-03-24 David Malcolm <dmalcolm@redhat.com>
363 * doc/analyzer.texi (Debugging the Analyzer): Add notes on useful
365 (Special Functions for Debugging the Analyzer): Convert to a
366 table, and rewrite in places.
367 (Other Debugging Techniques): Add notes on how to compare two
368 different exploded graphs.
370 2023-03-24 David Malcolm <dmalcolm@redhat.com>
373 * json.cc: Update comments to indicate that we now preserve
374 insertion order of keys within objects.
375 (object::print): Traverse keys in insertion order.
376 (object::set): Preserve insertion order of keys.
377 (selftest::test_writing_objects): Add an additional key to verify
378 that we preserve insertion order.
379 * json.h (object::m_keys): New field.
381 2023-03-24 Andrew MacLeod <amacleod@redhat.com>
383 PR tree-optimization/109238
384 * gimple-range-cache.cc (ranger_cache::resolve_dom): Ignore
385 predecessors which this block dominates.
387 2023-03-24 Richard Biener <rguenther@suse.de>
389 PR tree-optimization/106912
390 * tree-profile.cc (tree_profiling): Update stmts only when
391 profiling or testing coverage. Make sure to update calls
392 fntype, stripping 'const' there.
394 2023-03-24 Jakub Jelinek <jakub@redhat.com>
397 * builtins.cc (inline_expand_builtin_bytecmp): Return NULL_RTX early
398 if target == const0_rtx.
400 2023-03-24 Alexandre Oliva <oliva@adacore.com>
402 * doc/sourcebuild.texi (weak_undefined, posix_memalign):
403 Document options and effective targets.
405 2023-03-24 Costas Argyris <costas.argyris@gmail.com>
407 * config/i386/x-mingw32-utf8: Make HOST_EXTRA_OBJS_SYMBOL
410 2023-03-23 Pat Haugen <pthaugen@linux.ibm.com>
412 * config/rs6000/rs6000.md (*mod<mode>3, umod<mode>3): Add
413 non-earlyclobber alternative.
415 2023-03-23 Andrew Pinski <apinski@marvell.com>
418 * fold-const.cc (maybe_lvalue_p): Treat COMPOUND_LITERAL_EXPR
421 2023-03-23 Richard Biener <rguenther@suse.de>
423 PR tree-optimization/107569
424 * tree-ssa-sccvn.cc (eliminate_dom_walker::eliminate_stmt):
425 Do not push SSA names with zero uses as available leader.
426 (process_bb): Likewise.
428 2023-03-23 Richard Biener <rguenther@suse.de>
430 PR tree-optimization/109262
431 * tree-ssa-forwprop.cc (pass_forwprop::execute): When
432 combining a piecewise complex load avoid touching loads
433 that throw internally. Use fun, not cfun throughout.
435 2023-03-23 Jakub Jelinek <jakub@redhat.com>
437 * value-range.cc (irange::irange_union, irange::intersect): Fix
438 comment spelling bugs.
439 * gimple-range-trace.cc (range_tracer::do_header): Likewise.
440 * gimple-range-trace.h: Likewise.
441 * gimple-range-edge.cc: Likewise.
442 (gimple_outgoing_range_stmt_p,
443 gimple_outgoing_range::switch_edge_range,
444 gimple_outgoing_range::edge_range_p): Likewise.
445 * gimple-range.cc (gimple_ranger::prefill_stmt_dependencies,
446 gimple_ranger::fold_stmt, gimple_ranger::register_transitive_infer,
447 assume_query::assume_query, assume_query::calculate_phi): Likewise.
448 * gimple-range-edge.h: Likewise.
449 * value-range.h (Value_Range::set, Value_Range::lower_bound,
450 Value_Range::upper_bound, frange::set_undefined): Likewise.
451 * gimple-range-gori.h (range_def_chain::depend, gori_map::m_outgoing,
452 gori_compute): Likewise.
453 * gimple-range-fold.h (fold_using_range): Likewise.
454 * gimple-range-path.cc (path_range_query::compute_ranges_in_phis):
456 * gimple-range-gori.cc (range_def_chain::in_chain_p,
457 range_def_chain::dump, gori_map::calculate_gori,
458 gori_compute::compute_operand_range_switch,
459 gori_compute::logical_combine, gori_compute::refine_using_relation,
460 gori_compute::compute_operand1_range, gori_compute::may_recompute_p):
462 * gimple-range.h: Likewise.
463 (enable_ranger): Likewise.
464 * range-op.h (empty_range_varying): Likewise.
465 * value-query.h (value_query): Likewise.
466 * gimple-range-cache.cc (block_range_cache::set_bb_range,
467 block_range_cache::dump, ssa_global_cache::clear_global_range,
468 temporal_cache::temporal_value, temporal_cache::current_p,
469 ranger_cache::range_of_def, ranger_cache::propagate_updated_value,
470 ranger_cache::range_from_dom, ranger_cache::register_inferred_value):
472 * gimple-range-fold.cc (fur_edge::get_phi_operand,
473 fur_stmt::get_operand, gimple_range_adjustment,
474 fold_using_range::range_of_phi,
475 fold_using_range::relation_fold_and_or): Likewise.
476 * value-range-storage.h (irange_storage_slot::MAX_INTS): Likewise.
477 * value-query.cc (range_query::value_of_expr,
478 range_query::value_on_edge, range_query::query_relation): Likewise.
479 * tree-vrp.cc (remove_unreachable::remove_and_update_globals,
480 intersect_range_with_nonzero_bits): Likewise.
481 * gimple-range-infer.cc (gimple_infer_range::check_assume_func,
482 exit_range): Likewise.
483 * value-relation.h: Likewise.
484 (equiv_oracle, relation_trio::relation_trio, value_relation,
485 value_relation::value_relation, pe_min): Likewise.
486 * range-op-float.cc (range_operator_float::rv_fold,
487 frange_arithmetic, foperator_unordered_equal::op1_range,
488 foperator_div::rv_fold): Likewise.
489 * gimple-range-op.cc (cfn_clz::fold_range): Likewise.
490 * value-relation.cc (equiv_oracle::query_relation,
491 equiv_oracle::register_equiv, equiv_oracle::add_equiv_to_block,
492 value_relation::apply_transitive, relation_chain_head::find_relation,
493 dom_oracle::query_relation, dom_oracle::find_relation_block,
494 dom_oracle::find_relation_dom, path_oracle::register_equiv): Likewise.
495 * range-op.cc (range_operator::wi_fold_in_parts_equiv,
496 create_possibly_reversed_range, adjust_op1_for_overflow,
497 operator_mult::wi_fold, operator_exact_divide::op1_range,
498 operator_cast::lhs_op1_relation, operator_cast::fold_pair,
499 operator_cast::fold_range, operator_abs::wi_fold, range_op_cast_tests,
500 range_op_lshift_tests): Likewise.
502 2023-03-23 Andrew Stubbs <ams@codesourcery.com>
504 * config/gcn/gcn.cc (gcn_class_max_nregs): Handle vectors in SGPRs.
505 (move_callee_saved_registers): Detect the bug condition early.
507 2023-03-23 Andrew Stubbs <ams@codesourcery.com>
509 * config/gcn/gcn-protos.h (gcn_stepped_zero_int_parallel_p): New.
510 * config/gcn/gcn-valu.md (V_1REG_ALT): New.
512 (vec_extract<V_1REG:mode><V_1REG_ALT:mode>_nop): New.
513 (vec_extract<V_2REG:mode><V_2REG_ALT:mode>_nop): New.
514 (vec_extract<V_ALL:mode><V_ALL_ALT:mode>): Use new patterns.
515 * config/gcn/gcn.cc (gcn_stepped_zero_int_parallel_p): New.
516 * config/gcn/predicates.md (ascending_zero_int_parallel): New.
518 2023-03-23 Jakub Jelinek <jakub@redhat.com>
520 PR tree-optimization/109176
521 * tree-vect-generic.cc (expand_vector_condition): If a has
522 vector boolean type and is a comparison, also check if both
523 the comparison and VEC_COND_EXPR could be successfully expanded
526 2023-03-23 Pan Li <pan2.li@intel.com>
527 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
531 * config/riscv/riscv-modes.def (ADJUST_BYTESIZE): Adjust size
532 for vector mask modes.
533 * config/riscv/riscv.cc (riscv_v_adjust_bytesize): New.
534 * config/riscv/riscv.h (riscv_v_adjust_bytesize): New.
536 2023-03-23 Songhe Zhu <zhusonghe@eswincomputing.com>
538 * config/riscv/multilib-generator: Adjusting the loop of 'alt' in 'alts'.
540 2023-03-23 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
543 * config/riscv/riscv-protos.h (emit_vlmax_vsetvl): Define as global.
544 (emit_vlmax_op): Ditto.
545 * config/riscv/riscv-v.cc (get_sew): New function.
546 (emit_vlmax_vsetvl): Adapt function.
547 (emit_pred_op): Ditto.
548 (emit_vlmax_op): Ditto.
549 (emit_nonvlmax_op): Ditto.
550 (legitimize_move): Fix LRA ICE.
551 (gen_no_side_effects_vsetvl_rtx): Adapt function.
552 * config/riscv/vector.md (@mov<V_FRACT:mode><P:mode>_lra): New pattern.
553 (@mov<VB:mode><P:mode>_lra): Ditto.
554 (*mov<V_FRACT:mode><P:mode>_lra): Ditto.
555 (*mov<VB:mode><P:mode>_lra): Ditto.
557 2023-03-23 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
560 * config/riscv/riscv-vector-builtins-bases.cc (class vlenb): Add
561 __riscv_vlenb support.
563 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
564 * config/riscv/riscv-vector-builtins-functions.def (vlenb): Ditto.
565 * config/riscv/riscv-vector-builtins-shapes.cc (struct vlenb_def): Ditto.
567 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
568 * config/riscv/riscv-vector-builtins.cc: Ditto.
570 2023-03-23 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
571 kito-cheng <kito.cheng@sifive.com>
573 * config/riscv/riscv-vsetvl.cc (reg_available_p): Fix bugs.
574 (pass_vsetvl::compute_local_backward_infos): Fix bugs.
575 (pass_vsetvl::need_vsetvl): Fix bugs.
576 (pass_vsetvl::backward_demand_fusion): Fix bugs.
577 (pass_vsetvl::demand_fusion): Fix bugs.
578 (eliminate_insn): Fix bugs.
579 (insert_vsetvl): Ditto.
580 (pass_vsetvl::emit_local_forward_vsetvls): Ditto.
581 * config/riscv/riscv-vsetvl.h (enum vsetvl_type): Ditto.
582 * config/riscv/vector.md: Ditto.
584 2023-03-23 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
585 kito-cheng <kito.cheng@sifive.com>
587 * config/riscv/riscv-vector-builtins-bases.cc: Fix ternary bug.
588 * config/riscv/vector-iterators.md (nmsac): Ditto.
594 * config/riscv/vector.md (@pred_mul_<optab><mode>): Ditto.
595 (@pred_mul_plus<mode>): Ditto.
596 (*pred_madd<mode>): Ditto.
597 (*pred_macc<mode>): Ditto.
598 (*pred_mul_plus<mode>): Ditto.
599 (@pred_mul_plus<mode>_scalar): Ditto.
600 (*pred_madd<mode>_scalar): Ditto.
601 (*pred_macc<mode>_scalar): Ditto.
602 (*pred_mul_plus<mode>_scalar): Ditto.
603 (*pred_madd<mode>_extended_scalar): Ditto.
604 (*pred_macc<mode>_extended_scalar): Ditto.
605 (*pred_mul_plus<mode>_extended_scalar): Ditto.
606 (@pred_minus_mul<mode>): Ditto.
607 (*pred_<madd_nmsub><mode>): Ditto.
608 (*pred_nmsub<mode>): Ditto.
609 (*pred_<macc_nmsac><mode>): Ditto.
610 (*pred_nmsac<mode>): Ditto.
611 (*pred_mul_<optab><mode>): Ditto.
612 (*pred_minus_mul<mode>): Ditto.
613 (@pred_mul_<optab><mode>_scalar): Ditto.
614 (@pred_minus_mul<mode>_scalar): Ditto.
615 (*pred_<madd_nmsub><mode>_scalar): Ditto.
616 (*pred_nmsub<mode>_scalar): Ditto.
617 (*pred_<macc_nmsac><mode>_scalar): Ditto.
618 (*pred_nmsac<mode>_scalar): Ditto.
619 (*pred_mul_<optab><mode>_scalar): Ditto.
620 (*pred_minus_mul<mode>_scalar): Ditto.
621 (*pred_<madd_nmsub><mode>_extended_scalar): Ditto.
622 (*pred_nmsub<mode>_extended_scalar): Ditto.
623 (*pred_<macc_nmsac><mode>_extended_scalar): Ditto.
624 (*pred_nmsac<mode>_extended_scalar): Ditto.
625 (*pred_mul_<optab><mode>_extended_scalar): Ditto.
626 (*pred_minus_mul<mode>_extended_scalar): Ditto.
627 (*pred_<madd_msub><mode>): Ditto.
628 (*pred_<macc_msac><mode>): Ditto.
629 (*pred_<madd_msub><mode>_scalar): Ditto.
630 (*pred_<macc_msac><mode>_scalar): Ditto.
631 (@pred_neg_mul_<optab><mode>): Ditto.
632 (@pred_mul_neg_<optab><mode>): Ditto.
633 (*pred_<nmadd_msub><mode>): Ditto.
634 (*pred_<nmsub_nmadd><mode>): Ditto.
635 (*pred_<nmacc_msac><mode>): Ditto.
636 (*pred_<nmsac_nmacc><mode>): Ditto.
637 (*pred_neg_mul_<optab><mode>): Ditto.
638 (*pred_mul_neg_<optab><mode>): Ditto.
639 (@pred_neg_mul_<optab><mode>_scalar): Ditto.
640 (@pred_mul_neg_<optab><mode>_scalar): Ditto.
641 (*pred_<nmadd_msub><mode>_scalar): Ditto.
642 (*pred_<nmsub_nmadd><mode>_scalar): Ditto.
643 (*pred_<nmacc_msac><mode>_scalar): Ditto.
644 (*pred_<nmsac_nmacc><mode>_scalar): Ditto.
645 (*pred_neg_mul_<optab><mode>_scalar): Ditto.
646 (*pred_mul_neg_<optab><mode>_scalar): Ditto.
647 (@pred_widen_neg_mul_<optab><mode>): Ditto.
648 (@pred_widen_mul_neg_<optab><mode>): Ditto.
649 (@pred_widen_neg_mul_<optab><mode>_scalar): Ditto.
650 (@pred_widen_mul_neg_<optab><mode>_scalar): Ditto.
652 2023-03-23 liuhongt <hongtao.liu@intel.com>
654 * builtins.cc (builtin_memset_read_str): Replace
655 targetm.gen_memset_scratch_rtx with gen_reg_rtx.
656 (builtin_memset_gen_str): Ditto.
657 * config/i386/i386-expand.cc
658 (ix86_convert_const_wide_int_to_broadcast): Replace
659 ix86_gen_scratch_sse_rtx with gen_reg_rtx.
660 (ix86_expand_vector_move): Ditto.
661 * config/i386/i386-protos.h (ix86_gen_scratch_sse_rtx):
663 * config/i386/i386.cc (ix86_gen_scratch_sse_rtx): Removed.
664 (TARGET_GEN_MEMSET_SCRATCH_RTX): Removed.
665 * doc/tm.texi: Remove TARGET_GEN_MEMSET_SCRATCH_RTX.
666 * doc/tm.texi.in: Ditto.
669 2023-03-22 Vladimir N. Makarov <vmakarov@redhat.com>
671 * lra.cc (lra): Do not repeat inheritance and live range splitting
672 when asm error is found.
674 2023-03-22 Andrew Jenner <andrew@codesourcery.com>
676 * config/gcn/gcn-protos.h (gcn_expand_dpp_swap_pairs_insn)
677 (gcn_expand_dpp_distribute_even_insn)
678 (gcn_expand_dpp_distribute_odd_insn): Declare.
679 * config/gcn/gcn-valu.md (@dpp_swap_pairs<mode>)
680 (@dpp_distribute_even<mode>, @dpp_distribute_odd<mode>)
681 (cmul<conj_op><mode>3, cml<addsub_as><mode>4, vec_addsub<mode>3)
682 (cadd<rot><mode>3, vec_fmaddsub<mode>4, vec_fmsubadd<mode>4)
683 (fms<mode>4<exec>, fms<mode>4_negop2<exec>, fms<mode>4)
684 (fms<mode>4_negop2): New patterns.
685 * config/gcn/gcn.cc (gcn_expand_dpp_swap_pairs_insn)
686 (gcn_expand_dpp_distribute_even_insn)
687 (gcn_expand_dpp_distribute_odd_insn): New functions.
688 * config/gcn/gcn.md: Add entries to unspec enum.
690 2023-03-22 Aldy Hernandez <aldyh@redhat.com>
692 PR tree-optimization/109008
693 * value-range.cc (frange::set): Add nan_state argument.
694 * value-range.h (class nan_state): New.
695 (frange::get_nan_state): New.
697 2023-03-22 Martin Liska <mliska@suse.cz>
699 * configure: Regenerate.
701 2023-03-21 Joseph Myers <joseph@codesourcery.com>
703 * stor-layout.cc (finalize_type_size): Copy TYPE_TYPELESS_STORAGE
706 2023-03-21 Andrew MacLeod <amacleod@redhat.com>
708 PR tree-optimization/109192
709 * gimple-range-gori.cc (gori_compute::compute_operand_range):
710 Terminate gori calculations if a relation is not relevant.
711 * value-relation.h (value_relation::set_relation): Allow
712 equality between op1 and op2 if they are the same.
714 2023-03-21 Richard Biener <rguenther@suse.de>
716 PR tree-optimization/109219
717 * tree-vect-loop.cc (vectorizable_reduction): Check
718 slp_node, not STMT_SLP_TYPE.
719 * tree-vect-stmts.cc (vectorizable_condition): Likewise.
720 * tree-vect-slp.cc (vect_slp_analyze_node_operations_1):
721 Remove assertion on STMT_SLP_TYPE.
723 2023-03-21 Jakub Jelinek <jakub@redhat.com>
725 PR tree-optimization/109215
726 * tree.h (enum special_array_member): Adjust comments for int_0
728 * tree.cc (component_ref_sam_type): Clear zero_elts if memtype
729 has zero sized element type and the array has variable number of
730 elements or constant one or more elements.
731 (component_ref_size): Adjust comments, formatting fix.
733 2023-03-21 Arsen Arsenović <arsen@aarsen.me>
735 * configure.ac: Add check for the Texinfo 6.8
736 CONTENTS_OUTPUT_LOCATION customization variable and set it if
738 * configure: Regenerate.
739 * Makefile.in (MAKEINFO_TOC_INLINE_FLAG): New variable. Set by
740 configure.ac to -c CONTENTS_OUTPUT_LOCATION=inline if
741 CONTENTS_OUTPUT_LOCATION support is detected, empty otherwise.
742 ($(build_htmldir)/%/index.html): Pass MAKEINFO_TOC_INLINE_FLAG.
744 2023-03-21 Arsen Arsenović <arsen@aarsen.me>
746 * doc/extend.texi: Associate use_hazard_barrier_return index
747 entry with its attribute.
748 * doc/invoke.texi: Associate -fcanon-prefix-map index entry with
751 2023-03-21 Arsen Arsenović <arsen@aarsen.me>
753 * doc/implement-c.texi: Remove usage of @gol.
754 * doc/invoke.texi: Ditto.
755 * doc/sourcebuild.texi: Ditto.
756 * doc/include/gcc-common.texi: Remove @gol. In new Makeinfo and
757 texinfo.tex versions, the bug it was working around appears to
760 2023-03-21 Arsen Arsenović <arsen@aarsen.me>
762 * doc/include/texinfo.tex: Update to 2023-01-17.19.
764 2023-03-21 Arsen Arsenović <arsen@aarsen.me>
766 * doc/include/gcc-common.texi: Add @defbuiltin{,x} and
767 @enddefbuiltin for defining built-in functions.
768 * doc/extend.texi: Apply @defbuiltin{,x} to many, but not all,
769 places where it should be used.
771 2023-03-21 Arsen Arsenović <arsen@aarsen.me>
773 * doc/extend.texi (Formatted Output Function Checking): New
774 subsection for grouping together printf et al.
775 (Exception handling) Fix missing @ sign before copyright
776 header, which lead to the copyright line leaking into
777 '(gcc)Exception handling'.
778 * doc/gcc.texi: Set document language to en_US.
779 (@copying): Wrap front cover texts in quotations, move in manual
782 2023-03-21 Arsen Arsenović <arsen@aarsen.me>
784 * doc/gcc.texi: Add the Indices appendix, to make texinfo
785 generate nice indices overview page.
787 2023-03-21 Richard Biener <rguenther@suse.de>
789 PR tree-optimization/109170
790 * gimple-range-op.cc (cfn_pass_through_arg1): New.
791 (gimple_range_op_handler::maybe_builtin_call): Handle
792 __builtin_expect via cfn_pass_through_arg1.
794 2023-03-20 Michael Meissner <meissner@linux.ibm.com>
797 * config/rs6000/rs6000.cc (create_complex_muldiv): Delete.
798 (init_float128_ieee): Delete code to switch complex multiply and divide
800 (complex_multiply_builtin_code): New helper function.
801 (complex_divide_builtin_code): Likewise.
802 (rs6000_mangle_decl_assembler_name): Add support for mangling the name
803 of complex 128-bit multiply and divide built-in functions.
805 2023-03-20 Peter Bergner <bergner@linux.ibm.com>
808 * config/rs6000/rs6000-builtin.cc (stv_expand_builtin): Use tmode.
810 2023-03-19 Jonny Grant <jg@jguk.org>
812 * doc/extend.texi (Common Function Attributes) <nonnull>:
815 2023-03-18 Peter Bergner <bergner@linux.ibm.com>
817 PR rtl-optimization/109179
818 * lra-constraints.cc (combine_reload_insn): Enforce TO is not a debug
819 insn or note. Move the tests earlier to guard lra_get_insn_recog_data.
821 2023-03-17 Jakub Jelinek <jakub@redhat.com>
824 * function.h (push_struct_function): Add ABSTRACT_P argument defaulted
826 * function.cc (push_struct_function): Add ABSTRACT_P argument, pass it
827 to allocate_struct_function instead of false.
828 * tree-inline.cc (initialize_cfun): Don't copy DECL_ARGUMENTS
829 nor DECL_RESULT here. Pass true as ABSTRACT_P to
830 push_struct_function. Call targetm.target_option.relayout_function
832 (tree_function_versioning): Formatting fix.
834 2023-03-17 Vladimir N. Makarov <vmakarov@redhat.com>
836 * lra-constraints.cc: Include hooks.h.
837 (combine_reload_insn): New function.
838 (lra_constraints): Call it.
840 2023-03-17 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
841 kito-cheng <kito.cheng@sifive.com>
843 * config/riscv/riscv-v.cc (legitimize_move): Allow undef value
845 * config/riscv/riscv-vector-builtins.cc
846 (function_expander::use_ternop_insn): Fix bugs of ternary intrinsic.
847 (function_expander::use_widen_ternop_insn): Ditto.
848 * config/riscv/vector.md (@vundefined<mode>): New pattern.
849 (pred_mul_<optab><mode>_undef_merge): Remove.
850 (*pred_mul_<optab><mode>_undef_merge_scalar): Ditto.
851 (*pred_mul_<optab><mode>_undef_merge_extended_scalar): Ditto.
852 (pred_neg_mul_<optab><mode>_undef_merge): Ditto.
853 (*pred_neg_mul_<optab><mode>_undef_merge_scalar): Ditto.
855 2023-03-17 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
858 * config/riscv/riscv.md: Fix subreg bug.
860 2023-03-17 Jakub Jelinek <jakub@redhat.com>
863 * omp-expand.cc (expand_omp_for_ordered_loops): Add L0_BB argument,
864 use its loop_father rather than BODY_BB's loop_father.
865 (expand_omp_for_generic): Adjust expand_omp_for_ordered_loops caller.
866 If broken_loop with ordered > collapse and at least one of those
867 extra loops aren't guaranteed to have at least one iteration, change
868 l0_bb's loop_father to entry_bb's loop_father. Set cont_bb's
869 loop_father to l0_bb's loop_father rather than l1_bb's.
871 2023-03-17 Jakub Jelinek <jakub@redhat.com>
874 * gdbhooks.py (TreePrinter.to_string): Wrap
875 gdb.parse_and_eval('tree_code_type') in a try block, parse
876 and eval 'tree_code_type_tmpl<0>::tree_code_type' instead if it
877 raises exception. Update comments for the recent tree_code_type
880 2023-03-17 Sandra Loosemore <sandra@codesourcery.com>
882 * doc/extend.texi (BPF Built-in Functions): Fix numerous markup
883 issues. Add more line breaks to example so it doesn't overflow
886 2023-03-17 Sandra Loosemore <sandra@codesourcery.com>
888 * doc/extend.texi (Common Function Attributes) <access>: Fix bad
889 line breaks in examples.
890 <malloc>: Fix bad line breaks in running text, also copy-edit
892 (Extended Asm) <Generic Operand Modifiers>: Fix @multitable width.
893 * doc/invoke.texi (Option Summary) <Developer Options>: Fix misplaced
895 (C++ Dialect Options) <-fcontracts>: Add line break in example.
896 <-Wctad-maybe-unsupported>: Likewise.
897 <-Winvalid-constexpr>: Likewise.
898 (Warning Options) <-Wdangling-pointer>: Likewise.
899 <-Winterference-size>: Likewise.
900 <-Wvla-parameter>: Likewise.
901 (Static Analyzer Options): Fix bad line breaks in running text,
902 plus add some missing markup.
903 (Optimize Options) <openacc-privatization>: Fix more bad line
904 breaks in running text.
906 2023-03-16 Uros Bizjak <ubizjak@gmail.com>
908 * config/i386/i386-expand.cc (expand_vec_perm_pblendv):
909 Handle 8-byte modes only with TARGET_MMX_WITH_SSE.
910 (expand_vec_perm_2perm_pblendv): Ditto.
912 2023-03-16 Martin Liska <mliska@suse.cz>
915 * gcc.cc (driver_handle_option): Use x_main_input_basename
916 if x_dump_base_name is null.
917 * opts.cc (common_handle_option): Likewise.
919 2023-03-16 Richard Biener <rguenther@suse.de>
921 PR tree-optimization/109123
922 * gimple-ssa-warn-access.cc (pass_waccess::warn_invalid_pointer):
923 Do not emit -Wuse-after-free late.
924 (pass_waccess::check_call): Always check call pointer uses.
926 2023-03-16 Richard Biener <rguenther@suse.de>
928 PR tree-optimization/109141
929 * tree-dfa.h (renumber_gimple_stmt_uids_in_block): New.
930 * tree-dfa.cc (renumber_gimple_stmt_uids_in_block): Split
932 (renumber_gimple_stmt_uids): ... here and
933 (renumber_gimple_stmt_uids_in_blocks): ... here.
934 * gimple-ssa-warn-access.cc (pass_waccess::use_after_inval_p):
935 Use renumber_gimple_stmt_uids_in_block to also assign UIDs
937 (pass_waccess::check_pointer_uses): Process all PHIs.
939 2023-03-15 David Malcolm <dmalcolm@redhat.com>
942 * diagnostic-format-sarif.cc (class sarif_invocation): New.
943 (class sarif_ice_notification): New.
944 (sarif_builder::m_invocation_obj): New field.
945 (sarif_invocation::add_notification_for_ice): New.
946 (sarif_invocation::prepare_to_flush): New.
947 (sarif_ice_notification::sarif_ice_notification): New.
948 (sarif_builder::sarif_builder): Add m_invocation_obj.
949 (sarif_builder::end_diagnostic): Special-case DK_ICE and
951 (sarif_builder::flush_to_file): Call prepare_to_flush on
952 m_invocation_obj. Pass the latter to make_top_level_object.
953 (sarif_builder::make_result_object): Move creation of "locations"
955 (sarif_builder::make_locations_arr): ...this new function.
956 (sarif_builder::make_top_level_object): Add "invocation_obj" param
957 and pass it to make_run_object.
958 (sarif_builder::make_run_object): Add "invocation_obj" param and
960 (sarif_ice_handler): New callback.
961 (diagnostic_output_format_init_sarif): Wire up sarif_ice_handler.
962 * diagnostic.cc (diagnostic_initialize): Initialize new field
964 (diagnostic_action_after_output): If it is set, make one attempt
965 to call ice_handler_cb.
966 * diagnostic.h (diagnostic_context::ice_handler_cb): New field.
968 2023-03-15 Uros Bizjak <ubizjak@gmail.com>
970 * config/i386/i386-expand.cc (expand_vec_perm_blend):
971 Handle 8-byte modes only with TARGET_MMX_WITH_SSE. Handle V2SFmode
972 and fix V2HImode handling.
973 (expand_vec_perm_1): Try to emit BLEND instruction
975 * config/i386/mmx.md (*mmx_blendps): New insn pattern.
977 2023-03-15 Tobias Burnus <tobias@codesourcery.com>
979 * omp-low.cc (omp_runtime_api_call): Add omp_in_explicit_task.
981 2023-03-15 Richard Biener <rguenther@suse.de>
983 * gimple-ssa-warn-access.cc (pass_waccess::check_pointer_uses):
984 Do not diagnose clobbers.
986 2023-03-15 Richard Biener <rguenther@suse.de>
988 PR tree-optimization/109139
989 * tree-ssa-live.cc (remove_unused_locals): Look at the
990 base address for unused decls on the LHS of .DEFERRED_INIT.
992 2023-03-15 Xi Ruoyao <xry111@xry111.site>
995 * builtins.cc (inline_string_cmp): Force the character
996 difference into "result" pseudo-register, instead of reassign
999 2023-03-15 Christoph Müllner <christoph.muellner@vrull.eu>
1001 * config.gcc: Add thead.o to RISC-V extra_objs.
1002 * config/riscv/peephole.md: Add mempair peephole passes.
1003 * config/riscv/riscv-protos.h (riscv_split_64bit_move_p): New
1005 (th_mempair_operands_p): Likewise.
1006 (th_mempair_order_operands): Likewise.
1007 (th_mempair_prepare_save_restore_operands): Likewise.
1008 (th_mempair_save_restore_regs): Likewise.
1009 (th_mempair_output_move): Likewise.
1010 * config/riscv/riscv.cc (riscv_save_reg): Move code.
1011 (riscv_restore_reg): Move code.
1012 (riscv_for_each_saved_reg): Add code to emit mempair insns.
1013 * config/riscv/t-riscv: Add thead.cc.
1014 * config/riscv/thead.md (*th_mempair_load_<GPR:mode>2):
1016 (*th_mempair_store_<GPR:mode>2): Likewise.
1017 (*th_mempair_load_extendsidi2): Likewise.
1018 (*th_mempair_load_zero_extendsidi2): Likewise.
1019 * config/riscv/thead.cc: New file.
1021 2023-03-15 Christoph Müllner <christoph.muellner@vrull.eu>
1023 * config/riscv/constraints.md (TARGET_XTHEADFMV ? FP_REGS : NO_REGS)
1024 New constraint "th_f_fmv".
1025 (TARGET_XTHEADFMV ? GR_REGS : NO_REGS): New constraint
1027 * config/riscv/riscv.cc (riscv_split_doubleword_move):
1028 Add split code for XTheadFmv.
1029 (riscv_secondary_memory_needed): XTheadFmv does not need
1031 * config/riscv/riscv.md: Add new UNSPEC_XTHEADFMV and
1032 UNSPEC_XTHEADFMV_HW. Add support for XTheadFmv to
1033 movdf_hardfloat_rv32.
1034 * config/riscv/thead.md (th_fmv_hw_w_x): New INSN.
1035 (th_fmv_x_w): New INSN.
1036 (th_fmv_x_hw): New INSN.
1038 2023-03-15 Christoph Müllner <christoph.muellner@vrull.eu>
1040 * config/riscv/riscv.md (maddhisi4): New expand.
1041 (msubhisi4): New expand.
1042 * config/riscv/thead.md (*th_mula<mode>): New pattern.
1043 (*th_mulawsi): New pattern.
1044 (*th_mulawsi2): New pattern.
1045 (*th_maddhisi4): New pattern.
1046 (*th_sextw_maddhisi4): New pattern.
1047 (*th_muls<mode>): New pattern.
1048 (*th_mulswsi): New pattern.
1049 (*th_mulswsi2): New pattern.
1050 (*th_msubhisi4): New pattern.
1051 (*th_sextw_msubhisi4): New pattern.
1053 2023-03-15 Christoph Müllner <christoph.muellner@vrull.eu>
1055 * config/riscv/iterators.md (TARGET_64BIT): Add GPR2 iterator.
1056 * config/riscv/riscv-protos.h (riscv_expand_conditional_move):
1058 * config/riscv/riscv.cc (riscv_rtx_costs): Add costs for
1060 (riscv_expand_conditional_move): New function.
1061 (riscv_expand_conditional_move_onesided): New function.
1062 * config/riscv/riscv.md: Add support for XTheadCondMov.
1063 * config/riscv/thead.md (*th_cond_mov<GPR:mode><GPR2:mode>): Add
1064 support for XTheadCondMov.
1065 (*th_cond_gpr_mov<GPR:mode><GPR2:mode>): Likewise.
1067 2023-03-15 Christoph Müllner <christoph.muellner@vrull.eu>
1069 * config/riscv/bitmanip.md (clzdi2): New expand.
1070 (clzsi2): New expand.
1071 (ctz<mode>2): New expand.
1072 (popcount<mode>2): New expand.
1073 (<bitmanip_optab>si2): Rename INSN.
1074 (*<bitmanip_optab>si2): Hide INSN name.
1075 (<bitmanip_optab>di2): Rename INSN.
1076 (*<bitmanip_optab>di2): Hide INSN name.
1077 (rotrsi3): Remove INSN.
1078 (rotr<mode>3): Add expand.
1079 (*rotrsi3): New INSN.
1080 (rotrdi3): Rename INSN.
1081 (*rotrdi3): Hide INSN name.
1082 (rotrsi3_sext): Rename INSN.
1083 (*rotrsi3_sext): Hide INSN name.
1084 (bswap<mode>2): Remove INSN.
1085 (bswapdi2): Add expand.
1086 (bswapsi2): Add expand.
1087 (*bswap<mode>2): Hide INSN name.
1088 * config/riscv/riscv.cc (riscv_rtx_costs): Add costs for sign
1090 * config/riscv/riscv.md (extv<mode>): New expand.
1091 (extzv<mode>): New expand.
1092 * config/riscv/thead.md (*th_srri<mode>3): New INSN.
1093 (*th_ext<mode>): New INSN.
1094 (*th_extu<mode>): New INSN.
1095 (*th_clz<mode>2): New INSN.
1096 (*th_rev<mode>2): New INSN.
1098 2023-03-15 Christoph Müllner <christoph.muellner@vrull.eu>
1100 * config/riscv/riscv.cc (riscv_rtx_costs): Add xthead:tst cost.
1101 * config/riscv/thead.md (*th_tst<mode>3): New INSN.
1103 2023-03-15 Christoph Müllner <christoph.muellner@vrull.eu>
1105 * config/riscv/riscv.md: Include thead.md
1106 * config/riscv/thead.md: New file.
1108 2023-03-15 Christoph Müllner <christoph.muellner@vrull.eu>
1110 * config/riscv/riscv-cores.def (RISCV_CORE): Add "thead-c906".
1112 2023-03-15 Christoph Müllner <christoph.muellner@vrull.eu>
1114 * common/config/riscv/riscv-common.cc: Add xthead* extensions.
1115 * config/riscv/riscv-opts.h (MASK_XTHEADBA): New.
1116 (MASK_XTHEADBB): New.
1117 (MASK_XTHEADBS): New.
1118 (MASK_XTHEADCMO): New.
1119 (MASK_XTHEADCONDMOV): New.
1120 (MASK_XTHEADFMEMIDX): New.
1121 (MASK_XTHEADFMV): New.
1122 (MASK_XTHEADINT): New.
1123 (MASK_XTHEADMAC): New.
1124 (MASK_XTHEADMEMIDX): New.
1125 (MASK_XTHEADMEMPAIR): New.
1126 (MASK_XTHEADSYNC): New.
1127 (TARGET_XTHEADBA): New.
1128 (TARGET_XTHEADBB): New.
1129 (TARGET_XTHEADBS): New.
1130 (TARGET_XTHEADCMO): New.
1131 (TARGET_XTHEADCONDMOV): New.
1132 (TARGET_XTHEADFMEMIDX): New.
1133 (TARGET_XTHEADFMV): New.
1134 (TARGET_XTHEADINT): New.
1135 (TARGET_XTHEADMAC): New.
1136 (TARGET_XTHEADMEMIDX): New.
1137 (TARGET_XTHEADMEMPAIR): new.
1138 (TARGET_XTHEADSYNC): New.
1139 * config/riscv/riscv.opt: Add riscv_xthead_subext.
1141 2023-03-15 Hu, Lin1 <lin1.hu@intel.com>
1144 * config/i386/i386-builtin.def (__builtin_ia32_vaesdec_v16qi,
1145 __builtin_ia32_vaesdeclast_v16qi,__builtin_ia32_vaesenc_v16qi,
1146 __builtin_ia32_vaesenclast_v16qi): Require OPTION_MASK_ISA_AVX512VL.
1148 2023-03-14 Jakub Jelinek <jakub@redhat.com>
1151 * config/i386/i386-expand.cc (split_double_concat): Fix splitting
1152 when lo is equal to dhi and hi is a MEM which uses dlo register.
1154 2023-03-14 Martin Jambor <mjambor@suse.cz>
1157 * ipa-cp.cc (update_profiling_info): Drop counts of orig_node to
1158 global0 instead of zeroing when it does not have as many counts as
1161 2023-03-14 Martin Jambor <mjambor@suse.cz>
1164 * ipa-cp.cc (update_specialized_profile): Drop orig_node_count to
1165 ipa count, remove assert, lenient_count_portion_handling, dump
1166 also orig_node_count.
1168 2023-03-14 Uros Bizjak <ubizjak@gmail.com>
1170 * config/i386/i386-expand.cc (expand_vec_perm_movs):
1171 Handle V2SImode for TARGET_MMX_WITH_SSE.
1172 * config/i386/mmx.md (*mmx_movss_<mode>): Rename from *mmx_movss
1173 using V2FI mode iterator to handle both V2SI and V2SF modes.
1175 2023-03-14 Sam James <sam@gentoo.org>
1177 * config/riscv/genrvv-type-indexer.cc: Avoid calloc() poisoning on musl by
1178 including <sstream> earlier.
1179 * system.h: Add INCLUDE_SSTREAM.
1181 2023-03-14 Richard Biener <rguenther@suse.de>
1183 * tree-ssa-live.cc (remove_unused_locals): Do not treat
1184 the .DEFERRED_INIT of a variable as use, instead remove
1185 that if it is the only use.
1187 2023-03-14 Eric Botcazou <ebotcazou@adacore.com>
1189 PR rtl-optimization/107762
1190 * expr.cc (emit_group_store): Revert latest change.
1192 2023-03-14 Andre Vieira <andre.simoesdiasvieira@arm.com>
1194 PR tree-optimization/109005
1195 * tree-if-conv.cc (get_bitfield_rep): Replace BLKmode check with
1196 aggregate type check.
1198 2023-03-14 Jakub Jelinek <jakub@redhat.com>
1200 PR tree-optimization/109115
1201 * tree-vect-patterns.cc (vect_recog_divmod_pattern): Don't use
1202 r.upper_bound () on r.undefined_p () range.
1204 2023-03-14 Jan Hubicka <hubicka@ucw.cz>
1206 PR tree-optimization/106896
1207 * profile-count.cc (profile_count::to_sreal_scale): Synchronize
1208 implementatoin with probability_in; avoid some asserts.
1210 2023-03-13 Max Filippov <jcmvbkbc@gmail.com>
1212 * config/xtensa/linux.h (TARGET_ASM_FILE_END): New macro.
1214 2023-03-13 Sean Bright <sean@seanbright.com>
1216 * doc/invoke.texi (Warning Options): Remove errant 'See'
1219 2023-03-13 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
1221 * config/xtensa/xtensa.h (REG_OK_STRICT, REG_OK_FOR_INDEX_P,
1222 REG_OK_FOR_BASE_P): Remove.
1224 2023-03-13 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
1226 * config/riscv/vector-iterators.md (=vd,vr): Fine tune.
1227 (=vd,vd,vr,vr): Ditto.
1228 * config/riscv/vector.md: Ditto.
1230 2023-03-13 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
1232 * config/riscv/riscv-vector-builtins.cc
1233 (function_expander::use_compare_insn): Add operand predicate check.
1235 2023-03-13 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
1237 * config/riscv/vector.md: Fine tune RA constraints.
1239 2023-03-13 Tobias Burnus <tobias@codesourcery.com>
1241 * config/gcn/mkoffload.cc (main): Pass -save-temps on for the
1242 hsaco assemble/link.
1244 2023-03-13 Richard Biener <rguenther@suse.de>
1246 PR tree-optimization/109046
1247 * tree-ssa-forwprop.cc (pass_forwprop::execute): Combine
1248 piecewise complex loads.
1250 2023-03-12 Jakub Jelinek <jakub@redhat.com>
1252 * config/aarch64/aarch64.h (aarch64_bf16_type_node): Remove.
1253 (aarch64_bf16_ptr_type_node): Adjust comment.
1254 * config/aarch64/aarch64.cc (aarch64_gimplify_va_arg_expr): Use
1255 bfloat16_type_node rather than aarch64_bf16_type_node.
1256 (aarch64_libgcc_floating_mode_supported_p,
1257 aarch64_scalar_mode_supported_p): Also support BFmode.
1258 (aarch64_invalid_conversion, aarch64_invalid_unary_op): Remove.
1259 (aarch64_invalid_binary_op): Remove BFmode related rejections.
1260 (TARGET_INVALID_CONVERSION, TARGET_INVALID_UNARY_OP): Don't redefine.
1261 * config/aarch64/aarch64-builtins.cc (aarch64_bf16_type_node): Remove.
1262 (aarch64_int_or_fp_type): Use bfloat16_type_node rather than
1263 aarch64_bf16_type_node.
1264 (aarch64_init_simd_builtin_types): Likewise.
1265 (aarch64_init_bf16_types): Likewise. Don't create bfloat16_type_node,
1266 which is created in tree.cc already.
1267 * config/aarch64/aarch64-sve-builtins.def (svbfloat16_t): Likewise.
1269 2023-03-12 Roger Sayle <roger@nextmovesoftware.com>
1271 PR middle-end/109031
1272 * tree-chrec.cc (chrec_apply): When folding "{a, +, a} (x-1)",
1273 ensure that the type of x is as wide or wider than the type of a.
1275 2023-03-12 Tamar Christina <tamar.christina@arm.com>
1278 * config/aarch64/aarch64-simd.md (@aarch64_bitmask_udiv<mode>3): Remove.
1279 (*bitmask_shift_plus<mode>): New.
1280 * config/aarch64/aarch64-sve2.md (*bitmask_shift_plus<mode>): New.
1281 (@aarch64_bitmask_udiv<mode>3): Remove.
1282 * config/aarch64/aarch64.cc
1283 (aarch64_vectorize_can_special_div_by_constant,
1284 TARGET_VECTORIZE_CAN_SPECIAL_DIV_BY_CONST): Removed.
1285 (TARGET_VECTORIZE_PREFERRED_DIV_AS_SHIFTS_OVER_MULT,
1286 aarch64_vectorize_preferred_div_as_shifts_over_mult): New.
1288 2023-03-12 Tamar Christina <tamar.christina@arm.com>
1291 * target.def (preferred_div_as_shifts_over_mult): New.
1292 * doc/tm.texi.in: Document it.
1293 * doc/tm.texi: Regenerate.
1294 * targhooks.cc (default_preferred_div_as_shifts_over_mult): New.
1295 * targhooks.h (default_preferred_div_as_shifts_over_mult): New.
1296 * tree-vect-patterns.cc (vect_recog_divmod_pattern): Use it.
1298 2023-03-12 Tamar Christina <tamar.christina@arm.com>
1299 Richard Sandiford <richard.sandiford@arm.com>
1302 * tree-ssa-math-opts.cc (convert_mult_to_fma): Inhibit FMA in case not
1305 2023-03-12 Tamar Christina <tamar.christina@arm.com>
1306 Andrew MacLeod <amacleod@redhat.com>
1309 * gimple-range-op.h (gimple_range_op_handler): Add maybe_non_standard.
1310 * gimple-range-op.cc (gimple_range_op_handler::gimple_range_op_handler):
1312 (gimple_range_op_handler::maybe_non_standard): New.
1313 * range-op.cc (class operator_widen_plus_signed,
1314 operator_widen_plus_signed::wi_fold, class operator_widen_plus_unsigned,
1315 operator_widen_plus_unsigned::wi_fold, class operator_widen_mult_signed,
1316 operator_widen_mult_signed::wi_fold, class operator_widen_mult_unsigned,
1317 operator_widen_mult_unsigned::wi_fold,
1318 ptr_op_widen_mult_signed, ptr_op_widen_mult_unsigned,
1319 ptr_op_widen_plus_signed, ptr_op_widen_plus_unsigned): New.
1320 * range-op.h (ptr_op_widen_mult_signed, ptr_op_widen_mult_unsigned,
1321 ptr_op_widen_plus_signed, ptr_op_widen_plus_unsigned): New
1323 2023-03-12 Tamar Christina <tamar.christina@arm.com>
1326 * doc/tm.texi (TARGET_VECTORIZE_CAN_SPECIAL_DIV_BY_CONST): Remove.
1327 * doc/tm.texi.in: Likewise.
1328 * explow.cc (round_push, align_dynamic_address): Revert previous patch.
1329 * expmed.cc (expand_divmod): Likewise.
1330 * expmed.h (expand_divmod): Likewise.
1331 * expr.cc (force_operand, expand_expr_divmod): Likewise.
1332 * optabs.cc (expand_doubleword_mod, expand_doubleword_divmod): Likewise.
1333 * target.def (can_special_div_by_const): Remove.
1334 * target.h: Remove tree-core.h include
1335 * targhooks.cc (default_can_special_div_by_const): Remove.
1336 * targhooks.h (default_can_special_div_by_const): Remove.
1337 * tree-vect-generic.cc (expand_vector_operation): Remove hook.
1338 * tree-vect-patterns.cc (vect_recog_divmod_pattern): Remove hook.
1339 * tree-vect-stmts.cc (vectorizable_operation): Remove hook.
1341 2023-03-12 Sandra Loosemore <sandra@codesourcery.com>
1343 * doc/install.texi2html: Fix issue number typo in comment.
1345 2023-03-12 Gaius Mulley <gaiusmod2@gmail.com>
1347 * doc/gm2.texi (Elementary data types): Equivalence BOOLEAN with
1350 2023-03-12 Sandra Loosemore <sandra@codesourcery.com>
1352 * doc/invoke.texi (Optimize Options): Add markup to
1353 description of asan-kernel-mem-intrinsic-prefix, and clarify
1356 2023-03-11 Gerald Pfeifer <gerald@pfeifer.com>
1358 * doc/extend.texi (Named Address Spaces): Drop a redundant link
1361 2023-03-11 Jeff Law <jlaw@ventanamicro>
1364 * doc/extend.texi: Clarify Attribute Syntax a bit.
1366 2023-03-11 Sandra Loosemore <sandra@codesourcery.com>
1368 * doc/install.texi (Prerequisites): Suggest using newer versions
1370 (Final install): Clean up and modernize discussion of how to
1371 build or obtain the GCC manuals.
1372 * doc/install.texi2html: Update comment to point to the PR instead
1373 of "makeinfo 4.7 brokenness" (it's not specific to that version).
1375 2023-03-10 Jakub Jelinek <jakub@redhat.com>
1378 * optabs.cc (expand_fix): For conversions from BFmode to integral,
1379 use shifts to convert it to SFmode first and then convert SFmode
1382 2023-03-10 Andrew Pinski <apinski@marvell.com>
1384 * config/aarch64/aarch64.md: Add a new define_split
1387 2023-03-10 Richard Biener <rguenther@suse.de>
1389 * tree-ssa-structalias.cc (solve_graph): Immediately
1390 iterate self-cycles.
1392 2023-03-10 Jakub Jelinek <jakub@redhat.com>
1394 PR tree-optimization/109008
1395 * range-op-float.cc (float_widen_lhs_range): If not
1396 -frounding-math and not IBM double double format, extend lhs
1397 range just by 0.5ulp rather than 1ulp in each direction.
1399 2023-03-10 Jakub Jelinek <jakub@redhat.com>
1402 * config.gcc (x86_64-*-cygwin*): Don't add i386/t-cygwin-w64 into
1404 * config/i386/t-cygwin-w64: Remove.
1406 2023-03-10 Jakub Jelinek <jakub@redhat.com>
1409 * tree-core.h (tree_code_type, tree_code_length): For C++11 or
1410 C++14, don't declare as extern const arrays.
1411 (tree_code_type_tmpl, tree_code_length_tmpl): New types with
1412 static constexpr member arrays for C++11 or C++14.
1413 * tree.h (TREE_CODE_CLASS): For C++11 or C++14 use
1414 tree_code_type_tmpl <0>::tree_code_type instead of tree_code_type.
1415 (TREE_CODE_LENGTH): For C++11 or C++14 use
1416 tree_code_length_tmpl <0>::tree_code_length instead of
1418 * tree.cc (tree_code_type, tree_code_length): Remove.
1420 2023-03-10 Jakub Jelinek <jakub@redhat.com>
1423 * common.opt (fcanon-prefix-map): New option.
1424 * opts.cc: Include file-prefix-map.h.
1425 (flag_canon_prefix_map): New variable.
1426 (common_handle_option): Handle OPT_fcanon_prefix_map.
1427 (gen_command_line_string): Ignore OPT_fcanon_prefix_map.
1428 * file-prefix-map.h (flag_canon_prefix_map): Declare.
1429 * file-prefix-map.cc (struct file_prefix_map): Add canonicalize
1431 (add_prefix_map): Initialize canonicalize member from
1432 flag_canon_prefix_map, and if true canonicalize it using lrealpath.
1433 (remap_filename): Revert 2022-11-01 and 2022-11-07 changes,
1434 use lrealpath result only for map->canonicalize map entries.
1435 * lto-opts.cc (lto_write_options): Ignore OPT_fcanon_prefix_map.
1436 * opts-global.cc (handle_common_deferred_options): Clear
1437 flag_canon_prefix_map at the start and handle OPT_fcanon_prefix_map.
1438 * doc/invoke.texi (-fcanon-prefix-map): Document.
1439 (-ffile-prefix-map, -fdebug-prefix-map, -fprofile-prefix-map): Add
1440 see also for -fcanon-prefix-map.
1441 * doc/cppopts.texi (-fmacro-prefix-map): Likewise.
1443 2023-03-10 Jakub Jelinek <jakub@redhat.com>
1446 * cgraphunit.cc (check_global_declaration): Don't warn for unused
1447 variables which have OPT_Wunused_variable warning suppressed.
1449 2023-03-10 Jakub Jelinek <jakub@redhat.com>
1451 PR tree-optimization/109008
1452 * range-op-float.cc (float_widen_lhs_range): If lb is
1453 minimum representable finite number or ub is maximum
1454 representable finite number, instead of widening it to
1455 -inf or inf widen it to negative or positive 0x0.8p+(EMAX+1).
1456 Temporarily clear flag_finite_math_only when canonicalizing
1459 2023-03-10 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
1461 * config/riscv/riscv-builtins.cc (riscv_gimple_fold_builtin): New function.
1462 * config/riscv/riscv-protos.h (riscv_gimple_fold_builtin): Ditto.
1463 (gimple_fold_builtin): Ditto.
1464 * config/riscv/riscv-vector-builtins-bases.cc (class read_vl): New class.
1465 (class vleff): Ditto.
1467 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
1468 * config/riscv/riscv-vector-builtins-functions.def (read_vl): Ditto.
1470 * config/riscv/riscv-vector-builtins-shapes.cc (struct read_vl_def): Ditto.
1471 (struct fault_load_def): Ditto.
1473 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
1474 * config/riscv/riscv-vector-builtins.cc
1475 (rvv_arg_type_info::get_tree_type): Add size_ptr.
1476 (gimple_folder::gimple_folder): New class.
1477 (gimple_folder::fold): Ditto.
1478 (gimple_fold_builtin): New function.
1479 (get_read_vl_instance): Ditto.
1480 (get_read_vl_decl): Ditto.
1481 * config/riscv/riscv-vector-builtins.def (size_ptr): Add size_ptr.
1482 * config/riscv/riscv-vector-builtins.h (class gimple_folder): New class.
1483 (get_read_vl_instance): New function.
1484 (get_read_vl_decl): Ditto.
1485 * config/riscv/riscv-vsetvl.cc (fault_first_load_p): Ditto.
1486 (read_vl_insn_p): Ditto.
1487 (available_occurrence_p): Ditto.
1488 (backward_propagate_worthwhile_p): Ditto.
1489 (gen_vsetvl_pat): Adapt for vleff support.
1490 (get_forward_read_vl_insn): New function.
1491 (get_backward_fault_first_load_insn): Ditto.
1492 (source_equal_p): Adapt for vleff support.
1493 (first_ratio_invalid_for_second_sew_p): Remove.
1494 (first_ratio_invalid_for_second_lmul_p): Ditto.
1495 (first_lmul_less_than_second_lmul_p): Ditto.
1496 (first_ratio_less_than_second_ratio_p): Ditto.
1497 (support_relaxed_compatible_p): New function.
1498 (vector_insn_info::operator>): Remove.
1499 (vector_insn_info::operator>=): Refine.
1500 (vector_insn_info::parse_insn): Adapt for vleff support.
1501 (vector_insn_info::compatible_p): Ditto.
1502 (vector_insn_info::update_fault_first_load_avl): New function.
1503 (pass_vsetvl::transfer_after): Adapt for vleff support.
1504 (pass_vsetvl::demand_fusion): Ditto.
1505 (pass_vsetvl::cleanup_insns): Ditto.
1506 * config/riscv/riscv-vsetvl.def (DEF_INCOMPATIBLE_COND): Remove
1507 redundant condtions.
1508 * config/riscv/riscv-vsetvl.h (struct demands_cond): New function.
1509 * config/riscv/riscv.cc (TARGET_GIMPLE_FOLD_BUILTIN): New target hook.
1510 * config/riscv/riscv.md: Adapt for vleff support.
1511 * config/riscv/t-riscv: Ditto.
1512 * config/riscv/vector-iterators.md: New iterator.
1513 * config/riscv/vector.md (read_vlsi): New pattern.
1514 (read_vldi_zero_extend): Ditto.
1515 (@pred_fault_load<mode>): Ditto.
1517 2023-03-10 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
1519 * config/riscv/riscv-vector-builtins.cc
1520 (function_expander::use_ternop_insn): Use maybe_gen_insn instead.
1521 (function_expander::use_widen_ternop_insn): Ditto.
1522 * optabs.cc (maybe_gen_insn): Extend nops handling.
1524 2023-03-10 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
1526 * config/riscv/riscv-vector-builtins-bases.cc: Split indexed load
1527 patterns according to RVV ISA.
1528 * config/riscv/vector-iterators.md: New iterators.
1529 * config/riscv/vector.md
1530 (@pred_indexed_<order>load<VNX1_QHSD:mode><VNX1_QHSDI:mode>): Remove.
1531 (@pred_indexed_<order>load<mode>_same_eew): New pattern.
1532 (@pred_indexed_<order>load<mode>_x2_greater_eew): Ditto.
1533 (@pred_indexed_<order>load<mode>_x4_greater_eew): Ditto.
1534 (@pred_indexed_<order>load<mode>_x8_greater_eew): Ditto.
1535 (@pred_indexed_<order>load<mode>_x2_smaller_eew): Ditto.
1536 (@pred_indexed_<order>load<mode>_x4_smaller_eew): Ditto.
1537 (@pred_indexed_<order>load<mode>_x8_smaller_eew): Ditto.
1538 (@pred_indexed_<order>load<VNX2_QHSD:mode><VNX2_QHSDI:mode>): Remove.
1539 (@pred_indexed_<order>load<VNX4_QHSD:mode><VNX4_QHSDI:mode>): Ditto.
1540 (@pred_indexed_<order>load<VNX8_QHSD:mode><VNX8_QHSDI:mode>): Ditto.
1541 (@pred_indexed_<order>load<VNX16_QHS:mode><VNX16_QHSI:mode>): Ditto.
1542 (@pred_indexed_<order>load<VNX32_QH:mode><VNX32_QHI:mode>): Ditto.
1543 (@pred_indexed_<order>load<VNX64_Q:mode><VNX64_Q:mode>): Ditto.
1545 2023-03-10 Michael Collison <collison@rivosinc.com>
1547 * tree-vect-loop-manip.cc (vect_do_peeling): Use
1548 result of constant_lower_bound instead of vf for the lower
1549 bound of the epilog loop trip count.
1551 2023-03-09 Tamar Christina <tamar.christina@arm.com>
1553 * passes.cc (emergency_dump_function): Finish graph generation.
1555 2023-03-09 Tamar Christina <tamar.christina@arm.com>
1557 * config/aarch64/aarch64.md (tbranch_<code><mode>3): Restrict to SHORT
1558 and bottom bit only.
1560 2023-03-09 Andrew Pinski <apinski@marvell.com>
1562 PR tree-optimization/108980
1563 * gimple-array-bounds.cc (array_bounds_checker::check_array_ref):
1564 Reorgnize the call to warning for not strict flexible arrays
1565 to be before the check of warned.
1567 2023-03-09 Jason Merrill <jason@redhat.com>
1569 * doc/extend.texi: Comment out __is_deducible docs.
1571 2023-03-09 Jason Merrill <jason@redhat.com>
1574 * doc/extend.texi (Type Traits):: Document __is_deducible.
1576 2023-03-09 Costas Argyris <costas.argyris@gmail.com>
1579 * config.host: add object for x86_64-*-mingw*.
1580 * config/i386/sym-mingw32.cc: dummy file to attach
1582 * config/i386/utf8-mingw32.rc: windres resource file.
1583 * config/i386/winnt-utf8.manifest: XML manifest to
1585 * config/i386/x-mingw32: reference to x-mingw32-utf8.
1586 * config/i386/x-mingw32-utf8: Makefile fragment to
1587 embed UTF-8 manifest.
1589 2023-03-09 Vladimir N. Makarov <vmakarov@redhat.com>
1591 * lra-constraints.cc (process_alt_operands): Use operand modes for
1592 clobbered regs instead of the biggest access mode.
1594 2023-03-09 Richard Biener <rguenther@suse.de>
1596 PR middle-end/108995
1597 * fold-const.cc (extract_muldiv_1): Avoid folding
1598 (CST * b) / CST2 when sanitizing overflow and we rely on
1599 overflow being undefined.
1601 2023-03-09 Jakub Jelinek <jakub@redhat.com>
1602 Richard Biener <rguenther@suse.de>
1604 PR tree-optimization/109008
1605 * range-op-float.cc (float_widen_lhs_range): New function.
1606 (foperator_plus::op1_range, foperator_minus::op1_range,
1607 foperator_minus::op2_range, foperator_mult::op1_range,
1608 foperator_div::op1_range, foperator_div::op2_range): Use it.
1610 2023-03-07 Jonathan Grant <jg@jguk.org>
1613 * doc/invoke.texi (Instrumentation Options): Clarify
1614 LeakSanitizer behavior.
1616 2023-03-07 Benson Muite <benson_muite@emailplus.org>
1618 * doc/install.texi (Prerequisites): Add link to gmplib.org.
1620 2023-03-07 Pan Li <pan2.li@intel.com>
1621 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
1625 * config/riscv/riscv-modes.def (ADJUST_PRECISION): Adjust VNx*BI
1627 * config/riscv/riscv.cc (riscv_v_adjust_precision): New.
1628 * config/riscv/riscv.h (riscv_v_adjust_precision): New.
1629 * genmodes.cc (adj_precision): New.
1630 (ADJUST_PRECISION): New.
1631 (emit_mode_adjustments): Handle ADJUST_PRECISION.
1633 2023-03-07 Hans-Peter Nilsson <hp@axis.com>
1635 * doc/sourcebuild.texi: Document check_effective_target_tail_call.
1637 2023-03-06 Paul-Antoine Arras <pa@codesourcery.com>
1639 * config/gcn/gcn-valu.md (<expander><mode>3_exec): Add patterns for
1640 {s|u}{max|min} in QI, HI and DI modes.
1641 (<expander><mode>3): Add pattern for {s|u}{max|min} in DI mode.
1642 (cond_<fexpander><mode>): Add pattern for cond_f{max|min}.
1643 (cond_<expander><mode>): Add pattern for cond_{s|u}{max|min}.
1644 * config/gcn/gcn.cc (gcn_spill_class): Allow the exec register to be
1647 2023-03-06 Richard Biener <rguenther@suse.de>
1649 PR tree-optimization/109025
1650 * tree-vect-loop.cc (vect_is_simple_reduction): Verify
1651 the inner LC PHI use is the inner loop PHI latch definition
1652 before classifying an outer PHI as double reduction.
1654 2023-03-06 Jan Hubicka <hubicka@ucw.cz>
1657 * config/i386/x86-tune.def (X86_TUNE_USE_SCATTER_2PARTS): Enable for
1659 (X86_TUNE_USE_SCATTER_4PARTS): Likewise.
1660 (X86_TUNE_USE_SCATTER): Likewise.
1662 2023-03-06 Xi Ruoyao <xry111@xry111.site>
1665 * config/loongarch/loongarch.h (FP_RETURN): Use
1666 TARGET_*_FLOAT_ABI instead of TARGET_*_FLOAT.
1667 (UNITS_PER_FP_ARG): Likewise.
1669 2023-03-05 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
1671 * config/riscv/riscv-vsetvl.cc (reg_available_p): Fix bug.
1672 (pass_vsetvl::backward_demand_fusion): Ditto.
1674 2023-03-05 Liao Shihua <shihua@iscas.ac.cn>
1675 SiYu Wu <siyu@isrc.iscas.ac.cn>
1677 * config/riscv/crypto.md (riscv_sm3p0_<mode>): Add ZKSED's and ZKSH's
1679 (riscv_sm3p1_<mode>): New.
1680 (riscv_sm4ed_<mode>): New.
1681 (riscv_sm4ks_<mode>): New.
1682 * config/riscv/riscv-builtins.cc (AVAIL): Add ZKSED's and ZKSH's AVAIL.
1683 * config/riscv/riscv-scalar-crypto.def (RISCV_BUILTIN): Add ZKSED's and
1684 ZKSH's built-in functions.
1686 2023-03-05 Liao Shihua <shihua@iscas.ac.cn>
1687 SiYu Wu <siyu@isrc.iscas.ac.cn>
1689 * config/riscv/crypto.md (riscv_sha256sig0_<mode>): Add ZKNH's instructions.
1690 (riscv_sha256sig1_<mode>): New.
1691 (riscv_sha256sum0_<mode>): New.
1692 (riscv_sha256sum1_<mode>): New.
1693 (riscv_sha512sig0h): New.
1694 (riscv_sha512sig0l): New.
1695 (riscv_sha512sig1h): New.
1696 (riscv_sha512sig1l): New.
1697 (riscv_sha512sum0r): New.
1698 (riscv_sha512sum1r): New.
1699 (riscv_sha512sig0): New.
1700 (riscv_sha512sig1): New.
1701 (riscv_sha512sum0): New.
1702 (riscv_sha512sum1): New.
1703 * config/riscv/riscv-builtins.cc (AVAIL): And ZKNH's AVAIL.
1704 * config/riscv/riscv-scalar-crypto.def (RISCV_BUILTIN): And ZKNH's
1706 (DIRECT_BUILTIN): Add new.
1708 2023-03-05 Liao Shihua <shihua@iscas.ac.cn>
1709 SiYu Wu <siyu@isrc.iscas.ac.cn>
1711 * config/riscv/constraints.md (D03): Add constants of bs and rnum.
1713 * config/riscv/crypto.md (riscv_aes32dsi): Add ZKND's and ZKNE's instructions.
1714 (riscv_aes32dsmi): New.
1715 (riscv_aes64ds): New.
1716 (riscv_aes64dsm): New.
1717 (riscv_aes64im): New.
1718 (riscv_aes64ks1i): New.
1719 (riscv_aes64ks2): New.
1720 (riscv_aes32esi): New.
1721 (riscv_aes32esmi): New.
1722 (riscv_aes64es): New.
1723 (riscv_aes64esm): New.
1724 * config/riscv/riscv-builtins.cc (AVAIL): Add ZKND's and ZKNE's AVAIL.
1725 * config/riscv/riscv-scalar-crypto.def (DIRECT_BUILTIN): Add ZKND's and
1726 ZKNE's built-in functions.
1728 2023-03-05 Liao Shihua <shihua@iscas.ac.cn>
1729 SiYu Wu <siyu@isrc.iscas.ac.cn>
1731 * config/riscv/bitmanip.md: Add ZBKB's instructions.
1732 * config/riscv/riscv-builtins.cc (AVAIL): Add new.
1733 * config/riscv/riscv.md: Add new type for crypto instructions.
1734 * config/riscv/crypto.md: Add Scalar Cryptography extension's machine
1736 * config/riscv/riscv-scalar-crypto.def: Add Scalar Cryptography
1737 extension's built-in function file.
1739 2023-03-05 Liao Shihua <shihua@iscas.ac.cn>
1740 SiYu Wu <siyu@isrc.iscas.ac.cn>
1742 * config/riscv/riscv-builtins.cc (RISCV_FTYPE_NAME2): New.
1743 (RISCV_FTYPE_NAME3): New.
1744 (RISCV_ATYPE_QI): New.
1745 (RISCV_ATYPE_HI): New.
1746 (RISCV_FTYPE_ATYPES2): New.
1747 (RISCV_FTYPE_ATYPES3): New.
1748 * config/riscv/riscv-ftypes.def (2): New.
1751 2023-03-05 Vineet Gupta <vineetg@rivosinc.com>
1753 * config/riscv/riscv.cc (riscv_rtx_costs): Fixed IN_RANGE() to
1756 2023-03-05 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
1757 kito-cheng <kito.cheng@sifive.com>
1759 * config/riscv/predicates.md (vector_any_register_operand): New predicate.
1760 * config/riscv/riscv-c.cc (riscv_check_builtin_call): New function.
1761 (riscv_register_pragmas): Add builtin function check call.
1762 * config/riscv/riscv-protos.h (RVV_VUNDEF): Adapt macro.
1763 (check_builtin_call): New function.
1764 * config/riscv/riscv-vector-builtins-bases.cc (class vundefined): New class.
1765 (class vreinterpret): Ditto.
1766 (class vlmul_ext): Ditto.
1767 (class vlmul_trunc): Ditto.
1768 (class vset): Ditto.
1769 (class vget): Ditto.
1771 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
1772 * config/riscv/riscv-vector-builtins-functions.def (vluxei8): Change name.
1788 (vundefined): Add new intrinsic.
1789 (vreinterpret): Ditto.
1791 (vlmul_trunc): Ditto.
1794 * config/riscv/riscv-vector-builtins-shapes.cc (struct return_mask_def): New class.
1795 (struct narrow_alu_def): Ditto.
1796 (struct reduc_alu_def): Ditto.
1797 (struct vundefined_def): Ditto.
1798 (struct misc_def): Ditto.
1799 (struct vset_def): Ditto.
1800 (struct vget_def): Ditto.
1802 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
1803 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_EEW8_INTERPRET_OPS): New def.
1804 (DEF_RVV_EEW16_INTERPRET_OPS): Ditto.
1805 (DEF_RVV_EEW32_INTERPRET_OPS): Ditto.
1806 (DEF_RVV_EEW64_INTERPRET_OPS): Ditto.
1807 (DEF_RVV_X2_VLMUL_EXT_OPS): Ditto.
1808 (DEF_RVV_X4_VLMUL_EXT_OPS): Ditto.
1809 (DEF_RVV_X8_VLMUL_EXT_OPS): Ditto.
1810 (DEF_RVV_X16_VLMUL_EXT_OPS): Ditto.
1811 (DEF_RVV_X32_VLMUL_EXT_OPS): Ditto.
1812 (DEF_RVV_X64_VLMUL_EXT_OPS): Ditto.
1813 (DEF_RVV_LMUL1_OPS): Ditto.
1814 (DEF_RVV_LMUL2_OPS): Ditto.
1815 (DEF_RVV_LMUL4_OPS): Ditto.
1816 (vint16mf4_t): Ditto.
1817 (vint16mf2_t): Ditto.
1818 (vint16m1_t): Ditto.
1819 (vint16m2_t): Ditto.
1820 (vint16m4_t): Ditto.
1821 (vint16m8_t): Ditto.
1822 (vint32mf2_t): Ditto.
1823 (vint32m1_t): Ditto.
1824 (vint32m2_t): Ditto.
1825 (vint32m4_t): Ditto.
1826 (vint32m8_t): Ditto.
1827 (vint64m1_t): Ditto.
1828 (vint64m2_t): Ditto.
1829 (vint64m4_t): Ditto.
1830 (vint64m8_t): Ditto.
1831 (vuint16mf4_t): Ditto.
1832 (vuint16mf2_t): Ditto.
1833 (vuint16m1_t): Ditto.
1834 (vuint16m2_t): Ditto.
1835 (vuint16m4_t): Ditto.
1836 (vuint16m8_t): Ditto.
1837 (vuint32mf2_t): Ditto.
1838 (vuint32m1_t): Ditto.
1839 (vuint32m2_t): Ditto.
1840 (vuint32m4_t): Ditto.
1841 (vuint32m8_t): Ditto.
1842 (vuint64m1_t): Ditto.
1843 (vuint64m2_t): Ditto.
1844 (vuint64m4_t): Ditto.
1845 (vuint64m8_t): Ditto.
1846 (vint8mf4_t): Ditto.
1847 (vint8mf2_t): Ditto.
1852 (vuint8mf4_t): Ditto.
1853 (vuint8mf2_t): Ditto.
1854 (vuint8m1_t): Ditto.
1855 (vuint8m2_t): Ditto.
1856 (vuint8m4_t): Ditto.
1857 (vuint8m8_t): Ditto.
1858 (vint8mf8_t): Ditto.
1859 (vuint8mf8_t): Ditto.
1860 (vfloat32mf2_t): Ditto.
1861 (vfloat32m1_t): Ditto.
1862 (vfloat32m2_t): Ditto.
1863 (vfloat32m4_t): Ditto.
1864 (vfloat64m1_t): Ditto.
1865 (vfloat64m2_t): Ditto.
1866 (vfloat64m4_t): Ditto.
1867 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_TYPE): Ditto.
1868 (DEF_RVV_EEW8_INTERPRET_OPS): Ditto.
1869 (DEF_RVV_EEW16_INTERPRET_OPS): Ditto.
1870 (DEF_RVV_EEW32_INTERPRET_OPS): Ditto.
1871 (DEF_RVV_EEW64_INTERPRET_OPS): Ditto.
1872 (DEF_RVV_X2_VLMUL_EXT_OPS): Ditto.
1873 (DEF_RVV_X4_VLMUL_EXT_OPS): Ditto.
1874 (DEF_RVV_X8_VLMUL_EXT_OPS): Ditto.
1875 (DEF_RVV_X16_VLMUL_EXT_OPS): Ditto.
1876 (DEF_RVV_X32_VLMUL_EXT_OPS): Ditto.
1877 (DEF_RVV_X64_VLMUL_EXT_OPS): Ditto.
1878 (DEF_RVV_LMUL1_OPS): Ditto.
1879 (DEF_RVV_LMUL2_OPS): Ditto.
1880 (DEF_RVV_LMUL4_OPS): Ditto.
1881 (DEF_RVV_TYPE_INDEX): Ditto.
1882 (required_extensions_p): Adapt for new intrinsic support/
1883 (get_required_extensions): New function.
1884 (check_required_extensions): Ditto.
1885 (unsigned_base_type_p): Remove.
1886 (rvv_arg_type_info::get_scalar_ptr_type): New function.
1887 (get_mode_for_bitsize): Remove.
1888 (rvv_arg_type_info::get_scalar_const_ptr_type): New function.
1889 (rvv_arg_type_info::get_base_vector_type): Ditto.
1890 (rvv_arg_type_info::get_function_type_index): Ditto.
1891 (DEF_RVV_BASE_TYPE): New def.
1892 (function_builder::apply_predication): New class.
1893 (function_expander::mask_mode): Ditto.
1894 (function_checker::function_checker): Ditto.
1895 (function_checker::report_non_ice): Ditto.
1896 (function_checker::report_out_of_range): Ditto.
1897 (function_checker::require_immediate): Ditto.
1898 (function_checker::require_immediate_range): Ditto.
1899 (function_checker::check): Ditto.
1900 (check_builtin_call): Ditto.
1901 * config/riscv/riscv-vector-builtins.def (DEF_RVV_TYPE): New def.
1902 (DEF_RVV_BASE_TYPE): Ditto.
1903 (DEF_RVV_TYPE_INDEX): Ditto.
1911 (vuint8mf8_t): Ditto.
1912 (vuint8mf4_t): Ditto.
1913 (vuint8mf2_t): Ditto.
1914 (vuint8m1_t): Ditto.
1915 (vuint8m2_t): Ditto.
1917 (vuint8m4_t): Ditto.
1919 (vuint8m8_t): Ditto.
1920 (vint16mf4_t): Ditto.
1921 (vuint16mf2_t): Ditto.
1922 (vuint16m1_t): Ditto.
1923 (vuint16m2_t): Ditto.
1924 (vuint16m4_t): Ditto.
1925 (vuint16m8_t): Ditto.
1926 (vint32mf2_t): Ditto.
1927 (vuint32m1_t): Ditto.
1928 (vuint32m2_t): Ditto.
1929 (vuint32m4_t): Ditto.
1930 (vuint32m8_t): Ditto.
1931 (vuint64m1_t): Ditto.
1932 (vuint64m2_t): Ditto.
1933 (vuint64m4_t): Ditto.
1934 (vuint64m8_t): Ditto.
1935 (vfloat32mf2_t): Ditto.
1936 (vfloat32m1_t): Ditto.
1937 (vfloat32m2_t): Ditto.
1938 (vfloat32m4_t): Ditto.
1939 (vfloat32m8_t): Ditto.
1940 (vfloat64m1_t): Ditto.
1941 (vfloat64m4_t): Ditto.
1942 (vector): Move it def.
1945 (signed_vector): Ditto.
1946 (unsigned_vector): Ditto.
1947 (unsigned_scalar): Ditto.
1948 (vector_ptr): Ditto.
1949 (scalar_ptr): Ditto.
1950 (scalar_const_ptr): Ditto.
1954 (unsigned_long): Ditto.
1956 (eew8_index): Ditto.
1957 (eew16_index): Ditto.
1958 (eew32_index): Ditto.
1959 (eew64_index): Ditto.
1960 (shift_vector): Ditto.
1961 (double_trunc_vector): Ditto.
1962 (quad_trunc_vector): Ditto.
1963 (oct_trunc_vector): Ditto.
1964 (double_trunc_scalar): Ditto.
1965 (double_trunc_signed_vector): Ditto.
1966 (double_trunc_unsigned_vector): Ditto.
1967 (double_trunc_unsigned_scalar): Ditto.
1968 (double_trunc_float_vector): Ditto.
1969 (float_vector): Ditto.
1970 (lmul1_vector): Ditto.
1971 (widen_lmul1_vector): Ditto.
1972 (eew8_interpret): Ditto.
1973 (eew16_interpret): Ditto.
1974 (eew32_interpret): Ditto.
1975 (eew64_interpret): Ditto.
1976 (vlmul_ext_x2): Ditto.
1977 (vlmul_ext_x4): Ditto.
1978 (vlmul_ext_x8): Ditto.
1979 (vlmul_ext_x16): Ditto.
1980 (vlmul_ext_x32): Ditto.
1981 (vlmul_ext_x64): Ditto.
1982 * config/riscv/riscv-vector-builtins.h (DEF_RVV_BASE_TYPE): New def.
1983 (struct function_type_info): New function.
1984 (struct rvv_arg_type_info): Ditto.
1985 (class function_checker): New class.
1986 (rvv_arg_type_info::get_scalar_type): New function.
1987 (rvv_arg_type_info::get_vector_type): Ditto.
1988 (function_expander::ret_mode): New function.
1989 (function_checker::arg_mode): Ditto.
1990 (function_checker::ret_mode): Ditto.
1991 * config/riscv/t-riscv: Add generator.
1992 * config/riscv/vector-iterators.md: New iterators.
1993 * config/riscv/vector.md (vundefined<mode>): New pattern.
1994 (@vundefined<mode>): Ditto.
1995 (@vreinterpret<mode>): Ditto.
1996 (@vlmul_extx2<mode>): Ditto.
1997 (@vlmul_extx4<mode>): Ditto.
1998 (@vlmul_extx8<mode>): Ditto.
1999 (@vlmul_extx16<mode>): Ditto.
2000 (@vlmul_extx32<mode>): Ditto.
2001 (@vlmul_extx64<mode>): Ditto.
2002 (*vlmul_extx2<mode>): Ditto.
2003 (*vlmul_extx4<mode>): Ditto.
2004 (*vlmul_extx8<mode>): Ditto.
2005 (*vlmul_extx16<mode>): Ditto.
2006 (*vlmul_extx32<mode>): Ditto.
2007 (*vlmul_extx64<mode>): Ditto.
2008 * config/riscv/genrvv-type-indexer.cc: New file.
2010 2023-03-05 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
2012 * config/riscv/riscv-protos.h (enum vlen_enum): New enum.
2013 (slide1_sew64_helper): New function.
2014 * config/riscv/riscv-v.cc (compute_vlmax): Ditto.
2015 (get_unknown_min_value): Ditto.
2016 (force_vector_length_operand): Ditto.
2017 (gen_no_side_effects_vsetvl_rtx): Ditto.
2018 (get_vl_x2_rtx): Ditto.
2019 (slide1_sew64_helper): Ditto.
2020 * config/riscv/riscv-vector-builtins-bases.cc (class slideop): New class.
2021 (class vrgather): Ditto.
2022 (class vrgatherei16): Ditto.
2023 (class vcompress): Ditto.
2025 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
2026 * config/riscv/riscv-vector-builtins-functions.def (vslideup): Ditto.
2027 (vslidedown): Ditto.
2029 (vslide1down): Ditto.
2030 (vfslide1up): Ditto.
2031 (vfslide1down): Ditto.
2033 (vrgatherei16): Ditto.
2035 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_EI16_OPS): New macro.
2036 (vint8mf8_t): Ditto.
2037 (vint8mf4_t): Ditto.
2038 (vint8mf2_t): Ditto.
2042 (vint16mf4_t): Ditto.
2043 (vint16mf2_t): Ditto.
2044 (vint16m1_t): Ditto.
2045 (vint16m2_t): Ditto.
2046 (vint16m4_t): Ditto.
2047 (vint16m8_t): Ditto.
2048 (vint32mf2_t): Ditto.
2049 (vint32m1_t): Ditto.
2050 (vint32m2_t): Ditto.
2051 (vint32m4_t): Ditto.
2052 (vint32m8_t): Ditto.
2053 (vint64m1_t): Ditto.
2054 (vint64m2_t): Ditto.
2055 (vint64m4_t): Ditto.
2056 (vint64m8_t): Ditto.
2057 (vuint8mf8_t): Ditto.
2058 (vuint8mf4_t): Ditto.
2059 (vuint8mf2_t): Ditto.
2060 (vuint8m1_t): Ditto.
2061 (vuint8m2_t): Ditto.
2062 (vuint8m4_t): Ditto.
2063 (vuint16mf4_t): Ditto.
2064 (vuint16mf2_t): Ditto.
2065 (vuint16m1_t): Ditto.
2066 (vuint16m2_t): Ditto.
2067 (vuint16m4_t): Ditto.
2068 (vuint16m8_t): Ditto.
2069 (vuint32mf2_t): Ditto.
2070 (vuint32m1_t): Ditto.
2071 (vuint32m2_t): Ditto.
2072 (vuint32m4_t): Ditto.
2073 (vuint32m8_t): Ditto.
2074 (vuint64m1_t): Ditto.
2075 (vuint64m2_t): Ditto.
2076 (vuint64m4_t): Ditto.
2077 (vuint64m8_t): Ditto.
2078 (vfloat32mf2_t): Ditto.
2079 (vfloat32m1_t): Ditto.
2080 (vfloat32m2_t): Ditto.
2081 (vfloat32m4_t): Ditto.
2082 (vfloat32m8_t): Ditto.
2083 (vfloat64m1_t): Ditto.
2084 (vfloat64m2_t): Ditto.
2085 (vfloat64m4_t): Ditto.
2086 (vfloat64m8_t): Ditto.
2087 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_EI16_OPS): Ditto.
2088 * config/riscv/riscv.md: Adjust RVV instruction types.
2089 * config/riscv/vector-iterators.md (down): New iterator.
2090 (=vd,vr): New attribute.
2091 (UNSPEC_VSLIDE1UP): New unspec.
2092 * config/riscv/vector.md (@pred_slide<ud><mode>): New pattern.
2093 (*pred_slide<ud><mode>): Ditto.
2094 (*pred_slide<ud><mode>_extended): Ditto.
2095 (@pred_gather<mode>): Ditto.
2096 (@pred_gather<mode>_scalar): Ditto.
2097 (@pred_gatherei16<mode>): Ditto.
2098 (@pred_compress<mode>): Ditto.
2100 2023-03-05 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
2102 * config/riscv/riscv-vector-builtins.cc: Remove void_type_node.
2104 2023-03-05 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
2106 * config/riscv/constraints.md (Wb1): New constraint.
2107 * config/riscv/predicates.md
2108 (vector_least_significant_set_mask_operand): New predicate.
2109 (vector_broadcast_mask_operand): Ditto.
2110 * config/riscv/riscv-protos.h (enum vlmul_type): Adjust.
2111 (gen_scalar_move_mask): New function.
2112 * config/riscv/riscv-v.cc (gen_scalar_move_mask): Ditto.
2113 * config/riscv/riscv-vector-builtins-bases.cc (class vmv): New class.
2114 (class vmv_s): Ditto.
2116 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
2117 * config/riscv/riscv-vector-builtins-functions.def (vmv_x): Ditto.
2121 * config/riscv/riscv-vector-builtins-shapes.cc (struct scalar_move_def): Ditto.
2123 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
2124 * config/riscv/riscv-vector-builtins.cc (function_expander::mask_mode): Ditto.
2125 (function_expander::use_exact_insn): New function.
2126 (function_expander::use_contiguous_load_insn): New function.
2127 (function_expander::use_contiguous_store_insn): New function.
2128 (function_expander::use_ternop_insn): New function.
2129 (function_expander::use_widen_ternop_insn): New function.
2130 (function_expander::use_scalar_move_insn): New function.
2131 * config/riscv/riscv-vector-builtins.def (s): New operand suffix.
2132 * config/riscv/riscv-vector-builtins.h
2133 (function_expander::add_scalar_move_mask_operand): New class.
2134 * config/riscv/riscv-vsetvl.cc (ignore_vlmul_insn_p): New function.
2135 (scalar_move_insn_p): Ditto.
2136 (has_vsetvl_killed_avl_p): Ditto.
2137 (anticipatable_occurrence_p): Ditto.
2138 (insert_vsetvl): Ditto.
2139 (get_vl_vtype_info): Ditto.
2140 (calculate_sew): Ditto.
2141 (calculate_vlmul): Ditto.
2142 (incompatible_avl_p): Ditto.
2143 (different_sew_p): Ditto.
2144 (different_lmul_p): Ditto.
2145 (different_ratio_p): Ditto.
2146 (different_tail_policy_p): Ditto.
2147 (different_mask_policy_p): Ditto.
2148 (possible_zero_avl_p): Ditto.
2149 (first_ratio_invalid_for_second_sew_p): Ditto.
2150 (first_ratio_invalid_for_second_lmul_p): Ditto.
2151 (second_ratio_invalid_for_first_sew_p): Ditto.
2152 (second_ratio_invalid_for_first_lmul_p): Ditto.
2153 (second_sew_less_than_first_sew_p): Ditto.
2154 (first_sew_less_than_second_sew_p): Ditto.
2155 (compare_lmul): Ditto.
2156 (second_lmul_less_than_first_lmul_p): Ditto.
2157 (first_lmul_less_than_second_lmul_p): Ditto.
2158 (first_ratio_less_than_second_ratio_p): Ditto.
2159 (second_ratio_less_than_first_ratio_p): Ditto.
2160 (DEF_INCOMPATIBLE_COND): Ditto.
2161 (greatest_sew): Ditto.
2163 (second_sew): Ditto.
2164 (first_vlmul): Ditto.
2165 (second_vlmul): Ditto.
2166 (first_ratio): Ditto.
2167 (second_ratio): Ditto.
2168 (vlmul_for_first_sew_second_ratio): Ditto.
2169 (ratio_for_second_sew_first_vlmul): Ditto.
2170 (DEF_SEW_LMUL_FUSE_RULE): Ditto.
2171 (always_unavailable): Ditto.
2172 (avl_unavailable_p): Ditto.
2173 (sew_unavailable_p): Ditto.
2174 (lmul_unavailable_p): Ditto.
2175 (ge_sew_unavailable_p): Ditto.
2176 (ge_sew_lmul_unavailable_p): Ditto.
2177 (ge_sew_ratio_unavailable_p): Ditto.
2178 (DEF_UNAVAILABLE_COND): Ditto.
2179 (same_sew_lmul_demand_p): Ditto.
2180 (propagate_avl_across_demands_p): Ditto.
2181 (reg_available_p): Ditto.
2182 (avl_info::has_non_zero_avl): Ditto.
2183 (vl_vtype_info::has_non_zero_avl): Ditto.
2184 (vector_insn_info::operator>=): Refactor.
2185 (vector_insn_info::parse_insn): Adjust for scalar move.
2186 (vector_insn_info::demand_vl_vtype): Remove.
2187 (vector_insn_info::compatible_p): New function.
2188 (vector_insn_info::compatible_avl_p): Ditto.
2189 (vector_insn_info::compatible_vtype_p): Ditto.
2190 (vector_insn_info::available_p): Ditto.
2191 (vector_insn_info::merge): Ditto.
2192 (vector_insn_info::fuse_avl): Ditto.
2193 (vector_insn_info::fuse_sew_lmul): Ditto.
2194 (vector_insn_info::fuse_tail_policy): Ditto.
2195 (vector_insn_info::fuse_mask_policy): Ditto.
2196 (vector_insn_info::dump): Ditto.
2197 (vector_infos_manager::release): Ditto.
2198 (pass_vsetvl::compute_local_backward_infos): Adjust for scalar move support.
2199 (pass_vsetvl::get_backward_fusion_type): Adjust for scalar move support.
2200 (pass_vsetvl::hard_empty_block_p): Ditto.
2201 (pass_vsetvl::backward_demand_fusion): Ditto.
2202 (pass_vsetvl::forward_demand_fusion): Ditto.
2203 (pass_vsetvl::refine_vsetvls): Ditto.
2204 (pass_vsetvl::cleanup_vsetvls): Ditto.
2205 (pass_vsetvl::commit_vsetvls): Ditto.
2206 (pass_vsetvl::propagate_avl): Ditto.
2207 * config/riscv/riscv-vsetvl.h (enum demand_status): New class.
2208 (struct demands_pair): Ditto.
2209 (struct demands_cond): Ditto.
2210 (struct demands_fuse_rule): Ditto.
2211 * config/riscv/vector-iterators.md: New iterator.
2212 * config/riscv/vector.md (@pred_broadcast<mode>): New pattern.
2213 (*pred_broadcast<mode>): Ditto.
2214 (*pred_broadcast<mode>_extended_scalar): Ditto.
2215 (@pred_extract_first<mode>): Ditto.
2216 (*pred_extract_first<mode>): Ditto.
2217 (@pred_extract_first_trunc<mode>): Ditto.
2218 * config/riscv/riscv-vsetvl.def: New file.
2220 2023-03-05 Lin Sinan <sinan.lin@linux.alibaba.com>
2222 * config/riscv/bitmanip.md: allow 0 constant in max/min
2225 2023-03-05 Lin Sinan <sinan.lin@linux.alibaba.com>
2227 * config/riscv/bitmanip.md: Fix wrong index in the check.
2229 2023-03-04 Jakub Jelinek <jakub@redhat.com>
2231 PR middle-end/109006
2232 * vec.cc (test_auto_alias): Adjust comment for removal of
2234 * read-rtl-function.cc (function_reader::parse_block): Likewise.
2235 * gdbhooks.py: Likewise.
2237 2023-03-04 Jakub Jelinek <jakub@redhat.com>
2240 * selftest-diagnostic.cc
2241 (test_diagnostic_context::test_diagnostic_context): Set
2242 caret_max_width to 80.
2244 2023-03-03 Alexandre Oliva <oliva@adacore.com>
2246 * gimple-ssa-warn-access.cc
2247 (pass_waccess::check_dangling_stores): Skip non-stores.
2249 2023-03-03 Alexandre Oliva <oliva@adacore.com>
2251 * config/arm/vfp.md (*thumb2_movsi_vfp): Drop blank after tab
2252 after vmsr and vmrs, and lower the case of P0.
2254 2023-03-03 Jonathan Wakely <jwakely@redhat.com>
2256 PR middle-end/109006
2257 * gdbhooks.py (VecPrinter): Handle vec<T> as well as vec<T>*.
2259 2023-03-03 Jonathan Wakely <jwakely@redhat.com>
2261 PR middle-end/109006
2262 * gdbhooks.py (VecPrinter): Adjust for new vec layout.
2264 2023-03-03 Jakub Jelinek <jakub@redhat.com>
2267 * gimple-ssa-warn-access.cc (pass_waccess::maybe_check_access_sizes):
2268 Return immediately if OPT_Wnonnull or OPT_Wstringop_overflow_ is
2269 suppressed on stmt. For [static %E] warning, print access_nelts
2270 rather than access_size. Fix up comment wording.
2272 2023-03-03 Robin Dapp <rdapp@linux.ibm.com>
2274 * config/s390/driver-native.cc (s390_host_detect_local_cpu): Use
2275 arch14 instead of z16.
2277 2023-03-03 Anthony Green <green@moxielogic.com>
2279 * config/moxie/moxie.cc (TARGET_LRA_P): Remove.
2281 2023-03-03 Anthony Green <green@moxielogic.com>
2283 * config/moxie/constraints.md (A, B, W): Change
2284 define_constraint to define_memory_constraint.
2286 2023-03-03 Xi Ruoyao <xry111@xry111.site>
2288 * toplev.cc (process_options): Fix the spelling of
2289 "-fstack-clash-protection".
2291 2023-03-03 Richard Biener <rguenther@suse.de>
2293 PR tree-optimization/109002
2294 * tree-ssa-pre.cc (compute_partial_antic_aux): Properly
2295 PHI-translate ANTIC_IN.
2297 2023-03-03 Jakub Jelinek <jakub@redhat.com>
2299 PR tree-optimization/108988
2300 * gimple-fold.cc (gimple_fold_builtin_fputs): Fold len to
2301 size_type_node before passing it as argument to fwrite. Formatting
2304 2023-03-03 Richard Biener <rguenther@suse.de>
2307 * config/i386/i386.opt (--param x86-stv-max-visits): New param.
2308 * doc/invoke.texi (--param x86-stv-max-visits): Document it.
2309 * config/i386/i386-features.h (scalar_chain::max_visits): New.
2310 (scalar_chain::build): Add bitmap parameter, return boolean.
2311 (scalar_chain::add_insn): Likewise.
2312 (scalar_chain::analyze_register_chain): Likewise.
2313 * config/i386/i386-features.cc (scalar_chain::scalar_chain):
2314 Initialize max_visits.
2315 (scalar_chain::analyze_register_chain): When we exhaust
2316 max_visits, abort. Also abort when running into any
2318 (scalar_chain::add_insn): Propagate abort.
2319 (scalar_chain::build): Likewise. When aborting amend
2320 the set of disallowed insn with the insns set.
2321 (convert_scalars_to_vector): Adjust. Do not convert aborted
2324 2023-03-03 Richard Biener <rguenther@suse.de>
2327 * dwarf2out.cc (dwarf2out_late_global_decl): Do not
2328 generate a DIE for a function scope static.
2330 2023-03-03 Alexandre Oliva <oliva@adacore.com>
2332 * config/vx-common.h (WINT_TYPE): Alias to "wchar_t".
2334 2023-03-02 Jakub Jelinek <jakub@redhat.com>
2337 * target.h (emit_support_tinfos_callback): New typedef.
2338 * targhooks.h (default_emit_support_tinfos): Declare.
2339 * targhooks.cc (default_emit_support_tinfos): New function.
2340 * target.def (emit_support_tinfos): New target hook.
2341 * doc/tm.texi.in (emit_support_tinfos): Document it.
2342 * doc/tm.texi: Regenerated.
2343 * config/i386/i386.cc (ix86_emit_support_tinfos): New function.
2344 (TARGET_EMIT_SUPPORT_TINFOS): Redefine.
2346 2023-03-02 Vladimir N. Makarov <vmakarov@redhat.com>
2348 * ira-costs.cc: Include print-rtl.h.
2349 (record_reg_classes, scan_one_insn): Add code to print debug info.
2350 (record_operand_costs): Find and use smaller cost for hard reg
2353 2023-03-02 Kwok Cheung Yeung <kcy@codesourcery.com>
2354 Paul-Antoine Arras <pa@codesourcery.com>
2356 * builtins.cc (mathfn_built_in_explicit): New.
2357 * config/gcn/gcn.cc: Include case-cfn-macros.h.
2358 (mathfn_built_in_explicit): Add prototype.
2359 (gcn_vectorize_builtin_vectorized_function): New.
2360 (gcn_libc_has_function): New.
2361 (TARGET_LIBC_HAS_FUNCTION): Define.
2362 (TARGET_VECTORIZE_BUILTIN_VECTORIZED_FUNCTION): Define.
2364 2023-03-02 Richard Sandiford <richard.sandiford@arm.com>
2366 PR tree-optimization/108979
2367 * tree-vect-stmts.cc (vectorizable_operation): Don't mask
2368 operations on invariants.
2370 2023-03-02 Robin Dapp <rdapp@linux.ibm.com>
2372 * config/s390/predicates.md (vll_bias_operand): Add -1 bias.
2373 * config/s390/s390.cc (s390_option_override_internal): Make
2374 partial vector usage the default from z13 on.
2375 * config/s390/vector.md (len_load_v16qi): Add.
2376 (len_store_v16qi): Add.
2378 2023-03-02 Andre Vieira <andre.simoesdiasvieira@arm.com>
2380 * simplify-rtx.cc (simplify_context::simplify_subreg): Use byte instead
2381 of constant 0 offset.
2383 2023-03-02 Robert Suchanek <robert.suchanek@imgtec.com>
2385 * config/mips/mips.cc (mips_set_text_contents_type): Use HOST_WIDE_INT
2387 * config/mips/mips-protos.h (mips_set_text_contents_type): Likewise.
2389 2023-03-02 Junxian Zhu <zhujunxian@oss.cipunited.com>
2391 * config.gcc: add -with-{no-}msa build option.
2392 * config/mips/mips.h: Likewise.
2393 * doc/install.texi: Likewise.
2395 2023-03-02 Richard Sandiford <richard.sandiford@arm.com>
2397 PR tree-optimization/108603
2398 * explow.cc (convert_memory_address_addr_space_1): Only wrap
2399 the result of a recursive call in a CONST if no instructions
2402 2023-03-02 Richard Sandiford <richard.sandiford@arm.com>
2404 PR tree-optimization/108430
2405 * tree-vect-stmts.cc (vectorizable_condition): Fix handling
2406 of inverted condition.
2408 2023-03-02 Jakub Jelinek <jakub@redhat.com>
2411 * fold-const.cc (native_interpret_expr) <case REAL_CST>: Before memcmp
2412 comparison copy the bytes from ptr to a temporary buffer and clearing
2413 padding bits in there.
2415 2023-03-01 Tobias Burnus <tobias@codesourcery.com>
2417 PR middle-end/108545
2418 * gimplify.cc (struct tree_operand_hash_no_se): New.
2419 (omp_index_mapping_groups_1, omp_index_mapping_groups,
2420 omp_reindex_mapping_groups, omp_mapped_by_containing_struct,
2421 omp_tsort_mapping_groups_1, omp_tsort_mapping_groups,
2422 oacc_resolve_clause_dependencies, omp_build_struct_sibling_lists,
2423 gimplify_scan_omp_clauses): Use tree_operand_hash_no_se instead
2424 of tree_operand_hash.
2426 2023-03-01 LIU Hao <lh_mouse@126.com>
2429 * config/i386/host-mingw32.cc (mingw32_gt_pch_get_address):
2430 Remove the size limit `pch_VA_max_size`
2432 2023-03-01 Tobias Burnus <tobias@codesourcery.com>
2434 PR middle-end/108546
2435 * omp-low.cc (lower_omp_target): Remove optional handling
2436 on the receiver side, i.e. inside target (data), for
2439 2023-03-01 Jakub Jelinek <jakub@redhat.com>
2442 * cfgexpand.cc (expand_debug_expr): Handle WIDEN_{PLUS,MINUS}_EXPR
2443 and VEC_WIDEN_{PLUS,MINUS}_{HI,LO}_EXPR.
2445 2023-03-01 Richard Biener <rguenther@suse.de>
2447 PR tree-optimization/108970
2448 * tree-vect-loop-manip.cc (slpeel_can_duplicate_loop_p):
2449 Check we can copy the BBs.
2450 (slpeel_tree_duplicate_loop_to_edge_cfg): Avoid redundant
2452 (vect_do_peeling): Streamline error handling.
2454 2023-03-01 Richard Biener <rguenther@suse.de>
2456 PR tree-optimization/108950
2457 * tree-vect-patterns.cc (vect_recog_widen_sum_pattern):
2458 Check oprnd0 is defined in the loop.
2459 * tree-vect-loop.cc (vectorizable_reduction): Record all
2460 operands vector types, compute that of invariants and
2461 properly update their SLP nodes.
2463 2023-03-01 Kewen Lin <linkw@linux.ibm.com>
2466 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Allow
2467 implicit powerpc64 setting to be unset if 64 bit is enabled implicitly.
2469 2023-02-28 Qing Zhao <qing.zhao@oracle.com>
2471 PR middle-end/107411
2472 PR middle-end/107411
2473 * gimplify.cc (gimple_add_init_for_auto_var): Use sprintf to replace
2475 * tree-ssa-uninit.cc (warn_uninit): Handle the case when the
2476 LHS varaible of a .DEFERRED_INIT call doesn't have a DECL_NAME.
2478 2023-02-28 Jakub Jelinek <jakub@redhat.com>
2481 * ubsan.cc (ubsan_expand_bounds_ifn): Emit index >= bound
2482 comparison rather than index > bound.
2483 * gimple-fold.cc (gimple_fold_call): Use tree_int_cst_lt
2484 rather than tree_int_cst_le for IFN_UBSAN_BOUND comparison.
2485 * doc/invoke.texi (-fsanitize=bounds): Document that whether
2486 flexible array member-like arrays are instrumented or not depends
2487 on -fstrict-flex-arrays* options of strict_flex_array attributes.
2488 (-fsanitize=bounds-strict): Document that flexible array members
2489 are not instrumented.
2491 2023-02-27 Uroš Bizjak <ubizjak@gmail.com>
2495 * config/i386/i386.md (fmodxf3): Enable for flag_finite_math_only only.
2496 (fmod<mode>3): Ditto.
2497 (fpremxf4_i387): Ditto.
2498 (reminderxf3): Ditto.
2499 (reminder<mode>3): Ditto.
2500 (fprem1xf4_i387): Ditto.
2502 2023-02-27 Roger Sayle <roger@nextmovesoftware.com>
2504 * simplify-rtx.cc (simplify_unary_operation_1) <case FFS>: Avoid
2505 generating FFS with mismatched operand and result modes, by using
2506 an explicit SIGN_EXTEND/ZERO_EXTEND.
2507 <case POPCOUNT>: Likewise, for POPCOUNT of ZERO_EXTEND.
2508 <case PARITY>: Likewise, for PARITY of {ZERO,SIGN}_EXTEND.
2510 2023-02-27 Patrick Palka <ppalka@redhat.com>
2512 * hash-table.h (gt_pch_nx(hash_table<D>)): Remove static.
2513 * lra-int.h (lra_change_class): Likewise.
2514 * recog.h (which_op_alt): Likewise.
2515 * sel-sched-ir.h (sel_bb_empty_or_nop_p): Declare inline
2518 2023-02-27 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
2520 * config/xtensa/xtensa-protos.h (xtensa_match_CLAMPS_imms_p):
2522 * config/xtensa/xtensa.cc (xtensa_match_CLAMPS_imms_p):
2524 * config/xtensa/xtensa.h (TARGET_CLAMPS): New macro definition.
2525 * config/xtensa/xtensa.md (*xtensa_clamps): New insn pattern.
2527 2023-02-27 Max Filippov <jcmvbkbc@gmail.com>
2529 * config/xtensa/xtensa-dynconfig.cc (xtensa_get_config_v2)
2530 (xtensa_get_config_v3): New functions.
2532 2023-02-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2534 * config/aarch64/aarch64-simd.md (aarch64_abs<mode>): Fix typo in comment.
2536 2023-02-27 Lulu Cheng <chenglulu@loongson.cn>
2538 * config/host-linux.cc (TRY_EMPTY_VM_SPACE): Modify the value of
2539 the macro to 0x1000000000.
2541 2023-02-25 Gaius Mulley <gaiusmod2@gmail.com>
2544 * doc/gm2.texi (-fm2-pathname): New option documented.
2545 (-fm2-pathnameI): New option documented.
2546 (-fm2-prefix=): New option documented.
2547 (-fruntime-modules=): Update default module list.
2549 2023-02-25 Max Filippov <jcmvbkbc@gmail.com>
2552 * config/xtensa/xtensa-protos.h
2553 (xtensa_prepare_expand_call): Rename to xtensa_expand_call.
2554 * config/xtensa/xtensa.cc (xtensa_prepare_expand_call): Rename
2555 to xtensa_expand_call.
2556 (xtensa_expand_call): Emit the call and add a clobber expression
2557 for the static chain to it in case of windowed ABI.
2558 * config/xtensa/xtensa.md (call, call_value, sibcall)
2559 (sibcall_value): Call xtensa_expand_call and complete expansion
2560 right after that call.
2562 2023-02-24 Richard Biener <rguenther@suse.de>
2564 * vec.h (vec<T, A, vl_embed>::m_vecdata): Remove.
2565 (vec<T, A, vl_embed>::m_vecpfx): Align as T to avoid
2566 changing alignment of vec<T, A, vl_embed> and simplifying
2568 (vec<T, A, vl_embed>::address): Compute as this + 1.
2569 (vec<T, A, vl_embed>::embedded_size): Use sizeof the
2570 vector instead of the offset of the m_vecdata member.
2571 (auto_vec<T, N>::m_data): Turn storage into
2572 uninitialized unsigned char.
2573 (auto_vec<T, N>::auto_vec): Allow allocation of one
2574 stack member. Initialize m_vec in a special way to
2575 avoid later stringop overflow diagnostics.
2576 * vec.cc (test_auto_alias): New.
2577 (vec_cc_tests): Call it.
2579 2023-02-24 Richard Biener <rguenther@suse.de>
2581 * vec.h (vec<T, A, vl_embed>::lower_bound): Adjust to
2582 take a const reference to the object, use address to
2584 (vec<T, A, vl_embed>::contains): Use address to access data.
2585 (vec<T, A, vl_embed>::operator[]): Use address instead of
2586 m_vecdata to access data.
2587 (vec<T, A, vl_embed>::iterate): Likewise.
2588 (vec<T, A, vl_embed>::copy): Likewise.
2589 (vec<T, A, vl_embed>::quick_push): Likewise.
2590 (vec<T, A, vl_embed>::pop): Likewise.
2591 (vec<T, A, vl_embed>::quick_insert): Likewise.
2592 (vec<T, A, vl_embed>::ordered_remove): Likewise.
2593 (vec<T, A, vl_embed>::unordered_remove): Likewise.
2594 (vec<T, A, vl_embed>::block_remove): Likewise.
2595 (vec<T, A, vl_heap>::address): Likewise.
2597 2023-02-24 Martin Liska <mliska@suse.cz>
2600 * asan.cc (asan_add_global): Use proper TU name for normal
2601 global variables (and aux_base_name for the artificial one).
2603 2023-02-24 Jakub Jelinek <jakub@redhat.com>
2605 * config/i386/i386-builtin.def: Update description of BDESC
2606 and BDESC_FIRST in file comment to include mask2.
2608 2023-02-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2610 * config/aarch64/aarch64-cores.def (FLAGS): Update comment.
2612 2023-02-24 Jakub Jelinek <jakub@redhat.com>
2614 PR middle-end/108854
2615 * cgraphclones.cc (duplicate_thunk_for_node): If no parameter
2616 changes are needed, copy at least DECL_ARGUMENTS PARM_DECL
2617 nodes and adjust their DECL_CONTEXT.
2619 2023-02-24 Jakub Jelinek <jakub@redhat.com>
2622 * config/i386/i386-builtin.def (__builtin_ia32_cvtne2ps2bf16_v16bf,
2623 __builtin_ia32_cvtne2ps2bf16_v16bf_mask,
2624 __builtin_ia32_cvtne2ps2bf16_v16bf_maskz,
2625 __builtin_ia32_cvtne2ps2bf16_v8bf,
2626 __builtin_ia32_cvtne2ps2bf16_v8bf_mask,
2627 __builtin_ia32_cvtne2ps2bf16_v8bf_maskz,
2628 __builtin_ia32_cvtneps2bf16_v8sf_mask,
2629 __builtin_ia32_cvtneps2bf16_v8sf_maskz,
2630 __builtin_ia32_cvtneps2bf16_v4sf_mask,
2631 __builtin_ia32_cvtneps2bf16_v4sf_maskz,
2632 __builtin_ia32_dpbf16ps_v8sf, __builtin_ia32_dpbf16ps_v8sf_mask,
2633 __builtin_ia32_dpbf16ps_v8sf_maskz, __builtin_ia32_dpbf16ps_v4sf,
2634 __builtin_ia32_dpbf16ps_v4sf_mask,
2635 __builtin_ia32_dpbf16ps_v4sf_maskz): Require also
2636 OPTION_MASK_ISA_AVX512VL.
2638 2023-02-24 Sebastian Huber <sebastian.huber@embedded-brains.de>
2640 * config/riscv/t-rtems: Keep only -mcmodel=medany 64-bit multilibs.
2641 Add non-compact 32-bit multilibs.
2643 2023-02-24 Junxian Zhu <zhujunxian@oss.cipunited.com>
2645 * config/mips/mips.md (*clo<mode>2): New pattern.
2647 2023-02-24 Prachi Godbole <prachi.godbole@imgtec.com>
2649 * config/mips/mips.h (machine_function): New variable
2650 use_hazard_barrier_return_p.
2651 * config/mips/mips.md (UNSPEC_JRHB): New unspec.
2652 (mips_hb_return_internal): New insn pattern.
2653 * config/mips/mips.cc (mips_attribute_table): Add attribute
2654 use_hazard_barrier_return.
2655 (mips_use_hazard_barrier_return_p): New static function.
2656 (mips_function_attr_inlinable_p): Likewise.
2657 (mips_compute_frame_info): Set use_hazard_barrier_return_p.
2658 Emit error for unsupported architecture choice.
2659 (mips_function_ok_for_sibcall, mips_can_use_return_insn):
2660 Return false for use_hazard_barrier_return.
2661 (mips_expand_epilogue): Emit hazard barrier return.
2662 * doc/extend.texi: Document use_hazard_barrier_return.
2664 2023-02-23 Max Filippov <jcmvbkbc@gmail.com>
2666 * config/xtensa/xtensa-dynconfig.cc (config.h, system.h)
2667 (coretypes.h, diagnostic.h, intl.h): Use "..." instead of <...>
2668 for the gcc-internal headers.
2670 2023-02-23 Max Filippov <jcmvbkbc@gmail.com>
2672 * config/xtensa/t-xtensa (xtensa-dynconfig.o): Use $(COMPILE)
2673 and $(POSTCOMPILE) instead of manual dependency listing.
2674 * config/xtensa/xtensa-dynconfig.c: Rename to ...
2675 * config/xtensa/xtensa-dynconfig.cc: ... this.
2677 2023-02-23 Arsen Arsenović <arsen@aarsen.me>
2679 * doc/cfg.texi: Reorder index entries around @items.
2680 * doc/cpp.texi: Ditto.
2681 * doc/cppenv.texi: Ditto.
2682 * doc/cppopts.texi: Ditto.
2683 * doc/generic.texi: Ditto.
2684 * doc/install.texi: Ditto.
2685 * doc/extend.texi: Ditto.
2686 * doc/invoke.texi: Ditto.
2687 * doc/md.texi: Ditto.
2688 * doc/rtl.texi: Ditto.
2689 * doc/tm.texi.in: Ditto.
2690 * doc/trouble.texi: Ditto.
2691 * doc/tm.texi: Regenerate.
2693 2023-02-23 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
2695 * config/xtensa/xtensa.md: New peephole2 pattern that eliminates
2696 the occurrence of general-purpose register used only once and for
2697 transferring intermediate value.
2699 2023-02-23 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
2701 * config/xtensa/xtensa.cc (machine_function): Add new member
2702 'eliminated_callee_saved_bmp'.
2703 (xtensa_can_eliminate_callee_saved_reg_p): New function to
2704 determine whether the register can be eliminated or not.
2705 (xtensa_expand_prologue): Add invoking the above function and
2706 elimination the use of callee-saved register by using its stack
2707 slot through the stack pointer (or the frame pointer if needed)
2709 (xtensa_expand_prologue): Modify to not emit register restoration
2710 insn from its stack slot if the register is already eliminated.
2712 2023-02-23 Jakub Jelinek <jakub@redhat.com>
2714 PR translation/108890
2715 * config/xtensa/xtensa-dynconfig.c (xtensa_load_config): Drop _()s
2716 around fatal_error format strings.
2718 2023-02-23 Richard Biener <rguenther@suse.de>
2720 * tree-ssa-structalias.cc (handle_lhs_call): Do not
2721 re-create rhsc, only truncate it.
2723 2023-02-23 Jakub Jelinek <jakub@redhat.com>
2725 PR middle-end/106258
2726 * ipa-prop.cc (try_make_edge_direct_virtual_call): Handle
2727 BUILT_IN_UNREACHABLE_TRAP like BUILT_IN_UNREACHABLE.
2729 2023-02-23 Richard Biener <rguenther@suse.de>
2731 * tree-if-conv.cc (tree_if_conversion): Properly manage
2732 memory of refs and the contained data references.
2734 2023-02-23 Richard Biener <rguenther@suse.de>
2736 PR tree-optimization/108888
2737 * tree-if-conv.cc (if_convertible_stmt_p): Set PLF_2 on
2739 (predicate_statements): Only predicate calls with PLF_2.
2741 2023-02-23 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
2743 * config/xtensa/xtensa.md
2744 (zero_cost_loop_start, zero_cost_loop_end, loop_end):
2745 Add missing "SI:" to PLUS RTXes.
2747 2023-02-23 Max Filippov <jcmvbkbc@gmail.com>
2750 * config/xtensa/xtensa.cc (xtensa_expand_epilogue):
2751 Emit (use (reg:SI A0_REG)) at the end in the sibling call
2752 (i.e. the same place as (return) in the normal call).
2754 2023-02-23 Max Filippov <jcmvbkbc@gmail.com>
2757 2023-02-21 Max Filippov <jcmvbkbc@gmail.com>
2760 * config/xtensa/xtensa.cc (xtensa_expand_epilogue): Drop emit_use
2762 * config/xtensa/xtensa.md (sibcall, sibcall_internal)
2763 (sibcall_value, sibcall_value_internal): Add 'use' expression
2766 2023-02-23 Arsen Arsenović <arsen@aarsen.me>
2768 * doc/cppdiropts.texi: Reorder @opindex commands to precede
2769 @items they relate to.
2770 * doc/cppopts.texi: Ditto.
2771 * doc/cppwarnopts.texi: Ditto.
2772 * doc/invoke.texi: Ditto.
2773 * doc/lto.texi: Ditto.
2775 2023-02-22 Andrew Stubbs <ams@codesourcery.com>
2777 * internal-fn.cc (expand_MASK_CALL): New.
2778 * internal-fn.def (MASK_CALL): New.
2779 * internal-fn.h (expand_MASK_CALL): New prototype.
2780 * omp-simd-clone.cc (simd_clone_adjust_argument_types): Set vector_type
2781 for mask arguments also.
2782 * tree-if-conv.cc: Include cgraph.h.
2783 (if_convertible_stmt_p): Do if conversions for calls to SIMD calls.
2784 (predicate_statements): Convert functions to IFN_MASK_CALL.
2785 * tree-vect-loop.cc (vect_get_datarefs_in_loop): Recognise
2786 IFN_MASK_CALL as a SIMD function call.
2787 * tree-vect-stmts.cc (vectorizable_simd_clone_call): Handle
2788 IFN_MASK_CALL as an inbranch SIMD function call.
2789 Generate the mask vector arguments.
2791 2023-02-22 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
2793 * config/riscv/riscv-vector-builtins-bases.cc (class reducop): New class.
2794 (class widen_reducop): Ditto.
2795 (class freducop): Ditto.
2796 (class widen_freducop): Ditto.
2798 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
2799 * config/riscv/riscv-vector-builtins-functions.def (vredsum): Add reduction support.
2813 (vfwredosum): Ditto.
2814 (vfwredusum): Ditto.
2815 * config/riscv/riscv-vector-builtins-shapes.cc (struct reduc_alu_def): Ditto.
2817 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
2818 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_WI_OPS): New macro.
2819 (DEF_RVV_WU_OPS): Ditto.
2820 (DEF_RVV_WF_OPS): Ditto.
2821 (vint8mf8_t): Ditto.
2822 (vint8mf4_t): Ditto.
2823 (vint8mf2_t): Ditto.
2828 (vint16mf4_t): Ditto.
2829 (vint16mf2_t): Ditto.
2830 (vint16m1_t): Ditto.
2831 (vint16m2_t): Ditto.
2832 (vint16m4_t): Ditto.
2833 (vint16m8_t): Ditto.
2834 (vint32mf2_t): Ditto.
2835 (vint32m1_t): Ditto.
2836 (vint32m2_t): Ditto.
2837 (vint32m4_t): Ditto.
2838 (vint32m8_t): Ditto.
2839 (vuint8mf8_t): Ditto.
2840 (vuint8mf4_t): Ditto.
2841 (vuint8mf2_t): Ditto.
2842 (vuint8m1_t): Ditto.
2843 (vuint8m2_t): Ditto.
2844 (vuint8m4_t): Ditto.
2845 (vuint8m8_t): Ditto.
2846 (vuint16mf4_t): Ditto.
2847 (vuint16mf2_t): Ditto.
2848 (vuint16m1_t): Ditto.
2849 (vuint16m2_t): Ditto.
2850 (vuint16m4_t): Ditto.
2851 (vuint16m8_t): Ditto.
2852 (vuint32mf2_t): Ditto.
2853 (vuint32m1_t): Ditto.
2854 (vuint32m2_t): Ditto.
2855 (vuint32m4_t): Ditto.
2856 (vuint32m8_t): Ditto.
2857 (vfloat32mf2_t): Ditto.
2858 (vfloat32m1_t): Ditto.
2859 (vfloat32m2_t): Ditto.
2860 (vfloat32m4_t): Ditto.
2861 (vfloat32m8_t): Ditto.
2862 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_WI_OPS): Ditto.
2863 (DEF_RVV_WU_OPS): Ditto.
2864 (DEF_RVV_WF_OPS): Ditto.
2865 (required_extensions_p): Add reduction support.
2866 (rvv_arg_type_info::get_base_vector_type): Ditto.
2867 (rvv_arg_type_info::get_tree_type): Ditto.
2868 * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Ditto.
2869 * config/riscv/riscv.md: Ditto.
2870 * config/riscv/vector-iterators.md (minu): Ditto.
2871 * config/riscv/vector.md (@pred_reduc_<reduc><mode><vlmul1>): New patern.
2872 (@pred_reduc_<reduc><mode><vlmul1_zve32>): Ditto.
2873 (@pred_widen_reduc_plus<v_su><mode><vwlmul1>): Ditto.
2874 (@pred_widen_reduc_plus<v_su><mode><vwlmul1_zve32>):Ditto.
2875 (@pred_reduc_plus<order><mode><vlmul1>): Ditto.
2876 (@pred_reduc_plus<order><mode><vlmul1_zve32>): Ditto.
2877 (@pred_widen_reduc_plus<order><mode><vwlmul1>): Ditto.
2879 2023-02-22 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
2881 * config/riscv/iterators.md: New iterator.
2882 * config/riscv/riscv-vector-builtins-bases.cc (class widen_binop): New class.
2883 (enum ternop_type): New enum.
2884 (class vmacc): New class.
2885 (class imac): Ditto.
2886 (class vnmsac): Ditto.
2887 (enum widen_ternop_type): New enum.
2888 (class vmadd): Ditto.
2889 (class vnmsub): Ditto.
2890 (class iwmac): Ditto.
2891 (class vwmacc): Ditto.
2892 (class vwmaccu): Ditto.
2893 (class vwmaccsu): Ditto.
2894 (class vwmaccus): Ditto.
2895 (class reverse_binop): Ditto.
2896 (class vfmacc): Ditto.
2897 (class vfnmsac): Ditto.
2898 (class vfmadd): Ditto.
2899 (class vfnmsub): Ditto.
2900 (class vfnmacc): Ditto.
2901 (class vfmsac): Ditto.
2902 (class vfnmadd): Ditto.
2903 (class vfmsub): Ditto.
2904 (class vfwmacc): Ditto.
2905 (class vfwnmacc): Ditto.
2906 (class vfwmsac): Ditto.
2907 (class vfwnmsac): Ditto.
2908 (class float_misc): Ditto.
2909 (class fcmp): Ditto.
2910 (class vfclass): Ditto.
2911 (class vfcvt_x): Ditto.
2912 (class vfcvt_rtz_x): Ditto.
2913 (class vfcvt_f): Ditto.
2914 (class vfwcvt_x): Ditto.
2915 (class vfwcvt_rtz_x): Ditto.
2916 (class vfwcvt_f): Ditto.
2917 (class vfncvt_x): Ditto.
2918 (class vfncvt_rtz_x): Ditto.
2919 (class vfncvt_f): Ditto.
2920 (class vfncvt_rod_f): Ditto.
2922 * config/riscv/riscv-vector-builtins-bases.h:
2923 * config/riscv/riscv-vector-builtins-functions.def (vzext): Ditto.
2967 (vfcvt_rtz_x): Ditto.
2968 (vfcvt_rtz_xu): Ditto.
2972 (vfwcvt_rtz_x): Ditto.
2973 (vfwcvt_rtz_xu): Ditto.
2977 (vfncvt_rtz_x): Ditto.
2978 (vfncvt_rtz_xu): Ditto.
2980 (vfncvt_rod_f): Ditto.
2981 * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_def): Ditto.
2982 (struct move_def): Ditto.
2983 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_WEXTF_OPS): New macro.
2984 (DEF_RVV_CONVERT_I_OPS): Ditto.
2985 (DEF_RVV_CONVERT_U_OPS): Ditto.
2986 (DEF_RVV_WCONVERT_I_OPS): Ditto.
2987 (DEF_RVV_WCONVERT_U_OPS): Ditto.
2988 (DEF_RVV_WCONVERT_F_OPS): Ditto.
2989 (vfloat64m1_t): Ditto.
2990 (vfloat64m2_t): Ditto.
2991 (vfloat64m4_t): Ditto.
2992 (vfloat64m8_t): Ditto.
2993 (vint32mf2_t): Ditto.
2994 (vint32m1_t): Ditto.
2995 (vint32m2_t): Ditto.
2996 (vint32m4_t): Ditto.
2997 (vint32m8_t): Ditto.
2998 (vint64m1_t): Ditto.
2999 (vint64m2_t): Ditto.
3000 (vint64m4_t): Ditto.
3001 (vint64m8_t): Ditto.
3002 (vuint32mf2_t): Ditto.
3003 (vuint32m1_t): Ditto.
3004 (vuint32m2_t): Ditto.
3005 (vuint32m4_t): Ditto.
3006 (vuint32m8_t): Ditto.
3007 (vuint64m1_t): Ditto.
3008 (vuint64m2_t): Ditto.
3009 (vuint64m4_t): Ditto.
3010 (vuint64m8_t): Ditto.
3011 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_CONVERT_I_OPS): Ditto.
3012 (DEF_RVV_CONVERT_U_OPS): Ditto.
3013 (DEF_RVV_WCONVERT_I_OPS): Ditto.
3014 (DEF_RVV_WCONVERT_U_OPS): Ditto.
3015 (DEF_RVV_WCONVERT_F_OPS): Ditto.
3016 (DEF_RVV_F_OPS): Ditto.
3017 (DEF_RVV_WEXTF_OPS): Ditto.
3018 (required_extensions_p): Adjust for floating-point support.
3019 (check_required_extensions): Ditto.
3020 (unsigned_base_type_p): Ditto.
3021 (get_mode_for_bitsize): Ditto.
3022 (rvv_arg_type_info::get_base_vector_type): Ditto.
3023 (rvv_arg_type_info::get_tree_type): Ditto.
3024 * config/riscv/riscv-vector-builtins.def (v_f): New define.
3030 * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): New enum.
3031 (function_expander::arg_mode): New function.
3032 * config/riscv/vector-iterators.md (sof): New iterator.
3038 (fixuns_trunc): Ditto.
3040 * config/riscv/vector.md (@pred_broadcast<mode>): New pattern.
3041 (@pred_<optab><mode>): Ditto.
3042 (@pred_<optab><mode>_scalar): Ditto.
3043 (@pred_<optab><mode>_reverse_scalar): Ditto.
3044 (@pred_<copysign><mode>): Ditto.
3045 (@pred_<copysign><mode>_scalar): Ditto.
3046 (@pred_mul_<optab><mode>): Ditto.
3047 (pred_mul_<optab><mode>_undef_merge): Ditto.
3048 (*pred_<madd_nmsub><mode>): Ditto.
3049 (*pred_<macc_nmsac><mode>): Ditto.
3050 (*pred_mul_<optab><mode>): Ditto.
3051 (@pred_mul_<optab><mode>_scalar): Ditto.
3052 (*pred_mul_<optab><mode>_undef_merge_scalar): Ditto.
3053 (*pred_<madd_nmsub><mode>_scalar): Ditto.
3054 (*pred_<macc_nmsac><mode>_scalar): Ditto.
3055 (*pred_mul_<optab><mode>_scalar): Ditto.
3056 (@pred_neg_mul_<optab><mode>): Ditto.
3057 (pred_neg_mul_<optab><mode>_undef_merge): Ditto.
3058 (*pred_<nmadd_msub><mode>): Ditto.
3059 (*pred_<nmacc_msac><mode>): Ditto.
3060 (*pred_neg_mul_<optab><mode>): Ditto.
3061 (@pred_neg_mul_<optab><mode>_scalar): Ditto.
3062 (*pred_neg_mul_<optab><mode>_undef_merge_scalar): Ditto.
3063 (*pred_<nmadd_msub><mode>_scalar): Ditto.
3064 (*pred_<nmacc_msac><mode>_scalar): Ditto.
3065 (*pred_neg_mul_<optab><mode>_scalar): Ditto.
3066 (@pred_<misc_op><mode>): Ditto.
3067 (@pred_class<mode>): Ditto.
3068 (@pred_dual_widen_<optab><mode>): Ditto.
3069 (@pred_dual_widen_<optab><mode>_scalar): Ditto.
3070 (@pred_single_widen_<plus_minus:optab><mode>): Ditto.
3071 (@pred_single_widen_<plus_minus:optab><mode>_scalar): Ditto.
3072 (@pred_widen_mul_<optab><mode>): Ditto.
3073 (@pred_widen_mul_<optab><mode>_scalar): Ditto.
3074 (@pred_widen_neg_mul_<optab><mode>): Ditto.
3075 (@pred_widen_neg_mul_<optab><mode>_scalar): Ditto.
3076 (@pred_cmp<mode>): Ditto.
3077 (*pred_cmp<mode>): Ditto.
3078 (*pred_cmp<mode>_narrow): Ditto.
3079 (@pred_cmp<mode>_scalar): Ditto.
3080 (*pred_cmp<mode>_scalar): Ditto.
3081 (*pred_cmp<mode>_scalar_narrow): Ditto.
3082 (@pred_eqne<mode>_scalar): Ditto.
3083 (*pred_eqne<mode>_scalar): Ditto.
3084 (*pred_eqne<mode>_scalar_narrow): Ditto.
3085 (@pred_merge<mode>_scalar): Ditto.
3086 (@pred_fcvt_x<v_su>_f<mode>): Ditto.
3087 (@pred_<fix_cvt><mode>): Ditto.
3088 (@pred_<float_cvt><mode>): Ditto.
3089 (@pred_widen_fcvt_x<v_su>_f<mode>): Ditto.
3090 (@pred_widen_<fix_cvt><mode>): Ditto.
3091 (@pred_widen_<float_cvt><mode>): Ditto.
3092 (@pred_extend<mode>): Ditto.
3093 (@pred_narrow_fcvt_x<v_su>_f<mode>): Ditto.
3094 (@pred_narrow_<fix_cvt><mode>): Ditto.
3095 (@pred_narrow_<float_cvt><mode>): Ditto.
3096 (@pred_trunc<mode>): Ditto.
3097 (@pred_rod_trunc<mode>): Ditto.
3099 2023-02-22 Jakub Jelinek <jakub@redhat.com>
3101 PR middle-end/106258
3102 * cgraph.cc (cgraph_edge::redirect_call_stmt_to_callee,
3103 cgraph_update_edges_for_call_stmt_node, cgraph_node::verify_node):
3104 Handle BUILT_IN_UNREACHABLE_TRAP like BUILT_IN_UNREACHABLE.
3105 * cgraphclones.cc (cgraph_node::create_clone): Likewise.
3107 2023-02-22 Thomas Schwinge <thomas@codesourcery.com>
3109 * common.opt (-Wcomplain-wrong-lang): New.
3110 * doc/invoke.texi (-Wno-complain-wrong-lang): Document it.
3111 * opts-common.cc (prune_options): Handle it.
3112 * opts-global.cc (complain_wrong_lang): Use it.
3114 2023-02-21 David Malcolm <dmalcolm@redhat.com>
3117 * doc/invoke.texi: Document -fno-analyzer-suppress-followups.
3119 2023-02-21 Max Filippov <jcmvbkbc@gmail.com>
3122 * config/xtensa/xtensa.cc (xtensa_expand_epilogue): Drop emit_use
3124 * config/xtensa/xtensa.md (sibcall, sibcall_internal)
3125 (sibcall_value, sibcall_value_internal): Add 'use' expression
3128 2023-02-21 Richard Biener <rguenther@suse.de>
3130 PR tree-optimization/108691
3131 * tree-ssa-dce.cc (eliminate_unnecessary_stmts): Remove
3132 assert about calls_setjmp not becoming true when it was false.
3134 2023-02-21 Richard Biener <rguenther@suse.de>
3136 PR tree-optimization/108793
3137 * tree-ssa-loop-niter.cc (number_of_iterations_until_wrap):
3138 Use convert operands to niter_type when computing num.
3140 2023-02-21 Richard Biener <rguenther@suse.de>
3143 2023-02-13 Richard Biener <rguenther@suse.de>
3145 PR tree-optimization/108691
3146 * tree-cfg.cc (notice_special_calls): When the CFG is built
3147 honor gimple_call_ctrl_altering_p.
3148 * cfgexpand.cc (expand_call_stmt): Clear cfun->calls_setjmp
3149 temporarily if the call is not control-altering.
3150 * calls.cc (emit_call_1): Do not add REG_SETJMP if
3151 cfun->calls_setjmp is not set. Do not alter cfun->calls_setjmp.
3153 2023-02-21 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
3155 * config/xtensa/xtensa.cc (xtensa_call_save_reg): Change to return
3156 true if register A0 (return address register) when -Og is specified.
3158 2023-02-20 Uroš Bizjak <ubizjak@gmail.com>
3160 * config/i386/predicates.md
3161 (general_x64constmem_operand): New predicate.
3162 * config/i386/i386.md (*cmpqi_ext<mode>_1):
3163 Use nonimm_x64constmem_operand.
3164 (*cmpqi_ext<mode>_3): Use general_x64constmem_operand.
3165 (*addqi_ext<mode>_1): Ditto.
3166 (*testqi_ext<mode>_1): Ditto.
3167 (*andqi_ext<mode>_1): Ditto.
3168 (*andqi_ext<mode>_1_cc): Ditto.
3169 (*<any_or:code>qi_ext<mode>_1): Ditto.
3170 (*xorqi_ext<mode>_1_cc): Ditto.
3172 2023-02-20 Jakub Jelinek <jakub2redhat.com>
3175 * config/rs6000/rs6000.md (umaddditi4): Swap gen_maddlddi4 with
3176 gen_umadddi4_highpart{,_le}.
3178 2023-02-20 Kito Cheng <kito.cheng@sifive.com>
3180 * config/riscv/riscv.md (prefetch): Use r instead of p for the
3182 (riscv_prefetchi_<mode>): Ditto.
3184 2023-02-20 Richard Biener <rguenther@suse.de>
3186 PR tree-optimization/108816
3187 * tree-vect-loop-manip.cc (vect_loop_versioning): Adjust
3188 versioning condition split prerequesite, assert required
3191 2023-02-20 Richard Biener <rguenther@suse.de>
3193 PR tree-optimization/108825
3194 * tree-ssa-loop-manip.cc (verify_loop_closed_ssa): For
3195 loop-local verfication only verify there's no pending SSA
3198 2023-02-20 Richard Biener <rguenther@suse.de>
3200 PR tree-optimization/108819
3201 * tree-ssa-loop-niter.cc (number_of_iterations_cltz): Check
3202 we have an SSA name as iv_2 as expected.
3204 2023-02-18 Jakub Jelinek <jakub@redhat.com>
3206 PR tree-optimization/108819
3207 * tree-ssa-reassoc.cc (update_ops): Fold new stmt in place.
3209 2023-02-18 Jakub Jelinek <jakub@redhat.com>
3212 * config/i386/i386-protos.h (ix86_replace_reg_with_reg): Declare.
3213 * config/i386/i386-expand.cc (ix86_replace_reg_with_reg): New
3215 * config/i386/i386.md: Replace replace_rtx calls in all peephole2s
3216 with ix86_replace_reg_with_reg.
3218 2023-02-18 Gerald Pfeifer <gerald@pfeifer.com>
3220 * doc/invoke.texi (AVR Options): Update link to AVR-LibC.
3222 2023-02-18 Xi Ruoyao <xry111@xry111.site>
3224 * config.gcc (triplet_abi): Set its value based on $with_abi,
3226 (la_canonical_triplet): Set it after $triplet_abi is set
3228 * config/loongarch/t-linux (MULTILIB_OSDIRNAMES): Make the
3229 multiarch tuple for lp64d "loongarch64-linux-gnu" (without
3232 2023-02-18 Andrew Pinski <apinski@marvell.com>
3234 * match.pd: Remove #if GIMPLE around the
3237 2023-02-18 Andrew Pinski <apinski@marvell.com>
3239 * value-query.h (get_range_query): Return the global ranges
3242 2023-02-17 Siddhesh Poyarekar <siddhesh@gotplt.org>
3244 * doc/invoke.texi (@item -Wall): Fix typo in
3247 2023-02-17 Uroš Bizjak <ubizjak@gmail.com>
3250 * config/i386/predicates.md
3251 (nonimm_x64constmem_operand): New predicate.
3252 * config/i386/i386.md (*addqi_ext<mode>_0): New insn pattern.
3253 (*subqi_ext<mode>_0): Ditto.
3254 (*andqi_ext<mode>_0): Ditto.
3255 (*<any_or:code>qi_ext<mode>_0): Ditto.
3257 2023-02-17 Uroš Bizjak <ubizjak@gmail.com>
3260 * simplify-rtx.cc (simplify_context::simplify_subreg): Use
3261 int_outermode instead of GET_MODE (tem) to prevent
3262 VOIDmode from entering simplify_gen_subreg.
3264 2023-02-17 Richard Biener <rguenther@suse.de>
3266 PR tree-optimization/108821
3267 * tree-ssa-loop-im.cc (sm_seq_valid_bb): We can also not
3268 move volatile accesses.
3270 2023-02-17 Richard Biener <rguenther@suse.de>
3272 * tree-ssa.cc (ssa_undefined_value_p): Assert we are not
3273 called on virtual operands.
3274 * tree-ssa-sccvn.cc (vn_phi_lookup): Guard
3275 ssa_undefined_value_p calls.
3276 (vn_phi_insert): Likewise.
3277 (set_ssa_val_to): Likewise.
3278 (visit_phi): Avoid extra work with equivalences for
3279 virtual operand PHIs.
3281 2023-02-17 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3283 * config/riscv/riscv-vector-builtins-bases.cc (class mask_logic): New
3285 (class mask_nlogic): Ditto.
3286 (class mask_notlogic): Ditto.
3287 (class vmmv): Ditto.
3288 (class vmclr): Ditto.
3289 (class vmset): Ditto.
3290 (class vmnot): Ditto.
3291 (class vcpop): Ditto.
3292 (class vfirst): Ditto.
3293 (class mask_misc): Ditto.
3294 (class viota): Ditto.
3297 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
3298 * config/riscv/riscv-vector-builtins-functions.def (vmand): Ditto.
3317 * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_def): Ditto.
3318 (struct mask_alu_def): Ditto.
3320 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
3321 * config/riscv/riscv-vector-builtins.cc: Ditto.
3322 * config/riscv/riscv-vsetvl.cc (pass_vsetvl::cleanup_insns): Fix bug
3323 for dest it scalar RVV intrinsics.
3324 * config/riscv/vector-iterators.md (sof): New iterator.
3325 * config/riscv/vector.md (@pred_<optab>n<mode>): New pattern.
3326 (@pred_<optab>not<mode>): New pattern.
3327 (@pred_popcount<VB:mode><P:mode>): New pattern.
3328 (@pred_ffs<VB:mode><P:mode>): New pattern.
3329 (@pred_<misc_op><mode>): New pattern.
3330 (@pred_iota<mode>): New pattern.
3331 (@pred_series<mode>): New pattern.
3333 2023-02-17 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3335 * config/riscv/riscv-vector-builtins-functions.def (vadc): Rename.
3339 * config/riscv/riscv-vector-builtins.cc: Ditto.
3341 2023-02-17 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3342 kito-cheng <kito.cheng@sifive.com>
3344 * config/riscv/riscv-protos.h (sew64_scalar_helper): New function.
3345 * config/riscv/riscv-v.cc (has_vi_variant_p): Adjust.
3346 (sew64_scalar_helper): New function.
3347 * config/riscv/vector.md: Normalization.
3349 2023-02-17 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3351 * config/riscv/riscv-vector-builtins-functions.def (vsetvlmax): Rearrange.
3413 2023-02-17 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3415 * config/riscv/vector.md (@pred_<optab><mode>): Rearrange.
3416 (@pred_<optab><mode>_scalar): Ditto.
3417 (*pred_<optab><mode>_scalar): Ditto.
3418 (*pred_<optab><mode>_extended_scalar): Ditto.
3420 2023-02-17 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3422 * config/riscv/riscv-protos.h (riscv_run_selftests): Remove 'extern'.
3423 (init_builtins): Ditto.
3424 (mangle_builtin_type): Ditto.
3425 (verify_type_context): Ditto.
3426 (handle_pragma_vector): Ditto.
3427 (builtin_decl): Ditto.
3428 (expand_builtin): Ditto.
3429 (const_vec_all_same_in_range_p): Ditto.
3430 (legitimize_move): Ditto.
3431 (emit_vlmax_op): Ditto.
3432 (emit_nonvlmax_op): Ditto.
3437 (get_avl_type): Ditto.
3438 (calculate_ratio): Ditto.
3439 (enum vlmul_type): Ditto.
3441 (neg_simm5_p): Ditto.
3442 (has_vi_variant_p): Ditto.
3444 2023-02-17 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3446 * config/riscv/riscv-protos.h (simm32_p): Remove.
3447 * config/riscv/riscv-v.cc (simm32_p): Ditto.
3448 * config/riscv/vector.md: Use immediate_operand
3449 instead of riscv_vector::simm32_p.
3451 2023-02-16 Gerald Pfeifer <gerald@pfeifer.com>
3453 * doc/invoke.texi (Optimize Options): Reword the explanation
3454 getting minimal, maximal and default values of a parameter.
3456 2023-02-16 Patrick Palka <ppalka@redhat.com>
3458 * addresses.h: Mechanically drop 'static' from 'static inline'
3459 functions via s/^static inline/inline/g.
3461 * attribs.h: Likewise.
3462 * basic-block.h: Likewise.
3463 * bitmap.h: Likewise.
3464 * cfghooks.h: Likewise.
3465 * cfgloop.h: Likewise.
3466 * cgraph.h: Likewise.
3467 * cselib.h: Likewise.
3468 * data-streamer.h: Likewise.
3469 * debug.h: Likewise.
3471 * diagnostic.h: Likewise.
3472 * dominance.h: Likewise.
3473 * dumpfile.h: Likewise.
3474 * emit-rtl.h: Likewise.
3475 * except.h: Likewise.
3476 * expmed.h: Likewise.
3478 * fixed-value.h: Likewise.
3479 * gengtype.h: Likewise.
3480 * gimple-expr.h: Likewise.
3481 * gimple-iterator.h: Likewise.
3482 * gimple-predict.h: Likewise.
3483 * gimple-range-fold.h: Likewise.
3484 * gimple-ssa.h: Likewise.
3485 * gimple.h: Likewise.
3486 * graphite.h: Likewise.
3487 * hard-reg-set.h: Likewise.
3488 * hash-map.h: Likewise.
3489 * hash-set.h: Likewise.
3490 * hash-table.h: Likewise.
3491 * hwint.h: Likewise.
3492 * input.h: Likewise.
3493 * insn-addr.h: Likewise.
3494 * internal-fn.h: Likewise.
3495 * ipa-fnsummary.h: Likewise.
3496 * ipa-icf-gimple.h: Likewise.
3497 * ipa-inline.h: Likewise.
3498 * ipa-modref.h: Likewise.
3499 * ipa-prop.h: Likewise.
3500 * ira-int.h: Likewise.
3502 * lra-int.h: Likewise.
3504 * lto-streamer.h: Likewise.
3505 * memmodel.h: Likewise.
3506 * omp-general.h: Likewise.
3507 * optabs-query.h: Likewise.
3508 * optabs.h: Likewise.
3509 * plugin.h: Likewise.
3510 * pretty-print.h: Likewise.
3511 * range.h: Likewise.
3512 * read-md.h: Likewise.
3513 * recog.h: Likewise.
3515 * rtl-iter.h: Likewise.
3517 * sbitmap.h: Likewise.
3518 * sched-int.h: Likewise.
3519 * sel-sched-ir.h: Likewise.
3521 * sparseset.h: Likewise.
3522 * ssa-iterators.h: Likewise.
3523 * system.h: Likewise.
3524 * target-globals.h: Likewise.
3525 * target.h: Likewise.
3526 * timevar.h: Likewise.
3527 * tree-chrec.h: Likewise.
3528 * tree-data-ref.h: Likewise.
3529 * tree-iterator.h: Likewise.
3530 * tree-outof-ssa.h: Likewise.
3531 * tree-phinodes.h: Likewise.
3532 * tree-scalar-evolution.h: Likewise.
3533 * tree-sra.h: Likewise.
3534 * tree-ssa-alias.h: Likewise.
3535 * tree-ssa-live.h: Likewise.
3536 * tree-ssa-loop-manip.h: Likewise.
3537 * tree-ssa-loop.h: Likewise.
3538 * tree-ssa-operands.h: Likewise.
3539 * tree-ssa-propagate.h: Likewise.
3540 * tree-ssa-sccvn.h: Likewise.
3541 * tree-ssa.h: Likewise.
3542 * tree-ssanames.h: Likewise.
3543 * tree-streamer.h: Likewise.
3544 * tree-switch-conversion.h: Likewise.
3545 * tree-vectorizer.h: Likewise.
3547 * wide-int.h: Likewise.
3549 2023-02-16 Jakub Jelinek <jakub@redhat.com>
3551 PR tree-optimization/108657
3552 * tree-ssa-dse.cc (initialize_ao_ref_for_dse): If lhs of stmt
3553 exists and is not a SSA_NAME, call ao_ref_init even if the stmt
3554 is a call to internal or builtin function.
3556 2023-02-16 Jonathan Wakely <jwakely@redhat.com>
3558 * doc/invoke.texi (C++ Dialect Options): Suggest adding a
3559 using-declaration to unhide functions.
3561 2023-02-16 Jakub Jelinek <jakub@redhat.com>
3563 PR tree-optimization/108783
3564 * tree-ssa-reassoc.cc (eliminate_redundant_comparison): If lcode
3565 is equal to TREE_CODE (t), op1 to newop1 and op2 to newop2, set
3566 t to curr->op. Otherwise, punt if either newop1 or newop2 are
3567 SSA_NAME_OCCURS_IN_ABNORMAL_PHI SSA_NAMEs.
3569 2023-02-16 Richard Biener <rguenther@suse.de>
3571 PR tree-optimization/108791
3572 * tree-ssa-forwprop.cc (optimize_vector_load): Build
3573 the ADDR_EXPR of a TARGET_MEM_REF using a more meaningful
3576 2023-02-15 Eric Botcazou <ebotcazou@adacore.com>
3579 * config/i386/i386.cc (ix86_compute_frame_layout): Disable the
3580 effects of -fstack-clash-protection for TARGET_STACK_PROBE.
3581 (ix86_expand_prologue): Likewise.
3583 2023-02-15 Jan-Benedict Glaw <jbglaw@lug-owl.de>
3585 * config/bpf/bpf.cc (bpf_option_override): Fix doubled space.
3587 2023-02-15 Uroš Bizjak <ubizjak@gmail.com>
3589 * config/i386/i386.md (*cmpqi_ext<mode>_1): Use
3590 int248_register_operand predicate in zero_extract sub-RTX.
3591 (*cmpqi_ext<mode>_2): Ditto.
3592 (*cmpqi_ext<mode>_3): Ditto.
3593 (*cmpqi_ext<mode>_4): Ditto.
3594 (*extzvqi_mem_rex64): Ditto.
3596 (*insvqi_1_mem_rex64): Ditto.
3597 (@insv<mode>_1): Ditto.
3601 (*extendqi<SWI24:mode>_ext_1): Ditto.
3602 (*addqi_ext<mode>_1): Ditto.
3603 (*addqi_ext<mode>_2): Ditto.
3604 (*subqi_ext<mode>_2): Ditto.
3605 (*testqi_ext<mode>_1): Ditto.
3606 (*testqi_ext<mode>_2): Ditto.
3607 (*andqi_ext<mode>_1): Ditto.
3608 (*andqi_ext<mode>_1_cc): Ditto.
3609 (*andqi_ext<mode>_2): Ditto.
3610 (*<any_or:code>qi_ext<mode>_1): Ditto.
3611 (*<any_or:code>qi_ext<mode>_2): Ditto.
3612 (*xorqi_ext<mode>_1_cc): Ditto.
3613 (*negqi_ext<mode>_2): Ditto.
3614 (*ashlqi_ext<mode>_2): Ditto.
3615 (*<any_shiftrt:insn>qi_ext<mode>_2): Ditto.
3617 2023-02-15 Uroš Bizjak <ubizjak@gmail.com>
3619 * config/i386/predicates.md (int248_register_operand):
3620 Rename from extr_register_operand.
3621 * config/i386/i386.md (*extv<mode>): Update for renamed predicate.
3622 (*extzx<mode>): Ditto.
3623 (*ashl<dwi>3_doubleword_mask): Use int248_register_operand predicate.
3624 (*ashl<mode>3_mask): Ditto.
3625 (*<any_shiftrt:insn><mode>3_mask): Ditto.
3626 (*<any_shiftrt:insn><dwi>3_doubleword_mask): Ditto.
3627 (*<any_rotate:insn><mode>3_mask): Ditto.
3628 (*<btsc><mode>_mask): Ditto.
3629 (*btr<mode>_mask): Ditto.
3630 (*jcc_bt<mode>_mask_1): Ditto.
3632 2023-02-15 Richard Biener <rguenther@suse.de>
3635 * df-core.cc (df_worklist_propagate_forward): Put later
3636 blocks on worklist and only earlier blocks on pending.
3637 (df_worklist_propagate_backward): Likewise.
3638 (df_worklist_dataflow_doublequeue): Change the iteration
3639 to process new blocks in the same iteration if that
3640 maintains the iteration order.
3642 2023-02-15 Marek Polacek <polacek@redhat.com>
3644 PR middle-end/106080
3645 * gimple-ssa-warn-access.cc (is_auto_decl): Remove. Use auto_var_p
3648 2023-02-15 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3650 * config/riscv/predicates.md: Refine codes.
3651 * config/riscv/riscv-protos.h (RVV_VUNDEF): New macro.
3652 * config/riscv/riscv-v.cc: Refine codes.
3653 * config/riscv/riscv-vector-builtins-bases.cc (enum ternop_type): New
3655 (class imac): New class.
3656 (enum widen_ternop_type): New enum.
3657 (class iwmac): New class.
3659 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
3660 * config/riscv/riscv-vector-builtins-functions.def (vmacc): Ditto.
3668 * config/riscv/riscv-vector-builtins.cc
3669 (function_builder::apply_predication): Adjust for multiply-add support.
3670 (function_expander::add_vundef_operand): Refine codes.
3671 (function_expander::use_ternop_insn): New function.
3672 (function_expander::use_widen_ternop_insn): Ditto.
3673 * config/riscv/riscv-vector-builtins.h: New function.
3674 * config/riscv/vector.md (@pred_mul_<optab><mode>): New pattern.
3675 (pred_mul_<optab><mode>_undef_merge): Ditto.
3676 (*pred_<madd_nmsub><mode>): Ditto.
3677 (*pred_<macc_nmsac><mode>): Ditto.
3678 (*pred_mul_<optab><mode>): Ditto.
3679 (@pred_mul_<optab><mode>_scalar): Ditto.
3680 (*pred_mul_<optab><mode>_undef_merge_scalar): Ditto.
3681 (*pred_<madd_nmsub><mode>_scalar): Ditto.
3682 (*pred_<macc_nmsac><mode>_scalar): Ditto.
3683 (*pred_mul_<optab><mode>_scalar): Ditto.
3684 (*pred_mul_<optab><mode>_undef_merge_extended_scalar): Ditto.
3685 (*pred_<madd_nmsub><mode>_extended_scalar): Ditto.
3686 (*pred_<macc_nmsac><mode>_extended_scalar): Ditto.
3687 (*pred_mul_<optab><mode>_extended_scalar): Ditto.
3688 (@pred_widen_mul_plus<su><mode>): Ditto.
3689 (@pred_widen_mul_plus<su><mode>_scalar): Ditto.
3690 (@pred_widen_mul_plussu<mode>): Ditto.
3691 (@pred_widen_mul_plussu<mode>_scalar): Ditto.
3692 (@pred_widen_mul_plusus<mode>_scalar): Ditto.
3694 2023-02-15 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3696 * config/riscv/predicates.md (vector_mask_operand): Refine the codes.
3697 (vector_all_trues_mask_operand): New predicate.
3698 (vector_undef_operand): New predicate.
3699 (ltge_operator): New predicate.
3700 (comparison_except_ltge_operator): New predicate.
3701 (comparison_except_eqge_operator): New predicate.
3702 (ge_operator): New predicate.
3703 * config/riscv/riscv-v.cc (has_vi_variant_p): Add compare support.
3704 * config/riscv/riscv-vector-builtins-bases.cc (class icmp): New class.
3706 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
3707 * config/riscv/riscv-vector-builtins-functions.def (vmseq): Ditto.
3717 * config/riscv/riscv-vector-builtins-shapes.cc
3718 (struct return_mask_def): Adjust for compare support.
3719 * config/riscv/riscv-vector-builtins.cc
3720 (function_expander::use_compare_insn): New function.
3721 * config/riscv/riscv-vector-builtins.h
3722 (function_expander::add_integer_operand): Ditto.
3723 * config/riscv/riscv.cc (riscv_print_operand): Add compare support.
3724 * config/riscv/riscv.md: Add vector min/max attributes.
3725 * config/riscv/vector-iterators.md (xnor): New iterator.
3726 * config/riscv/vector.md (@pred_cmp<mode>): New pattern.
3727 (*pred_cmp<mode>): Ditto.
3728 (*pred_cmp<mode>_narrow): Ditto.
3729 (@pred_ltge<mode>): Ditto.
3730 (*pred_ltge<mode>): Ditto.
3731 (*pred_ltge<mode>_narrow): Ditto.
3732 (@pred_cmp<mode>_scalar): Ditto.
3733 (*pred_cmp<mode>_scalar): Ditto.
3734 (*pred_cmp<mode>_scalar_narrow): Ditto.
3735 (@pred_eqne<mode>_scalar): Ditto.
3736 (*pred_eqne<mode>_scalar): Ditto.
3737 (*pred_eqne<mode>_scalar_narrow): Ditto.
3738 (*pred_cmp<mode>_extended_scalar): Ditto.
3739 (*pred_cmp<mode>_extended_scalar_narrow): Ditto.
3740 (*pred_eqne<mode>_extended_scalar): Ditto.
3741 (*pred_eqne<mode>_extended_scalar_narrow): Ditto.
3742 (@pred_ge<mode>_scalar): Ditto.
3743 (@pred_<optab><mode>): Ditto.
3744 (@pred_n<optab><mode>): Ditto.
3745 (@pred_<optab>n<mode>): Ditto.
3746 (@pred_not<mode>): Ditto.
3748 2023-02-15 Martin Jambor <mjambor@suse.cz>
3751 * ipa-sra.cc (push_param_adjustments_for_index): Do not omit
3752 creation of non-scalar replacements even if IPA-CP knows their
3755 2023-02-15 Jakub Jelinek <jakub@redhat.com>
3759 * config/rs6000/rs6000.md (<u>maddditi4): Change into umaddditi4 only
3760 expander, change operand 3 to be TImode, emit maddlddi4 and
3761 umadddi4_highpart{,_le} with its low half and finally add the high
3764 2023-02-15 Martin Liska <mliska@suse.cz>
3766 * doc/invoke.texi: Document --param=asan-kernel-mem-intrinsic-prefix.
3768 2023-02-15 Richard Biener <rguenther@suse.de>
3770 * sanopt.cc (sanitize_asan_mark_unpoison): Use bitmap
3771 for with_poison and alias worklist to it.
3772 (sanitize_asan_mark_poison): Likewise.
3774 2023-02-15 Richard Biener <rguenther@suse.de>
3777 * config/i386/i386-features.cc (scalar_chain::add_to_queue):
3778 Combine bitmap test and set.
3779 (scalar_chain::add_insn): Likewise.
3780 (scalar_chain::analyze_register_chain): Remove redundant
3781 attempt to add to queue and instead strengthen assert.
3782 Sink common attempts to mark the def dual-mode.
3783 (scalar_chain::add_to_queue): Remove redundant insn bitmap
3786 2023-02-15 Richard Biener <rguenther@suse.de>
3789 * config/i386/i386-features.cc (convert_scalars_to_vector):
3790 Switch candidates bitmaps to tree view before building the chains.
3792 2023-02-15 Hans-Peter Nilsson <hp@axis.com>
3794 * reload1.cc (gen_reload): Correct rtx parameter for fatal_insn
3795 "failure trying to reload" call.
3797 2023-02-15 Hans-Peter Nilsson <hp@axis.com>
3799 * gdbinit.in (phrs): New command.
3800 * sel-sched-dump.cc (debug_hard_reg_set): Remove debug-function.
3801 * ira-color.cc (debug_hard_reg_set): New, calling print_hard_reg_set.
3803 2023-02-14 David Faust <david.faust@oracle.com>
3806 * config/bpf/constraints.md (q): New memory constraint.
3807 * config/bpf/bpf.md (zero_extendhidi2): Use it here.
3808 (zero_extendqidi2): Likewise.
3809 (zero_extendsidi2): Likewise.
3810 (*mov<MM:mode>): Likewise.
3812 2023-02-14 Andrew Pinski <apinski@marvell.com>
3814 PR tree-optimization/108355
3815 PR tree-optimization/96921
3816 * match.pd: Add pattern for "1 - bool_val".
3818 2023-02-14 Richard Biener <rguenther@suse.de>
3820 * tree-ssa-sccvn.cc (vn_phi_compute_hash): Key skipping
3821 basic block index hashing on the availability of ->cclhs.
3822 (vn_phi_eq): Avoid re-doing sanity checks for CSE but
3823 rely on ->cclhs availability.
3824 (vn_phi_lookup): Set ->cclhs only when we are eventually
3825 going to CSE the PHI.
3826 (vn_phi_insert): Likewise.
3828 2023-02-14 Eric Botcazou <ebotcazou@adacore.com>
3830 * gimplify.cc (gimplify_save_expr): Add missing guard.
3832 2023-02-14 Richard Biener <rguenther@suse.de>
3834 PR tree-optimization/108782
3835 * tree-vect-loop.cc (vect_phi_first_order_recurrence_p):
3836 Make sure we're not vectorizing an inner loop.
3838 2023-02-14 Jakub Jelinek <jakub@redhat.com>
3841 * params.opt (-param=asan-kernel-mem-intrinsic-prefix=): New param.
3842 * asan.h (asan_memfn_rtl): Declare.
3843 * asan.cc (asan_memfn_rtls): New variable.
3844 (asan_memfn_rtl): New function.
3845 * builtins.cc (expand_builtin): If
3846 param_asan_kernel_mem_intrinsic_prefix and function is
3847 kernel-{,hw}address sanitized, emit calls to
3848 __{,hw}asan_{memcpy,memmove,memset} rather than
3849 {memcpy,memmove,memset}. Use sanitize_flags_p (SANITIZE_ADDRESS)
3850 instead of flag_sanitize & SANITIZE_ADDRESS to check if
3851 asan_intercepted_p functions shouldn't be expanded inline.
3853 2023-02-14 Richard Sandiford <richard.sandiford@arm.com>
3855 PR tree-optimization/96373
3856 * tree-vect-stmts.cc (vectorizable_operation): Predicate trapping
3857 operations on the loop mask. Reject partial vectors if this isn't
3860 2023-02-13 Richard Sandiford <richard.sandiford@arm.com>
3862 PR rtl-optimization/108681
3863 * lra-spills.cc (lra_final_code_change): Extend subreg replacement
3864 code to handle bare uses and clobbers.
3866 2023-02-13 Vladimir N. Makarov <vmakarov@redhat.com>
3868 * ira.cc (ira_update_equiv_info_by_shuffle_insn): Clear equiv
3869 caller_save_p flag when clearing defined_p flag.
3870 (setup_reg_equiv): Ditto.
3871 * lra-constraints.cc (lra_constraints): Ditto.
3873 2023-02-13 Uroš Bizjak <ubizjak@gmail.com>
3876 * config/i386/predicates.md (extr_register_operand):
3877 New special predicate.
3878 * config/i386/i386.md (*extv<mode>): Use extr_register_operand
3879 as operand 1 predicate.
3880 (*exzv<mode>): Ditto.
3881 (*extendqi<SWI24:mode>_ext_1): New insn pattern.
3883 2023-02-13 Richard Biener <rguenther@suse.de>
3885 PR tree-optimization/28614
3886 * tree-ssa-sccvn.cc (can_track_predicate_on_edge): Avoid
3887 walking all edges in most cases.
3888 (vn_nary_op_insert_pieces_predicated): Avoid repeated
3889 calls to can_track_predicate_on_edge unless checking is
3891 (process_bb): Instead call it once here for each edge
3892 we register possibly multiple predicates on.
3894 2023-02-13 Richard Biener <rguenther@suse.de>
3896 PR tree-optimization/108691
3897 * tree-cfg.cc (notice_special_calls): When the CFG is built
3898 honor gimple_call_ctrl_altering_p.
3899 * cfgexpand.cc (expand_call_stmt): Clear cfun->calls_setjmp
3900 temporarily if the call is not control-altering.
3901 * calls.cc (emit_call_1): Do not add REG_SETJMP if
3902 cfun->calls_setjmp is not set. Do not alter cfun->calls_setjmp.
3904 2023-02-13 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
3907 * config/s390/s390.cc (s390_bb_fallthru_entry_likely): Remove.
3908 (struct s390_sched_state): Initialise to zero.
3909 (s390_sched_variable_issue): For better debuggability also emit
3911 (s390_sched_init): Unconditionally reset scheduler state.
3913 2023-02-13 Richard Sandiford <richard.sandiford@arm.com>
3915 * ifcvt.h (noce_if_info::cond_inverted): New field.
3916 * ifcvt.cc (cond_move_convert_if_block): Swap the then and else
3917 values when cond_inverted is true.
3918 (noce_find_if_block): Allow the condition to be inverted when
3919 handling conditional moves.
3921 2023-02-13 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
3923 * config/s390/predicates.md (execute_operation): Use
3924 constrain_operands instead of extract_constrain_insn in order to
3925 determine wheter there exists a valid alternative.
3927 2023-02-13 Claudiu Zissulescu <claziss@gmail.com>
3929 * common/config/arc/arc-common.cc (arc_option_optimization_table):
3930 Remove millicode from list.
3932 2023-02-13 Martin Liska <mliska@suse.cz>
3934 * doc/invoke.texi: Document ira-simple-lra-insn-threshold.
3936 2023-02-13 Richard Biener <rguenther@suse.de>
3938 PR tree-optimization/106722
3939 * tree-ssa-dce.cc (mark_last_stmt_necessary): Return
3940 whether we marked a stmt.
3941 (mark_control_dependent_edges_necessary): When
3942 mark_last_stmt_necessary didn't mark any stmt make sure
3943 to mark its control dependent edges.
3944 (propagate_necessity): Likewise.
3946 2023-02-13 Kito Cheng <kito.cheng@sifive.com>
3948 * config/riscv/riscv.h (RISCV_DWARF_VLENB): New.
3949 (DWARF_FRAME_REGISTERS): New.
3950 (DWARF_REG_TO_UNWIND_COLUMN): New.
3952 2023-02-12 Gerald Pfeifer <gerald@pfeifer.com>
3954 * doc/sourcebuild.texi: Remove (broken) direct reference to
3955 "The GNU configure and build system".
3957 2023-02-12 Jin Ma <jinma@linux.alibaba.com>
3959 * config/riscv/riscv.cc (riscv_adjust_libcall_cfi_prologue): Change
3960 gen_add3_insn to gen_rtx_SET.
3961 (riscv_adjust_libcall_cfi_epilogue): Likewise.
3963 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3965 * config/riscv/riscv-vector-builtins-bases.cc (class sat_op): New class.
3966 (class vnclip): Ditto.
3968 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
3969 * config/riscv/riscv-vector-builtins-functions.def (vaadd): Ditto.
3978 * config/riscv/vector-iterators.md (su): Add instruction.
3981 * config/riscv/vector.md (@pred_<sat_op><mode>): New pattern.
3982 (@pred_<sat_op><mode>_scalar): Ditto.
3983 (*pred_<sat_op><mode>_scalar): Ditto.
3984 (*pred_<sat_op><mode>_extended_scalar): Ditto.
3985 (@pred_narrow_clip<v_su><mode>): Ditto.
3986 (@pred_narrow_clip<v_su><mode>_scalar): Ditto.
3988 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
3990 * config/riscv/constraints.md (Wbr): Remove unused constraint.
3991 * config/riscv/predicates.md: Fix move operand predicate.
3992 * config/riscv/riscv-vector-builtins-bases.cc (class vnshift): New class.
3993 (class vncvt_x): Ditto.
3994 (class vmerge): Ditto.
3995 (class vmv_v): Ditto.
3997 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
3998 * config/riscv/riscv-vector-builtins-functions.def (vsra): Ditto.
4005 * config/riscv/riscv-vector-builtins-shapes.cc (struct narrow_alu_def): Ditto.
4006 (struct move_def): Ditto.
4008 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
4009 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_WEXTI_OPS): New variable.
4010 (DEF_RVV_WEXTU_OPS): Ditto
4011 * config/riscv/riscv-vector-builtins.def (x_x_w): Fix type for suffix.
4016 * config/riscv/riscv.cc (riscv_print_operand): Refine ASM printting rule.
4017 * config/riscv/vector-iterators.md (nmsac):New iterator.
4018 (nmsub): New iterator.
4019 * config/riscv/vector.md (@pred_merge<mode>): New pattern.
4020 (@pred_merge<mode>_scalar): New pattern.
4021 (*pred_merge<mode>_scalar): New pattern.
4022 (*pred_merge<mode>_extended_scalar): New pattern.
4023 (@pred_narrow_<optab><mode>): New pattern.
4024 (@pred_narrow_<optab><mode>_scalar): New pattern.
4025 (@pred_trunc<mode>): New pattern.
4027 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4029 * config/riscv/riscv-vector-builtins-bases.cc (class vmadc): New class.
4030 (class vmsbc): Ditto.
4031 (BASE): Define new class.
4032 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
4033 * config/riscv/riscv-vector-builtins-functions.def (vmadc): New define.
4035 * config/riscv/riscv-vector-builtins-shapes.cc (struct return_mask_def):
4038 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
4039 * config/riscv/riscv-vector-builtins.cc
4040 (function_expander::use_exact_insn): Adjust for new support
4041 * config/riscv/riscv-vector-builtins.h
4042 (function_base::has_merge_operand_p): New function.
4043 * config/riscv/vector-iterators.md: New iterator.
4044 * config/riscv/vector.md (@pred_madc<mode>): New pattern.
4045 (@pred_msbc<mode>): Ditto.
4046 (@pred_madc<mode>_scalar): Ditto.
4047 (@pred_msbc<mode>_scalar): Ditto.
4048 (*pred_madc<mode>_scalar): Ditto.
4049 (*pred_madc<mode>_extended_scalar): Ditto.
4050 (*pred_msbc<mode>_scalar): Ditto.
4051 (*pred_msbc<mode>_extended_scalar): Ditto.
4052 (@pred_madc<mode>_overflow): Ditto.
4053 (@pred_msbc<mode>_overflow): Ditto.
4054 (@pred_madc<mode>_overflow_scalar): Ditto.
4055 (@pred_msbc<mode>_overflow_scalar): Ditto.
4056 (*pred_madc<mode>_overflow_scalar): Ditto.
4057 (*pred_madc<mode>_overflow_extended_scalar): Ditto.
4058 (*pred_msbc<mode>_overflow_scalar): Ditto.
4059 (*pred_msbc<mode>_overflow_extended_scalar): Ditto.
4061 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4063 * config/riscv/riscv-protos.h (simm5_p): Add vadc/vsbc support.
4064 * config/riscv/riscv-v.cc (simm32_p): Ditto.
4065 * config/riscv/riscv-vector-builtins-bases.cc (class vadc): New class.
4066 (class vsbc): Ditto.
4068 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
4069 * config/riscv/riscv-vector-builtins-functions.def (vadc): Ditto.
4071 * config/riscv/riscv-vector-builtins-shapes.cc
4072 (struct no_mask_policy_def): Ditto.
4074 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
4075 * config/riscv/riscv-vector-builtins.cc
4076 (rvv_arg_type_info::get_base_vector_type): Add vadc/vsbc support.
4077 (rvv_arg_type_info::get_tree_type): Ditto.
4078 (function_expander::use_exact_insn): Ditto.
4079 * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Ditto.
4080 (function_base::use_mask_predication_p): New function.
4081 * config/riscv/vector-iterators.md: New iterator.
4082 * config/riscv/vector.md (@pred_adc<mode>): New pattern.
4083 (@pred_sbc<mode>): Ditto.
4084 (@pred_adc<mode>_scalar): Ditto.
4085 (@pred_sbc<mode>_scalar): Ditto.
4086 (*pred_adc<mode>_scalar): Ditto.
4087 (*pred_adc<mode>_extended_scalar): Ditto.
4088 (*pred_sbc<mode>_scalar): Ditto.
4089 (*pred_sbc<mode>_extended_scalar): Ditto.
4091 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4093 * config/riscv/vector.md: use "zero" reg.
4095 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4097 * config/riscv/riscv-vector-builtins-bases.cc (class widen_binop): New
4099 (class vwmulsu): Ditto.
4100 (class vwcvt): Ditto.
4101 (BASE): Add integer widening support.
4102 * config/riscv/riscv-vector-builtins-bases.h: Ditto
4103 * config/riscv/riscv-vector-builtins-functions.def (vwadd): New class.
4106 (vwmulu): New class.
4107 (vwmulsu): New class.
4108 (vwaddu): New class.
4109 (vwsubu): New class.
4110 (vwcvt_x): New class.
4111 (vwcvtu_x): New class.
4112 * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_def): New
4114 (struct widen_alu_def): New class.
4116 * config/riscv/riscv-vector-builtins-shapes.h: New class.
4117 * config/riscv/riscv-vector-builtins.cc
4118 (rvv_arg_type_info::get_base_vector_type): Add integer widening support.
4119 (rvv_arg_type_info::get_tree_type): Ditto.
4120 * config/riscv/riscv-vector-builtins.def (x_x_v): Change into "x_v"
4122 * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Add integer
4124 * config/riscv/riscv-vsetvl.cc (change_insn): Fix reg_equal use bug.
4125 * config/riscv/riscv.h (X0_REGNUM): New constant.
4126 * config/riscv/vector-iterators.md: New iterators.
4127 * config/riscv/vector.md
4128 (@pred_dual_widen_<any_widen_binop:optab><any_extend:su><mode>): New
4130 (@pred_dual_widen_<any_widen_binop:optab><any_extend:su><mode>_scalar):
4132 (@pred_single_widen_<plus_minus:optab><any_extend:su><mode>): Ditto.
4133 (@pred_single_widen_<plus_minus:optab><any_extend:su><mode>_scalar):
4135 (@pred_widen_mulsu<mode>): Ditto.
4136 (@pred_widen_mulsu<mode>_scalar): Ditto.
4137 (@pred_<optab><mode>): Ditto.
4139 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4140 kito-cheng <kito.cheng@sifive.com>
4142 * common/config/riscv/riscv-common.cc: Add flag for 'V' extension.
4143 * config/riscv/riscv-vector-builtins-bases.cc (class vmulh): New class.
4145 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
4146 * config/riscv/riscv-vector-builtins-functions.def (vmulh): Add vmulh
4150 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_FULL_V_I_OPS):
4152 (DEF_RVV_FULL_V_U_OPS): Ditto.
4153 (vint8mf8_t): Ditto.
4154 (vint8mf4_t): Ditto.
4155 (vint8mf2_t): Ditto.
4160 (vint16mf4_t): Ditto.
4161 (vint16mf2_t): Ditto.
4162 (vint16m1_t): Ditto.
4163 (vint16m2_t): Ditto.
4164 (vint16m4_t): Ditto.
4165 (vint16m8_t): Ditto.
4166 (vint32mf2_t): Ditto.
4167 (vint32m1_t): Ditto.
4168 (vint32m2_t): Ditto.
4169 (vint32m4_t): Ditto.
4170 (vint32m8_t): Ditto.
4171 (vint64m1_t): Ditto.
4172 (vint64m2_t): Ditto.
4173 (vint64m4_t): Ditto.
4174 (vint64m8_t): Ditto.
4175 (vuint8mf8_t): Ditto.
4176 (vuint8mf4_t): Ditto.
4177 (vuint8mf2_t): Ditto.
4178 (vuint8m1_t): Ditto.
4179 (vuint8m2_t): Ditto.
4180 (vuint8m4_t): Ditto.
4181 (vuint8m8_t): Ditto.
4182 (vuint16mf4_t): Ditto.
4183 (vuint16mf2_t): Ditto.
4184 (vuint16m1_t): Ditto.
4185 (vuint16m2_t): Ditto.
4186 (vuint16m4_t): Ditto.
4187 (vuint16m8_t): Ditto.
4188 (vuint32mf2_t): Ditto.
4189 (vuint32m1_t): Ditto.
4190 (vuint32m2_t): Ditto.
4191 (vuint32m4_t): Ditto.
4192 (vuint32m8_t): Ditto.
4193 (vuint64m1_t): Ditto.
4194 (vuint64m2_t): Ditto.
4195 (vuint64m4_t): Ditto.
4196 (vuint64m8_t): Ditto.
4197 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_FULL_V_I_OPS): Ditto.
4198 (DEF_RVV_FULL_V_U_OPS): Ditto.
4199 (check_required_extensions): Add vmulh support.
4200 (rvv_arg_type_info::get_tree_type): Ditto.
4201 * config/riscv/riscv-vector-builtins.h (RVV_REQUIRE_FULL_V): Ditto.
4202 (enum rvv_base_type): Ditto.
4203 * config/riscv/riscv.opt: Add 'V' extension flag.
4204 * config/riscv/vector-iterators.md (su): New iterator.
4205 * config/riscv/vector.md (@pred_mulh<v_su><mode>): New pattern.
4206 (@pred_mulh<v_su><mode>_scalar): Ditto.
4207 (*pred_mulh<v_su><mode>_scalar): Ditto.
4208 (*pred_mulh<v_su><mode>_extended_scalar): Ditto.
4210 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4212 * config/riscv/iterators.md: Add sign_extend/zero_extend.
4213 * config/riscv/riscv-vector-builtins-bases.cc (class ext): New class.
4215 * config/riscv/riscv-vector-builtins-bases.h: Add vsext/vzext support.
4216 * config/riscv/riscv-vector-builtins-functions.def (vsext): New macro
4219 * config/riscv/riscv-vector-builtins-shapes.cc (struct alu_def): Adjust
4220 for vsext/vzext support.
4221 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_WEXTI_OPS): New
4223 (DEF_RVV_QEXTI_OPS): Ditto.
4224 (DEF_RVV_OEXTI_OPS): Ditto.
4225 (DEF_RVV_WEXTU_OPS): Ditto.
4226 (DEF_RVV_QEXTU_OPS): Ditto.
4227 (DEF_RVV_OEXTU_OPS): Ditto.
4228 (vint16mf4_t): Ditto.
4229 (vint16mf2_t): Ditto.
4230 (vint16m1_t): Ditto.
4231 (vint16m2_t): Ditto.
4232 (vint16m4_t): Ditto.
4233 (vint16m8_t): Ditto.
4234 (vint32mf2_t): Ditto.
4235 (vint32m1_t): Ditto.
4236 (vint32m2_t): Ditto.
4237 (vint32m4_t): Ditto.
4238 (vint32m8_t): Ditto.
4239 (vint64m1_t): Ditto.
4240 (vint64m2_t): Ditto.
4241 (vint64m4_t): Ditto.
4242 (vint64m8_t): Ditto.
4243 (vuint16mf4_t): Ditto.
4244 (vuint16mf2_t): Ditto.
4245 (vuint16m1_t): Ditto.
4246 (vuint16m2_t): Ditto.
4247 (vuint16m4_t): Ditto.
4248 (vuint16m8_t): Ditto.
4249 (vuint32mf2_t): Ditto.
4250 (vuint32m1_t): Ditto.
4251 (vuint32m2_t): Ditto.
4252 (vuint32m4_t): Ditto.
4253 (vuint32m8_t): Ditto.
4254 (vuint64m1_t): Ditto.
4255 (vuint64m2_t): Ditto.
4256 (vuint64m4_t): Ditto.
4257 (vuint64m8_t): Ditto.
4258 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_WEXTI_OPS): Ditto.
4259 (DEF_RVV_QEXTI_OPS): Ditto.
4260 (DEF_RVV_OEXTI_OPS): Ditto.
4261 (DEF_RVV_WEXTU_OPS): Ditto.
4262 (DEF_RVV_QEXTU_OPS): Ditto.
4263 (DEF_RVV_OEXTU_OPS): Ditto.
4264 (rvv_arg_type_info::get_base_vector_type): Add sign_exted/zero_extend
4266 (rvv_arg_type_info::get_tree_type): Ditto.
4267 * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Ditto.
4268 * config/riscv/vector-iterators.md (z): New attribute.
4269 * config/riscv/vector.md (@pred_<optab><mode>_vf2): New pattern.
4270 (@pred_<optab><mode>_vf4): Ditto.
4271 (@pred_<optab><mode>_vf8): Ditto.
4273 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4275 * config/riscv/iterators.md: Add saturating Addition && Subtraction.
4276 * config/riscv/riscv-v.cc (has_vi_variant_p): Ditto.
4277 * config/riscv/riscv-vector-builtins-bases.cc (BASE): Ditto.
4278 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
4279 * config/riscv/riscv-vector-builtins-functions.def (vsadd): New def.
4283 * config/riscv/vector-iterators.md (sll.vi): Adjust for Saturating
4288 * config/riscv/vector.md (@pred_<optab><mode>): New pattern.
4289 (@pred_<optab><mode>_scalar): New pattern.
4290 (*pred_<optab><mode>_scalar): New pattern.
4291 (*pred_<optab><mode>_extended_scalar): New pattern.
4293 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4295 * config/riscv/iterators.md: Add neg and not.
4296 * config/riscv/riscv-vector-builtins-bases.cc (class unop): New class.
4298 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
4299 * config/riscv/riscv-vector-builtins-functions.def (vadd): Rename binop
4320 * config/riscv/riscv-vector-builtins-shapes.cc (struct binop_def): Ditto.
4321 (struct alu_def): Ditto.
4323 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
4324 * config/riscv/riscv-vector-builtins.cc: Support unary C/C/++.
4325 * config/riscv/vector-iterators.md: New iterator.
4326 * config/riscv/vector.md (@pred_<optab><mode>): New pattern
4328 2023-02-12 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4330 * config/riscv/riscv-vsetvl.cc (pass_vsetvl::compute_probabilities): Skip exit block.
4332 2023-02-11 Jakub Jelinek <jakub@redhat.com>
4335 * ipa-cp.cc (ipa_agg_value_from_jfunc): Return NULL_TREE also if
4336 item->offset bit position is too large to be representable as
4337 unsigned int byte position.
4339 2023-02-11 Gerald Pfeifer <gerald@pfeifer.com>
4341 * doc/extend.texi (Other Builtins): Adjust link to WG14 N965.
4343 2023-02-10 Vladimir N. Makarov <vmakarov@redhat.com>
4345 * ira.cc (update_equiv_regs): Set up ira_reg_equiv for
4346 valid_combine only when ira_use_lra_p is true.
4348 2023-02-10 Vladimir N. Makarov <vmakarov@redhat.com>
4350 * params.opt (ira-simple-lra-insn-threshold): Add new param.
4351 * ira.cc (ira): Use the param to switch on simple LRA.
4353 2023-02-10 Andrew MacLeod <amacleod@redhat.com>
4355 PR tree-optimization/108687
4356 * gimple-range-cache.cc (ranger_cache::range_on_edge): Revert
4357 back to RFD_NONE mode for calculations.
4358 (ranger_cache::propagate_cache): Call the internal edge range API
4359 with RFD_READ_ONLY instead of changing the external routine.
4361 2023-02-10 Andrew MacLeod <amacleod@redhat.com>
4363 PR tree-optimization/108520
4364 * gimple-range-infer.cc (check_assume_func): Invoke
4365 gimple_range_global directly instead using global_range_query.
4366 * value-query.cc (get_range_global): Add function context and
4367 avoid calling nonnull_arg_p if not cfun.
4368 (gimple_range_global): Add function context pointer.
4369 * value-query.h (imple_range_global): Add function context.
4371 2023-02-10 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4373 * config/riscv/constraints.md (Wdm): Adjust constraint.
4374 (Wbr): New constraint.
4375 * config/riscv/predicates.md (reg_or_int_operand): New predicate.
4376 * config/riscv/riscv-protos.h (emit_pred_op): Remove function.
4377 (emit_vlmax_op): New function.
4378 (emit_nonvlmax_op): Ditto.
4380 (neg_simm5_p): Ditto.
4381 (has_vi_variant_p): Ditto.
4382 * config/riscv/riscv-v.cc (emit_pred_op): Adjust function.
4383 (emit_vlmax_op): New function.
4384 (emit_nonvlmax_op): Ditto.
4385 (expand_const_vector): Adjust function.
4386 (legitimize_move): Ditto.
4387 (simm32_p): New function.
4389 (neg_simm5_p): Ditto.
4390 (has_vi_variant_p): Ditto.
4391 * config/riscv/riscv-vector-builtins-bases.cc (class vrsub): New class.
4393 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
4394 * config/riscv/riscv-vector-builtins-functions.def (vmin): Remove
4397 (vminu): Remove signed cases.
4399 (vdiv): Remove unsigned cases.
4401 (vdivu): Remove signed cases.
4410 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_U_OPS): New macro.
4411 * config/riscv/riscv.h: change VL/VTYPE as fixed reg.
4412 * config/riscv/vector-iterators.md: New iterators.
4413 * config/riscv/vector.md (@pred_broadcast<mode>): Adjust pattern for vx
4415 (@pred_<optab><mode>_scalar): New pattern.
4416 (@pred_sub<mode>_reverse_scalar): Ditto.
4417 (*pred_<optab><mode>_scalar): Ditto.
4418 (*pred_<optab><mode>_extended_scalar): Ditto.
4419 (*pred_sub<mode>_reverse_scalar): Ditto.
4420 (*pred_sub<mode>_extended_reverse_scalar): Ditto.
4422 2023-02-10 Richard Biener <rguenther@suse.de>
4424 PR tree-optimization/108724
4425 * tree-vect-stmts.cc (vectorizable_operation): Avoid
4426 using word_mode vectors when vector lowering will
4427 decompose them to elementwise operations.
4429 2023-02-10 Jakub Jelinek <jakub@redhat.com>
4432 2023-02-09 Martin Liska <mliska@suse.cz>
4435 * doc/extend.texi: Document that the function
4436 does not work correctly for old VIA processors.
4438 2023-02-10 Andrew Pinski <apinski@marvell.com>
4439 Andrew Macleod <amacleod@redhat.com>
4441 PR tree-optimization/108684
4442 * tree-ssa-dce.cc (simple_dce_from_worklist):
4443 Check all ssa names and not just non-vdef ones
4444 before accepting the inline-asm.
4445 Call unlink_stmt_vdef on the statement before
4448 2023-02-09 Vladimir N. Makarov <vmakarov@redhat.com>
4450 * ira.h (struct ira_reg_equiv_s): Add new field caller_save_p.
4451 * ira.cc (validate_equiv_mem): Check memref address variance.
4452 (no_equiv): Clear caller_save_p flag.
4453 (update_equiv_regs): Define caller save equivalence for
4455 (setup_reg_equiv): Clear defined_p flag for caller save equivalence.
4456 * lra-constraints.cc (lra_copy_reg_equiv): Add new arg
4457 call_save_p. Use caller save equivalence depending on the arg.
4458 (split_reg): Adjust the call.
4460 2023-02-09 Jakub Jelinek <jakub@redhat.com>
4463 * common/config/i386/cpuinfo.h (get_zhaoxin_cpu): Formatting fixes.
4464 (cpu_indicator_init): Call get_available_features for all CPUs with
4465 max_level >= 1, rather than just Intel, AMD or Zhaoxin. Formatting
4468 2023-02-09 Jakub Jelinek <jakub@redhat.com>
4470 PR tree-optimization/108688
4471 * match.pd (bit_field_ref [bit_insert]): Simplify BIT_FIELD_REF
4472 of BIT_INSERT_EXPR extracting exactly all inserted bits even
4473 when without mode precision. Formatting fixes.
4475 2023-02-09 Andrew Pinski <apinski@marvell.com>
4477 PR tree-optimization/108688
4478 * match.pd (bit_field_ref [bit_insert]): Avoid generating
4479 BIT_FIELD_REFs of non-mode-precision integral operands.
4481 2023-02-09 Martin Liska <mliska@suse.cz>
4484 * doc/extend.texi: Document that the function
4485 does not work correctly for old VIA processors.
4487 2023-02-09 Andreas Schwab <schwab@suse.de>
4489 * lto-wrapper.cc (merge_and_complain): Handle
4490 -funwind-tables and -fasynchronous-unwind-tables.
4491 (append_compiler_options): Likewise.
4493 2023-02-09 Richard Biener <rguenther@suse.de>
4495 PR tree-optimization/26854
4496 * tree-into-ssa.cc (update_ssa): Turn blocks_to_update to tree
4497 view around insert_updated_phi_nodes_for.
4498 * tree-ssa-alias.cc (maybe_skip_until): Allocate visited bitmap
4500 (walk_aliased_vdefs_1): Likewise.
4502 2023-02-08 Gerald Pfeifer <gerald@pfeifer.com>
4504 * doc/include/gpl_v3.texi: Change fsf.org to www.fsf.org.
4506 2023-02-08 Srinath Parvathaneni <srinath.parvathaneni@arm.com>
4509 * config.gcc (tm_mlib_file): Define new variable.
4511 2023-02-08 Jakub Jelinek <jakub@redhat.com>
4513 PR tree-optimization/108692
4514 * tree-vect-patterns.cc (vect_widened_op_tree): If rhs_code is
4515 widened_code which is different from code, don't call
4516 vect_look_through_possible_promotion but instead just check op is
4517 SSA_NAME with integral type for which vect_is_simple_use is true
4518 and call set_op on this_unprom.
4520 2023-02-08 Andrea Corallo <andrea.corallo@arm.com>
4522 * config/aarch64/aarch64-protos.h (aarch_ra_sign_key): Remove
4524 * config/aarch64/aarch64.cc (aarch_ra_sign_key): Remove
4526 * config/aarch64/aarch64.opt (aarch64_ra_sign_key): Rename
4527 to 'aarch_ra_sign_key'.
4528 * config/arm/aarch-common.cc (aarch_ra_sign_key): Remove
4530 * config/arm/arm-protos.h (aarch_ra_sign_key): Likewise.
4531 * config/arm/arm.cc (enum aarch_key_type): Remove definition.
4532 * config/arm/arm.opt: Define.
4534 2023-02-08 Richard Sandiford <richard.sandiford@arm.com>
4536 PR tree-optimization/108316
4537 * tree-vect-stmts.cc (get_load_store_type): When using
4538 internal functions for gather/scatter, make sure that the type
4539 of the offset argument is consistent with the offset vector type.
4541 2023-02-08 Vladimir N. Makarov <vmakarov@redhat.com>
4544 2023-02-07 Vladimir N. Makarov <vmakarov@redhat.com>
4546 * ira.h (struct ira_reg_equiv_s): Add new field caller_save_p.
4547 * ira.cc (validate_equiv_mem): Check memref address variance.
4548 (update_equiv_regs): Define caller save equivalence for
4550 (setup_reg_equiv): Clear defined_p flag for caller save equivalence.
4551 * lra-constraints.cc (lra_copy_reg_equiv): Add new arg
4552 call_save_p. Use caller save equivalence depending on the arg.
4553 (split_reg): Adjust the call.
4555 2023-02-08 Jakub Jelinek <jakub@redhat.com>
4557 * tree.def (SAD_EXPR): Remove outdated comment about missing
4560 2023-02-07 Marek Polacek <polacek@redhat.com>
4562 * doc/invoke.texi: Update -fchar8_t documentation.
4564 2023-02-07 Vladimir N. Makarov <vmakarov@redhat.com>
4566 * ira.h (struct ira_reg_equiv_s): Add new field caller_save_p.
4567 * ira.cc (validate_equiv_mem): Check memref address variance.
4568 (update_equiv_regs): Define caller save equivalence for
4570 (setup_reg_equiv): Clear defined_p flag for caller save equivalence.
4571 * lra-constraints.cc (lra_copy_reg_equiv): Add new arg
4572 call_save_p. Use caller save equivalence depending on the arg.
4573 (split_reg): Adjust the call.
4575 2023-02-07 Richard Biener <rguenther@suse.de>
4577 PR tree-optimization/26854
4578 * gimple-fold.cc (has_use_on_stmt): Look at stmt operands
4579 instead of immediate uses.
4581 2023-02-07 Jakub Jelinek <jakub@redhat.com>
4583 PR tree-optimization/106923
4584 * ipa-split.cc (execute_split_functions): Don't split returns_twice
4587 2023-02-07 Jakub Jelinek <jakub@redhat.com>
4589 PR tree-optimization/106433
4590 * cgraph.cc (set_const_flag_1): Recurse on simd clones too.
4591 (cgraph_node::set_pure_flag): Call set_pure_flag_1 on simd clones too.
4593 2023-02-07 Jan Hubicka <jh@suse.cz>
4595 * config/i386/x86-tune.def (X86_TUNE_AVX256_OPTIMAL): Turn off
4598 2023-02-06 Andrew Stubbs <ams@codesourcery.com>
4600 * config/gcn/mkoffload.cc (gcn_stack_size): New global variable.
4601 (process_asm): Create a constructor for GCN_STACK_SIZE.
4602 (main): Parse the -mstack-size option.
4604 2023-02-06 Alex Coplan <alex.coplan@arm.com>
4607 * config/aarch64/aarch64-simd.md (aarch64_bfmlal<bt>_lane<q>v4sf):
4608 Use correct constraint for operand 3.
4610 2023-02-06 Martin Jambor <mjambor@suse.cz>
4612 * ipa-sra.cc (adjust_parameter_descriptions): Fix a typo in a dump.
4614 2023-02-06 Xi Ruoyao <xry111@xry111.site>
4616 * config/loongarch/loongarch.md (bytepick_w_ashift_amount):
4617 New define_int_iterator.
4618 (bytepick_d_ashift_amount): Likewise.
4619 (bytepick_imm): New define_int_attr.
4620 (bytepick_w_lshiftrt_amount): Likewise.
4621 (bytepick_d_lshiftrt_amount): Likewise.
4622 (bytepick_w_<bytepick_imm>): New define_insn template.
4623 (bytepick_w_<bytepick_imm>_extend): Likewise.
4624 (bytepick_d_<bytepick_imm>): Likewise.
4625 (bytepick_w): Remove unused define_insn.
4626 (bytepick_d): Likewise.
4627 (UNSPEC_BYTEPICK_W): Remove unused unspec.
4628 (UNSPEC_BYTEPICK_D): Likewise.
4629 * config/loongarch/predicates.md (const_0_to_3_operand):
4630 Remove unused define_predicate.
4631 (const_0_to_7_operand): Likewise.
4633 2023-02-06 Jakub Jelinek <jakub@redhat.com>
4635 PR tree-optimization/108655
4636 * ubsan.cc (sanitize_unreachable_fn): For -funreachable-traps
4637 or -fsanitize=unreachable -fsanitize-trap=unreachable return
4638 BUILT_IN_UNREACHABLE_TRAP decl rather than BUILT_IN_TRAP.
4640 2023-02-05 Gerald Pfeifer <gerald@pfeifer.com>
4642 * doc/install.texi (Specific): Remove PW32.
4644 2023-02-03 Jakub Jelinek <jakub@redhat.com>
4646 PR tree-optimization/108647
4647 * range-op.cc (operator_equal::op1_range,
4648 operator_not_equal::op1_range): Don't test op2 bound
4649 equality if op2.undefined_p (), instead set_varying.
4650 (operator_lt::op1_range, operator_le::op1_range,
4651 operator_gt::op1_range, operator_ge::op1_range): Return false if
4653 (operator_lt::op2_range, operator_le::op2_range,
4654 operator_gt::op2_range, operator_ge::op2_range): Return false if
4657 2023-02-03 Aldy Hernandez <aldyh@redhat.com>
4659 PR tree-optimization/108639
4660 * value-range.cc (irange::legacy_equal_p): Compare nonzero bits as
4662 (irange::operator==): Same.
4664 2023-02-03 Aldy Hernandez <aldyh@redhat.com>
4666 PR tree-optimization/108647
4667 * range-op-float.cc (foperator_lt::op1_range): Handle undefined ranges.
4668 (foperator_lt::op2_range): Same.
4669 (foperator_le::op1_range): Same.
4670 (foperator_le::op2_range): Same.
4671 (foperator_gt::op1_range): Same.
4672 (foperator_gt::op2_range): Same.
4673 (foperator_ge::op1_range): Same.
4674 (foperator_ge::op2_range): Same.
4675 (foperator_unordered_lt::op1_range): Same.
4676 (foperator_unordered_lt::op2_range): Same.
4677 (foperator_unordered_le::op1_range): Same.
4678 (foperator_unordered_le::op2_range): Same.
4679 (foperator_unordered_gt::op1_range): Same.
4680 (foperator_unordered_gt::op2_range): Same.
4681 (foperator_unordered_ge::op1_range): Same.
4682 (foperator_unordered_ge::op2_range): Same.
4684 2023-02-03 Andrew MacLeod <amacleod@redhat.com>
4686 PR tree-optimization/107570
4687 * tree-vrp.cc (remove_and_update_globals): Reset SCEV.
4689 2023-02-03 Gaius Mulley <gaiusmod2@gmail.com>
4691 * doc/gm2.texi (Internals): Remove from menu.
4692 (Using): Comment out ifnohtml conditional.
4693 (Documentation): Use gcc url.
4694 (License): Node simplified.
4695 (Copying): New node. Include gpl_v3_without_node.
4696 (Contributing): Node simplified.
4697 (Internals): Commented out.
4698 (Libraries): Node simplified.
4703 2023-02-03 Christophe Lyon <christophe.lyon@arm.com>
4705 * config/arm/mve.md (mve_vabavq_p_<supf><mode>): Add length
4707 (mve_vqshluq_m_n_s<mode>): Likewise.
4708 (mve_vshlq_m_<supf><mode>): Likewise.
4709 (mve_vsriq_m_n_<supf><mode>): Likewise.
4710 (mve_vsubq_m_<supf><mode>): Likewise.
4712 2023-02-03 Martin Jambor <mjambor@suse.cz>
4715 * ipa-sra.cc (push_param_adjustments_for_index): Remove a size check
4716 when comparing to an IPA-CP value.
4717 (dump_list_of_param_indices): New function.
4718 (adjust_parameter_descriptions): Check for mismatching IPA-CP values.
4719 Dump removed candidates using dump_list_of_param_indices.
4720 * ipa-param-manipulation.cc
4721 (ipa_param_body_adjustments::modify_expression): Add assert checking
4722 sizes of a VIEW_CONVERT_EXPR will match.
4723 (ipa_param_body_adjustments::modify_assignment): Likewise.
4725 2023-02-03 Monk Chiang <monk.chiang@sifive.com>
4727 * config/riscv/riscv.h: Remove VL_REGS, VTYPE_REGS class.
4728 * config/riscv/riscv.cc: Ditto.
4730 2023-02-03 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4732 * config/riscv/vector-iterators.md (sll.vi): Fix constraint bug.
4736 * config/riscv/vector.md: Ditto.
4738 2023-02-03 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
4740 * config/riscv/predicates.md (pmode_reg_or_uimm5_operand): New predicate.
4741 * config/riscv/riscv-vector-builtins-bases.cc: New class.
4742 * config/riscv/riscv-vector-builtins-functions.def (vsll): Ditto.
4745 * config/riscv/riscv-vector-builtins.cc: Ditto.
4746 * config/riscv/vector.md (@pred_<optab><mode>_scalar): New pattern.
4748 2023-02-02 Iain Sandoe <iain@sandoe.co.uk>
4750 * toplev.cc (toplev::main): Only print the version information header
4751 from toplevel main().
4753 2023-02-02 Paul-Antoine Arras <pa@codesourcery.com>
4755 * config/gcn/gcn-valu.md (cond_<expander><mode>): Add
4756 cond_{ashl|ashr|lshr}
4758 2023-02-02 Richard Sandiford <richard.sandiford@arm.com>
4760 PR rtl-optimization/108086
4761 * rtl-ssa/insns.h (insn_info): Make m_num_defs a full unsigned int.
4762 Adjust size-related commentary accordingly.
4764 2023-02-02 Richard Sandiford <richard.sandiford@arm.com>
4766 PR rtl-optimization/108508
4767 * rtl-ssa/accesses.cc (function_info::split_clobber_group): When
4768 the splay tree search gives the first clobber in the second group,
4769 make sure that the root of the first clobber group is updated
4770 correctly. Enter the new clobber group into the definition splay
4773 2023-02-02 Jin Ma <jinma@linux.alibaba.com>
4775 * common/config/riscv/riscv-common.cc (riscv_compute_multilib):
4776 Fix finding best match score.
4778 2023-02-02 Jakub Jelinek <jakub@redhat.com>
4781 PR rtl-optimization/108463
4783 * cselib.cc (cselib_current_insn): Move declaration earlier.
4784 (cselib_hasher::equal): For debug only locs, temporarily override
4785 cselib_current_insn to their l->setting_insn for the
4786 rtx_equal_for_cselib_1 call, so that unsuccessful comparisons don't
4787 promote some debug locs.
4788 * sched-deps.cc (sched_analyze_2) <case MEM>: For MEMs in DEBUG_INSNs
4789 when using cselib call cselib_lookup_from_insn on the address but
4790 don't substitute it.
4792 2023-02-02 Richard Biener <rguenther@suse.de>
4794 PR middle-end/108625
4795 * genmatch.cc (expr::gen_transform): Also disallow resimplification
4796 from pushing to lseq with force_leaf.
4797 (dt_simplify::gen_1): Likewise.
4799 2023-02-02 Andrew Stubbs <ams@codesourcery.com>
4801 * config/gcn/gcn-run.cc: Include libgomp-gcn.h.
4802 (struct kernargs): Replace the common content with kernargs_abi.
4803 (struct heap): Delete.
4804 (main): Read GCN_STACK_SIZE envvar.
4805 Allocate space for the device stacks.
4806 Write the new kernargs fields.
4807 * config/gcn/gcn.cc (gcn_option_override): Remove stack_size_opt.
4808 (default_requested_args): Remove PRIVATE_SEGMENT_BUFFER_ARG and
4809 PRIVATE_SEGMENT_WAVE_OFFSET_ARG.
4810 (gcn_addr_space_convert): Mask the QUEUE_PTR_ARG content.
4811 (gcn_expand_prologue): Move the TARGET_PACKED_WORK_ITEMS to the top.
4812 Set up the stacks from the values in the kernargs, not private.
4813 (gcn_expand_builtin_1): Match the stack configuration in the prologue.
4814 (gcn_hsa_declare_function_name): Turn off the private segment.
4815 (gcn_conditional_register_usage): Ensure QUEUE_PTR is fixed.
4816 * config/gcn/gcn.h (FIXED_REGISTERS): Fix the QUEUE_PTR register.
4817 * config/gcn/gcn.opt (mstack-size): Change the description.
4819 2023-02-02 Andre Vieira <andre.simoesdiasvieira@arm.com>
4822 * config/arm/arm.h (VALID_MVE_PRED_MODE): Add V2QI.
4823 * config/arm/arm.cc (thumb2_legitimate_address_p): Use HImode for
4824 addressing MVE predicate modes.
4825 (mve_bool_vec_to_const): Change to represent correct MVE predicate
4827 (arm_hard_regno_mode_ok): Use VALID_MVE_PRED_MODE instead of checking
4829 (arm_vector_mode_supported_p): Likewise.
4830 (arm_mode_to_pred_mode): Add V2QI.
4831 * config/arm/arm-builtins.cc (UNOP_PRED_UNONE_QUALIFIERS): New
4833 (UNOP_PRED_PRED_QUALIFIERS): New qualifier
4834 (BINOP_PRED_UNONE_PRED_QUALIFIERS): New qualifier.
4835 (v2qi_UP): New macro.
4836 (v4bi_UP): New macro.
4837 (v8bi_UP): New macro.
4838 (v16bi_UP): New macro.
4839 (arm_expand_builtin_args): Make it able to expand the new predicate
4841 * config/arm/arm-modes.def (V2QI): New mode.
4842 * config/arm/arm-simd-builtin-types.def (Pred1x16_t, Pred2x8_t
4843 Pred4x4_t): Remove unused predicate builtin types.
4844 * config/arm/arm_mve.h (__arm_vctp16q, __arm_vctp32q, __arm_vctp64q,
4845 __arm_vctp8q, __arm_vpnot, __arm_vctp8q_m, __arm_vctp64q_m,
4846 __arm_vctp32q_m, __arm_vctp16q_m): Use predicate modes.
4847 * config/arm/arm_mve_builtins.def (vctp16q, vctp32q, vctp64q, vctp8q,
4848 vpnot, vctp8q_m, vctp16q_m, vctp32q_m, vctp64q_m): Likewise.
4849 * config/arm/constraints.md (DB): Check for VALID_MVE_PRED_MODE instead
4850 of MODE_VECTOR_BOOL.
4851 * config/arm/iterators.md (MVE_7, MVE_7_HI): Add V2QI
4852 (MVE_VPRED): Likewise.
4853 (MVE_vpred): Add V2QI and map upper case predicate modes to lower case.
4854 (MVE_vctp): New mode attribute.
4858 * config/arm/mve.md (mve_vctp<mode1>qhi): Rename this...
4859 (mve_vctp<MVE_vctp>q<MVE_vpred>): ... to this. And use new mode
4861 (mve_vpnothi): Rename this...
4862 (mve_vpnotv16bi): ... to this.
4863 (mve_vctp<mode1>q_mhi): Rename this...
4864 (mve_vctp<MVE_vctp>q_m<MVE_vpred>):... to this.
4865 (mve_vldrdq_gather_base_z_<supf>v2di,
4866 mve_vldrdq_gather_offset_z_<supf>v2di,
4867 mve_vldrdq_gather_shifted_offset_z_<supf>v2di,
4868 mve_vstrdq_scatter_base_p_<supf>v2di,
4869 mve_vstrdq_scatter_offset_p_<supf>v2di,
4870 mve_vstrdq_scatter_offset_p_<supf>v2di_insn,
4871 mve_vstrdq_scatter_shifted_offset_p_<supf>v2di,
4872 mve_vstrdq_scatter_shifted_offset_p_<supf>v2di_insn,
4873 mve_vstrdq_scatter_base_wb_p_<supf>v2di,
4874 mve_vldrdq_gather_base_wb_z_<supf>v2di,
4875 mve_vldrdq_gather_base_nowb_z_<supf>v2di,
4876 mve_vldrdq_gather_base_wb_z_<supf>v2di_insn): Use V2QI insead of HI for
4878 * config/arm/unspecs.md (VCTP8Q, VCTP16Q, VCTP32Q, VCTP64Q): Replace
4880 (VCTP): ... with this.
4881 (VCTP8Q_M, VCTP16Q_M, VCTP32Q_M, VCTP64Q_M): Replace these...
4882 (VCTP_M): ... with this.
4883 * config/arm/vfp.md (*thumb2_movhi_vfp, *thumb2_movhi_fp16): Use
4884 VALID_MVE_PRED_MODE instead of checking for MODE_VECTOR_BOOL class.
4886 2023-02-02 Andre Vieira <andre.simoesdiasvieira@arm.com>
4889 * config/arm/arm.cc (arm_hard_regno_mode_ok): Use new MACRO.
4890 (arm_modes_tieable_p): Make MVE predicate modes tieable.
4891 * config/arm/arm.h (VALID_MVE_PRED_MODE): New define.
4892 * simplify-rtx.cc (simplify_context::simplify_subreg): Teach
4893 simplify_subreg to simplify subregs where the outermode is not scalar.
4895 2023-02-02 Andre Vieira <andre.simoesdiasvieira@arm.com>
4898 * config/arm/arm-builtins.cc (arm_simd_builtin_type): Rewrite to use
4899 new qualifiers parameter and use unsigned short type for MVE predicate.
4900 (arm_init_builtin): Call arm_simd_builtin_type with qualifiers
4902 (arm_init_crypto_builtins): Likewise.
4904 2023-02-02 Jakub Jelinek <jakub@redhat.com>
4907 * builtins.def (BUILT_IN_UNREACHABLE_TRAP): New builtin.
4908 * internal-fn.def (TRAP): Remove.
4909 * internal-fn.cc (expand_TRAP): Remove.
4910 * tree.cc (build_common_builtin_nodes): Define
4911 BUILT_IN_UNREACHABLE_TRAP if not yet defined.
4912 (builtin_decl_unreachable): Use BUILT_IN_UNREACHABLE_TRAP
4913 instead of BUILT_IN_TRAP.
4914 * gimple.cc (gimple_build_builtin_unreachable): Remove
4915 emitting internal function for BUILT_IN_TRAP.
4916 * asan.cc (maybe_instrument_call): Handle BUILT_IN_UNREACHABLE_TRAP.
4917 * cgraph.cc (cgraph_edge::verify_corresponds_to_fndecl): Handle
4918 BUILT_IN_UNREACHABLE_TRAP instead of BUILT_IN_TRAP.
4919 * ipa-devirt.cc (possible_polymorphic_call_target_p): Handle
4920 BUILT_IN_UNREACHABLE_TRAP.
4921 * builtins.cc (expand_builtin, is_inexpensive_builtin): Likewise.
4922 * tree-cfg.cc (verify_gimple_call,
4923 pass_warn_function_return::execute): Likewise.
4924 * attribs.cc (decl_attributes): Don't report exclusions on
4925 BUILT_IN_UNREACHABLE_TRAP either.
4927 2023-02-02 liuhongt <hongtao.liu@intel.com>
4929 PR tree-optimization/108601
4930 * tree-vectorizer.h (vect_can_peel_nonlinear_iv_p): Removed.
4932 (vectorizable_nonlinear_induction): Remove
4933 vect_can_peel_nonlinear_iv_p.
4934 (vect_can_peel_nonlinear_iv_p): Don't peel
4935 nonlinear iv(mult or shift) for epilog when vf is not
4936 constant and moved the defination to ..
4937 * tree-vect-loop-manip.cc (vect_can_peel_nonlinear_iv_p):
4940 2023-02-02 Jakub Jelinek <jakub@redhat.com>
4942 PR middle-end/108435
4943 * tree-nested.cc (convert_nonlocal_omp_clauses)
4944 <case OMP_CLAUSE_LASTPRIVATE>: If info->new_local_var_chain and *seq
4945 is not a GIMPLE_BIND, wrap the sequence into a new GIMPLE_BIND
4946 before calling declare_vars.
4947 (convert_nonlocal_omp_clauses) <case OMP_CLAUSE_LINEAR>: Merge
4948 with the OMP_CLAUSE_LASTPRIVATE handling except for whether
4949 seq is initialized to &OMP_CLAUSE_LASTPRIVATE_GIMPLE_SEQ (clause)
4950 or &OMP_CLAUSE_LINEAR_GIMPLE_SEQ (clause).
4952 2023-02-01 Tamar Christina <tamar.christina@arm.com>
4954 * common/config/aarch64/aarch64-common.cc
4955 (struct aarch64_option_extension): Add native_detect and document struct
4957 (all_extensions): Set new field native_detect.
4958 * config/aarch64/aarch64.cc (struct aarch64_option_extension): Delete
4961 2023-02-01 Martin Liska <mliska@suse.cz>
4963 * ipa-devirt.cc (odr_types_equivalent_p): Respect *warned
4966 2023-02-01 Andrew MacLeod <amacleod@redhat.com>
4968 PR tree-optimization/108356
4969 * gimple-range-cache.cc (ranger_cache::range_on_edge): Always
4970 do a search of the DOM tree for a range.
4972 2023-02-01 Martin Liska <mliska@suse.cz>
4975 * cgraphunit.cc (walk_polymorphic_call_targets): Insert
4976 ony non-null values.
4977 * ipa.cc (walk_polymorphic_call_targets): Likewise.
4979 2023-02-01 Martin Liska <mliska@suse.cz>
4982 * gcc.cc (LINK_COMPRESS_DEBUG_SPEC): Report error only for
4985 2023-02-01 Jakub Jelinek <jakub@redhat.com>
4988 * ree.cc (combine_reaching_defs): Don't return false for paradoxical
4989 subregs in DEBUG_INSNs.
4991 2023-02-01 Richard Sandiford <richard.sandiford@arm.com>
4993 * compare-elim.cc (find_flags_uses_in_insn): Guard use of SET_SRC.
4995 2023-02-01 Andreas Krebbel <krebbel@linux.ibm.com>
4997 * config/s390/s390.cc (s390_restore_gpr_p): New function.
4998 (s390_preserve_gpr_arg_in_range_p): New function.
4999 (s390_preserve_gpr_arg_p): New function.
5000 (s390_preserve_fpr_arg_p): New function.
5001 (s390_register_info_stdarg_fpr): Rename to ...
5002 (s390_register_info_arg_fpr): ... this. Add -mpreserve-args handling.
5003 (s390_register_info_stdarg_gpr): Rename to ...
5004 (s390_register_info_arg_gpr): ... this. Add -mpreserve-args handling.
5005 (s390_register_info): Use the renamed functions above.
5006 (s390_optimize_register_info): Likewise.
5007 (save_fpr): Generate CFI for -mpreserve-args.
5008 (save_gprs): Generate CFI for -mpreserve-args. Drop return value.
5009 (s390_emit_prologue): Adjust to changed calling convention of save_gprs.
5010 (s390_optimize_prologue): Likewise.
5011 * config/s390/s390.opt: New option -mpreserve-args
5013 2023-02-01 Andreas Krebbel <krebbel@linux.ibm.com>
5015 * config/s390/s390.cc (save_gprs): Use gen_frame_mem.
5016 (restore_gprs): Likewise.
5017 (s390_emit_stack_tie): Make the stack_tie to be dependent on the
5018 frame pointer if a frame-pointer is used.
5019 (s390_emit_prologue): Emit stack_tie when frame-pointer is needed.
5020 * config/s390/s390.md (stack_tie): Add a register operand and
5022 (@stack_tie<mode>): ... this.
5024 2023-02-01 Andreas Krebbel <krebbel@linux.ibm.com>
5026 * dwarf2cfi.cc (dwarf2out_frame_debug_cfa_restore): Add
5028 (dwarf2out_frame_debug): Add case for REG_CFA_NORESTORE.
5029 * reg-notes.def (REG_CFA_NOTE): New reg note definition.
5031 2023-02-01 Richard Biener <rguenther@suse.de>
5033 PR middle-end/108500
5034 * dominance.cc (assign_dfs_numbers): Replace recursive DFS
5035 with tree traversal algorithm.
5037 2023-02-01 Jason Merrill <jason@redhat.com>
5039 * doc/invoke.texi: Document -Wno-changes-meaning.
5041 2023-02-01 David Malcolm <dmalcolm@redhat.com>
5043 * doc/invoke.texi (Static Analyzer Options): Add notes about
5044 limitations of -fanalyzer.
5046 2023-01-31 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5048 * config/riscv/constraints.md (vj): New.
5050 * config/riscv/iterators.md: Add more opcode.
5051 * config/riscv/predicates.md (vector_arith_operand): New.
5052 (vector_neg_arith_operand): New.
5053 (vector_shift_operand): New.
5054 * config/riscv/riscv-vector-builtins-bases.cc (class binop): New.
5055 * config/riscv/riscv-vector-builtins-bases.h: (vadd): New.
5072 * config/riscv/riscv-vector-builtins-functions.def (vadd): New.
5089 * config/riscv/riscv-vector-builtins-shapes.cc (struct binop_def): New.
5090 * config/riscv/riscv-vector-builtins-shapes.h (binop): New.
5091 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_I_OPS): New.
5092 (DEF_RVV_U_OPS): New.
5093 (rvv_arg_type_info::get_base_vector_type): Handle
5094 RVV_BASE_shift_vector.
5095 (rvv_arg_type_info::get_tree_type): Ditto.
5096 * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Add
5097 RVV_BASE_shift_vector.
5098 * config/riscv/riscv.cc (riscv_print_operand): Handle 'V'.
5099 * config/riscv/vector-iterators.md: Handle more opcode.
5100 * config/riscv/vector.md (@pred_<optab><mode>): New.
5102 2023-01-31 Philipp Tomsich <philipp.tomsich@vrull.eu>
5105 * config/aarch64/aarch64.cc (aarch_macro_fusion_pair_p): Check
5108 2023-01-31 Richard Sandiford <richard.sandiford@arm.com>
5110 PR tree-optimization/108608
5111 * tree-vect-loop.cc (vect_transform_reduction): Handle single
5112 def-use cycles that involve function calls rather than tree codes.
5114 2023-01-31 Andrew MacLeod <amacleod@redhat.com>
5116 PR tree-optimization/108385
5117 * gimple-range-gori.cc (gori_compute::compute_operand_range):
5118 Allow VARYING computations to continue if there is a relation.
5119 * range-op.cc (pointer_plus_operator::op2_range): New.
5121 2023-01-31 Andrew MacLeod <amacleod@redhat.com>
5123 PR tree-optimization/108359
5124 * range-op.cc (range_operator::wi_fold_in_parts_equiv): New.
5125 (range_operator::fold_range): If op1 is equivalent to op2 then
5126 invoke new fold_in_parts_equiv to operate on sub-components.
5127 * range-op.h (wi_fold_in_parts_equiv): New prototype.
5129 2023-01-31 Andrew MacLeod <amacleod@redhat.com>
5131 * gimple-range-gori.cc (gori_compute::compute_operand_range): Do
5132 not abort calculations if there is a valid relation available.
5133 (gori_compute::refine_using_relation): Pass correct relation trio.
5134 (gori_compute::compute_operand1_range): Create trio and use it.
5135 (gori_compute::compute_operand2_range): Ditto.
5136 * range-op.cc (operator_plus::op1_range): Use correct trio member.
5137 (operator_minus::op1_range): Use correct trio member.
5138 * value-relation.cc (value_relation::create_trio): New.
5139 * value-relation.h (value_relation::create_trio): New prototype.
5141 2023-01-31 Jakub Jelinek <jakub@redhat.com>
5144 * config/i386/i386-expand.cc
5145 (ix86_convert_const_wide_int_to_broadcast): Return nullptr if
5146 CONST_WIDE_INT_NUNITS (op) times HOST_BITS_PER_WIDE_INT isn't
5147 equal to bitsize of mode.
5149 2023-01-31 Jakub Jelinek <jakub@redhat.com>
5151 PR rtl-optimization/108596
5152 * bb-reorder.cc (fix_up_fall_thru_edges): Handle the case where cur_bb
5153 ends with asm goto and has a crossing fallthrough edge to the same bb
5154 that contains at least one of its labels by restoring EDGE_CROSSING
5155 flag even on possible edge from cur_bb to new_bb successor.
5157 2023-01-31 Jakub Jelinek <jakub@redhat.com>
5160 * config/i386/avx512erintrin.h (_mm512_exp2a23_round_pd,
5161 _mm512_exp2a23_round_ps, _mm512_rcp28_round_pd, _mm512_rcp28_round_ps,
5162 _mm512_rsqrt28_round_pd, _mm512_rsqrt28_round_ps): Use
5163 _mm512_undefined_pd () or _mm512_undefined_ps () instead of using
5164 uninitialized automatic variable __W.
5166 2023-01-31 Gerald Pfeifer <gerald@pfeifer.com>
5168 * doc/include/fdl.texi: Change fsf.org to www.fsf.org.
5170 2023-01-30 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5172 * config/riscv/riscv-protos.h (get_vector_mode): New function.
5173 * config/riscv/riscv-v.cc (get_vector_mode): Ditto.
5174 * config/riscv/riscv-vector-builtins-bases.cc (enum lst_type): New enum.
5175 (class loadstore): Adjust for indexed loads/stores support.
5177 * config/riscv/riscv-vector-builtins-bases.h: New function declare.
5178 * config/riscv/riscv-vector-builtins-functions.def (vluxei8): Ditto.
5194 * config/riscv/riscv-vector-builtins-shapes.cc
5195 (struct indexed_loadstore_def): New class.
5197 * config/riscv/riscv-vector-builtins-shapes.h: Ditto.
5198 * config/riscv/riscv-vector-builtins.cc (required_extensions_p): Adjust
5199 for indexed loads/stores support.
5200 (check_required_extensions): Ditto.
5201 (rvv_arg_type_info::get_base_vector_type): New function.
5202 (rvv_arg_type_info::get_tree_type): Ditto.
5203 (function_builder::add_unique_function): Adjust for indexed loads/stores
5205 (function_expander::use_exact_insn): New function.
5206 * config/riscv/riscv-vector-builtins.h (enum rvv_base_type): Adjust for
5207 indexed loads/stores support.
5208 (struct rvv_arg_type_info): Ditto.
5209 (function_expander::index_mode): New function.
5210 (function_base::apply_tail_policy_p): Ditto.
5211 (function_base::apply_mask_policy_p): Ditto.
5212 * config/riscv/vector-iterators.md (unspec): New unspec.
5213 * config/riscv/vector.md (unspec): Ditto.
5214 (@pred_indexed_<order>load<VNX1_QHSD:mode><VNX1_QHSDI:mode>): New
5216 (@pred_indexed_<order>store<VNX1_QHSD:mode><VNX1_QHSDI:mode>): Ditto.
5217 (@pred_indexed_<order>load<VNX2_QHSD:mode><VNX2_QHSDI:mode>): Ditto.
5218 (@pred_indexed_<order>store<VNX2_QHSD:mode><VNX2_QHSDI:mode>): Ditto.
5219 (@pred_indexed_<order>load<VNX4_QHSD:mode><VNX4_QHSDI:mode>): Ditto.
5220 (@pred_indexed_<order>store<VNX4_QHSD:mode><VNX4_QHSDI:mode>): Ditto.
5221 (@pred_indexed_<order>load<VNX8_QHSD:mode><VNX8_QHSDI:mode>): Ditto.
5222 (@pred_indexed_<order>store<VNX8_QHSD:mode><VNX8_QHSDI:mode>): Ditto.
5223 (@pred_indexed_<order>load<VNX16_QHS:mode><VNX16_QHSI:mode>): Ditto.
5224 (@pred_indexed_<order>store<VNX16_QHS:mode><VNX16_QHSI:mode>): Ditto.
5225 (@pred_indexed_<order>load<VNX32_QH:mode><VNX32_QHI:mode>): Ditto.
5226 (@pred_indexed_<order>store<VNX32_QH:mode><VNX32_QHI:mode>): Ditto.
5227 (@pred_indexed_<order>load<VNX64_Q:mode><VNX64_Q:mode>): Ditto.
5228 (@pred_indexed_<order>store<VNX64_Q:mode><VNX64_Q:mode>): Ditto.
5230 2023-01-30 Flavio Cruz <flaviocruz@gmail.com>
5232 * config.gcc: Recognize x86_64-*-gnu* targets and include
5234 * config/i386/gnu64.h: Define configuration for new target
5235 including ld.so location.
5237 2023-01-30 Philipp Tomsich <philipp.tomsich@vrull.eu>
5239 * config/aarch64/aarch64-cores.def (AARCH64_CORE): Update
5240 ampere1a to include SM4.
5242 2023-01-30 Andrew Pinski <apinski@marvell.com>
5244 PR tree-optimization/108582
5245 * tree-ssa-phiopt.cc (match_simplify_replacement): Add check
5246 for middlebb to have no phi nodes.
5248 2023-01-30 Richard Biener <rguenther@suse.de>
5250 PR tree-optimization/108574
5251 * tree-ssa-sccvn.cc (visit_phi): Instead of swapping
5252 sameval and def, ignore the equivalence if there's the
5253 danger of oscillating between two values.
5255 2023-01-30 Andreas Schwab <schwab@suse.de>
5257 * common/config/riscv/riscv-common.cc
5258 (riscv_option_optimization_table)
5259 [TARGET_DEFAULT_ASYNC_UNWIND_TABLES]: Enable
5260 -fasynchronous-unwind-tables and -funwind-tables.
5261 * config.gcc (riscv*-*-linux*): Define
5262 TARGET_DEFAULT_ASYNC_UNWIND_TABLES.
5264 2023-01-30 YunQiang Su <yunqiang.su@cipunited.com>
5266 * Makefile.in (CROSS_SYSTEM_HEADER_DIR): set according the
5267 value of includedir.
5269 2023-01-30 Richard Biener <rguenther@suse.de>
5272 * cgraph.cc (possibly_call_in_translation_unit_p): Relax
5275 2023-01-30 liuhongt <hongtao.liu@intel.com>
5277 * config/i386/i386.opt: Change AVX512FP16 to AVX512-FP16.
5278 * doc/invoke.texi: Ditto.
5280 2023-01-29 Jan Hubicka <hubicka@ucw.cz>
5282 * ipa-utils.cc: Include calls.h, cfgloop.h and cfganal.h
5283 (stmt_may_terminate_function_p): If assuming return or EH
5284 volatile asm is safe.
5285 (find_always_executed_bbs): Fix handling of terminating BBS and
5286 infinite loops; add debug output.
5287 * tree-ssa-alias.cc (stmt_kills_ref_p): Fix debug output
5289 2023-01-28 Philipp Tomsich <philipp.tomsich@vrull.eu>
5291 * config/aarch64/aarch64.cc (aarch64_uxt_size): fix an
5292 off-by-one in checking the permissible shift-amount.
5294 2023-01-28 Gerald Pfeifer <gerald@pfeifer.com>
5296 * doc/extend.texi (Named Address Spaces): Update link to the
5299 2023-01-28 Gerald Pfeifer <gerald@pfeifer.com>
5301 * doc/standards.texi (Standards): Fix markup.
5303 2023-01-28 Gerald Pfeifer <gerald@pfeifer.com>
5305 * doc/standards.texi (Standards): Update link to Objective-C book.
5307 2023-01-28 Gerald Pfeifer <gerald@pfeifer.com>
5309 * doc/invoke.texi (Instrumentation Options): Update reference to
5312 2023-01-28 Gerald Pfeifer <gerald@pfeifer.com>
5314 * doc/standards.texi: Update Go1 link.
5316 2023-01-28 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5318 * config/riscv/predicates.md (pmode_reg_or_0_operand): New predicate.
5319 * config/riscv/riscv-vector-builtins-bases.cc (class loadstore):
5322 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
5323 * config/riscv/riscv-vector-builtins-functions.def (vlse): New class.
5325 * config/riscv/riscv-vector-builtins.cc
5326 (function_expander::use_contiguous_load_insn): Support vlse/vsse.
5327 * config/riscv/vector.md (@pred_strided_load<mode>): New md pattern.
5328 (@pred_strided_store<mode>): Ditto.
5330 2023-01-28 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5332 * config/riscv/vector.md (tail_policy_op_idx): Remove.
5333 (mask_policy_op_idx): Remove.
5334 (avl_type_op_idx): Remove.
5336 2023-01-27 Richard Sandiford <richard.sandiford@arm.com>
5338 PR tree-optimization/96373
5339 * tree.h (sign_mask_for): Declare.
5340 * tree.cc (sign_mask_for): New function.
5341 (signed_or_unsigned_type_for): For vector types, try to use the
5342 related_int_vector_mode.
5343 * genmatch.cc (commutative_op): Handle conditional internal functions.
5344 * match.pd: Fold an IFN_COND_MUL+copysign into an IFN_COND_XOR+and.
5346 2023-01-27 Richard Sandiford <richard.sandiford@arm.com>
5348 * tree-vectorizer.cc (vector_costs::compare_inside_loop_cost):
5349 Use the likely minimum VF when bounding the denominators to
5350 the estimated number of iterations.
5352 2023-01-27 Richard Biener <rguenther@suse.de>
5355 * doc/invoke.texi (-shared): Clarify effect on -ffast-math
5356 and -Ofast FP environment side-effects.
5358 2023-01-27 Richard Biener <rguenther@suse.de>
5361 * config/mips/gnu-user.h (GNU_USER_TARGET_MATHFILE_SPEC):
5362 Don't add crtfastmath.o for -shared.
5364 2023-01-27 Richard Biener <rguenther@suse.de>
5367 * config/ia64/linux.h (ENDFILE_SPEC): Don't add crtfastmath.o
5370 2023-01-27 Richard Biener <rguenther@suse.de>
5373 * config/alpha/linux.h (ENDFILE_SPEC): Don't add
5374 crtfastmath.o for -shared.
5376 2023-01-27 Andrew MacLeod <amacleod@redhat.com>
5378 PR tree-optimization/108306
5379 * range-op.cc (operator_lshift::fold_range): Return [0, 0] not
5380 varying for shifts that are always out of void range.
5381 (operator_rshift::fold_range): Return [0, 0] not
5382 varying for shifts that are always out of void range.
5384 2023-01-27 Andrew MacLeod <amacleod@redhat.com>
5386 PR tree-optimization/108447
5387 * gimple-range-fold.cc (old_using_range::relation_fold_and_or):
5388 Do not attempt to fold HONOR_NAN types.
5390 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5392 * config/riscv/riscv-vector-builtins-shapes.cc (struct loadstore_def):
5393 Remove _m suffix for "vop_m" C++ overloaded API name.
5395 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5397 * config/riscv/riscv-vector-builtins-bases.cc (BASE): Add vlm/vsm support.
5398 * config/riscv/riscv-vector-builtins-bases.h: Ditto.
5399 * config/riscv/riscv-vector-builtins-functions.def (vlm): New define.
5401 * config/riscv/riscv-vector-builtins-shapes.cc (struct loadstore_def): Add vlm/vsm support.
5402 * config/riscv/riscv-vector-builtins-types.def (DEF_RVV_B_OPS): Ditto.
5410 * config/riscv/riscv-vector-builtins.cc (DEF_RVV_B_OPS): Ditto.
5411 (rvv_arg_type_info::get_tree_type): Ditto.
5412 (function_expander::use_contiguous_load_insn): Ditto.
5413 * config/riscv/vector.md (@pred_store<mode>): Ditto.
5415 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5417 * config/riscv/riscv-vsetvl.cc (vsetvl_insn_p): Add condition to avoid ICE.
5418 (vsetvl_discard_result_insn_p): New function.
5419 (reg_killed_by_bb_p): rename to find_reg_killed_by.
5420 (find_reg_killed_by): New name.
5421 (get_vl): allow it to be called by more functions.
5422 (has_vsetvl_killed_avl_p): Add condition.
5423 (get_avl): allow it to be called by more functions.
5424 (insn_should_be_added_p): New function.
5425 (get_all_nonphi_defs): Refine function.
5426 (get_all_sets): Ditto.
5427 (get_same_bb_set): New function.
5428 (any_insn_in_bb_p): Ditto.
5429 (any_set_in_bb_p): Ditto.
5430 (get_vl_vtype_info): Add VLMAX forward optimization.
5431 (source_equal_p): Fix issues.
5432 (extract_single_source): Refine.
5433 (avl_info::multiple_source_equal_p): New function.
5434 (avl_info::operator==): Adjust for final version.
5435 (vl_vtype_info::operator==): Ditto.
5436 (vl_vtype_info::same_avl_p): Ditto.
5437 (vector_insn_info::parse_insn): Ditto.
5438 (vector_insn_info::available_p): New function.
5439 (vector_insn_info::merge): Adjust for final version.
5440 (vector_insn_info::dump): Add hard_empty.
5441 (pass_vsetvl::hard_empty_block_p): New function.
5442 (pass_vsetvl::backward_demand_fusion): Adjust for final version.
5443 (pass_vsetvl::forward_demand_fusion): Ditto.
5444 (pass_vsetvl::demand_fusion): Ditto.
5445 (pass_vsetvl::cleanup_illegal_dirty_blocks): New function.
5446 (pass_vsetvl::compute_local_properties): Adjust for final version.
5447 (pass_vsetvl::can_refine_vsetvl_p): Ditto.
5448 (pass_vsetvl::refine_vsetvls): Ditto.
5449 (pass_vsetvl::commit_vsetvls): Ditto.
5450 (pass_vsetvl::propagate_avl): New function.
5451 (pass_vsetvl::lazy_vsetvl): Adjust for new version.
5452 * config/riscv/riscv-vsetvl.h (enum def_type): New enum.
5454 2023-01-27 Jakub Jelinek <jakub@redhat.com>
5457 * doc/extend.texi: Fix up return type of __builtin_va_arg_pack_len
5460 2023-01-27 Jakub Jelinek <jakub@redhat.com>
5463 * cgraph.cc (cgraph_edge::verify_corresponds_to_fndecl): Allow
5464 redirection of calls to __builtin_trap in addition to redirection
5465 to __builtin_unreachable.
5467 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5469 * config/riscv/riscv-vsetvl.cc (before_p): Fix bug.
5471 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5473 * config/riscv/riscv-vsetvl.cc (gen_vsetvl_pat): Refine function args.
5474 (emit_vsetvl_insn): Ditto.
5476 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5478 * config/riscv/vector.md: Fix constraints.
5480 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5482 * config/riscv/vector-iterators.md: Add TARGET_MIN_VLEN > 32 predicates.
5484 2023-01-27 Patrick Palka <ppalka@redhat.com>
5485 Jakub Jelinek <jakub@redhat.com>
5487 * tree-core.h (tree_code_type, tree_code_length): For
5488 C++17 and later, add inline keyword, otherwise don't define
5489 the arrays, but declare extern arrays.
5490 * tree.cc (tree_code_type, tree_code_length): Define these
5491 arrays for C++14 and older.
5493 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5495 * config/riscv/riscv-vsetvl.h: Change it into public.
5497 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5499 * config/riscv/riscv-passes.def (INSERT_PASS_BEFORE): Reorder VSETVL
5502 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5504 * config/riscv/riscv-vsetvl.cc (pass_vsetvl::execute): Always call split_all_insns.
5506 2023-01-27 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5508 * config/riscv/vector.md: Fix incorrect attributes.
5510 2023-01-27 Richard Biener <rguenther@suse.de>
5513 * config/loongarch/gnu-user.h (GNU_USER_TARGET_MATHFILE_SPEC):
5514 Don't add crtfastmath.o for -shared.
5516 2023-01-27 Alexandre Oliva <oliva@gnu.org>
5518 * doc/options.texi (option, RejectNegative): Mention that
5519 -g-started options are also implicitly negatable.
5521 2023-01-26 Kito Cheng <kito.cheng@sifive.com>
5523 * config/riscv/riscv-vector-builtins.cc (register_builtin_types):
5524 Use get_typenode_from_name to get fixed-width integer type
5526 * config/riscv/riscv-vector-builtins.def: Update define with
5527 fixed-width integer type nodes.
5529 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5531 * config/riscv/riscv-vsetvl.cc (same_bb_and_before_p): Remove it.
5532 (real_insn_and_same_bb_p): New function.
5533 (same_bb_and_after_or_equal_p): Remove it.
5534 (before_p): New function.
5535 (reg_killed_by_bb_p): Ditto.
5536 (has_vsetvl_killed_avl_p): Ditto.
5537 (get_vl): Move location so that we can call it.
5538 (anticipatable_occurrence_p): Fix issue of AVL=REG support.
5539 (available_occurrence_p): Ditto.
5540 (dominate_probability_p): Remove it.
5541 (can_backward_propagate_p): Remove it.
5542 (get_all_nonphi_defs): New function.
5543 (get_all_predecessors): Ditto.
5544 (any_insn_in_bb_p): Ditto.
5545 (insert_vsetvl): Adjust AVL REG.
5546 (source_equal_p): New function.
5547 (extract_single_source): Ditto.
5548 (avl_info::single_source_equal_p): Ditto.
5549 (avl_info::operator==): Adjust for AVL=REG.
5550 (vl_vtype_info::same_avl_p): Ditto.
5551 (vector_insn_info::set_demand_info): Remove it.
5552 (vector_insn_info::compatible_p): Adjust for AVL=REG.
5553 (vector_insn_info::compatible_avl_p): New function.
5554 (vector_insn_info::merge): Adjust AVL=REG.
5555 (vector_insn_info::dump): Ditto.
5556 (pass_vsetvl::merge_successors): Remove it.
5557 (enum fusion_type): New enum.
5558 (pass_vsetvl::get_backward_fusion_type): New function.
5559 (pass_vsetvl::backward_demand_fusion): Adjust for AVL=REG.
5560 (pass_vsetvl::forward_demand_fusion): Ditto.
5561 (pass_vsetvl::demand_fusion): Ditto.
5562 (pass_vsetvl::prune_expressions): Ditto.
5563 (pass_vsetvl::compute_local_properties): Ditto.
5564 (pass_vsetvl::cleanup_vsetvls): Ditto.
5565 (pass_vsetvl::commit_vsetvls): Ditto.
5566 (pass_vsetvl::init): Ditto.
5567 * config/riscv/riscv-vsetvl.h (enum fusion_type): New enum.
5568 (enum merge_type): New enum.
5570 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5572 * config/riscv/riscv-vsetvl.cc
5573 (vector_infos_manager::vector_infos_manager): Add probability.
5574 (vector_infos_manager::dump): Ditto.
5575 (pass_vsetvl::compute_probabilities): Ditto.
5576 * config/riscv/riscv-vsetvl.h (struct vector_block_info): Ditto.
5578 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5580 * config/riscv/riscv-vsetvl.cc (vector_insn_info::operator==): Remove dirty_pat.
5581 (vector_insn_info::merge): Ditto.
5582 (vector_insn_info::dump): Ditto.
5583 (pass_vsetvl::merge_successors): Ditto.
5584 (pass_vsetvl::backward_demand_fusion): Ditto.
5585 (pass_vsetvl::forward_demand_fusion): Ditto.
5586 (pass_vsetvl::commit_vsetvls): Ditto.
5587 * config/riscv/riscv-vsetvl.h: Ditto.
5589 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5591 * config/riscv/riscv-vsetvl.cc (add_label_notes): Rename insn to
5594 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5596 * config/riscv/riscv-vsetvl.cc (pass_vsetvl::backward_demand_fusion): Refine codes.
5598 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5600 * config/riscv/riscv-vsetvl.cc (pass_vsetvl::forward_demand_fusion):
5601 Add pre-check for redundant flow.
5603 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5605 * config/riscv/riscv-vsetvl.cc (vector_infos_manager::create_bitmap_vectors): New function.
5606 (vector_infos_manager::free_bitmap_vectors): Ditto.
5607 (pass_vsetvl::pre_vsetvl): Adjust codes.
5608 * config/riscv/riscv-vsetvl.h: New function declaration.
5610 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5612 * config/riscv/riscv-vsetvl.cc (can_backward_propagate_p): Fix for null iter_bb.
5613 (vector_insn_info::set_demand_info): New function.
5614 (pass_vsetvl::emit_local_forward_vsetvls): Adjust for refinement of Phase 3.
5615 (pass_vsetvl::merge_successors): Ditto.
5616 (pass_vsetvl::compute_global_backward_infos): Ditto.
5617 (pass_vsetvl::backward_demand_fusion): Ditto.
5618 (pass_vsetvl::forward_demand_fusion): Ditto.
5619 (pass_vsetvl::demand_fusion): New function.
5620 (pass_vsetvl::lazy_vsetvl): Adjust for refinement of phase 3.
5621 * config/riscv/riscv-vsetvl.h: New function declaration.
5623 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5625 * config/riscv/riscv-vsetvl.cc (vector_insn_info::operator>=): Fix available condition.
5627 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5629 * config/riscv/riscv-vsetvl.cc (change_vsetvl_insn): New function.
5630 (pass_vsetvl::compute_global_backward_infos): Simplify codes.
5632 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5634 * config/riscv/riscv-vsetvl.cc (loop_basic_block_p): Adjust function.
5635 (backward_propagate_worthwhile_p): Fix non-worthwhile.
5637 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5639 * config/riscv/riscv-vsetvl.cc (change_insn): Adjust in_group in validate_change.
5641 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5643 * config/riscv/riscv-vsetvl.cc (vector_infos_manager::all_same_avl_p): New function.
5644 (pass_vsetvl::can_refine_vsetvl_p): Add AVL check.
5645 (pass_vsetvl::commit_vsetvls): Ditto.
5646 * config/riscv/riscv-vsetvl.h: New function declaration.
5648 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5650 * config/riscv/vector.md:
5652 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5654 * config/riscv/riscv-vector-builtins-bases.cc (class loadstore): use
5656 * config/riscv/riscv-vector-builtins.cc
5657 (function_expander::add_mem_operand): Refine function.
5658 (function_expander::use_contiguous_load_insn): Adjust new
5660 (function_expander::use_contiguous_store_insn): Ditto.
5661 * config/riscv/riscv-vector-builtins.h: Refine function.
5662 * config/riscv/vector.md (@pred_store<mode>): New pattern.
5664 2023-01-26 Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
5666 * config/riscv/riscv-vector-builtins.cc: Change to scalar pointer.
5668 2023-01-26 Marek Polacek <polacek@redhat.com>
5670 PR middle-end/108543
5671 * opts.cc (parse_sanitizer_options): Don't always clear SANITIZE_ADDRESS
5672 if it was previously set.
5674 2023-01-26 Jakub Jelinek <jakub@redhat.com>
5676 PR tree-optimization/108540
5677 * range-op-float.cc (foperator_equal::fold_range): If both op1 and op2
5678 are singletons, use range_true even if op1 != op2
5679 when one range is [-0.0, -0.0] and another [0.0, 0.0]. Similarly,
5680 even if intersection of the ranges is empty and one has
5681 zero low bound and another zero high bound, use range_true_and_false
5682 rather than range_false.
5683 (foperator_not_equal::fold_range): If both op1 and op2
5684 are singletons, use range_false even if op1 != op2
5685 when one range is [-0.0, -0.0] and another [0.0, 0.0]. Similarly,
5686 even if intersection of the ranges is empty and one has
5687 zero low bound and another zero high bound, use range_true_and_false
5688 rather than range_true.
5690 2023-01-26 Jakub Jelinek <jakub@redhat.com>
5692 * value-relation.cc (kind_string): Add const.
5693 (rr_negate_table, rr_swap_table, rr_intersect_table,
5694 rr_union_table, rr_transitive_table): Add static const, change
5695 element type from relation_kind to unsigned char.
5696 (relation_negate, relation_swap, relation_intersect, relation_union,
5697 relation_transitive): Cast rr_*_table element to relation_kind.
5698 (relation_to_code): Add static const.
5699 (relation_tests): Assert VREL_LAST is smaller than UCHAR_MAX.
5701 2023-01-26 Richard Biener <rguenther@suse.de>
5703 PR tree-optimization/108547
5704 * gimple-predicate-analysis.cc (value_sat_pred_p):
5707 2023-01-26 Siddhesh Poyarekar <siddhesh@gotplt.org>
5709 PR tree-optimization/108522
5710 * tree-object-size.cc (compute_object_offset): Make EXPR
5711 argument non-const. Call component_ref_field_offset.
5713 2023-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5715 * config/aarch64/aarch64-option-extensions.def (cssc): Specify
5716 FEATURE_STRING field.
5718 2023-01-26 Gerald Pfeifer <gerald@pfeifer.com>
5720 * doc/sourcebuild.texi: Refer to projects as GCC and GDB.
5722 2023-01-25 Iain Sandoe <iain@sandoe.co.uk>
5726 * gcc.cc: Provide default specs for Modula-2 so that when the
5727 language is not built-in better diagnostics are emitted for
5728 attempts to use .mod or .m2i file extensions.
5730 2023-01-25 Andrea Corallo <andrea.corallo@arm.com>
5732 * config/arm/mve.md (mve_vqnegq_s<mode>): Fix spacing.
5734 2023-01-25 Andrea Corallo <andrea.corallo@arm.com>
5736 * config/arm/mve.md (mve_vqabsq_s<mode>): Fix spacing.
5738 2023-01-25 Andrea Corallo <andrea.corallo@arm.com>
5740 * config/arm/mve.md (mve_vnegq_f<mode>, mve_vnegq_s<mode>):
5743 2023-01-25 Andrea Corallo <andrea.corallo@arm.com>
5745 * config/arm/mve.md (@mve_vclzq_s<mode>): Fix spacing.
5747 2023-01-25 Andrea Corallo <andrea.corallo@arm.com>
5749 * config/arm/mve.md (mve_vclsq_s<mode>): Fix spacing.
5751 2023-01-25 Richard Biener <rguenther@suse.de>
5753 PR tree-optimization/108523
5754 * tree-ssa-sccvn.cc (visit_phi): Avoid using the exclusive
5755 backedge value for the result when using predication to
5758 2023-01-25 Richard Biener <rguenther@suse.de>
5760 * doc/lto.texi (Command line options): Reword and update reference
5761 to removed lto_read_all_file_options.
5763 2023-01-25 Richard Sandiford <richard.sandiford@arm.com>
5765 * config/aarch64/aarch64.md (umax<mode>3): Separate the CNT and CSSC
5768 2023-01-25 Gerald Pfeifer <gerald@pfeifer.com>
5770 * doc/contrib.texi: Add Jose E. Marchesi.
5772 2023-01-25 Jakub Jelinek <jakub@redhat.com>
5774 PR tree-optimization/108498
5775 * gimple-ssa-store-merging.cc (class store_operand_info):
5776 End coment with full stop rather than comma.
5777 (split_group): Likewise.
5778 (merged_store_group::apply_stores): Clear string_concatenation if
5779 start or end aren't on a byte boundary.
5781 2023-01-25 Siddhesh Poyarekar <siddhesh@gotplt.org>
5782 Jakub Jelinek <jakub@redhat.com>
5784 PR tree-optimization/108522
5785 * tree-object-size.cc (compute_object_offset): Use
5786 TREE_OPERAND(ref, 2) for COMPONENT_REF when available.
5788 2023-01-24 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
5790 * config/xtensa/xtensa.md:
5791 Fix exit from loops detecting references before overwriting in the
5794 2023-01-24 Vladimir N. Makarov <vmakarov@redhat.com>
5796 * lra-constraints.cc (get_hard_regno): Remove final_p arg. Always
5797 do elimination but only for hard register.
5798 (operands_match_p, uses_hard_regs_p, process_alt_operands): Adjust
5799 calls of get_hard_regno.
5801 2023-01-24 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
5803 * config/s390/s390-d.cc (s390_d_target_versions): Fix detection
5806 2023-01-24 Andre Vieira <andre.simoesdiasvieira@arm.com>
5809 * config/arm/mve.md (mve_vstrbq_p_<supf><mode>, mve_vstrhq_p_fv8hf,
5810 mve_vstrhq_p_<supf><mode>, mve_vstrwq_p_<supf>v4si): Add memory operand
5813 2023-01-24 Xianmiao Qu <cooper.qu@linux.alibaba.com>
5815 * config.gcc(csky-*-linux*): Define CSKY_ENABLE_MULTILIB
5816 and only include 'csky/t-csky-linux' when enable multilib.
5817 * config/csky/csky-linux-elf.h(SYSROOT_SUFFIX_SPEC): Don't
5818 define it when disable multilib.
5820 2023-01-24 Richard Biener <rguenther@suse.de>
5822 PR tree-optimization/108500
5823 * dominance.h (calculate_dominance_info): Add parameter
5824 to indicate fast-query compute, defaulted to true.
5825 * dominance.cc (calculate_dominance_info): Honor
5826 fast-query compute parameter.
5827 * tree-cfgcleanup.cc (cleanup_tree_cfg_noloop): Do
5828 not compute the dominator fast-query DFS numbers.
5830 2023-01-24 Eric Biggers <ebiggers@google.com>
5833 * optc-save-gen.awk: Fix copy-and-paste error.
5835 2023-01-24 Jakub Jelinek <jakub@redhat.com>
5838 * cgraphbuild.cc: Include gimplify.h.
5839 (record_reference): Replace VAR_DECLs with DECL_HAS_VALUE_EXPR_P with
5840 their corresponding DECL_VALUE_EXPR expressions after unsharing.
5842 2023-01-24 Srinath Parvathaneni <srinath.parvathaneni@arm.com>
5845 * config.gcc (tm_file): Move the variable out of loop.
5847 2023-01-24 Lulu Cheng <chenglulu@loongson.cn>
5848 Yang Yujie <yangyujie@loongson.cn>
5851 * config/loongarch/loongarch.cc (loongarch_classify_address):
5852 Add precessint for CONST_INT.
5853 (loongarch_print_operand_reloc): Operand modifier 'c' is supported.
5854 (loongarch_print_operand): Increase the processing of '%c'.
5855 * doc/extend.texi: Adds documents for LoongArch operand modifiers.
5856 And port the public operand modifiers information to this document.
5858 2023-01-23 Srinath Parvathaneni <srinath.parvathaneni@arm.com>
5860 * doc/invoke.texi (-mbranch-protection): Update documentation.
5862 2023-01-23 Richard Biener <rguenther@suse.de>
5865 * config/sparc/freebsd.h (ENDFILE_SPEC): Don't add crtfastmath.o
5867 * config/sparc/linux.h (ENDFILE_SPEC): Likewise.
5868 * config/sparc/linux64.h (ENDFILE_SPEC): Likewise.
5869 * config/sparc/sp-elf.h (ENDFILE_SPEC): Likewise.
5870 * config/sparc/sp64-elf.h (ENDFILE_SPEC): Likewise.
5872 2023-01-23 Srinath Parvathaneni <srinath.parvathaneni@arm.com>
5874 * config/arm/aout.h (ra_auth_code): Add entry in enum.
5875 * config/arm/arm.cc (emit_multi_reg_push): Add RA_AUTH_CODE register
5876 to dwarf frame expression.
5877 (arm_emit_multi_reg_pop): Restore RA_AUTH_CODE register.
5878 (arm_expand_prologue): Update frame related information and reg notes
5879 for pac/pacbit insn.
5880 (arm_regno_class): Check for pac pseudo reigster.
5881 (arm_dbx_register_number): Assign ra_auth_code register number in dwarf.
5882 (arm_init_machine_status): Set pacspval_needed to zero.
5883 (arm_debugger_regno): Check for PAC register.
5884 (arm_unwind_emit_sequence): Print .save directive with ra_auth_code
5886 (arm_unwind_emit_set): Add entry for IP_REGNUM in switch case.
5887 (arm_unwind_emit): Update REG_CFA_REGISTER case._
5888 * config/arm/arm.h (FIRST_PSEUDO_REGISTER): Modify.
5889 (DWARF_PAC_REGNUM): Define.
5890 (IS_PAC_REGNUM): Likewise.
5891 (enum reg_class): Add PAC_REG entry.
5892 (machine_function): Add pacbti_needed state to structure.
5893 * config/arm/arm.md (RA_AUTH_CODE): Define.
5895 2023-01-23 Srinath Parvathaneni <srinath.parvathaneni@arm.com>
5897 * config.gcc ($tm_file): Update variable.
5898 * config/arm/arm-mlib.h: Create new header file.
5899 * config/arm/t-rmprofile (MULTI_ARCH_DIRS_RM): Rename mbranch-protection
5900 multilib arch directory.
5901 (MULTILIB_REUSE): Add multilib reuse rules.
5902 (MULTILIB_MATCHES): Add multilib match rules.
5904 2023-01-23 Srinath Parvathaneni <srinath.parvathaneni@arm.com>
5906 * config/arm/arm-cpus.in (cortex-m85): Define new CPU.
5907 * config/arm/arm-tables.opt: Regenerate.
5908 * config/arm/arm-tune.md: Likewise.
5909 * doc/invoke.texi (Arm Options): Document -mcpu=cortex-m85.
5910 * (-mfix-cmse-cve-2021-35465): Likewise.
5912 2023-01-23 Richard Biener <rguenther@suse.de>
5914 PR tree-optimization/108482
5915 * tree-vect-generic.cc (expand_vector_operations): Fold remaining
5916 .LOOP_DIST_ALIAS calls.
5918 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
5920 * config.gcc (arm*-*-*): Add 'aarch-bti-insert.o' object.
5921 * config/arm/arm-protos.h: Update.
5922 * config/arm/aarch-common-protos.h: Declare
5923 'aarch_bti_arch_check'.
5924 * config/arm/arm.cc (aarch_bti_enabled) Update.
5925 (aarch_bti_j_insn_p, aarch_pac_insn_p, aarch_gen_bti_c)
5926 (aarch_gen_bti_j, aarch_bti_arch_check): New functions.
5927 * config/arm/arm.md (bti_nop): New insn.
5928 * config/arm/t-arm (PASSES_EXTRA): Add 'arm-passes.def'.
5929 (aarch-bti-insert.o): New target.
5930 * config/arm/unspecs.md (VUNSPEC_BTI_NOP): New unspec.
5931 * config/arm/aarch-bti-insert.cc (rest_of_insert_bti): Verify arch
5933 (gate): Make use of 'aarch_bti_arch_check'.
5934 * config/arm/arm-passes.def: New file.
5935 * config/aarch64/aarch64.cc (aarch_bti_arch_check): New function.
5937 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
5939 * config.gcc (aarch64*-*-*): Rename 'aarch64-bti-insert.o' into
5940 'aarch-bti-insert.o'.
5941 * config/aarch64/aarch64-protos.h: Remove 'aarch64_bti_enabled'
5943 * config/aarch64/aarch64.cc (aarch_bti_enabled): Rename.
5944 (aarch_bti_j_insn_p, aarch_pac_insn_p): New functions.
5945 (aarch64_output_mi_thunk)
5946 (aarch64_print_patchable_function_entry)
5947 (aarch64_file_end_indicate_exec_stack): Update renamed function
5948 calls to renamed functions.
5949 * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins): Likewise.
5950 * config/aarch64/t-aarch64 (aarch-bti-insert.o): Update
5952 * config/aarch64/aarch64-bti-insert.cc: Delete.
5953 * config/arm/aarch-bti-insert.cc: New file including and
5954 generalizing code from aarch64-bti-insert.cc.
5955 * config/arm/aarch-common-protos.h: Update.
5957 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
5959 * config/arm/arm.h (arm_arch8m_main): Declare it.
5960 * config/arm/arm-protos.h (arm_current_function_pac_enabled_p):
5962 * config/arm/arm.cc (arm_arch8m_main): Define it.
5963 (arm_option_reconfigure_globals): Set arm_arch8m_main.
5964 (arm_compute_frame_layout, arm_expand_prologue)
5965 (thumb2_expand_return, arm_expand_epilogue)
5966 (arm_conditional_register_usage): Update for pac codegen.
5967 (arm_current_function_pac_enabled_p): New function.
5968 (aarch_bti_enabled) New function.
5969 (use_return_insn): Return zero when pac is enabled.
5970 * config/arm/arm.md (pac_ip_lr_sp, pacbti_ip_lr_sp, aut_ip_lr_sp):
5972 * config/arm/unspecs.md (UNSPEC_PAC_NOP)
5973 (VUNSPEC_PACBTI_NOP, VUNSPEC_AUT_NOP): Add unspecs.
5975 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
5977 * config/arm/t-rmprofile: Add multilib rules for march +pacbti and
5980 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
5981 Tejas Belagod <tbelagod@arm.com>
5983 * config/arm/arm.cc (arm_file_start): Emit EABI attributes for
5984 Tag_PAC_extension, Tag_BTI_extension, TAG_BTI_use, TAG_PACRET_use.
5986 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
5987 Tejas Belagod <tbelagod@arm.com>
5988 Srinath Parvathaneni <srinath.parvathaneni@arm.com>
5990 * ginclude/unwind-arm-common.h (_Unwind_VRS_RegClass): Introduce
5991 new pseudo register class _UVRSC_PAC.
5993 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
5994 Tejas Belagod <tbelagod@arm.com>
5996 * config/arm/arm-c.cc (arm_cpu_builtins): Define
5997 __ARM_FEATURE_BTI_DEFAULT, __ARM_FEATURE_PAC_DEFAULT,
5998 __ARM_FEATURE_PAUTH and __ARM_FEATURE_BTI.
6000 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
6001 Tejas Belagod <tbelagod@arm.com>
6003 * doc/sourcebuild.texi: Document arm_pacbti_hw.
6005 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
6006 Tejas Belagod <tbelagod@arm.com>
6007 Richard Earnshaw <Richard.Earnshaw@arm.com>
6009 * config/arm/arm.cc (arm_configure_build_target): Parse and validate
6010 -mbranch-protection option and initialize appropriate data structures.
6011 * config/arm/arm.opt (-mbranch-protection): New option.
6012 * doc/invoke.texi (Arm Options): Document it.
6014 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
6015 Tejas Belagod <tbelagod@arm.com>
6017 * config/arm/arm.h (TARGET_HAVE_PACBTI): New macro.
6018 * config/arm/arm-cpus.in (pacbti): New feature.
6019 * doc/invoke.texi (Arm Options): Document it.
6021 2023-01-23 Andrea Corallo <andrea.corallo@arm.com>
6022 Tejas Belagod <tbelagod@arm.com>
6024 * common/config/aarch64/aarch64-common.cc: Include aarch-common.h.
6025 (all_architectures): Fix comment.
6026 (aarch64_parse_extension): Rename return type, enum value names.
6027 * config/aarch64/aarch64-c.cc (aarch64_update_cpp_builtins): Rename
6028 factored out aarch_ra_sign_scope and aarch_ra_sign_key variables.
6029 Also rename corresponding enum values.
6030 * config/aarch64/aarch64-opts.h (aarch64_function_type): Factor
6031 out aarch64_function_type and move it to common code as
6032 aarch_function_type in aarch-common.h.
6033 * config/aarch64/aarch64-protos.h: Include common types header,
6034 move out types aarch64_parse_opt_result and aarch64_key_type to
6036 * config/aarch64/aarch64.cc: Move mbranch-protection parsing types
6037 and functions out into aarch-common.h and aarch-common.cc. Fix up
6038 all the name changes resulting from the move.
6039 * config/aarch64/aarch64.md: Fix up aarch64_ra_sign_key type name change
6041 * config/aarch64/aarch64.opt: Include aarch-common.h to import
6042 type move. Fix up name changes from factoring out common code and
6044 * config/arm/aarch-common-protos.h: Export factored out routines to both
6046 * config/arm/aarch-common.cc: Include newly factored out types.
6047 Move all mbranch-protection code and data structures from
6049 * config/arm/aarch-common.h: New header that declares types shared
6050 between aarch32 and aarch64 backends.
6051 * config/arm/arm-protos.h: Declare types and variables that are
6052 made common to aarch64 and aarch32 backends - aarch_ra_sign_key,
6053 aarch_ra_sign_scope and aarch_enable_bti.
6054 * config/arm/arm.opt (config/arm/aarch-common.h): Include header.
6055 (aarch_ra_sign_scope, aarch_enable_bti): Declare variable.
6056 * config/arm/arm.cc: Add missing includes.
6058 2023-01-23 Tobias Burnus <tobias@codesourcery.com>
6060 * doc/install.texi (amdgcn, nvptx): Require newlib 4.3.0.
6062 2023-01-23 Richard Biener <rguenther@suse.de>
6064 PR tree-optimization/108449
6065 * cgraphunit.cc (check_global_declaration): Do not turn
6066 undefined statics into externs.
6068 2023-01-22 Dimitar Dimitrov <dimitar@dinux.eu>
6070 * config/pru/pru.h (CLZ_DEFINED_VALUE_AT_ZERO): Fix value for QI
6072 * config/pru/pru.md (clz): Fix generated code for QI and HI
6075 2023-01-22 Cupertino Miranda <cupertino.miranda@oracle.com>
6077 * config/v850/v850.cc (v850_select_section): Put const volatile
6078 objects into read-only sections.
6080 2023-01-20 Tejas Belagod <tejas.belagod@arm.com>
6082 * config/aarch64/arm_neon.h (vmull_p64, vmull_high_p64, vaeseq_u8,
6083 vaesdq_u8, vaesmcq_u8, vaesimcq_u8): Gate under "nothing+aes".
6084 (vsha1*_u32, vsha256*_u32): Gate under "nothing+sha2".
6086 2023-01-20 Jakub Jelinek <jakub@redhat.com>
6088 PR tree-optimization/108457
6089 * tree-ssa-loop-niter.cc (build_cltz_expr): Use
6090 SCALAR_INT_TYPE_MODE (utype) directly as C[LT]Z_DEFINED_VALUE_AT_ZERO
6091 argument instead of a temporary. Formatting fixes.
6093 2023-01-19 Jakub Jelinek <jakub@redhat.com>
6095 PR tree-optimization/108447
6096 * value-relation.cc (rr_union_table): Fix VREL_UNDEFINED row order.
6097 (relation_tests): Add self-tests for relation_{intersect,union}
6099 * selftest.h (relation_tests): Declare.
6100 * function-tests.cc (test_ranges): Call it.
6102 2023-01-19 H.J. Lu <hjl.tools@gmail.com>
6105 * config/i386/i386-expand.cc (ix86_expand_builtin): Check
6106 invalid third argument to __builtin_ia32_prefetch.
6108 2023-01-19 Jakub Jelinek <jakub@redhat.com>
6110 PR middle-end/108459
6111 * omp-expand.cc (expand_omp_for_init_counts): Use fold_build1 rather
6112 than fold_unary for NEGATE_EXPR.
6114 2023-01-19 Christophe Lyon <christophe.lyon@arm.com>
6117 * config/aarch64/aarch64.cc (aarch64_layout_arg): Improve
6118 comment. Move assert about alignment a bit later.
6120 2023-01-19 Jakub Jelinek <jakub@redhat.com>
6122 PR tree-optimization/108440
6123 * tree-ssa-forwprop.cc: Include gimple-range.h.
6124 (simplify_rotate): For the forms with T2 wider than T and shift counts of
6125 Y and B - Y add & (B - 1) masking for the rotate count if Y could be equal
6126 to B. For the forms with T2 wider than T and shift counts of
6127 Y and (-Y) & (B - 1), don't punt if range could be [B, B2], but only if
6128 range doesn't guarantee Y < B or Y = N * B. If range doesn't guarantee
6129 Y < B, also add & (B - 1) masking for the rotate count. Use lazily created
6130 pass specific ranger instead of get_global_range_query.
6131 (pass_forwprop::execute): Disable that ranger at the end of pass if it has
6134 2023-01-19 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
6136 * config/aarch64/aarch64-simd.md (aarch64_simd_vec_set<mode>): Use
6137 exact_log2 (INTVAL (operands[2])) >= 0 as condition for gating
6139 (aarch64_simd_vec_copy_lane<mode>): Likewise.
6140 (aarch64_simd_vec_copy_lane_<vswap_width_name><mode>): Likewise.
6142 2023-01-19 Alexandre Oliva <oliva@adacore.com>
6145 * sched-deps.cc (sched_analyze_2): Skip cselib address lookup
6148 2023-01-18 Martin Jambor <mjambor@suse.cz>
6151 * cgraph.cc (cgraph_node::remove): Check whether nodes up the
6152 lcone_of chain also do not need the body.
6154 2023-01-18 Richard Biener <rguenther@suse.de>
6157 2022-12-16 Richard Biener <rguenther@suse.de>
6159 PR middle-end/108086
6160 * tree-inline.cc (remap_ssa_name): Do not unshare the
6161 result from the decl_map.
6163 2023-01-18 Murray Steele <murray.steele@arm.com>
6166 * config/arm/arm_mve.h (__arm_vst1q_p_u8): Use prefixed intrinsic
6168 (__arm_vst1q_p_s8): Likewise.
6169 (__arm_vld1q_z_u8): Likewise.
6170 (__arm_vld1q_z_s8): Likewise.
6171 (__arm_vst1q_p_u16): Likewise.
6172 (__arm_vst1q_p_s16): Likewise.
6173 (__arm_vld1q_z_u16): Likewise.
6174 (__arm_vld1q_z_s16): Likewise.
6175 (__arm_vst1q_p_u32): Likewise.
6176 (__arm_vst1q_p_s32): Likewise.
6177 (__arm_vld1q_z_u32): Likewise.
6178 (__arm_vld1q_z_s32): Likewise.
6179 (__arm_vld1q_z_f16): Likewise.
6180 (__arm_vst1q_p_f16): Likewise.
6181 (__arm_vld1q_z_f32): Likewise.
6182 (__arm_vst1q_p_f32): Likewise.
6184 2023-01-18 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
6186 * config/xtensa/xtensa.md (xorsi3_internal):
6187 Rename from the original of "xorsi3".
6188 (xorsi3): New expansion pattern that emits addition rather than
6189 bitwise-XOR when the second source is a constant of -2147483648
6192 2023-01-18 Kewen Lin <linkw@linux.ibm.com>
6193 Andrew Pinski <apinski@marvell.com>
6196 * config/rs6000/rs6000-overload.def (VEC_VSUBCUQ): Fix typo
6197 vec_vsubcuqP with vec_vsubcuq.
6199 2023-01-18 Kewen Lin <linkw@linux.ibm.com>
6202 * config/rs6000/rs6000.cc (rs6000_opaque_type_invalid_use_p): Add the
6203 support for invalid uses of MMA opaque type in function arguments.
6205 2023-01-18 liuhongt <hongtao.liu@intel.com>
6208 * config/i386/cygwin.h (ENDFILE_SPEC): Link crtfastmath.o
6209 whenever -mdaz-ftz is specified. Don't link crtfastmath.o when
6210 -share or -mno-daz-ftz is specified.
6211 * config/i386/darwin.h (ENDFILE_SPEC): Ditto.
6212 * config/i386/mingw32.h (ENDFILE_SPEC): Ditto.
6214 2023-01-17 Jose E. Marchesi <jose.marchesi@oracle.com>
6216 * config/bpf/bpf.cc (bpf_option_override): Disable
6219 2023-01-17 Jakub Jelinek <jakub@redhat.com>
6221 PR tree-optimization/106523
6222 * tree-ssa-forwprop.cc (simplify_rotate): For the
6223 patterns with (-Y) & (B - 1) in one operand's shift
6224 count and Y in another, if T2 has wider precision than T,
6225 punt if Y could have a value in [B, B2 - 1] range.
6227 2023-01-16 H.J. Lu <hjl.tools@gmail.com>
6230 * config/i386/i386.cc (x86_output_mi_thunk): Disable
6231 -mforce-indirect-call for PIC in 32-bit mode.
6233 2023-01-16 Jan Hubicka <hubicka@ucw.cz>
6236 * ipa-modref.cc (modref_access_analysis::analyze): Use
6237 find_always_executed_bbs.
6238 * ipa-sra.cc (process_scan_results): Likewise.
6239 * ipa-utils.cc (stmt_may_terminate_function_p): New function.
6240 (find_always_executed_bbs): New function.
6241 * ipa-utils.h (stmt_may_terminate_function_p): Declare.
6242 (find_always_executed_bbs): Declare.
6244 2023-01-16 Jan Hubicka <jh@suse.cz>
6246 * config/i386/i386.cc (ix86_vectorize_builtin_scatter): Guard scatter
6247 by TARGET_USE_SCATTER.
6248 * config/i386/i386.h (TARGET_USE_SCATTER_2PARTS,
6249 TARGET_USE_SCATTER_4PARTS, TARGET_USE_SCATTER): New macros.
6250 * config/i386/x86-tune.def (TARGET_USE_SCATTER_2PARTS,
6251 TARGET_USE_SCATTER_4PARTS, TARGET_USE_SCATTER): New tunes.
6252 (X86_TUNE_AVOID_256FMA_CHAINS, X86_TUNE_AVOID_512FMA_CHAINS): Disable
6253 for znver4. (X86_TUNE_USE_GATHER): Disable for zen4.
6255 2023-01-16 Richard Biener <rguenther@suse.de>
6258 * config/sol2.h (ENDFILE_SPEC): Don't add crtfastmath.o for -shared.
6260 2023-01-16 Stam Markianos-Wright <stam.markianos-wright@arm.com>
6264 * config/arm/arm_mve.h (__ARM_mve_coerce2): Split types.
6265 (__ARM_mve_coerce3): Likewise.
6267 2023-01-16 Andrew Carlotti <andrew.carlotti@arm.com>
6269 * tree-ssa-loop-niter.cc (build_popcount_expr): Add IFN support.
6271 2023-01-16 Andrew Carlotti <andrew.carlotti@arm.com>
6273 * tree-ssa-loop-niter.cc (number_of_iterations_cltz): New.
6274 (number_of_iterations_bitcount): Add call to the above.
6275 (number_of_iterations_exit_assumptions): Add EQ_EXPR case for
6276 c[lt]z idiom recognition.
6278 2023-01-16 Andrew Carlotti <andrew.carlotti@arm.com>
6280 * doc/sourcebuild.texi: Add missing target attributes.
6282 2023-01-16 Andrew Carlotti <andrew.carlotti@arm.com>
6284 PR tree-optimization/94793
6285 * tree-scalar-evolution.cc (expression_expensive_p): Add checks
6287 * tree-ssa-loop-niter.cc (build_cltz_expr): New.
6288 (number_of_iterations_cltz_complement): New.
6289 (number_of_iterations_bitcount): Add call to the above.
6291 2023-01-16 Jonathan Wakely <jwakely@redhat.com>
6293 * doc/extend.texi (Common Function Attributes): Fix grammar.
6295 2023-01-16 Jakub Jelinek <jakub@redhat.com>
6298 * config/riscv/riscv-vsetvl.h: Add space in between Copyright and (C).
6299 * config/riscv/riscv-vsetvl.cc: Likewise.
6301 2023-01-16 Jakub Jelinek <jakub@redhat.com>
6304 * config/i386/xmmintrin.h (_mm_undefined_ps): Temporarily
6305 disable -Winit-self using pragma GCC diagnostic ignored.
6306 * config/i386/emmintrin.h (_mm_undefined_pd, _mm_undefined_si128):
6308 * config/i386/avxintrin.h (_mm256_undefined_pd, _mm256_undefined_ps,
6309 _mm256_undefined_si256): Likewise.
6310 * config/i386/avx512fintrin.h (_mm512_undefined_pd,
6311 _mm512_undefined_ps, _mm512_undefined_epi32): Likewise.
6312 * config/i386/avx512fp16intrin.h (_mm_undefined_ph,
6313 _mm256_undefined_ph, _mm512_undefined_ph): Likewise.
6315 2023-01-16 Kewen Lin <linkw@linux.ibm.com>
6318 * config/rs6000/rs6000.cc (rs6000_opaque_type_invalid_use_p): Add the
6319 support for invalid uses in inline asm, factor out the checking and
6320 erroring to lambda function check_and_error_invalid_use.
6322 2023-01-15 Aldy Hernandez <aldyh@redhat.com>
6324 PR tree-optimization/107608
6325 * range-op-float.cc (range_operator_float::fold_range): Avoid
6326 folding into INF when flag_trapping_math.
6327 * value-range.h (frange::known_isinf): Return false for possible NANs.
6329 2023-01-15 Xianmiao Qu <cooper.qu@linux.alibaba.com>
6331 * config.gcc (csky-*-*): Support --with-float=softfp.
6333 2023-01-14 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
6335 * config/xtensa/xtensa-protos.h (order_regs_for_local_alloc):
6336 Rename to xtensa_adjust_reg_alloc_order.
6337 * config/xtensa/xtensa.cc (xtensa_adjust_reg_alloc_order):
6338 Ditto. And also remove code to reorder register numbers for
6339 leaf functions, rename the tables, and adjust the allocation
6340 order for the call0 ABI to use register A0 more.
6341 (xtensa_leaf_regs): Remove.
6342 * config/xtensa/xtensa.h (REG_ALLOC_ORDER): Cosmetics.
6343 (order_regs_for_local_alloc): Rename as the above.
6344 (LEAF_REGISTERS, LEAF_REG_REMAP, leaf_function): Remove.
6346 2023-01-14 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
6348 * config/aarch64/aarch64-sve.md (aarch64_vec_duplicate_vq<mode>_le):
6349 Change to define_insn_and_split to fold ldr+dup to ld1rq.
6350 * config/aarch64/predicates.md (aarch64_sve_dup_ld1rq_operand): New.
6352 2023-01-14 Alexandre Oliva <oliva@adacore.com>
6354 * hash-table.h (is_deleted): Precheck !is_empty.
6355 (mark_deleted): Postcheck !is_empty.
6356 (copy constructor): Test is_empty before is_deleted.
6358 2023-01-14 Alexandre Oliva <oliva@adacore.com>
6361 * config/arm/arm.md (movmisaligndi): Prefer aligned SImode
6364 2023-01-13 Eric Botcazou <ebotcazou@adacore.com>
6366 PR rtl-optimization/108274
6367 * function.cc (thread_prologue_and_epilogue_insns): Also update the
6368 DF information for calls in a few more cases.
6370 2023-01-13 John David Anglin <danglin@gcc.gnu.org>
6372 * config/pa/pa-linux.h (TARGET_SYNC_LIBCALL): Delete define.
6373 * config/pa/pa.cc (pa_init_libfuncs): Use MAX_SYNC_LIBFUNC_SIZE
6375 * config/pa/pa.h (TARGET_SYNC_LIBCALLS): Use flag_sync_libcalls.
6376 (MAX_SYNC_LIBFUNC_SIZE): Define.
6377 (TARGET_CPU_CPP_BUILTINS): Define __SOFTFP__ when soft float is
6379 * config/pa/pa.md (atomic_storeqi): Emit __atomic_exchange_1
6380 libcall when sync libcalls are disabled.
6381 (atomic_storehi, atomic_storesi, atomic_storedi): Likewise.
6382 (atomic_loaddi): Emit __atomic_load_8 libcall when sync libcalls
6383 are disabled on 32-bit target.
6384 * config/pa/pa.opt (matomic-libcalls): New option.
6385 * doc/invoke.texi (HPPA Options): Update.
6387 2023-01-13 Alexander Monakov <amonakov@ispras.ru>
6389 PR rtl-optimization/108117
6390 PR rtl-optimization/108132
6391 * sched-deps.cc (deps_analyze_insn): Do not schedule across
6392 calls before reload.
6394 2023-01-13 Srinath Parvathaneni <srinath.parvathaneni@arm.com>
6396 * common/config/arm/arm-common.cc (arm_canon_arch_option_1): Ignore cde
6397 options for -mlibarch.
6398 * config/arm/arm-cpus.in (begin cpu cortex-m55): Add cde options.
6399 * doc/invoke.texi (CDE): Document options for Cortex-M55 CPU.
6401 2023-01-13 Qing Zhao <qing.zhao@oracle.com>
6403 * attribs.cc (strict_flex_array_level_of): Move this function to ...
6404 * attribs.h (strict_flex_array_level_of): Remove the declaration.
6405 * gimple-array-bounds.cc (array_bounds_checker::check_array_ref):
6406 replace the referece to strict_flex_array_level_of with
6408 * tree.cc (component_ref_size): Likewise.
6410 2023-01-13 Richard Biener <rguenther@suse.de>
6413 * config/arm/linux-eabi.h (ENDFILE_SPEC): Don't add
6414 crtfastmath.o for -shared.
6415 * config/arm/unknown-elf.h (STARTFILE_SPEC): Likewise.
6417 2023-01-13 Richard Biener <rguenther@suse.de>
6420 * config/aarch64/aarch64-elf-raw.h (ENDFILE_SPEC): Don't add
6421 crtfastmath.o for -shared.
6422 * config/aarch64/aarch64-freebsd.h (GNU_USER_TARGET_MATHFILE_SPEC):
6424 * config/aarch64/aarch64-linux.h (GNU_USER_TARGET_MATHFILE_SPEC):
6427 2023-01-13 Richard Sandiford <richard.sandiford@arm.com>
6429 * config/aarch64/aarch64.cc (aarch64_dwarf_frame_reg_mode): New
6431 (TARGET_DWARF_FRAME_REG_MODE): Define.
6433 2023-01-13 Richard Biener <rguenther@suse.de>
6436 * config/aarch64/aarch64.cc (aarch64_gimple_fold_builtin): Don't
6437 update EH info on the fly.
6439 2023-01-13 Richard Biener <rguenther@suse.de>
6441 PR tree-optimization/108387
6442 * tree-ssa-sccvn.cc (visit_nary_op): Check for SSA_NAME
6443 value before inserting expression into the tables.
6445 2023-01-12 Andrew Pinski <apinski@marvell.com>
6446 Roger Sayle <roger@nextmovesoftware.com>
6448 PR tree-optimization/92342
6449 * match.pd ((m1 CMP m2) * d -> (m1 CMP m2) ? d : 0):
6450 Use tcc_comparison and :c for the multiply.
6451 (b & -(a CMP c) -> (a CMP c)?b:0): New pattern.
6453 2023-01-12 Christophe Lyon <christophe.lyon@arm.com>
6454 Richard Sandiford <richard.sandiford@arm.com>
6457 * config/aarch64/aarch64.cc (aarch64_function_arg_alignment):
6458 Check DECL_PACKED for bitfield.
6459 (aarch64_layout_arg): Warn when parameter passing ABI changes.
6460 (aarch64_function_arg_boundary): Do not warn here.
6461 (aarch64_gimplify_va_arg_expr): Warn when parameter passing ABI
6464 2023-01-12 Christophe Lyon <christophe.lyon@arm.com>
6465 Richard Sandiford <richard.sandiford@arm.com>
6467 * config/aarch64/aarch64.cc (aarch64_function_arg_alignment): Fix
6469 (aarch64_layout_arg): Factorize warning conditions.
6470 (aarch64_function_arg_boundary): Fix typo.
6471 * function.cc (currently_expanding_function_start): New variable.
6472 (expand_function_start): Handle
6473 currently_expanding_function_start.
6474 * function.h (currently_expanding_function_start): Declare.
6476 2023-01-12 Richard Biener <rguenther@suse.de>
6478 PR tree-optimization/99412
6479 * tree-ssa-reassoc.cc (is_phi_for_stmt): Remove.
6480 (swap_ops_for_binary_stmt): Remove reduction handling.
6481 (rewrite_expr_tree_parallel): Adjust.
6482 (reassociate_bb): Likewise.
6483 * tree-parloops.cc (build_new_reduction): Handle MINUS_EXPR.
6485 2023-01-12 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
6487 * config/xtensa/xtensa.md (ctzsi2, ffssi2):
6488 Rearrange the emitting codes.
6490 2023-01-12 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
6492 * config/xtensa/xtensa.md (*btrue):
6493 Correct value of the attribute "length" that depends on
6494 TARGET_DENSITY and operands, and add '?' character to the register
6495 constraint of the compared operand.
6497 2023-01-12 Alexandre Oliva <oliva@adacore.com>
6499 * hash-table.h (expand): Check elements and deleted counts.
6502 2023-01-11 Roger Sayle <roger@nextmovesoftware.com>
6504 PR tree-optimization/71343
6505 * tree-ssa-sccvn.cc (visit_nary_op) <case LSHIFT_EXPR>: Make
6506 the value number of the expression X << C the same as the value
6507 number for the multiplication X * (1<<C).
6509 2023-01-11 David Faust <david.faust@oracle.com>
6512 * config/bpf/bpf.cc (bpf_print_operand): Correct handling for
6513 floating point modes.
6515 2023-01-11 Eric Botcazou <ebotcazou@adacore.com>
6517 PR tree-optimization/108199
6518 * tree-sra.cc (sra_modify_expr): Deal with reverse storage order
6519 for bit-field references.
6521 2023-01-11 Kewen Lin <linkw@linux.ibm.com>
6523 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Make
6524 OPTION_MASK_P10_FUSION implicit setting honour Power10 tuning setting.
6525 * config/rs6000/rs6000-cpus.def (ISA_3_1_MASKS_SERVER): Remove
6526 OPTION_MASK_P10_FUSION.
6528 2023-01-11 Richard Biener <rguenther@suse.de>
6530 PR tree-optimization/107767
6531 * tree-cfgcleanup.cc (phi_alternatives_equal): Export.
6532 * tree-cfgcleanup.h (phi_alternatives_equal): Declare.
6533 * tree-switch-conversion.cc (switch_conversion::collect):
6534 Count unique non-default targets accounting for later
6535 merging opportunities.
6537 2023-01-11 Martin Liska <mliska@suse.cz>
6539 PR middle-end/107976
6540 * params.opt: Limit JT params.
6541 * stmt.cc (emit_case_dispatch_table): Use auto_vec.
6543 2023-01-11 Richard Biener <rguenther@suse.de>
6545 PR tree-optimization/108352
6546 * tree-ssa-threadbackward.cc
6547 (back_threader_profitability::profitable_path_p): Adjust
6548 heuristic that allows non-multi-way branch threads creating
6550 * doc/invoke.texi (--param fsm-scale-path-blocks): Remove.
6551 (--param fsm-scale-path-stmts): Adjust.
6552 * params.opt (--param=fsm-scale-path-blocks=): Remove.
6553 (-param=fsm-scale-path-stmts=): Adjust description.
6555 2023-01-11 Richard Biener <rguenther@suse.de>
6557 PR tree-optimization/108353
6558 * tree-ssa-propagate.cc (cfg_blocks_back, ssa_edge_worklist_back):
6560 (add_ssa_edge): Simplify.
6561 (add_control_edge): Likewise.
6562 (ssa_prop_init): Likewise.
6563 (ssa_prop_fini): Likewise.
6564 (ssa_propagation_engine::ssa_propagate): Likewise.
6566 2023-01-11 Andreas Krebbel <krebbel@linux.ibm.com>
6568 * config/s390/s390.md (*not<mode>): New pattern.
6570 2023-01-11 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
6572 * config/xtensa/xtensa.cc (xtensa_insn_cost):
6573 Let insn cost for size be obtained by applying COSTS_N_INSNS()
6574 to instruction length and then dividing by 3.
6576 2023-01-10 Richard Biener <rguenther@suse.de>
6578 PR tree-optimization/106293
6579 * tree-ssa-dse.cc (dse_classify_store): Use a worklist to
6580 process degenerate PHI defs.
6582 2023-01-10 Roger Sayle <roger@nextmovesoftware.com>
6584 PR rtl-optimization/106421
6585 * cprop.cc (bypass_block): Check that DEST is local to this
6586 function (non-NULL) before calling find_edge.
6588 2023-01-10 Martin Jambor <mjambor@suse.cz>
6591 * ipa-param-manipulation.h (ipa_param_body_adjustments): New members
6592 sort_replacements, lookup_first_base_replacement and
6593 m_sorted_replacements_p.
6594 * ipa-param-manipulation.cc: Define INCLUDE_ALGORITHM.
6595 (ipa_param_body_adjustments::register_replacement): Set
6596 m_sorted_replacements_p to false.
6597 (compare_param_body_replacement): New function.
6598 (ipa_param_body_adjustments::sort_replacements): Likewise.
6599 (ipa_param_body_adjustments::common_initialization): Call
6601 (ipa_param_body_adjustments::ipa_param_body_adjustments): Initialize
6602 m_sorted_replacements_p.
6603 (ipa_param_body_adjustments::lookup_replacement_1): Rework to use
6605 (ipa_param_body_adjustments::lookup_first_base_replacement): New
6607 (ipa_param_body_adjustments::modify_call_stmt): Use
6608 lookup_first_base_replacement.
6609 * omp-simd-clone.cc (ipa_simd_modify_function_body): Call
6610 adjustments->sort_replacements.
6612 2023-01-10 Richard Biener <rguenther@suse.de>
6614 PR tree-optimization/108314
6615 * tree-vect-stmts.cc (vectorizable_condition): Do not
6616 perform BIT_NOT_EXPR optimization for EXTRACT_LAST_REDUCTION.
6618 2023-01-10 Xianmiao Qu <cooper.qu@linux.alibaba.com>
6620 * config/csky/csky-linux-elf.h (SYSROOT_SUFFIX_SPEC): New.
6622 2023-01-10 Xianmiao Qu <cooper.qu@linux.alibaba.com>
6624 * config/csky/csky.h (MULTILIB_DEFAULTS): Fix float abi option.
6626 2023-01-10 Xianmiao Qu <cooper.qu@linux.alibaba.com>
6628 * config/csky/csky.cc (csky_cpu_cpp_builtins): Add builtin
6629 defines for soft float abi.
6631 2023-01-10 Xianmiao Qu <cooper.qu@linux.alibaba.com>
6633 * config/csky/csky.md (smart_bseti): Change condition to CSKY_ISA_FEATURE (E1).
6634 (smart_bclri): Likewise.
6635 (fast_bseti): Change condition to CSKY_ISA_FEATURE (E2).
6636 (fast_bclri): Likewise.
6637 (fast_cmpnesi_i): Likewise.
6638 (*fast_cmpltsi_i): Likewise.
6639 (*fast_cmpgeusi_i): Likewise.
6641 2023-01-10 Xianmiao Qu <cooper.qu@linux.alibaba.com>
6643 * config/csky/csky_insn_fpuv3.md (l<frm_pattern><fixsuop><mode>si2): Test
6644 flag_fp_int_builtin_inexact || !flag_trapping_math.
6645 (<frm_pattern><mode>2): Likewise.
6647 2023-01-10 Andreas Krebbel <krebbel@linux.ibm.com>
6649 * config/s390/s390.cc (s390_register_info): Check call_used_regs
6650 instead of hard-coding the register numbers for call saved
6652 (s390_optimize_register_info): Likewise.
6654 2023-01-09 Eric Botcazou <ebotcazou@adacore.com>
6656 * doc/gm2.texi (Overview): Fix @node markers.
6657 (Using): Likewise. Remove subsections that were moved to Overview
6658 from the menu and move others around.
6660 2023-01-09 Richard Biener <rguenther@suse.de>
6662 PR middle-end/108209
6663 * genmatch.cc (commutative_op): Fix return value for
6664 user-id with non-commutative first replacement.
6666 2023-01-09 Jakub Jelinek <jakub@redhat.com>
6669 * calls.cc (expand_call): For calls with
6670 TYPE_NO_NAMED_ARGS_STDARG_P (funtype) use zero for n_named_args.
6673 2023-01-09 Richard Biener <rguenther@suse.de>
6676 * cfgexpand.cc (discover_nonconstant_array_refs_r): Volatile
6677 qualified accesses also force objects to memory.
6679 2023-01-09 Martin Liska <mliska@suse.cz>
6682 * lto-cgraph.cc (compute_ltrans_boundary): Do not insert
6683 NULL (deleleted value) to a hash_set.
6685 2023-01-08 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
6687 * config/xtensa/xtensa.md (*splice_bits):
6688 New insn_and_split pattern.
6690 2023-01-07 Takayuki 'January June' Suwa <jjsuwa_sys3175@yahoo.co.jp>
6692 * config/xtensa/xtensa.cc
6693 (xtensa_split_imm_two_addends, xtensa_emit_add_imm):
6694 New helper functions.
6695 (xtensa_set_return_address, xtensa_output_mi_thunk):
6696 Change to use the helper function.
6697 (xtensa_emit_adjust_stack_ptr): Ditto.
6698 And also change to try reusing the content of scratch register
6699 A9 if the register is not modified in the function body.
6701 2023-01-07 LIU Hao <lh_mouse@126.com>
6703 PR middle-end/108300
6704 * config/xtensa/xtensa-dynconfig.c: Define `WIN32_LEAN_AND_MEAN`
6706 * diagnostic-color.cc: Likewise.
6707 * plugin.cc: Likewise.
6708 * prefix.cc: Likewise.
6710 2023-01-06 Joseph Myers <joseph@codesourcery.com>
6712 * doc/extend.texi (__builtin_tgmath): Do not restate standard rule
6713 for handling real integer types.
6715 2023-01-06 Tamar Christina <tamar.christina@arm.com>
6718 2022-12-12 Tamar Christina <tamar.christina@arm.com>
6720 * config/aarch64/aarch64-simd.md (*aarch64_simd_movv2hf): New.
6721 (mov<mode>, movmisalign<mode>, aarch64_dup_lane<mode>,
6722 aarch64_store_lane0<mode>, aarch64_simd_vec_set<mode>,
6723 @aarch64_simd_vec_copy_lane<mode>, vec_set<mode>,
6724 reduc_<optab>_scal_<mode>, reduc_<fmaxmin>_scal_<mode>,
6725 aarch64_reduc_<optab>_internal<mode>, aarch64_get_lane<mode>,
6726 vec_init<mode><Vel>, vec_extract<mode><Vel>): Support V2HF.
6727 (aarch64_simd_dupv2hf): New.
6728 * config/aarch64/aarch64.cc (aarch64_classify_vector_mode):
6730 * config/aarch64/iterators.md (VHSDF_P): New.
6731 (V2F, VMOVE, nunits, Vtype, Vmtype, Vetype, stype, VEL,
6732 Vel, q, vp): Add V2HF.
6733 * config/arm/types.md (neon_fp_reduc_add_h): New.
6735 2023-01-06 Martin Liska <mliska@suse.cz>
6737 PR middle-end/107966
6738 * doc/options.texi: Fix Var documentation in internal manual.
6740 2023-01-05 Roger Sayle <roger@nextmovesoftware.com>
6743 2023-01-03 Roger Sayle <roger@nextmovesoftware.com>
6745 * config/i386/i386-expand.cc (ix86_expand_int_movcc): Rewrite
6746 RTL expansion to allow condition (mask) to be shared/reused,
6747 by avoiding overwriting pseudos and adding REG_EQUAL notes.
6749 2023-01-05 Iain Sandoe <iain@sandoe.co.uk>
6751 * common.opt: Add -static-libgm2.
6752 * config/darwin.h (LINK_SPEC): Handle static-libgm2.
6753 * doc/gm2.texi: Document static-libgm2.
6754 * gcc.cc (driver_handle_option): Allow static-libgm2.
6756 2023-01-05 Tejas Joshi <TejasSanjay.Joshi@amd.com>
6758 * common/config/i386/i386-common.cc (processor_alias_table):
6759 Use CPU_ZNVER4 for znver4.
6760 * config/i386/i386.md: Add znver4.md.
6761 * config/i386/znver4.md: New.
6763 2023-01-04 Jakub Jelinek <jakub@redhat.com>
6765 PR tree-optimization/108253
6766 * tree-vrp.cc (maybe_set_nonzero_bits): Handle var with pointer
6769 2023-01-04 Jakub Jelinek <jakub@redhat.com>
6771 PR middle-end/108237
6772 * generic-match-head.cc: Include tree-pass.h.
6773 (canonicalize_math_p, optimize_vectors_before_lowering_p): Define
6774 to false if cfun and cfun->curr_properties has PROP_gimple_opt_math
6775 resp. PROP_gimple_lvec property set.
6777 2023-01-04 Jakub Jelinek <jakub@redhat.com>
6780 * convert.cc (do_narrow): Punt for MULT_EXPR if original
6781 type doesn't wrap around and -fsanitize=signed-integer-overflow
6783 * fold-const.cc (fold_unary_loc) <CASE_CONVERT>: Likewise.
6785 2023-01-04 Hu, Lin1 <lin1.hu@intel.com>
6787 * common/config/i386/cpuinfo.h (get_intel_cpu): Handle Emeraldrapids.
6788 * common/config/i386/i386-common.cc: Add Emeraldrapids.
6790 2023-01-04 Hu, Lin1 <lin1.hu@intel.com>
6792 * common/config/i386/cpuinfo.h (get_intel_cpu): Remove case 0xb5
6795 2023-01-03 Sandra Loosemore <sandra@codesourcery.com>
6797 * cgraph.h (struct cgraph_node): Add gc_candidate bit, modify
6798 default constructor to initialize it.
6799 * cgraphunit.cc (expand_all_functions): Save gc_candidate functions
6800 for last and iterate to handle recursive calls. Delete leftover
6801 candidates at the end.
6802 * omp-simd-clone.cc (simd_clone_create): Set gc_candidate bit
6804 * tree-vect-stmts.cc (vectorizable_simd_clone_call): Clear
6805 gc_candidate bit when a clone is used.
6807 2023-01-03 Florian Weimer <fweimer@redhat.com>
6810 2023-01-02 Florian Weimer <fweimer@redhat.com>
6812 * dwarf2cfi.cc (init_return_column_size): Remove.
6813 (init_one_dwarf_reg_size): Adjust.
6814 (generate_dwarf_reg_sizes): New function. Extracted
6815 from expand_builtin_init_dwarf_reg_sizes.
6816 (expand_builtin_init_dwarf_reg_sizes): Call
6817 generate_dwarf_reg_sizes.
6818 * target.def (init_dwarf_reg_sizes_extra): Adjust
6820 * config/msp430/msp430.cc
6821 (msp430_init_dwarf_reg_sizes_extra): Adjust.
6822 * config/rs6000/rs6000.cc
6823 (rs6000_init_dwarf_reg_sizes_extra): Likewise.
6824 * doc/tm.texi: Update.
6826 2023-01-03 Florian Weimer <fweimer@redhat.com>
6829 2023-01-02 Florian Weimer <fweimer@redhat.com>
6831 * debug.h (dwarf_reg_sizes_constant): Declare.
6832 * dwarf2cfi.cc (dwarf_reg_sizes_constant): New function.
6834 2023-01-03 Siddhesh Poyarekar <siddhesh@gotplt.org>
6836 PR tree-optimization/105043
6837 * doc/extend.texi (Object Size Checking): Split out into two
6838 subsections and mention _FORTIFY_SOURCE.
6840 2023-01-03 Roger Sayle <roger@nextmovesoftware.com>
6842 * config/i386/i386-expand.cc (ix86_expand_int_movcc): Rewrite
6843 RTL expansion to allow condition (mask) to be shared/reused,
6844 by avoiding overwriting pseudos and adding REG_EQUAL notes.
6846 2023-01-03 Roger Sayle <roger@nextmovesoftware.com>
6849 * config/i386/i386-features.cc
6850 (general_scalar_chain::compute_convert_gain) <case PLUS>: Consider
6851 the gain/cost of converting a MEM operand.
6853 2023-01-03 Jakub Jelinek <jakub@redhat.com>
6855 PR middle-end/108264
6856 * expr.cc (store_expr): For stores into SUBREG_PROMOTED_* targets
6857 from source which doesn't have scalar integral mode first convert
6860 2023-01-03 Jakub Jelinek <jakub@redhat.com>
6862 PR rtl-optimization/108263
6863 * cfgrtl.cc (fixup_reorder_chain): Avoid trying to redirect
6866 2023-01-02 Alexander Monakov <amonakov@ispras.ru>
6869 * config/i386/lujiazui.md (lujiazui_div): New automaton.
6870 (lua_div): New unit.
6871 (lua_idiv_qi): Correct unit in the reservation.
6872 (lua_idiv_qi_load): Ditto.
6873 (lua_idiv_hi): Ditto.
6874 (lua_idiv_hi_load): Ditto.
6875 (lua_idiv_si): Ditto.
6876 (lua_idiv_si_load): Ditto.
6877 (lua_idiv_di): Ditto.
6878 (lua_idiv_di_load): Ditto.
6879 (lua_fdiv_SF): Ditto.
6880 (lua_fdiv_SF_load): Ditto.
6881 (lua_fdiv_DF): Ditto.
6882 (lua_fdiv_DF_load): Ditto.
6883 (lua_fdiv_XF): Ditto.
6884 (lua_fdiv_XF_load): Ditto.
6885 (lua_ssediv_SF): Ditto.
6886 (lua_ssediv_load_SF): Ditto.
6887 (lua_ssediv_V4SF): Ditto.
6888 (lua_ssediv_load_V4SF): Ditto.
6889 (lua_ssediv_V8SF): Ditto.
6890 (lua_ssediv_load_V8SF): Ditto.
6891 (lua_ssediv_SD): Ditto.
6892 (lua_ssediv_load_SD): Ditto.
6893 (lua_ssediv_V2DF): Ditto.
6894 (lua_ssediv_load_V2DF): Ditto.
6895 (lua_ssediv_V4DF): Ditto.
6896 (lua_ssediv_load_V4DF): Ditto.
6898 2023-01-02 Florian Weimer <fweimer@redhat.com>
6900 * debug.h (dwarf_reg_sizes_constant): Declare.
6901 * dwarf2cfi.cc (dwarf_reg_sizes_constant): New function.
6903 2023-01-02 Florian Weimer <fweimer@redhat.com>
6905 * dwarf2cfi.cc (init_return_column_size): Remove.
6906 (init_one_dwarf_reg_size): Adjust.
6907 (generate_dwarf_reg_sizes): New function. Extracted
6908 from expand_builtin_init_dwarf_reg_sizes.
6909 (expand_builtin_init_dwarf_reg_sizes): Call
6910 generate_dwarf_reg_sizes.
6911 * target.def (init_dwarf_reg_sizes_extra): Adjust
6913 * config/msp430/msp430.cc
6914 (msp430_init_dwarf_reg_sizes_extra): Adjust.
6915 * config/rs6000/rs6000.cc
6916 (rs6000_init_dwarf_reg_sizes_extra): Likewise.
6917 * doc/tm.texi: Update.
6919 2023-01-02 Jakub Jelinek <jakub@redhat.com>
6921 * gcc.cc (process_command): Update copyright notice dates.
6922 * gcov-dump.cc (print_version): Ditto.
6923 * gcov.cc (print_version): Ditto.
6924 * gcov-tool.cc (print_version): Ditto.
6925 * gengtype.cc (create_file): Ditto.
6926 * doc/cpp.texi: Bump @copying's copyright year.
6927 * doc/cppinternals.texi: Ditto.
6928 * doc/gcc.texi: Ditto.
6929 * doc/gccint.texi: Ditto.
6930 * doc/gcov.texi: Ditto.
6931 * doc/install.texi: Ditto.
6932 * doc/invoke.texi: Ditto.
6934 2023-01-01 Roger Sayle <roger@nextmovesoftware.com>
6935 Uroš Bizjak <ubizjak@gmail.com>
6937 * config/i386/i386.md (extendditi2): New define_insn.
6938 (define_split): Use DWIH mode iterator to treat new extendditi2
6939 identically to existing extendsidi2_1.
6940 (define_peephole2): Likewise.
6941 (define_peephole2): Likewise.
6942 (define_Split): Likewise.
6945 Copyright (C) 2023 Free Software Foundation, Inc.
6947 Copying and distribution of this file, with or without modification,
6948 are permitted in any medium without royalty provided the copyright
6949 notice and this notice are preserved.