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

fix: correct Linux cpu usage #2039

Merged
merged 2 commits into from
Feb 27, 2025
Merged

fix: correct Linux cpu usage #2039

merged 2 commits into from
Feb 27, 2025

Conversation

vansangpfiev
Copy link
Contributor

Describe Your Changes

This pull request includes significant updates to the hardware service and CPU information handling. The main changes involve refactoring the CPU information retrieval, removing redundant code, and updating the hardware service to use the new CPU information structure.

Refactoring and Code Simplification:

  • engine/utils/hardware/cpu_info.h: Refactored the GetCPUUsage function to handle CPU usage calculation for different operating systems within the CpuInfo struct. Added new methods and members to the CpuInfo struct to support this functionality.

  • engine/utils/hardware/cpu_usage.h: Removed the entire file as its functionality has been integrated into cpu_info.h.

Hardware Service Updates:

Miscellaneous:

Fixes Issues

  • Closes #
  • Closes #

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 27, 2025 03:29
@vansangpfiev vansangpfiev merged commit 2691939 into dev Feb 27, 2025
16 checks passed
@vansangpfiev vansangpfiev deleted the s/fix/linux-cpu-usage branch February 27, 2025 05:03
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