]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - gcc/gimplify-me.c
Update copyright years.
[thirdparty/gcc.git] / gcc / gimplify-me.c
index f56bdbb78d6aa39e1c5126be823e1d9ce29777ea..47148fbd14fc27e0807c781a39b204af331e9c96 100644 (file)
@@ -1,7 +1,7 @@
 /* Tree lowering to gimple for middle end use only.  
    This converts the GENERIC functions-as-trees tree representation into
    the GIMPLE form.
-   Copyright (C) 2013-2015 Free Software Foundation, Inc.
+   Copyright (C) 2013-2020 Free Software Foundation, Inc.
    Major work done by Sebastian Pop <s.pop@laposte.net>,
    Diego Novillo <dnovillo@redhat.com> and Jason Merrill <jason@redhat.com>.
 
@@ -24,17 +24,12 @@ along with GCC; see the file COPYING3.  If not see
 #include "config.h"
 #include "system.h"
 #include "coretypes.h"
-#include "alias.h"
 #include "backend.h"
 #include "tree.h"
 #include "gimple.h"
-#include "hard-reg-set.h"
 #include "ssa.h"
-#include "options.h"
-#include "fold-const.h"
 #include "stmt.h"
 #include "stor-layout.h"
-#include "internal-fn.h"
 #include "tree-eh.h"
 #include "gimple-iterator.h"
 #include "gimplify.h"
@@ -155,12 +150,12 @@ force_gimple_operand_gsi (gimple_stmt_iterator *gsi, tree expr,
    GIMPLE statements are inserted before *GSI_P.  */
 
 void
-gimple_regimplify_operands (gimple stmt, gimple_stmt_iterator *gsi_p)
+gimple_regimplify_operands (gimple *stmt, gimple_stmt_iterator *gsi_p)
 {
   size_t i, num_ops;
   tree lhs;
   gimple_seq pre = NULL;
-  gimple post_stmt = NULL;
+  gimple *post_stmt = NULL;
 
   push_gimplify_context (gimple_in_ssa_p (cfun));
 
@@ -278,7 +273,7 @@ gimple_regimplify_operands (gimple stmt, gimple_stmt_iterator *gsi_p)
                          || !(i & (ECF_CONST | ECF_PURE)))
                        need_temp = true;
                    }
-                 if (stmt_can_throw_internal (stmt))
+                 if (stmt_can_throw_internal (cfun, stmt))
                    need_temp = true;
                }
            }
@@ -304,7 +299,8 @@ gimple_regimplify_operands (gimple stmt, gimple_stmt_iterator *gsi_p)
          if (need_temp)
            {
              tree temp = create_tmp_reg (TREE_TYPE (lhs));
-             if (gimple_in_ssa_p (cfun))
+             if (gimple_in_ssa_p (cfun)
+                 && is_gimple_reg_type (TREE_TYPE (lhs)))
                temp = make_ssa_name (temp);
              gimple_set_lhs (stmt, temp);
              post_stmt = gimple_build_assign (lhs, temp);