[gcc(refs/users/marxin/heads/loop-unswitching-switch-v3)] Simplify gimple_lv_add_condition_to_bb.
Martin Liska
marxin@gcc.gnu.org
Mon Sep 13 15:31:07 GMT 2021
https://gcc.gnu.org/g:e3e992c0fa9296002e9b53d5e156171354b9312e
commit e3e992c0fa9296002e9b53d5e156171354b9312e
Author: Martin Liska <mliska@suse.cz>
Date: Mon Sep 13 15:25:41 2021 +0200
Simplify gimple_lv_add_condition_to_bb.
Diff:
---
gcc/tree-cfg.c | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/gcc/tree-cfg.c b/gcc/tree-cfg.c
index 138f4361a6c..159e5d83c06 100644
--- a/gcc/tree-cfg.c
+++ b/gcc/tree-cfg.c
@@ -9055,13 +9055,9 @@ gimple_lv_add_condition_to_bb (basic_block first_head ATTRIBUTE_UNUSED,
/* Build new conditional expr */
gsi = gsi_last_bb (cond_bb);
- if (COMPARISON_CLASS_P (cond_expr)
- || TREE_CODE (cond_expr) == TRUTH_NOT_EXPR
- || is_gimple_min_invariant (cond_expr)
- || SSA_VAR_P (cond_expr))
- ;
- else
- cond_expr = force_gimple_operand_gsi (&gsi, cond_expr, true, NULL_TREE, false,
+ cond_expr = force_gimple_operand_gsi_1 (&gsi, cond_expr,
+ is_gimple_condexpr_for_cond,
+ NULL_TREE, false,
GSI_CONTINUE_LINKING);
new_cond_expr = gimple_build_cond_from_tree (cond_expr,
NULL_TREE, NULL_TREE);
More information about the Gcc-cvs
mailing list