Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Zwinkau
libfirm
Commits
4afe0598
Commit
4afe0598
authored
Mar 04, 2014
by
Christoph Mallon
Browse files
iropt: Check symmetric case of a op b == a, if this case failed.
parent
a2cdfd49
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/ir/iropt.c
View file @
4afe0598
...
...
@@ -4197,7 +4197,8 @@ static ir_node *transform_node_Cmp(ir_node *n)
}
else
{
x
=
get_commutative_other_op
(
left
,
right
);
}
goto
cmp_x_eq_0
;
if
(
x
)
goto
cmp_x_eq_0
;
}
if
(
is_Add
(
right
)
||
is_Eor
(
right
)
||
is_Sub
(
right
)
||
is_Or_Eor_Add
(
right
))
{
if
(
is_Sub
(
right
))
{
...
...
@@ -4205,8 +4206,8 @@ static ir_node *transform_node_Cmp(ir_node *n)
}
else
{
x
=
get_commutative_other_op
(
right
,
left
);
}
cmp_x_eq_0:
if
(
x
)
{
cmp_x_eq_0:
;
ir_graph
*
irg
=
get_irn_irg
(
n
);
left
=
x
;
right
=
create_zero_const
(
irg
,
mode
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment