Commit bf6ae338 authored by balazs.kilvady's avatar balazs.kilvady Committed by Commit bot

MIPS: Fix 'Fix Turbofan: Modify WASM linkage to store floats using only 4 bytes.'

Port b9ded4ce

BUG=
TEST=cctest/test-run-native-calls/Float32Select_stack_params_return_reg,
cctest/test-run-native-calls/MixedParams_2, cctest/test-run-native-calls/MixedParams_3

Review-Url: https://codereview.chromium.org/2043743005
Cr-Commit-Position: refs/heads/master@{#36833}
parent ed90142f
......@@ -1893,7 +1893,13 @@ void CodeGenerator::AssembleMove(InstructionOperand* source,
DCHECK(destination->IsFPRegister() || destination->IsFPStackSlot());
MemOperand src = g.ToMemOperand(source);
if (destination->IsFPRegister()) {
__ ldc1(g.ToDoubleRegister(destination), src);
LocationOperand* op = LocationOperand::cast(source);
if (op->representation() == MachineRepresentation::kFloat64) {
__ ldc1(g.ToDoubleRegister(destination), src);
} else {
DCHECK_EQ(MachineRepresentation::kFloat32, op->representation());
__ lwc1(g.ToDoubleRegister(destination), src);
}
} else {
FPURegister temp = kScratchDoubleReg;
__ ldc1(temp, src);
......
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