commit d7601d1e5583c8ab48bfa8f91596e3ab10be1bce
parent efdc0184057376e8494dbc53cc6b17b6adb7ffbb
Author: André Bargull <andre.bargull@gmail.com>
Date: Mon, 20 Oct 2025 08:20:23 +0000
Bug 1993951 - Part 5: Use dins for copySignDouble on mips64. r=spidermonkey-reviewers,iain
The `mfch1` instruction is only needed for mips32. On mips64 we can directly
use `dins` to write the full register.
Differential Revision: https://phabricator.services.mozilla.com/D268370
Diffstat:
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/js/src/jit/mips-shared/MacroAssembler-mips-shared.cpp b/js/src/jit/mips-shared/MacroAssembler-mips-shared.cpp
@@ -3450,17 +3450,13 @@ void MacroAssembler::copySignDouble(FloatRegister lhs, FloatRegister rhs,
Register lhsi = temps.Acquire();
Register rhsi = temps.Acquire();
- // Manipulate high words of double inputs.
- moveFromDoubleHi(lhs, lhsi);
- moveFromDoubleHi(rhs, rhsi);
+ moveFromDouble(lhs, lhsi);
+ moveFromDouble(rhs, rhsi);
// Combine.
- ma_ins(rhsi, lhsi, 0, 31);
+ ma_dins(rhsi, lhsi, Imm32(0), Imm32(63));
- if (lhs != output) {
- moveDouble(lhs, output);
- }
- moveToDoubleHi(rhsi, output);
+ moveToDouble(rhsi, output);
}
void MacroAssembler::copySignFloat32(FloatRegister lhs, FloatRegister rhs,