aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorneonloop2021-10-10 18:04:20 +0000
committerneonloop2021-10-10 18:04:20 +0000
commit00a12100d3b15a81890fe81ccc71f986ecf30fdd (patch)
tree59240225aeac0e9be300f7530460bc96c8cc92af
parent902d4f9728479e02e1961e119404895ce4cbbbb8 (diff)
downloadpicoarch-00a12100d3b15a81890fe81ccc71f986ecf30fdd.tar.gz
picoarch-00a12100d3b15a81890fe81ccc71f986ecf30fdd.tar.bz2
picoarch-00a12100d3b15a81890fe81ccc71f986ecf30fdd.zip
Updates patches for recent changes
-rw-r--r--patches/gpsp/1000-trimui-build.patch14
-rw-r--r--patches/gpsp/1002-frameskip-changes.patch12
-rw-r--r--patches/pcsx_rearmed/0002-lookup-verify-dirty-literals.patch76
3 files changed, 13 insertions, 89 deletions
diff --git a/patches/gpsp/1000-trimui-build.patch b/patches/gpsp/1000-trimui-build.patch
index b3dd044..2f9e7da 100644
--- a/patches/gpsp/1000-trimui-build.patch
+++ b/patches/gpsp/1000-trimui-build.patch
@@ -1,5 +1,5 @@
diff --git a/Makefile b/Makefile
-index f043a85..b2a5562 100644
+index ecefd12..91fc859 100644
--- a/Makefile
+++ b/Makefile
@@ -451,6 +451,20 @@ else ifeq ($(platform), rs90)
@@ -23,10 +23,10 @@ index f043a85..b2a5562 100644
# Windows
else
TARGET := $(TARGET_NAME)_libretro.dll
-@@ -479,7 +493,14 @@ ifeq ($(DEBUG), 1)
+@@ -477,7 +491,14 @@ endif
+ ifeq ($(DEBUG), 1)
OPTIMIZE := -O0 -g
else
- OPTIMIZE_SAFE := -O2 -DNDEBUG
- OPTIMIZE := -O3 -DNDEBUG
+ OPTIMIZE ?= -O3 -DNDEBUG
+endif
@@ -40,7 +40,7 @@ index f043a85..b2a5562 100644
DEFINES := -DHAVE_STRINGS_H -DHAVE_STDINT_H -DHAVE_INTTYPES_H -D__LIBRETRO__ -DINLINE=inline -Wall
diff --git a/arm/arm_stub.S b/arm/arm_stub.S
-index 4058b22..03e9996 100644
+index cb68726..6593cf2 100644
--- a/arm/arm_stub.S
+++ b/arm/arm_stub.S
@@ -79,8 +79,26 @@ _##symbol:
@@ -71,7 +71,7 @@ index 4058b22..03e9996 100644
@ Will load the register set from memory into the appropriate cached registers.
@ See arm_emit.h for listing explanation.
-@@ -539,7 +557,7 @@ return_to_main:
+@@ -538,7 +556,7 @@ return_to_main:
#define execute_store_builder(store_type, str_op, str_op16, load_op, tnum) ;\
;\
defsymbl(execute_store_u##store_type) ;\
@@ -80,7 +80,7 @@ index 4058b22..03e9996 100644
add r2, r2, #((STORE_TBL_OFF + 16*4*tnum) >> 2) /* add table offset */;\
ldr pc, [reg_base, r2, lsl #2] /* load handler addr */;\
nop ;\
-@@ -628,7 +646,7 @@ execute_store_builder(32, str, str, ldr, 2)
+@@ -627,7 +645,7 @@ execute_store_builder(32, str, str, ldr, 2)
@ This is a store that is executed in a strm case (so no SMC checks in-between)
defsymbl(execute_store_u32_safe)
@@ -89,7 +89,7 @@ index 4058b22..03e9996 100644
add r2, r2, #((STORE_TBL_OFF + 16*4*3) >> 2)
ldr pc, [reg_base, r2, lsl #2]
nop
-@@ -773,9 +791,9 @@ lookup_pc_arm:
+@@ -772,9 +790,9 @@ lookup_pc_arm:
defsymbl(execute_load_##load_type) ;\
.if albits >= 1 ;\
ror r1, r0, #(albits) /* move alignment bits to MSB */;\
diff --git a/patches/gpsp/1002-frameskip-changes.patch b/patches/gpsp/1002-frameskip-changes.patch
index 3444df9..67ca596 100644
--- a/patches/gpsp/1002-frameskip-changes.patch
+++ b/patches/gpsp/1002-frameskip-changes.patch
@@ -1,8 +1,8 @@
-diff --git a/libretro.c b/libretro.c
-index f31235b..241a69e 100644
---- a/libretro.c
-+++ b/libretro.c
-@@ -1099,7 +1099,7 @@ void retro_run(void)
+diff --git a/libretro/libretro.c b/libretro/libretro.c
+index 59c1b33..be1709c 100644
+--- a/libretro/libretro.c
++++ b/libretro/libretro.c
+@@ -1106,7 +1106,7 @@ void retro_run(void)
1 : 0;
if (!skip_next_frame ||
@@ -11,7 +11,7 @@ index f31235b..241a69e 100644
{
skip_next_frame = 0;
frameskip_counter = 0;
-@@ -1116,7 +1116,7 @@ void retro_run(void)
+@@ -1123,7 +1123,7 @@ void retro_run(void)
1 : 0;
if (!skip_next_frame ||
diff --git a/patches/pcsx_rearmed/0002-lookup-verify-dirty-literals.patch b/patches/pcsx_rearmed/0002-lookup-verify-dirty-literals.patch
deleted file mode 100644
index 83746c1..0000000
--- a/patches/pcsx_rearmed/0002-lookup-verify-dirty-literals.patch
+++ /dev/null
@@ -1,76 +0,0 @@
-From f5c6b3357ecbbc35cefa011dc4a8d9f1d23c87ee Mon Sep 17 00:00:00 2001
-From: neonloop
-Date: Fri, 2 Jul 2021 22:23:41 +0000
-Subject: Always look up verify_dirty literals from offsets
-
-Literals are deduplicated, so there's no guarantee they will be stored
-next to each other, even if they're written sequentially. verify_dirty
-and get_bounds must use the offsets on each instruction, instead of
-assuming values are stored sequentially.
----
- libpcsxcore/new_dynarec/arm/assem_arm.c | 38 ++++++++++++++++++++++-----------
- 1 file changed, 26 insertions(+), 12 deletions(-)
-
-diff --git a/libpcsxcore/new_dynarec/arm/assem_arm.c b/libpcsxcore/new_dynarec/arm/assem_arm.c
-index db1d2af..a373bd3 100644
---- a/libpcsxcore/new_dynarec/arm/assem_arm.c
-+++ b/libpcsxcore/new_dynarec/arm/assem_arm.c
-@@ -241,14 +241,21 @@ static u_int get_clean_addr(int addr)
- static int verify_dirty(u_int *ptr)
- {
- #ifndef HAVE_ARMV7
-+ u_int offset;
- // get from literal pool
- assert((*ptr&0xFFFF0000)==0xe59f0000);
-- u_int offset=*ptr&0xfff;
-- u_int *l_ptr=(void *)ptr+offset+8;
-- u_int source=l_ptr[0];
-- u_int copy=l_ptr[1];
-- u_int len=l_ptr[2];
-- ptr+=4;
-+ offset=*ptr&0xfff;
-+ u_int source=*(u_int*)((void *)ptr+offset+8);
-+ ptr++;
-+ assert((*ptr&0xFFFF0000)==0xe59f0000);
-+ offset=*ptr&0xfff;
-+ u_int copy=*(u_int*)((void *)ptr+offset+8);
-+ ptr++;
-+ assert((*ptr&0xFFFF0000)==0xe59f0000);
-+ offset=*ptr&0xfff;
-+ u_int len=*(u_int*)((void *)ptr+offset+8);
-+ ptr++;
-+ ptr++;
- #else
- // ARMv7 movw/movt
- assert((*ptr&0xFFF00000)==0xe3000000);
-@@ -285,14 +292,21 @@ static void get_bounds(int addr,u_int *start,u_int *end)
- {
- u_int *ptr=(u_int *)addr;
- #ifndef HAVE_ARMV7
-+ u_int offset;
- // get from literal pool
- assert((*ptr&0xFFFF0000)==0xe59f0000);
-- u_int offset=*ptr&0xfff;
-- u_int *l_ptr=(void *)ptr+offset+8;
-- u_int source=l_ptr[0];
-- //u_int copy=l_ptr[1];
-- u_int len=l_ptr[2];
-- ptr+=4;
-+ offset=*ptr&0xfff;
-+ u_int source=*(u_int*)((void *)ptr+offset+8);
-+ ptr++;
-+ //assert((*ptr&0xFFFF0000)==0xe59f0000);
-+ //offset=*ptr&0xfff;
-+ //u_int copy=*(u_int*)((void *)ptr+offset+8);
-+ ptr++;
-+ assert((*ptr&0xFFFF0000)==0xe59f0000);
-+ offset=*ptr&0xfff;
-+ u_int len=*(u_int*)((void *)ptr+offset+8);
-+ ptr++;
-+ ptr++;
- #else
- // ARMv7 movw/movt
- assert((*ptr&0xFFF00000)==0xe3000000);
---
-cgit v1.2.3
-