projects
/
gcc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
re PR middle-end/42834 (memcpy folding overeager)
[gcc.git]
/
gcc
/
ipa-inline.c
diff --git
a/gcc/ipa-inline.c
b/gcc/ipa-inline.c
index f9e4cf3cfa736c73b5591f314d99aaeecc7c39a5..691bf6ca771ca130cb7ce1e60882e8d28a87ca0f 100644
(file)
--- a/
gcc/ipa-inline.c
+++ b/
gcc/ipa-inline.c
@@
-1832,10
+1832,12
@@
likely_eliminated_by_inlining_p (gimple stmt)
bool rhs_free = false;
bool lhs_free = false;
bool rhs_free = false;
bool lhs_free = false;
- while (handled_component_p (inner_lhs) || TREE_CODE (inner_lhs) == INDIRECT_REF)
+ while (handled_component_p (inner_lhs)
+ || TREE_CODE (inner_lhs) == MEM_REF)
inner_lhs = TREE_OPERAND (inner_lhs, 0);
while (handled_component_p (inner_rhs)
inner_lhs = TREE_OPERAND (inner_lhs, 0);
while (handled_component_p (inner_rhs)
- || TREE_CODE (inner_rhs) == ADDR_EXPR || TREE_CODE (inner_rhs) == INDIRECT_REF)
+ || TREE_CODE (inner_rhs) == ADDR_EXPR
+ || TREE_CODE (inner_rhs) == MEM_REF)
inner_rhs = TREE_OPERAND (inner_rhs, 0);
inner_rhs = TREE_OPERAND (inner_rhs, 0);
@@
-1855,7
+1857,8
@@
likely_eliminated_by_inlining_p (gimple stmt)
|| (TREE_CODE (inner_lhs) == SSA_NAME
&& TREE_CODE (SSA_NAME_VAR (inner_lhs)) == RESULT_DECL))
lhs_free = true;
|| (TREE_CODE (inner_lhs) == SSA_NAME
&& TREE_CODE (SSA_NAME_VAR (inner_lhs)) == RESULT_DECL))
lhs_free = true;
- if (lhs_free && (is_gimple_reg (rhs) || is_gimple_min_invariant (rhs)))
+ if (lhs_free
+ && (is_gimple_reg (rhs) || is_gimple_min_invariant (rhs)))
rhs_free = true;
if (lhs_free && rhs_free)
return true;
rhs_free = true;
if (lhs_free && rhs_free)
return true;