diff options
| author | Admiral H. Curtiss <pikachu025@gmail.com> | 2022-11-04 23:13:09 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-11-04 23:13:09 +0100 |
| commit | 8b4e315fb7e001501735fe41f1fa46d0cede4733 (patch) | |
| tree | 8a4284394a0ee1810efb19ce15d1c7b84aa8bc14 /Source/Core/Common | |
| parent | c2e6d85ba7477c34cd3e65e3c45bad8f9d322c7b (diff) | |
| parent | d0de68c41bb7d1676ae99cf750cb1bbabb7317a1 (diff) | |
Merge pull request #11242 from Sintendo/arm64cmp
JitArm64: Optimize cmp
Diffstat (limited to 'Source/Core/Common')
| -rw-r--r-- | Source/Core/Common/Arm64Emitter.h | 33 |
1 files changed, 21 insertions, 12 deletions
diff --git a/Source/Core/Common/Arm64Emitter.h b/Source/Core/Common/Arm64Emitter.h index caf997a29d..19d63a8dae 100644 --- a/Source/Core/Common/Arm64Emitter.h +++ b/Source/Core/Common/Arm64Emitter.h @@ -309,6 +309,18 @@ enum class ShiftType ROR = 3, }; +enum class ExtendSpecifier +{ + UXTB = 0x0, + UXTH = 0x1, + UXTW = 0x2, /* Also LSL on 32bit width */ + UXTX = 0x3, /* Also LSL on 64bit width */ + SXTB = 0x4, + SXTH = 0x5, + SXTW = 0x6, + SXTX = 0x7, +}; + enum class IndexType { Unsigned, @@ -405,18 +417,6 @@ private: Width64Bit, }; - enum class ExtendSpecifier - { - UXTB = 0x0, - UXTH = 0x1, - UXTW = 0x2, /* Also LSL on 32bit width */ - UXTX = 0x3, /* Also LSL on 64bit width */ - SXTB = 0x4, - SXTH = 0x5, - SXTW = 0x6, - SXTX = 0x7, - }; - enum class TypeSpecifier { ExtendedReg, @@ -463,6 +463,15 @@ public: } m_shifttype = ShiftType::LSL; } + ArithOption(ARM64Reg Rd, ExtendSpecifier extend_type, u32 shift = 0) + { + m_destReg = Rd; + m_width = Is64Bit(Rd) ? WidthSpecifier::Width64Bit : WidthSpecifier::Width32Bit; + m_extend = extend_type; + m_type = TypeSpecifier::ExtendedReg; + m_shifttype = ShiftType::LSL; + m_shift = shift; + } ArithOption(ARM64Reg Rd, ShiftType shift_type, u32 shift) { m_destReg = Rd; |
