From bff6e0d2778d1dde100ff5f4703d446920b9f05d Mon Sep 17 00:00:00 2001 From: kd-11 Date: Tue, 11 Jul 2023 03:34:45 +0300 Subject: [PATCH] rsx: Don't assert when surface and texture cache overlap lockable memory - It's not a serious enough problem and the root cause is understood. --- rpcs3/Emu/RSX/Common/texture_cache.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/rpcs3/Emu/RSX/Common/texture_cache.h b/rpcs3/Emu/RSX/Common/texture_cache.h index 664eb65d1a..7c92dffc8d 100644 --- a/rpcs3/Emu/RSX/Common/texture_cache.h +++ b/rpcs3/Emu/RSX/Common/texture_cache.h @@ -3264,7 +3264,13 @@ namespace rsx else { // Unlikely situation, but the only one which would allow re-upload from CPU to overlap this section. - ensure(!found->is_flushable()); + if (found->is_flushable()) + { + // Technically this is possible in games that may change surface pitch at random (insomniac engine) + // FIXME: A proper fix includes pitch conversion and surface inheritance chains between surface targets and blit targets (unified cache) which is a very long-term thing. + const auto range = found->get_section_range(); + rsx_log.error("[Pitch Mismatch] GPU-resident data at 0x%x->0x%x is discarded due to surface cache data clobbering it.", range.start, range.end); + } found->discard(true); } }