Skip to content

Commit

Permalink
Translate Wasm's f32x4.convert_i32x4_u instruction to Cranelift's fcv…
Browse files Browse the repository at this point in the history
…t_from_uint
  • Loading branch information
abrown committed Jun 11, 2020
1 parent c86feb6 commit 87ee333
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cranelift/wasm/src/code_translator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1544,9 +1544,12 @@ pub fn translate_operator<FE: FuncEnvironment + ?Sized>(
let a = pop1_with_bitcast(state, I32X4, builder);
state.push1(builder.ins().fcvt_from_sint(F32X4, a))
}
Operator::F32x4ConvertI32x4U => {
let a = pop1_with_bitcast(state, I32X4, builder);
state.push1(builder.ins().fcvt_from_uint(F32X4, a))
}
Operator::I32x4TruncSatF32x4S
| Operator::I32x4TruncSatF32x4U
| Operator::F32x4ConvertI32x4U
| Operator::I8x16Abs
| Operator::I16x8Abs
| Operator::I32x4Abs
Expand Down

0 comments on commit 87ee333

Please sign in to comment.