From: negativeExponent Date: Sun, 10 May 2020 06:38:56 +0000 (+0800) Subject: More core option fixes X-Git-Tag: r24l~646^2 X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ec253988202457b6aa5de5272b4f980d4219bed9;p=pcsx_rearmed.git More core option fixes - This PR fixes core options and moves them to the related dynarec modes where they are implemented. LIGHTREC = relates to platforms that supports the new Lightrec mode NEW_DYNAREC = relates to previous dynarec implementation that is still used for some 32bit devices - Dynarec Recompiler core option, both dynarec implementation can be enabled or disabled --- diff --git a/frontend/libretro.c b/frontend/libretro.c index cfcb7608..89946f3a 100644 --- a/frontend/libretro.c +++ b/frontend/libretro.c @@ -574,7 +574,7 @@ static int controller_port_variable(unsigned port, struct retro_variable *var) break; } - return environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, var) || var->value; + return environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, var) && var->value; } static void update_controller_port_variable(unsigned port) @@ -1777,7 +1777,7 @@ static void update_variables(bool in_flight) display_internal_fps = true; } -#ifndef DRC_DISABLE +#if defined(LIGHTREC) || defined(NEW_DYNAREC) var.value = NULL; var.key = "pcsx_rearmed_drc"; @@ -1807,7 +1807,7 @@ static void update_variables(bool in_flight) psxCpu->Reset(); // not really a reset.. } } -#endif +#endif /* LIGHTREC || NEW_DYNAREC */ var.value = NULL; var.key = "pcsx_rearmed_spu_reverb"; @@ -1910,7 +1910,7 @@ static void update_variables(bool in_flight) Config.SpuIrq = 1; } -#ifndef DRC_DISABLE +#ifdef NEW_DYNAREC var.value = NULL; var.key = "pcsx_rearmed_nosmccheck"; if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value) @@ -1940,7 +1940,7 @@ static void update_variables(bool in_flight) else new_dynarec_hacks &= ~NDHACK_GTE_NO_FLAGS; } -#endif +#endif /* NEW_DYNAREC */ #ifdef GPU_PEOPS var.value = NULL; @@ -2224,7 +2224,7 @@ static void update_variables(bool in_flight) } } -#if defined(LIGHTREC) || defined(NEW_DYNAREC) +#ifdef NEW_DYNAREC var.value = NULL; var.key = "pcsx_rearmed_psxclock"; if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value) diff --git a/frontend/libretro_core_options.h b/frontend/libretro_core_options.h index ea5577b0..2c694468 100644 --- a/frontend/libretro_core_options.h +++ b/frontend/libretro_core_options.h @@ -548,7 +548,7 @@ struct retro_core_option_definition option_defs_us[] = { #endif }, -#ifndef DRC_DISABLE +#if defined(LIGHTREC) || defined(NEW_DYNAREC) { "pcsx_rearmed_drc", "Dynamic Recompiler", @@ -560,6 +560,9 @@ struct retro_core_option_definition option_defs_us[] = { }, "enabled", }, +#endif /* LIGHTREC || NEW_DYNAREC */ + +#ifdef NEW_DYNAREC { "pcsx_rearmed_psxclock", "PSX CPU Clock", @@ -648,7 +651,7 @@ struct retro_core_option_definition option_defs_us[] = { "57", #endif }, -#endif /* DRC_DISABLE */ +#endif /* NEW_DYNAREC */ #ifdef GPU_NEON { @@ -1009,7 +1012,7 @@ struct retro_core_option_definition option_defs_us[] = { "disabled", }, -#ifndef DRC_DISABLE +#ifdef NEW_DYNAREC { "pcsx_rearmed_nosmccheck", "(Speed Hack) Disable SMC Checks", @@ -1043,7 +1046,7 @@ struct retro_core_option_definition option_defs_us[] = { }, "disabled", }, -#endif /* DRC_DISABLE */ +#endif /* NEW_DYNAREC */ { NULL, NULL, NULL, {{0}}, NULL }, }; diff --git a/frontend/libretro_core_options_intl.h b/frontend/libretro_core_options_intl.h index 16c40a08..107cd571 100644 --- a/frontend/libretro_core_options_intl.h +++ b/frontend/libretro_core_options_intl.h @@ -285,7 +285,7 @@ struct retro_core_option_definition option_defs_tr[] = { NULL }, -#ifndef DRC_DISABLE +#ifdef NEW_DYNAREC { "pcsx_rearmed_drc", "Dinamik Yeniden Derleyici", @@ -308,7 +308,7 @@ struct retro_core_option_definition option_defs_tr[] = { }, NULL }, -#endif /* DRC_DISABLE */ +#endif /* NEW_DYNAREC */ #ifdef __ARM_NEON__ { @@ -360,7 +360,7 @@ struct retro_core_option_definition option_defs_tr[] = { }, /* GPU PEOPS OPTIONS */ -#ifdef DRC_DISABLE +#ifdef GPU_PEOPS { "pcsx_rearmed_show_gpu_peops_settings", "Gelişmiş GPU Ayarlarını Göster", @@ -451,7 +451,7 @@ struct retro_core_option_definition option_defs_tr[] = { }, NULL }, -#endif +#endif /* GPU_PEOPS */ { "pcsx_rearmed_show_bios_bootlogo", @@ -528,7 +528,7 @@ struct retro_core_option_definition option_defs_tr[] = { NULL }, -#ifndef DRC_DISABLE +#ifdef NEW_DYNAREC { "pcsx_rearmed_nosmccheck", "(Speed Hack) SMC Kontrollerini Devre Dışı Bırak", @@ -556,7 +556,7 @@ struct retro_core_option_definition option_defs_tr[] = { }, NULL }, -#endif /* DRC_DISABLE */ +#endif /* NEW_DYNAREC */ { NULL, NULL, NULL, {{0}}, NULL }, }; diff --git a/libpcsxcore/new_dynarec/new_dynarec.h b/libpcsxcore/new_dynarec/new_dynarec.h index e7eb247d..d196f592 100644 --- a/libpcsxcore/new_dynarec/new_dynarec.h +++ b/libpcsxcore/new_dynarec/new_dynarec.h @@ -1,4 +1,4 @@ -#define NEW_DYNAREC 1 +/* #define NEW_DYNAREC 1 */ extern int pcaddr; extern int pending_exception;