public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Andre Simoes Dias Vieira <avieira@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r14-4763] parloops: Allow poly nit and bound Date: Thu, 19 Oct 2023 17:30:51 +0000 (GMT) [thread overview] Message-ID: <20231019173051.A29D0385773F@sourceware.org> (raw) https://gcc.gnu.org/g:53d40858c8370b2079bfb017c6870b244b718800 commit r14-4763-g53d40858c8370b2079bfb017c6870b244b718800 Author: Andre Vieira <andre.simoesdiasvieira@arm.com> Date: Thu Oct 19 18:27:18 2023 +0100 parloops: Allow poly nit and bound Teach parloops how to handle a poly nit and bound e ahead of the changes to enable non-constant simdlen. gcc/ChangeLog: * tree-parloops.cc (try_transform_to_exit_first_loop_alt): Accept poly NIT and ALT_BOUND. Diff: --- gcc/tree-parloops.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gcc/tree-parloops.cc b/gcc/tree-parloops.cc index a35f3d5023b0..80f3dd6dce28 100644 --- a/gcc/tree-parloops.cc +++ b/gcc/tree-parloops.cc @@ -2531,14 +2531,15 @@ try_transform_to_exit_first_loop_alt (class loop *loop, tree nit_type = TREE_TYPE (nit); /* Figure out whether nit + 1 overflows. */ - if (TREE_CODE (nit) == INTEGER_CST) + if (poly_int_tree_p (nit)) { if (!tree_int_cst_equal (nit, TYPE_MAX_VALUE (nit_type))) { alt_bound = fold_build2_loc (UNKNOWN_LOCATION, PLUS_EXPR, nit_type, nit, build_one_cst (nit_type)); - gcc_assert (TREE_CODE (alt_bound) == INTEGER_CST); + gcc_assert (TREE_CODE (alt_bound) == INTEGER_CST + || TREE_CODE (alt_bound) == POLY_INT_CST); transform_to_exit_first_loop_alt (loop, reduction_list, alt_bound); return true; }
reply other threads:[~2023-10-19 17:30 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20231019173051.A29D0385773F@sourceware.org \ --to=avieira@gcc.gnu.org \ --cc=gcc-cvs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).