rs6000.c (expand_block_move): Use SImode and HImode with STRICT_ALIGNMENT.
authorDavid Edelsohn <edelsohn@gnu.org>
Fri, 3 Sep 2004 01:12:30 +0000 (01:12 +0000)
committerDavid Edelsohn <dje@gcc.gnu.org>
Fri, 3 Sep 2004 01:12:30 +0000 (21:12 -0400)
        * config/rs6000/rs6000.c (expand_block_move): Use SImode and
        HImode with STRICT_ALIGNMENT.

From-SVN: r87021

gcc/ChangeLog
gcc/config/rs6000/rs6000.c

index 96eb1b86835ee5627e89fc8355fe8b48dfb92a2e..ab1327ba75e21ec9773cb517c5d9028c0ab9b345 100644 (file)
@@ -1,3 +1,8 @@
+2004-09-02  David Edelsohn  <edelsohn@gnu.org>
+
+       * config/rs6000/rs6000.c (expand_block_move): Use SImode and
+       HImode with STRICT_ALIGNMENT.
+
 2004-09-02  Mark Mitchell  <mark@codesourcery.com>
 
        * config/arm/bpabi.h (TARGET_BPABI_CPP_BUILTINS): Define.
index 335dbe3d16e85dcfba4faf4f8d41a2627dd66b8b..1881fc198c7e037a022a66b7320e90dcf767acc8 100644 (file)
@@ -8510,13 +8510,13 @@ expand_block_move (rtx operands[])
          move_bytes = (bytes > 8) ? 8 : bytes;
          gen_func.movmemsi = gen_movmemsi_2reg;
        }
-      else if (bytes >= 4 && !STRICT_ALIGNMENT)
+      else if (bytes >= 4 && (align >= 32 || !STRICT_ALIGNMENT))
        {                       /* move 4 bytes */
          move_bytes = 4;
          mode = SImode;
          gen_func.mov = gen_movsi;
        }
-      else if (bytes == 2 && !STRICT_ALIGNMENT)
+      else if (bytes == 2 && (align >= 16 || !STRICT_ALIGNMENT))
        {                       /* move 2 bytes */
          move_bytes = 2;
          mode = HImode;