void LIRGeneratorARM::visitCopySign(MCopySign* ins) { MDefinition* lhs = ins->lhs(); MDefinition* rhs = ins->rhs(); MOZ_ASSERT(IsFloatingPointType(lhs->type())); MOZ_ASSERT(lhs->type() == rhs->type()); MOZ_ASSERT(lhs->type() == ins->type()); LInstructionHelper<1, 2, 2>* lir; if (lhs->type() == MIRType::Double) lir = new(alloc()) LCopySignD(); else lir = new(alloc()) LCopySignF(); lir->setTemp(0, temp()); lir->setTemp(1, temp()); lowerForFPU(lir, ins, lhs, rhs); }
void LIRGenerator::visitCopySign(MCopySign* ins) { MDefinition* lhs = ins->lhs(); MDefinition* rhs = ins->rhs(); MOZ_ASSERT(IsFloatingPointType(lhs->type())); MOZ_ASSERT(lhs->type() == rhs->type()); MOZ_ASSERT(lhs->type() == ins->type()); LInstructionHelper<1, 2, 2>* lir; if (lhs->type() == MIRType::Double) { lir = new (alloc()) LCopySignD(); } else { lir = new (alloc()) LCopySignF(); } lir->setTemp(0, temp()); lir->setTemp(1, temp()); lir->setOperand(0, useRegisterAtStart(lhs)); lir->setOperand(1, useRegister(rhs)); defineReuseInput(lir, ins, 0); }