I64Extend16S should operate on 16 bits, not 8.

This showed up in clippy warnings as the code for this case was
the same as for `I64Extend8S`.
This commit is contained in:
Bruce Mitchener
2018-03-05 20:23:50 +07:00
committed by Dan Gohman
parent 13b167770c
commit d2d02565fb

View File

@@ -654,7 +654,7 @@ pub fn translate_operator<FE: FuncEnvironment + ?Sized>(
}
Operator::I64Extend16S => {
let val = state.pop1();
state.push1(builder.ins().ireduce(I8, val));
state.push1(builder.ins().ireduce(I16, val));
let val = state.pop1();
state.push1(builder.ins().sextend(I64, val));
}