Commit ead8e569 authored by Matthias Braun's avatar Matthias Braun
Browse files

sparc: fix float to short conversion

parent 67926613
...@@ -326,7 +326,7 @@ static int sparc_rewrite_Conv(ir_node *node, void *ctx) ...@@ -326,7 +326,7 @@ static int sparc_rewrite_Conv(ir_node *node, void *ctx)
return 1; return 1;
} }
if (mode_is_float(from_mode) && mode_is_int(to_mode) if (mode_is_float(from_mode) && mode_is_int(to_mode)
&& get_mode_size_bits(to_mode) == 32 && get_mode_size_bits(to_mode) <= 32
&& !mode_is_signed(to_mode)) { && !mode_is_signed(to_mode)) {
rewrite_float_unsigned_Conv(node); rewrite_float_unsigned_Conv(node);
return 1; return 1;
......
...@@ -1436,7 +1436,7 @@ static ir_node *gen_Conv(ir_node *node) ...@@ -1436,7 +1436,7 @@ static ir_node *gen_Conv(ir_node *node)
} else { } else {
/* float -> int conv */ /* float -> int conv */
if (!mode_is_signed(dst_mode)) if (!mode_is_signed(dst_mode))
panic("float to unsigned not implemented yet"); panic("float to unsigned not lowered");
return create_ftoi(dbgi, block, new_op, src_mode); return create_ftoi(dbgi, block, new_op, src_mode);
} }
} else { } else {
......
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