sh.c (sh_gimplify_va_arg_expr): Wrap the result with a NOP_EXPR if needed.
authorKaz Kojima <kkojima@gcc.gnu.org>
Tue, 21 Jul 2009 12:45:52 +0000 (12:45 +0000)
committerKaz Kojima <kkojima@gcc.gnu.org>
Tue, 21 Jul 2009 12:45:52 +0000 (12:45 +0000)
* config/sh/sh.c (sh_gimplify_va_arg_expr): Wrap the result
with a NOP_EXPR if needed.

From-SVN: r149854

gcc/ChangeLog
gcc/config/sh/sh.c

index c189dda3f5038a9233ae5d484bd84692dc27f03e..68a81ccb44dd19705279604cd6e0f240ca5a2b25 100644 (file)
@@ -1,3 +1,8 @@
+2009-07-21  Kaz Kojima  <kkojima@gcc.gnu.org>
+
+       * config/sh/sh.c (sh_gimplify_va_arg_expr): Wrap the result
+       with a NOP_EXPR if needed.
+
 2009-07-21  Paul Brook <paul@codesourcery.com>
 
        * tree-vectorizer.c (increase_alignment): Handle nested arrays.
index b4c190029dfe4a7e9abae452dc46ea3b6541bdb2..788b0fe13916a19f9c1b4a3fe15092d4e755fa55 100644 (file)
@@ -7857,7 +7857,7 @@ sh_gimplify_va_arg_expr (tree valist, tree type, gimple_seq *pre_p,
   if (result)
     {
       gimplify_assign (result, tmp, pre_p);
-
+      result = build1 (NOP_EXPR, TREE_TYPE (result), result);
       tmp = build1 (LABEL_EXPR, void_type_node, unshare_expr (lab_over));
       gimplify_and_add (tmp, pre_p);
     }