i386.c (ix86_expand_clrmem): Properly call gen_strset for 64bit target.
authorH.J. Lu <hongjiu.lu@intel.com>
Sat, 7 Aug 2004 16:34:00 +0000 (16:34 +0000)
committerH.J. Lu <hjl@gcc.gnu.org>
Sat, 7 Aug 2004 16:34:00 +0000 (09:34 -0700)
2004-08-07  H.J. Lu  <hongjiu.lu@intel.com>

* config/i386/i386.c (ix86_expand_clrmem): Properly call
gen_strset for 64bit target.

From-SVN: r85673

gcc/ChangeLog
gcc/config/i386/i386.c

index 7cd55d3df51375547cf6393205c9fca38659da1d..11aaa96d4db6c87085cabfd70b1465cfb588534c 100644 (file)
@@ -1,3 +1,8 @@
+2004-08-07  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * config/i386/i386.c (ix86_expand_clrmem): Properly call
+       gen_strset for 64bit target.
+
 2004-08-07  Olivier Hainque  <hainque@act-europe.fr>
 
        * config/vxworks.h (HANDLE_SYSV_PRAGMA): Remove definition.
index 951573415da73d62289ae747c9c79b75d4b90f02..e1e2027b2e379c12259250366afb231b683bb1ba 100644 (file)
@@ -11569,7 +11569,10 @@ ix86_expand_clrmem (rtx dst, rtx count_exp, rtx align_exp)
                rtx mem = adjust_automodify_address_nv (dst,
                                                        GET_MODE (zeroreg),
                                                        destreg, offset);
-               emit_insn (gen_strset (destreg, mem, zeroreg));
+               emit_insn (gen_strset (destreg, mem,
+                                      (TARGET_64BIT
+                                       ? gen_rtx_SUBREG (SImode, zeroreg, 0)
+                                       : zeroreg)));
                offset += size;
              }
          else