void Jit::CompFPComp(int lhs, int rhs, u8 compare, bool allowNaN) { gpr.MapReg(MIPS_REG_FPCOND, false, true); MOVSS(XMM0, fpr.R(lhs)); CMPSS(XMM0, fpr.R(rhs), compare); MOVD_xmm(gpr.R(MIPS_REG_FPCOND), XMM0); // This means that NaN also means true, e.g. !<> or !>, etc. if (allowNaN) { MOVSS(XMM0, fpr.R(lhs)); CMPUNORDSS(XMM0, fpr.R(rhs)); MOVD_xmm(R(EAX), XMM0); OR(32, gpr.R(MIPS_REG_FPCOND), R(EAX)); } }
void Jit::CompFPComp(int lhs, int rhs, u8 compare, bool allowNaN) { MOVSS(XMM0, fpr.R(lhs)); CMPSS(XMM0, fpr.R(rhs), compare); MOVSS(M(¤tMIPS->fpcond), XMM0); // This means that NaN also means true, e.g. !<> or !>, etc. if (allowNaN) { MOVSS(XMM0, fpr.R(lhs)); CMPUNORDSS(XMM0, fpr.R(rhs)); MOVSS(M(&ssCompareTemp), XMM0); MOV(32, R(EAX), M(&ssCompareTemp)); OR(32, M(¤tMIPS->fpcond), R(EAX)); } }
void Jit::CompFPComp(int lhs, int rhs, u8 compare, bool allowNaN) { gpr.MapReg(MIPS_REG_FPCOND, false, true); // This means that NaN also means true, e.g. !<> or !>, etc. if (allowNaN) { CopyFPReg(XMM0, fpr.R(lhs)); CopyFPReg(XMM1, fpr.R(lhs)); CMPSS(XMM0, fpr.R(rhs), compare); CMPUNORDSS(XMM1, fpr.R(rhs)); POR(XMM0, R(XMM1)); } else { CopyFPReg(XMM0, fpr.R(lhs)); CMPSS(XMM0, fpr.R(rhs), compare); } MOVD_xmm(gpr.R(MIPS_REG_FPCOND), XMM0); }