clz/ctz/popcnt

This commit is contained in:
Jef
2019-01-17 13:51:18 +01:00
parent 74d168ec4b
commit e0f032a0e5
4 changed files with 141 additions and 22 deletions

View File

@@ -395,6 +395,9 @@ pub fn translate(
Operator::I32Or => ctx.i32_or(),
Operator::I32Xor => ctx.i32_xor(),
Operator::I32Mul => ctx.i32_mul(),
Operator::I32Clz => ctx.i32_clz(),
Operator::I32Ctz => ctx.i32_ctz(),
Operator::I32Popcnt => ctx.i32_popcnt(),
Operator::I64Eq => ctx.i64_eq(),
Operator::I64Eqz => ctx.i64_eqz(),
Operator::I64Ne => ctx.i64_neq(),
@@ -412,6 +415,9 @@ pub fn translate(
Operator::I64Or => ctx.i64_or(),
Operator::I64Xor => ctx.i64_xor(),
Operator::I64Mul => ctx.i64_mul(),
Operator::I64Clz => ctx.i64_clz(),
Operator::I64Ctz => ctx.i64_ctz(),
Operator::I64Popcnt => ctx.i64_popcnt(),
Operator::Drop => ctx.drop(),
Operator::SetLocal { local_index } => ctx.set_local(local_index),
Operator::GetLocal { local_index } => ctx.get_local(local_index),