Commit fe534c99 authored by Christoph Mallon's avatar Christoph Mallon
Browse files

Simplify is_Const_Minus_1().

[r15847]
parent 68c75332
......@@ -230,19 +230,7 @@ static int is_Const_1(ir_node *node) {
}
static int is_Const_Minus_1(ir_node *node) {
tarval *tv;
ir_mode *mode;
if(!is_Const(node))
return 0;
mode = get_irn_mode(node);
if(!mode_is_signed(mode))
return 0;
tv = get_Const_tarval(node);
tv = tarval_neg(tv);
return tarval_is_one(tv);
return is_Const(node) && is_Const_all_one(node);
}
/**
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment