loop.c (emit_prefetch_instructions): Use the prefetch insn's mode, not Pmode.
authorAldy Hernandez <aldyh@redhat.com>
Fri, 25 Jan 2002 04:32:46 +0000 (04:32 +0000)
committerAldy Hernandez <aldyh@gcc.gnu.org>
Fri, 25 Jan 2002 04:32:46 +0000 (04:32 +0000)
2002-01-24  Aldy Hernandez  <aldyh@redhat.com>

        * loop.c (emit_prefetch_instructions): Use the prefetch insn's
        mode, not Pmode.

        * builtins.c (expand_builtin_prefetch): Same.

From-SVN: r49200

gcc/ChangeLog
gcc/builtins.c
gcc/loop.c

index b4606723808e12c31806d0046ab6689af493b87d..f5b81e05512ad86a9401c7d662c6c1761a19765e 100644 (file)
@@ -1,3 +1,10 @@
+2002-01-24  Aldy Hernandez  <aldyh@redhat.com>
+
+        * loop.c (emit_prefetch_instructions): Use the prefetch insn's
+        mode, not Pmode.
+
+        * builtins.c (expand_builtin_prefetch): Same.
+
 2002-01-24  Alexandre Oliva  <aoliva@redhat.com>
 
        * config/sh/sh.md (sym_label2reg): Make sure all CONSTs have
index 404bf46a0047e9a339a36422d505b1ec38dc084a..9d308aeaff08f09a1d950d9c8596fa41fdf937de 100644 (file)
@@ -785,7 +785,8 @@ expand_builtin_prefetch (arglist)
   if (HAVE_prefetch)
     {
       if (! (*insn_data[(int)CODE_FOR_prefetch].operand[0].predicate)
-           (op0, Pmode))
+           (op0,
+            insn_data[(int)CODE_FOR_prefetch].operand[0].mode))
         op0 = force_reg (Pmode, op0);
       emit_insn (gen_prefetch (op0, op1, op2));
     }
index 3f874a8652ac85ddbf4ca43db68a8e2333ba6e9b..ebd59af59ff2d59e67d53ee8a46b60ff6bab3aca 100644 (file)
@@ -4023,7 +4023,8 @@ emit_prefetch_instructions (loop)
 
              /* Make sure the address operand is valid for prefetch.  */
              if (! (*insn_data[(int)CODE_FOR_prefetch].operand[0].predicate)
-                   (loc, Pmode))
+                   (loc,
+                    insn_data[(int)CODE_FOR_prefetch].operand[0].mode))
                loc = force_reg (Pmode, loc);
              emit_insn_before (gen_prefetch (loc, GEN_INT (info[i].write),
                                              GEN_INT (3)),