]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
integrate.c (expand_inline_function): Don't inline if would lose /u on a BLKmode...
authorRichard Kenner <kenner@vlsi1.ultra.nyu.edu>
Mon, 14 Apr 2003 21:33:05 +0000 (21:33 +0000)
committerRichard Kenner <kenner@gcc.gnu.org>
Mon, 14 Apr 2003 21:33:05 +0000 (17:33 -0400)
* integrate.c (expand_inline_function): Don't inline if would
lose /u on a BLKmode TARGET.

From-SVN: r65594

gcc/ChangeLog
gcc/integrate.c

index a53b3b686b5232065b7382820217c54afe7827d8..8b0dafc18f9741992d6dd114fa36a01793b2b60c 100644 (file)
@@ -1,3 +1,8 @@
+2003-04-14  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>
+
+       * integrate.c (expand_inline_function): Don't inline if would
+       lose /u on a BLKmode TARGET.
+
 2003-04-14  Joel Brobecker  <brobecker@gnat.com>
 
         * dwarf2out.c (gen_compile_unit_die): Emit DW_LANG_Ada95 instead
index f26a94c66a1193f07ce65e00cf203ce5a9b0c590..7a1865881c66cb46220fbf8895252af09f001710 100644 (file)
@@ -736,6 +736,14 @@ expand_inline_function (fndecl, parms, target, ignore, type,
        return (rtx) (size_t) -1;
     }
 
+  /* If there is a TARGET which is a readonly BLKmode MEM and DECL_RESULT
+     is also a mem, we are going to lose the readonly on the stores, so don't
+     inline.  */
+  if (target != 0 && GET_CODE (target) == MEM && GET_MODE (target) == BLKmode
+      && RTX_UNCHANGING_P (target) && DECL_RTL_SET_P (DECL_RESULT (fndecl))
+      && GET_CODE (DECL_RTL (DECL_RESULT (fndecl))) == MEM)
+    return (rtx) (size_t) -1;
+
   /* Extra arguments are valid, but will be ignored below, so we must
      evaluate them here for side-effects.  */
   for (; actual; actual = TREE_CHAIN (actual))