aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/hw/lcd.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/hw/lcd.cpp')
-rw-r--r--src/core/hw/lcd.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/core/hw/lcd.cpp b/src/core/hw/lcd.cpp
index 963c8d98..6f93709e 100644
--- a/src/core/hw/lcd.cpp
+++ b/src/core/hw/lcd.cpp
@@ -7,11 +7,12 @@
#include "common/common_types.h"
#include "common/logging/log.h"
-#include "core/arm/arm_interface.h"
-#include "core/hle/hle.h"
#include "core/hw/hw.h"
#include "core/hw/lcd.h"
+#include "core/tracer/recorder.h"
+#include "video_core/debug_utils/debug_utils.h"
+
namespace LCD {
Regs g_regs;
@@ -42,6 +43,13 @@ inline void Write(u32 addr, const T data) {
}
g_regs[index] = static_cast<u32>(data);
+
+ // Notify tracer about the register write
+ // This is happening *after* handling the write to make sure we properly catch all memory reads.
+ if (Pica::g_debug_context && Pica::g_debug_context->recorder) {
+ // addr + GPU VBase - IO VBase + IO PBase
+ Pica::g_debug_context->recorder->RegisterWritten<T>(addr + HW::VADDR_LCD - 0x1EC00000 + 0x10100000, data);
+ }
}
// Explicitly instantiate template functions because we aren't defining this in the header: