summaryrefslogtreecommitdiffstats
path: root/src/core
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2015-05-31 11:48:00 +0200
committerLioncash <mathew1800@gmail.com>2015-06-01 03:51:46 +0200
commitc00781a908c9198c16bbbb06661ba162b48d81d5 (patch)
treed0e61e7c3f96eb5e2aea10a2d787ebcc67b13c1b /src/core
parentarm_dyncom_thumb: Implement CPS and SETEND (diff)
downloadyuzu-c00781a908c9198c16bbbb06661ba162b48d81d5.tar
yuzu-c00781a908c9198c16bbbb06661ba162b48d81d5.tar.gz
yuzu-c00781a908c9198c16bbbb06661ba162b48d81d5.tar.bz2
yuzu-c00781a908c9198c16bbbb06661ba162b48d81d5.tar.lz
yuzu-c00781a908c9198c16bbbb06661ba162b48d81d5.tar.xz
yuzu-c00781a908c9198c16bbbb06661ba162b48d81d5.tar.zst
yuzu-c00781a908c9198c16bbbb06661ba162b48d81d5.zip
Diffstat (limited to 'src/core')
-rw-r--r--src/core/arm/dyncom/arm_dyncom_thumb.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/core/arm/dyncom/arm_dyncom_thumb.cpp b/src/core/arm/dyncom/arm_dyncom_thumb.cpp
index 897bb0460..83b532aac 100644
--- a/src/core/arm/dyncom/arm_dyncom_thumb.cpp
+++ b/src/core/arm/dyncom/arm_dyncom_thumb.cpp
@@ -275,7 +275,10 @@ tdstate thumb_translate(u32 addr, u32 instr, u32* ainstr, u32* inst_size) {
: 0xE28DDF00) // ADD
|(tinstr & 0x007F); // off7
} else if ((tinstr & 0x0F00) == 0x0e00) {
- *ainstr = 0xEF000000 | 0x180000; // base | BKPT mask
+ // BKPT
+ *ainstr = 0xEF000000 // base
+ | BITS(tinstr, 0, 3) // imm4 field;
+ | (BITS(tinstr, 4, 7) << 8); // beginning 4 bits of imm12
} else if ((tinstr & 0x0F00) == 0x0200) {
static const ARMword subset[4] = {
0xE6BF0070, // SXTH