diff --git a/CompatBot/EventHandlers/LogParsing/LogParser.LogSections.cs b/CompatBot/EventHandlers/LogParsing/LogParser.LogSections.cs index 1e9a65bf..ca4f4c84 100644 --- a/CompatBot/EventHandlers/LogParsing/LogParser.LogSections.cs +++ b/CompatBot/EventHandlers/LogParsing/LogParser.LogSections.cs @@ -59,6 +59,7 @@ internal partial class LogParser ["Use LLVM CPU:"] = LlvmCpuArch(), ["thread scheduler"] = ThreadSchedulerMode(), ["SPU Decoder:"] = SpuDecoderType(), + ["SPU Reservation Busy Waiting Enabled:"] = SpuEventsBusyLoop(), ["Disable SPU GETLLAR Spin Optimization:"] = DisableSpuGetllarSpinOptimization(), ["secondary cores:"] = SecondaryCores(), //["priority:"] = LowerThreadPriority(), diff --git a/CompatBot/EventHandlers/LogParsing/LogParser.RegexPatterns.cs b/CompatBot/EventHandlers/LogParsing/LogParser.RegexPatterns.cs index f7ad0874..e291bbc4 100644 --- a/CompatBot/EventHandlers/LogParsing/LogParser.RegexPatterns.cs +++ b/CompatBot/EventHandlers/LogParsing/LogParser.RegexPatterns.cs @@ -69,6 +69,8 @@ internal partial class LogParser private static partial Regex ThreadSchedulerMode(); [GeneratedRegex(@"SPU Decoder: (?[^\r\n]*?)\r?$", DefaultOptions)] private static partial Regex SpuDecoderType(); + [GeneratedRegex(@"SPU Reservation Busy Waiting Enabled: (?[^\r\n]*?)\r?$", DefaultOptions)] + private static partial Regex SpuEventsBusyLoop(); [GeneratedRegex(@"Disable SPU GETLLAR Spin Optimization: (?[^\r\n]*?)\r?$", DefaultOptions)] private static partial Regex DisableSpuGetllarSpinOptimization(); [GeneratedRegex(@"secondary cores: (?[^\r\n]*?)\r?$", DefaultOptions)] diff --git a/CompatBot/Utils/ResultFormatters/LogParserResultFormatter.WeirdSettingsSection.cs b/CompatBot/Utils/ResultFormatters/LogParserResultFormatter.WeirdSettingsSection.cs index ca039627..db0bc498 100644 --- a/CompatBot/Utils/ResultFormatters/LogParserResultFormatter.WeirdSettingsSection.cs +++ b/CompatBot/Utils/ResultFormatters/LogParserResultFormatter.WeirdSettingsSection.cs @@ -272,12 +272,14 @@ internal static partial class LogParserResult if (items["spu_decoder"] is string spuDecoder && spuDecoder.Contains("Interpreter", StringComparison.InvariantCultureIgnoreCase)) notes.Add("⚠️ Please set `SPU Decoder` to use recompiler for better performance"); - if (items["accurate_getllar"] == EnabledMark) + if (items["accurate_getllar"] is EnabledMark) notes.Add("ℹ️ `Accurate GETLLAR` is enabled"); - if (items["accurate_putlluc"] == EnabledMark) + if (items["accurate_putlluc"] is EnabledMark) notes.Add("ℹ️ `Accurate PUTLLUC` is enabled"); - if (items["accurate_rsx_reservation"] == EnabledMark) + if (items["accurate_rsx_reservation"] is EnabledMark) notes.Add("ℹ️ `Accurate RSX Reservation Access` is enabled"); + if (items["spu_events_busy_loop"] is EnabledMark && threadCount < 12) + notes.Add("⚠️ `SPU Events Busy Loop` is enabled on a CPU with few threads"); if (KnownGamesThatRequireAccurateXfloat.Contains(serial) && items["xfloat_mode"] is not "Accurate") notes.Add("⚠️ `Accurate xfloat` is required for this game"); @@ -614,7 +616,7 @@ internal static partial class LogParserResult notes.Add("ℹ️ `SPU Thread Count` is best to set to `2`"); } } - if (items["spu_loop_detection"] == EnabledMark) + if (items["spu_loop_detection"] is EnabledMark) notes.Add("ℹ️ If you have distorted audio, try disabling `SPU Loop Detection`"); if (items["frame_limit"] is not null and not "Off") notes.Add("⚠️ `Frame Limiter` is not required, please disable");