From f48b6345f2eed6c4ac4fe6547f812c45ec5ef54d Mon Sep 17 00:00:00 2001 From: Matt Borgerson Date: Fri, 21 Sep 2018 01:27:20 -0700 Subject: [PATCH] haxm: Skip unconditional marking of pages as dirty Marking all pages as always dirty has some really bad consequences for the current NV2A emulation. The lesser of two evils for now is to leave the pages as-is. Eventually this will be replaced by proper dirty page tracking once HAXM supports it. --- target/i386/hax-mem.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/target/i386/hax-mem.c b/target/i386/hax-mem.c index 87bdbfd6b8..504b2563b5 100644 --- a/target/i386/hax-mem.c +++ b/target/i386/hax-mem.c @@ -281,7 +281,14 @@ static void hax_log_sync(MemoryListener *listener, return; } +#ifndef XBOX + /* FIXME: Marking all pages as always dirty has some really bad consequences + * for the current NV2A emulation. The lesser of two evils for now is to + * leave the pages as-is. Eventually this will be replaced by proper dirty + * page tracking once HAXM supports it. + */ memory_region_set_dirty(mr, 0, int128_get64(section->size)); +#endif } static MemoryListener hax_memory_listener = {