-
Notifications
You must be signed in to change notification settings - Fork 19
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
Add additional metrics for hyperthreaded cores in CpuUsage plugin #248
base: master
Are you sure you want to change the base?
Conversation
This change allows the virtual-to-physical ratio of a hyperthreaded core to be specified in a config file.
src/supremm/summarize.py
Outdated
@@ -47,6 +49,10 @@ def __init__(self, preprocessors, analytics, job, config, fail_fast=False): | |||
self.start = time.time() | |||
self.archives_processed = 0 | |||
self.fail_fast = fail_fast | |||
if resconfig is not None and 'hyperthreaded_ratio' in config._config['resources'][resconfig['name']]: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if resconfig is not None and 'hyperthreaded_ratio' in config._config['resources'][resconfig['name']]: | |
if resconfig is not None and 'hyperthreaded_ratio' in resconfig: |
src/supremm/summarize.py
Outdated
@@ -47,6 +49,10 @@ def __init__(self, preprocessors, analytics, job, config, fail_fast=False): | |||
self.start = time.time() | |||
self.archives_processed = 0 | |||
self.fail_fast = fail_fast | |||
if resconfig is not None and 'hyperthreaded_ratio' in config._config['resources'][resconfig['name']]: | |||
self.hyperthreadedratio = config._config['resources'][resconfig['name']]['hyperthreaded_ratio'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
self.hyperthreadedratio = config._config['resources'][resconfig['name']]['hyperthreaded_ratio'] | |
self.hyperthreadedratio = resconfig['hyperthreaded_ratio'] |
A resource config is passed as an additional argument to the Summarize class. This can make it easier to directly access a config value for the resource being used.
This needs corresponding changes to |
The CpuUsage plugin now generates additional metrics when hyperthreading is on. Hyperthreading is indicated by providing the ratio of virtual/physical cores in a config file.