Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-100382

DEV - Pathfinding Memory Leak

    XMLWordPrintable

    Details

    • Confirmation Status:
      Unconfirmed

      Description

      We have identified a memory leak in Minecraft's Pathfinding System.
      In MCP Naming, the NodeProcessor class (PathfinderAbstract in mc-dev naming) is the culprit.

      First parameter is IBlockAccess, which is set by the first method in the class. This parameter is set to an instance of a Chunk Cache.

      However, the 2nd method called postProcess in MCP, never cleans up this reference.

      This causes an Entity's Pathfinding instances to hold onto a reference of a ChunkCache.

      This ChunkCache then holds references to many Chunks, even after they unload.

      These unloaded chunks then hold references to other leaked Entity objects, who also have references to Pathfinders...

      This leaks to potential to create a chain of leaked objects.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              aikar Aikar
            • Votes:
              6 Vote for this issue
              Watchers:
              15 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: