Getting Started with MemReplay

Overview

This article will explain how to collect memory information from a running CRYENGINE game.

Offline Recording of Memory Information

Make sure you are using a Profile build. Debug builds don't always redefine new/malloc.

Run the game with -memreplay in your arguments list.

MemReplay is now tracking every allocation/free call and streams it into a memlog-date-time.zmrl file. See table below for file location (depending on platform type):

Platform

Folder

PC

<root>\bin\<build folder>, e.g. win_x64

Xbox One

Game root on console

PS4

Data folder on console

MemReplay can be stopped manually by calling the console command memReplayStop. This will flush the remaining information to the disc.

Do not use the console command memReplayResume as a replacement for argument -memreplay or after memReplayStop has been called.

Offline Recording on Xbox One

The Xbox One platform requires some extra steps to get a valid call stack:

  1. Call memReplayStop via console.
  2. Go to the debugger and save a core dump (without heap) - *.dmp file.
  3. Make sure you have the dump file and the zmrl file available locally.
  4. Open MemReplay and load the zmrl file.
  5. MemReplay asks you to locate the dump file.