Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Jul 4, 2025. It is now read-only.

fix: correct RAM usage #2019

Merged
merged 2 commits into from
Feb 26, 2025
Merged

fix: correct RAM usage #2019

merged 2 commits into from
Feb 26, 2025

Conversation

vansangpfiev
Copy link
Contributor

@vansangpfiev vansangpfiev commented Feb 24, 2025

Describe Your Changes

This pull request includes changes to the GetMemoryInfo function in the engine/utils/hardware/ram_info.h file to improve the accuracy of memory information retrieval on macOS systems. The changes focus on replacing the calculation of used memory with available memory.

Changes to memory information retrieval:

  • Replaced the variable used_memory with avail_memory to calculate available memory instead of used memory.
  • Updated the calculation of available memory to include free_count and inactive_count instead of active_count, inactive_count, and wire_count.
  • Modified the return statement to reflect the new available memory calculation.

Fixes Issues

Self Checklist

  • Added relevant comments, esp in complex areas
  • Updated docs (for bug fixes / features)
  • Created issues for follow-up changes or refactoring needed

@vansangpfiev vansangpfiev marked this pull request as ready for review February 26, 2025 02:27
@vansangpfiev vansangpfiev merged commit ca2327a into dev Feb 26, 2025
16 checks passed
@vansangpfiev vansangpfiev deleted the s/fix/ram-macos branch February 26, 2025 06:49
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants