mirror of
https://github.com/fluencelabs/wasmer
synced 2024-12-04 18:10:18 +00:00
Garbage in upper 32 bits shouldn't propagate to I64ExtendI32U's result.
This commit is contained in:
parent
77de93ec0e
commit
51e085a7ba
@ -4043,6 +4043,7 @@ impl FunctionCodeGenerator<CodegenError> for X64FunctionCode {
|
||||
false,
|
||||
)[0];
|
||||
self.value_stack.push(ret);
|
||||
|
||||
Self::emit_relaxed_binop(
|
||||
a,
|
||||
&mut self.machine,
|
||||
@ -4051,6 +4052,16 @@ impl FunctionCodeGenerator<CodegenError> for X64FunctionCode {
|
||||
loc,
|
||||
ret,
|
||||
);
|
||||
if let Location::Memory(base, off) = ret {
|
||||
Self::emit_relaxed_binop(
|
||||
a,
|
||||
&mut self.machine,
|
||||
Assembler::emit_mov,
|
||||
Size::S32,
|
||||
Location::Imm32(0),
|
||||
Location::Memory(base, off + 4),
|
||||
);
|
||||
}
|
||||
}
|
||||
Operator::I64ExtendI32S => {
|
||||
let loc =
|
||||
|
Loading…
Reference in New Issue
Block a user