Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Negative values fix #57

Merged
merged 6 commits into from
Jan 22, 2024
Merged

Conversation

kifetew
Copy link
Contributor

@kifetew kifetew commented Jan 17, 2024

changes related to negative values

@adelnoureddine
Copy link
Member

Thanks a lot @kifetew. I"ll check your proposed modification in the coming days on Linux and RPi, and merge after that if all goes well.

@adelnoureddine adelnoureddine self-assigned this Jan 18, 2024
@adelnoureddine adelnoureddine linked an issue Jan 18, 2024 that may be closed by this pull request
@@ -247,47 +258,91 @@ private Map<Thread, Map<CallTree, Integer>> extractCallTreesStats(Map<Thread, Li
return stats;
}

// /**
// * Updates the CPU times for each Thread.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rather not comment existing methods, but modify them (or remove), as it's easier to see the changes with your commit

* @param totalThreadsCpuTime the CPU time used by all the monitored threads
* @param processEnergy the energy consumed by the process
* @return for each PID, the percentage of CPU time used by the associated thread
*
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add a description of the method in the javadoc? As you merged two methods together, you can just reuse both descriptions into one.

@adelnoureddine
Copy link
Member

Thanks @kifetew, I'll merge your PR.

@adelnoureddine adelnoureddine merged commit 5441c26 into joular:develop Jan 22, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Negative consumption values reported
2 participants