public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Richard Biener <rguenth@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r14-5554] Revert "tree-optimization/112281 - loop distribution and zero dependence distances" Date: Fri, 17 Nov 2023 13:48:54 +0000 (GMT) [thread overview] Message-ID: <20231117134854.F1C123858D1E@sourceware.org> (raw) https://gcc.gnu.org/g:1f28b2e4d8f8ea54848c332c707fa4ca5f028fa1 commit r14-5554-g1f28b2e4d8f8ea54848c332c707fa4ca5f028fa1 Author: Richard Biener <rguenther@suse.de> Date: Fri Nov 17 14:47:07 2023 +0100 Revert "tree-optimization/112281 - loop distribution and zero dependence distances" This reverts commit 5ea2965b499f9e491e45db19fedbccfccb75076a. Diff: --- gcc/testsuite/gcc.dg/torture/pr112281.c | 19 ------------------- gcc/tree-loop-distribution.cc | 7 +++---- 2 files changed, 3 insertions(+), 23 deletions(-) diff --git a/gcc/testsuite/gcc.dg/torture/pr112281.c b/gcc/testsuite/gcc.dg/torture/pr112281.c deleted file mode 100644 index 3f0a61a9376..00000000000 --- a/gcc/testsuite/gcc.dg/torture/pr112281.c +++ /dev/null @@ -1,19 +0,0 @@ -/* { dg-do run } */ -/* { dg-additional-options "-ftree-loop-distribution" } */ - -struct { - int : 8; - int a; -} b, d[4] = {{0}, {0}, {0}, {5}}; -int c, e; -int main() -{ - for (c = 2; c; c--) - for (e = 0; e < 2; e++) { - d[c] = b = d[c + 1]; - d[c + 1].a = 0; - } - if (b.a != 0) - __builtin_abort(); - return 0; -} diff --git a/gcc/tree-loop-distribution.cc b/gcc/tree-loop-distribution.cc index 5ededd97c3d..ffca535064b 100644 --- a/gcc/tree-loop-distribution.cc +++ b/gcc/tree-loop-distribution.cc @@ -2163,10 +2163,9 @@ loop_distribution::pg_add_dependence_edges (struct graph *rdg, int dir, gcc.dg/tree-ssa/pr94969.c. */ if (DDR_NUM_DIST_VECTS (ddr) != 1) this_dir = 2; - /* If the dependence distance is zero in the innermost - loop preserve stmt order. */ - else if (DDR_DIST_VECT (ddr, 0) - [DDR_LOOP_NEST (ddr).length () - 1] == 0) + /* If the overlap is exact preserve stmt order. */ + else if (lambda_vector_zerop (DDR_DIST_VECT (ddr, 0), + DDR_NB_LOOPS (ddr))) ; /* Else as the distance vector is lexicographic positive swap the dependence direction. */
reply other threads:[~2023-11-17 13:48 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=20231117134854.F1C123858D1E@sourceware.org \ --to=rguenth@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).