public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Michael Meissner <meissner@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc(refs/users/meissner/heads/dmf004)] Don't do load/store vector with length if overlap.
Date: Wed, 16 Nov 2022 08:28:34 +0000 (GMT)	[thread overview]
Message-ID: <20221116082834.7E83B3955CBD@sourceware.org> (raw)

https://gcc.gnu.org/g:cc045071b71691506e598fd39969e18dd05cc6f5

commit cc045071b71691506e598fd39969e18dd05cc6f5
Author: Michael Meissner <meissner@linux.ibm.com>
Date:   Wed Nov 16 03:28:12 2022 -0500

    Don't do load/store vector with length if overlap.
    
    2022-11-16   Michael Meissner  <meissner@linux.ibm.com>
    
    gcc/
    
            * config/rs6000/rs6000-string.cc (expand_block_move): Don't do the
            optimization to use load/store vector with length if the source and
            destination might overlap.

Diff:
---
 gcc/config/rs6000/rs6000-string.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/config/rs6000/rs6000-string.cc b/gcc/config/rs6000/rs6000-string.cc
index 6e1e51c15fb..038f194c32c 100644
--- a/gcc/config/rs6000/rs6000-string.cc
+++ b/gcc/config/rs6000/rs6000-string.cc
@@ -2838,7 +2838,7 @@ expand_block_move (rtx operands[], bool might_overlap)
       if (TARGET_BLOCK_OPS_UNALIGNED_VSX && TARGET_P9_VECTOR && TARGET_64BIT
 	  && rs6000_memcpy_inline_bytes > 0
 	  && rs6000_memcpy_inline_bytes <= 255
-	  && optimize && !optimize_size)
+	  && !might_overlap && optimize && !optimize_size)
 	{
 	  expand_block_move_variable (orig_dest, orig_src, bytes_rtx);
 	  return 1;

             reply	other threads:[~2022-11-16  8:28 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-16  8:28 Michael Meissner [this message]
2022-11-17 21:55 Michael Meissner

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=20221116082834.7E83B3955CBD@sourceware.org \
    --to=meissner@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: link
Be 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).