Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Zwinkau
libfirm
Commits
e742a703
Commit
e742a703
authored
Nov 12, 2015
by
Christoph Mallon
Browse files
iropt: Simplify test for highest bit being 0.
parent
6d07016c
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/opt/iropt.c
View file @
e742a703
...
...
@@ -6157,10 +6157,8 @@ static ir_node *transform_node_Shrs(ir_node *n)
const
bitinfo
*
const
bn
=
get_bitinfo
(
n
);
if
(
bn
!=
NULL
&&
get_mode_arithmetic
(
mode
)
==
irma_twos_complement
)
{
ir_tarval
*
z
=
bn
->
z
;
unsigned
mode_bits
=
get_mode_size_bits
(
mode
);
unsigned
highest_bit
=
get_tarval_highest_bit
(
z
);
if
(
highest_bit
+
1U
!=
mode_bits
)
{
unsigned
const
mode_bits
=
get_mode_size_bits
(
mode
);
if
(
tarval_get_bit
(
bn
->
z
,
mode_bits
-
1
)
==
0
)
{
dbg_info
*
const
dbgi
=
get_irn_dbg_info
(
n
);
ir_node
*
const
block
=
get_nodes_block
(
n
);
n
=
new_rd_Shr
(
dbgi
,
block
,
a
,
b
,
mode
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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