Add measurement and load location information to the run summary report
Resolves: rhbz#2081325 Signed-off-by: Leah Leshchinsky <lleshchi@redhat.com>
This commit is contained in:
parent
a91b2c49e8
commit
bc70d36587
92
rteval-Add-measurement-and-load-location-to-run-repo.patch
Normal file
92
rteval-Add-measurement-and-load-location-to-run-repo.patch
Normal file
@ -0,0 +1,92 @@
|
|||||||
|
From 3d878311c145f3c06032d7df57d1fefa529943f3 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Leah Leshchinsky <lleshchi@redhat.com>
|
||||||
|
Date: Tue, 16 Aug 2022 14:19:31 -0400
|
||||||
|
Subject: [PATCH] rteval: Add measurement and load location to run report
|
||||||
|
|
||||||
|
The run report produced at the end of a run does not contain information
|
||||||
|
on load and measurement thread locations.
|
||||||
|
|
||||||
|
Adjust MakeReport() functions of LoadModules and MeasurementModules
|
||||||
|
class so that new properties with number of loads and cpu information
|
||||||
|
are added to the XML report and can be read by rteval_text.xsl.
|
||||||
|
|
||||||
|
Signed-off-by: Leah Leshchinsky <lleshchi@redhat.com>
|
||||||
|
Signed-off-by: John Kacur <jkacur@redhat.com>
|
||||||
|
|
||||||
|
diff --git a/rteval/modules/loads/__init__.py b/rteval/modules/loads/__init__.py
|
||||||
|
index 2c2105efa964..7daa57a19c66 100644
|
||||||
|
--- a/rteval/modules/loads/__init__.py
|
||||||
|
+++ b/rteval/modules/loads/__init__.py
|
||||||
|
@@ -30,6 +30,7 @@ import libxml2
|
||||||
|
from rteval.Log import Log
|
||||||
|
from rteval.rtevalConfig import rtevalCfgSection
|
||||||
|
from rteval.modules import RtEvalModules, rtevalModulePrototype
|
||||||
|
+from rteval.systopology import collapse_cpulist, CpuList, SysTopology as SysTop
|
||||||
|
|
||||||
|
class LoadThread(rtevalModulePrototype):
|
||||||
|
def __init__(self, name, config, logger=None):
|
||||||
|
@@ -131,6 +132,14 @@ class LoadModules(RtEvalModules):
|
||||||
|
def MakeReport(self):
|
||||||
|
rep_n = RtEvalModules.MakeReport(self)
|
||||||
|
rep_n.newProp("load_average", str(self.GetLoadAvg()))
|
||||||
|
+ rep_n.newProp("loads", str(self.ModulesLoaded()))
|
||||||
|
+ cpulist = self._cfg.GetSection(self._module_config).cpulist
|
||||||
|
+ if cpulist:
|
||||||
|
+ # Convert str to list and remove offline cpus
|
||||||
|
+ cpulist = CpuList(cpulist).cpulist
|
||||||
|
+ else:
|
||||||
|
+ cpulist = SysTop().online_cpus()
|
||||||
|
+ rep_n.newProp("loadcpus", collapse_cpulist(cpulist))
|
||||||
|
|
||||||
|
return rep_n
|
||||||
|
|
||||||
|
diff --git a/rteval/modules/measurement/__init__.py b/rteval/modules/measurement/__init__.py
|
||||||
|
index 318248bd7e35..d99873e64a1a 100644
|
||||||
|
--- a/rteval/modules/measurement/__init__.py
|
||||||
|
+++ b/rteval/modules/measurement/__init__.py
|
||||||
|
@@ -24,7 +24,7 @@
|
||||||
|
|
||||||
|
import libxml2
|
||||||
|
from rteval.modules import RtEvalModules, ModuleContainer
|
||||||
|
-
|
||||||
|
+from rteval.systopology import collapse_cpulist, CpuList, SysTopology as SysTop
|
||||||
|
|
||||||
|
class MeasurementProfile(RtEvalModules):
|
||||||
|
"""Keeps and controls all the measurement modules with the same measurement profile"""
|
||||||
|
@@ -189,6 +189,14 @@ measurement profiles, based on their characteristics"""
|
||||||
|
|
||||||
|
# Get the reports from all meaurement modules in all measurement profiles
|
||||||
|
rep_n = libxml2.newNode("Measurements")
|
||||||
|
+ cpulist = self.__cfg.GetSection("measurement").cpulist
|
||||||
|
+ if cpulist:
|
||||||
|
+ # Convert str to list and remove offline cpus
|
||||||
|
+ cpulist = CpuList(cpulist).cpulist
|
||||||
|
+ else:
|
||||||
|
+ cpulist = SysTop().online_cpus()
|
||||||
|
+ rep_n.newProp("measurecpus", collapse_cpulist(cpulist))
|
||||||
|
+
|
||||||
|
for mp in self.__measureprofiles:
|
||||||
|
mprep_n = mp.MakeReport()
|
||||||
|
if mprep_n:
|
||||||
|
diff --git a/rteval/rteval_text.xsl b/rteval/rteval_text.xsl
|
||||||
|
index c40063e3dd19..7ecfac6b6140 100644
|
||||||
|
--- a/rteval/rteval_text.xsl
|
||||||
|
+++ b/rteval/rteval_text.xsl
|
||||||
|
@@ -13,6 +13,14 @@
|
||||||
|
<xsl:value-of select="run_info/date"/><xsl:text> </xsl:text><xsl:value-of select="run_info/time"/>
|
||||||
|
<xsl:text> </xsl:text>
|
||||||
|
|
||||||
|
+ <xsl:text> Loads: </xsl:text>
|
||||||
|
+ <xsl:value-of select="loads/@loads"/><xsl:text> loads run on cores </xsl:text><xsl:value-of select="loads/@loadcpus"/>
|
||||||
|
+ <xsl:text> </xsl:text>
|
||||||
|
+
|
||||||
|
+ <xsl:text> Measurement: </xsl:text>
|
||||||
|
+ <xsl:text>measurement threads run on cores </xsl:text><xsl:value-of select="Measurements/@measurecpus"/>
|
||||||
|
+ <xsl:text> </xsl:text>
|
||||||
|
+
|
||||||
|
<xsl:text> Run time: </xsl:text>
|
||||||
|
<xsl:value-of select="run_info/@days"/><xsl:text> days </xsl:text>
|
||||||
|
<xsl:value-of select="run_info/@hours"/><xsl:text>h </xsl:text>
|
||||||
|
--
|
||||||
|
2.31.1
|
||||||
|
|
@ -1,6 +1,6 @@
|
|||||||
Name: rteval
|
Name: rteval
|
||||||
Version: 3.4
|
Version: 3.4
|
||||||
Release: 3%{?dist}
|
Release: 4%{?dist}
|
||||||
Summary: Utility to evaluate system suitability for RT Linux
|
Summary: Utility to evaluate system suitability for RT Linux
|
||||||
|
|
||||||
Group: Development/Tools
|
Group: Development/Tools
|
||||||
@ -42,6 +42,7 @@ Patch9: rteval-cyclictest-Reset-cpulist-from-newly-calculate.patch
|
|||||||
Patch10: rteval-Fix-loads-cpulist-restriction.patch
|
Patch10: rteval-Fix-loads-cpulist-restriction.patch
|
||||||
Patch11: rteval-Allow-user-to-enter-compressed-cpu-lists-fix.patch
|
Patch11: rteval-Allow-user-to-enter-compressed-cpu-lists-fix.patch
|
||||||
Patch12: rteval-Move-cpuinfo-to-systopology.py-and-delete-mis.patch
|
Patch12: rteval-Move-cpuinfo-to-systopology.py-and-delete-mis.patch
|
||||||
|
Patch13: rteval-Add-measurement-and-load-location-to-run-repo.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
The rteval script is a utility for measuring various aspects of
|
The rteval script is a utility for measuring various aspects of
|
||||||
@ -66,6 +67,7 @@ to the screen.
|
|||||||
%patch10 -p1
|
%patch10 -p1
|
||||||
%patch11 -p1
|
%patch11 -p1
|
||||||
%patch12 -p1
|
%patch12 -p1
|
||||||
|
%patch13 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%{__python3} setup.py build
|
%{__python3} setup.py build
|
||||||
@ -87,6 +89,10 @@ to the screen.
|
|||||||
%{_bindir}/rteval
|
%{_bindir}/rteval
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Sep 26 2022 Leah Leshchinsky <lleshchi@redhat.com> - 3.4-4
|
||||||
|
- Add measurement and load location information to the run summary report
|
||||||
|
Resolves: rhbz#2081325
|
||||||
|
|
||||||
* Tue Sep 13 2022 John Kacur <jkacur@rredhat.com> - 3.4-3
|
* Tue Sep 13 2022 John Kacur <jkacur@rredhat.com> - 3.4-3
|
||||||
- Make use of systopology instead of misc everywhere
|
- Make use of systopology instead of misc everywhere
|
||||||
- Allow user to enter compressed form of cpulist
|
- Allow user to enter compressed form of cpulist
|
||||||
|
Loading…
Reference in New Issue
Block a user