Skip to content

Commit

Permalink
print container features
Browse files Browse the repository at this point in the history
Signed-off-by: Sunyanan Choochotkaew <[email protected]>
  • Loading branch information
sunya-ch committed Oct 10, 2023
1 parent a967d9d commit 7357b49
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions pkg/bpfassets/attacher/libbpf_attacher.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ func attachLibbpfModule() (*bpf.Module, error) {

// if any counter is not enabled, we need disable HardwareCountersEnabled
HardwareCountersEnabled = false
klog.Info("set HardwareCountersEnabled=false")
}
}
}
Expand Down
2 changes: 2 additions & 0 deletions pkg/model/container_energy.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ func CreateContainerPowerEstimatorModel(containerFeatureNames, systemMetaDataFea
ContainerPlatformPowerModel, err = createPowerModelEstimator(modelConfig)
if err == nil {
klog.Infof("Using the %s Power Model to estimate Container Platform Power", modelConfig.ModelType.String()+"/"+modelConfig.ModelOutputType.String())
klog.Infof("container feature names: %v", modelConfig.ContainerFeatureNames)
} else {
klog.Infof("Failed to create %s Power Model to estimate Container Platform Power: %v\n", modelConfig.ModelType.String()+"/"+modelConfig.ModelOutputType.String(), err)
}
Expand All @@ -116,6 +117,7 @@ func CreateContainerPowerEstimatorModel(containerFeatureNames, systemMetaDataFea
ContainerComponentPowerModel, err = createPowerModelEstimator(modelConfig)
if err == nil {
klog.Infof("Using the %s Power Model to estimate Container Component Power", modelConfig.ModelType.String()+"/"+modelConfig.ModelOutputType.String())
klog.Infof("container feature names: %v", modelConfig.ContainerFeatureNames)
} else {
klog.Infof("Failed to create %s Power Model to estimate Container Component Power: %v\n", modelConfig.ModelType.String()+"/"+modelConfig.ModelOutputType.String(), err)
}
Expand Down

0 comments on commit 7357b49

Please sign in to comment.