Skip to content

Investigate insufficient memory cleanups on level unload #646

Open
@xezon

Description

@xezon

As seen in GameLogic::reset, the m_objVector does not shrink on level unload.

	m_objVector.clear();
	m_objVector.resize(OBJ_HASH_SIZE, NULL); // 8192

I expect it is not intended to not shrink memory back to initial levels on reset. It means that the maximum memory allocated from a long match session will carry over to all subsequent match sessions.

In case of m_objVector we are looking at 400+ kb memory savings per 1 hour match or so.

This is probably a general issue across many classes and should be optimized.

Metadata

Metadata

Assignees

No one assigned

    Labels

    InvestigateMemoryIs memory relatedMinorSeverity: Minor < Major < Critical < Blocker

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions