Added support for CMP_APPROX to EQV_R and moved the code to a template.
This commit is contained in:
parent
99849bc0c5
commit
5375a99cf6
2 changed files with 49 additions and 52 deletions
|
|
@ -1219,27 +1219,7 @@ void JitCompiler::EmitLENV2()
|
|||
void JitCompiler::EmitEQV2_R()
|
||||
{
|
||||
EmitComparisonOpcode([&](bool check, asmjit::Label& fail, asmjit::Label& success) {
|
||||
if (static_cast<bool>(A & CMP_APPROX)) I_FatalError("CMP_APPROX not implemented for EQV2_R.\n");
|
||||
|
||||
cc.ucomisd(regF[B], regF[C]);
|
||||
if (check) {
|
||||
cc.jp(success);
|
||||
cc.jne(success);
|
||||
}
|
||||
else {
|
||||
cc.jp(fail);
|
||||
cc.jne(fail);
|
||||
}
|
||||
|
||||
cc.ucomisd(regF[B + 1], regF[C + 1]);
|
||||
if (check) {
|
||||
cc.jp(success);
|
||||
cc.je(fail);
|
||||
}
|
||||
else {
|
||||
cc.jp(fail);
|
||||
cc.jne(fail);
|
||||
}
|
||||
EmitVectorComparison<2> (check, fail, success);
|
||||
});
|
||||
}
|
||||
|
||||
|
|
@ -1406,37 +1386,7 @@ void JitCompiler::EmitLENV3()
|
|||
void JitCompiler::EmitEQV3_R()
|
||||
{
|
||||
EmitComparisonOpcode([&](bool check, asmjit::Label& fail, asmjit::Label& success) {
|
||||
if (static_cast<bool>(A & CMP_APPROX)) I_FatalError("CMP_APPROX not implemented for EQV3_R.\n");
|
||||
|
||||
cc.ucomisd(regF[B], regF[C]);
|
||||
if (check) {
|
||||
cc.jp(success);
|
||||
cc.jne(success);
|
||||
}
|
||||
else {
|
||||
cc.jp(fail);
|
||||
cc.jne(fail);
|
||||
}
|
||||
|
||||
cc.ucomisd(regF[B + 1], regF[C + 1]);
|
||||
if (check) {
|
||||
cc.jp(success);
|
||||
cc.jne(success);
|
||||
}
|
||||
else {
|
||||
cc.jp(fail);
|
||||
cc.jne(fail);
|
||||
}
|
||||
|
||||
cc.ucomisd(regF[B + 2], regF[C + 2]);
|
||||
if (check) {
|
||||
cc.jp(success);
|
||||
cc.je(fail);
|
||||
}
|
||||
else {
|
||||
cc.jp(fail);
|
||||
cc.jne(fail);
|
||||
}
|
||||
EmitVectorComparison<3> (check, fail, success);
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue