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
5a7a2ef8
Commit
5a7a2ef8
authored
Dec 21, 2015
by
yb9976
Browse files
Make transformer robust against mode_b constants.
parent
d86e50f0
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/be/ia32/ia32_transform.c
View file @
5a7a2ef8
...
...
@@ -2211,6 +2211,16 @@ static bool is_bt_relation(ir_relation const relation, ir_mode *const mode)
static
ir_node
*
get_flags_node
(
ir_node
*
cmp
,
x86_condition_code_t
*
cc_out
)
{
if
(
is_Const
(
cmp
))
{
/* For -O0 and some enabled optimizations,
* we might end up with mode_b constants. */
*
cc_out
=
is_Const_null
(
cmp
)
?
x86_cc_above_equal
:
x86_cc_below
;
dbg_info
*
dbgi
=
get_irn_dbg_info
(
cmp
);
ir_node
*
block
=
be_transform_nodes_block
(
cmp
);
return
new_bd_ia32_Stc
(
dbgi
,
block
);
}
/* must have a Cmp as input */
ir_relation
relation
=
get_Cmp_relation
(
cmp
);
ir_node
*
l
=
get_Cmp_left
(
cmp
);
...
...
Write
Preview
Markdown
is supported
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