mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Fix: Add cmpPtr(Address, Imm32) on x86/x64.(no bug, r=red-no-arm)
This commit is contained in:
parent
81d5c6440b
commit
e021b7c7f8
@ -1832,6 +1832,7 @@ MacroAssemblerARMCompat::storePtr(const Register &src, const AbsoluteAddress &de
|
||||
void
|
||||
MacroAssemblerARMCompat::cmp32(const Register &lhs, const Imm32 &rhs)
|
||||
{
|
||||
JS_ASSERT(lhs != ScratchRegister);
|
||||
ma_cmp(lhs, rhs);
|
||||
}
|
||||
|
||||
@ -1844,6 +1845,7 @@ MacroAssemblerARMCompat::cmp32(const Register &lhs, const Register &rhs)
|
||||
void
|
||||
MacroAssemblerARMCompat::cmpPtr(const Register &lhs, const ImmWord &rhs)
|
||||
{
|
||||
JS_ASSERT(lhs != ScratchRegister);
|
||||
ma_cmp(lhs, Imm32(rhs.value));
|
||||
}
|
||||
|
||||
@ -1863,8 +1865,8 @@ MacroAssemblerARMCompat::cmpPtr(const Address &lhs, const Register &rhs)
|
||||
void
|
||||
MacroAssemblerARMCompat::cmpPtr(const Address &lhs, const ImmWord &rhs)
|
||||
{
|
||||
loadPtr(lhs, ScratchRegister);
|
||||
ma_cmp(ScratchRegister, Imm32(rhs.value));
|
||||
loadPtr(lhs, lr);
|
||||
ma_cmp(lr, Imm32(rhs.value));
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -326,6 +326,9 @@ class MacroAssemblerX64 : public MacroAssemblerX86Shared
|
||||
void cmpPtr(const Address &lhs, const ImmGCPtr rhs) {
|
||||
cmpPtr(Operand(lhs), rhs);
|
||||
}
|
||||
void cmpPtr(const Address &lhs, const ImmWord rhs) {
|
||||
cmpPtr(Operand(lhs), rhs);
|
||||
}
|
||||
void cmpPtr(const Operand &lhs, const Register &rhs) {
|
||||
cmpq(lhs, rhs);
|
||||
}
|
||||
|
@ -373,6 +373,9 @@ class MacroAssemblerX86 : public MacroAssemblerX86Shared
|
||||
void cmpPtr(const Address &lhs, const Register &rhs) {
|
||||
cmpl(Operand(lhs), rhs);
|
||||
}
|
||||
void cmpPtr(const Address &lhs, const ImmWord rhs) {
|
||||
cmpl(Operand(lhs), rhs);
|
||||
}
|
||||
void testPtr(const Register &lhs, const Register &rhs) {
|
||||
return testl(lhs, rhs);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user