diff options
| author | Michael Gielda <mgielda@antmicro.com> | 2021-09-15 01:47:10 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-09-15 01:47:10 +0200 |
| commit | fb2e61a435f6a9d2201d521df47c9bfd12031df3 (patch) | |
| tree | b31f1d5b1d262ce9bfae673afc621dc34a402178 /Ryujinx.Tests.Unicorn/libs/linux | |
| parent | 5d08e9b495a2315e8a4758a8123466665085d044 (diff) | |
Add Linux Unicorn patch + desc. (#2609)
Diffstat (limited to 'Ryujinx.Tests.Unicorn/libs/linux')
| -rw-r--r-- | Ryujinx.Tests.Unicorn/libs/linux/unicorn_fspcr.patch | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/Ryujinx.Tests.Unicorn/libs/linux/unicorn_fspcr.patch b/Ryujinx.Tests.Unicorn/libs/linux/unicorn_fspcr.patch new file mode 100644 index 00000000..391c2fb6 --- /dev/null +++ b/Ryujinx.Tests.Unicorn/libs/linux/unicorn_fspcr.patch @@ -0,0 +1,24 @@ +diff --git a/qemu/target-arm/unicorn_arm.c b/qemu/target-arm/unicorn_arm.c +index 5ff9ebb..d4953f4 100644 +--- a/qemu/target-arm/unicorn_arm.c ++++ b/qemu/target-arm/unicorn_arm.c +@@ -101,6 +101,9 @@ int arm_reg_read(struct uc_struct *uc, unsigned int *regs, void **vals, int coun + case UC_ARM_REG_FPEXC: + *(int32_t *)value = ARM_CPU(uc, mycpu)->env.vfp.xregs[ARM_VFP_FPEXC]; + break; ++ case UC_ARM_REG_FPSCR: ++ *(int32_t *)value = vfp_get_fpscr(&ARM_CPU(uc, mycpu)->env); ++ break; + case UC_ARM_REG_IPSR: + *(uint32_t *)value = xpsr_read(&ARM_CPU(uc, mycpu)->env) & 0x1ff; + break; +@@ -175,6 +178,9 @@ int arm_reg_write(struct uc_struct *uc, unsigned int *regs, void* const* vals, i + case UC_ARM_REG_FPEXC: + ARM_CPU(uc, mycpu)->env.vfp.xregs[ARM_VFP_FPEXC] = *(int32_t *)value; + break; ++ case UC_ARM_REG_FPSCR: ++ vfp_set_fpscr(&ARM_CPU(uc, mycpu)->env, *(uint32_t *)value); ++ break; + case UC_ARM_REG_IPSR: + xpsr_write(&ARM_CPU(uc, mycpu)->env, *(uint32_t *)value, 0x1ff); + break; |
