From 2170939771946fdc934aea71f56db1e33dbe3df8 Mon Sep 17 00:00:00 2001 From: Fengyun Liu Date: Fri, 19 Apr 2024 18:09:08 +0200 Subject: [PATCH] Use self.benchSuiteName instead self.name in mx_vm_benchmark.py --- common.json | 2 +- sdk/mx.sdk/mx_sdk_benchmark.py | 7 +++---- substratevm/mx.substratevm/mx_substratevm_benchmark.py | 3 --- vm/mx.vm/mx_vm_benchmark.py | 7 +++++-- 4 files changed, 9 insertions(+), 10 deletions(-) diff --git a/common.json b/common.json index 11a64df55a15..5d02b36586fe 100644 --- a/common.json +++ b/common.json @@ -4,7 +4,7 @@ "Jsonnet files should not include this file directly but use ci/common.jsonnet instead." ], - "mx_version": "7.32.0", + "mx_version": "7.32.2", "COMMENT.jdks": "When adding or removing JDKs keep in sync with JDKs in ci/common.jsonnet", "jdks": { diff --git a/sdk/mx.sdk/mx_sdk_benchmark.py b/sdk/mx.sdk/mx_sdk_benchmark.py index a30344ada1d5..aaf48de97b3d 100644 --- a/sdk/mx.sdk/mx_sdk_benchmark.py +++ b/sdk/mx.sdk/mx_sdk_benchmark.py @@ -894,7 +894,8 @@ def name(self): return "specjvm2008" def benchSuiteName(self, bmSuiteArgs=None): - return self.name() + # For historical reasons, we have the suffix. Dropping the suffix would require data migration. + return "specjvm2008-single" def group(self): return "Graal" @@ -992,14 +993,12 @@ def flakySuccessPatterns(self): return [] def rules(self, out, benchmarks, bmSuiteArgs): - # For historical reasons, we have the suffix. Dropping the suffix would require data migration. - suite_name = self.benchSuiteName() + "-single" return [ mx_benchmark.StdOutRule( r"^Score on (?P[a-zA-Z0-9\._]+): (?P[0-9]+((,|\.)[0-9]+)?) ops/m$", # pylint: disable=line-too-long { "benchmark": ("", str), - "bench-suite": suite_name, + "bench-suite": self.benchSuiteName(), "vm": "jvmci", "config.name": "default", "metric.name": "throughput", diff --git a/substratevm/mx.substratevm/mx_substratevm_benchmark.py b/substratevm/mx.substratevm/mx_substratevm_benchmark.py index 26b274855e04..42f0d10e942f 100644 --- a/substratevm/mx.substratevm/mx_substratevm_benchmark.py +++ b/substratevm/mx.substratevm/mx_substratevm_benchmark.py @@ -628,9 +628,6 @@ class SpecJVM2008NativeImageBenchmarkSuite(mx_sdk_benchmark.SpecJvm2008Benchmark def name(self): return 'specjvm2008-native-image' - def benchSuiteName(self, bmSuiteArgs=None): - return 'specjvm2008' - def run(self, benchmarks, bmSuiteArgs) -> mx_benchmark.DataPoints: return self.intercept_run(super(), benchmarks, bmSuiteArgs) diff --git a/vm/mx.vm/mx_vm_benchmark.py b/vm/mx.vm/mx_vm_benchmark.py index d1b1a820e016..f0aac7391239 100644 --- a/vm/mx.vm/mx_vm_benchmark.py +++ b/vm/mx.vm/mx_vm_benchmark.py @@ -993,6 +993,7 @@ def image_build_statistics_rules(self, benchmarks): rules = [] for i in range(0, len(metric_objects)): rules += self._get_image_build_stats_rules({ + "bench-suite": self.config.benchmark_suite_name, "benchmark": benchmarks[0], "metric.name": "image-build-stats", "metric.type": "numeric", @@ -1013,6 +1014,7 @@ def image_build_timers_rules(self, benchmarks): phase = measured_phases[i] value_name = phase + "_time" rules += self._get_image_build_stats_rules({ + "bench-suite": self.config.benchmark_suite_name, "benchmark": benchmarks[0], "metric.name": "compile-time", "metric.type": "numeric", @@ -1025,6 +1027,7 @@ def image_build_timers_rules(self, benchmarks): }, [value_name]) value_name = phase + "_memory" rules += self._get_image_build_stats_rules({ + "bench-suite": self.config.benchmark_suite_name, "benchmark": benchmarks[0], "metric.name": "compile-time", "metric.type": "numeric", @@ -1411,7 +1414,7 @@ def rules(self, out, benchmarks, bmSuiteArgs): assert len(benchmarks) == 1 return [ mx_benchmark.StdOutRule(r'^Hundred thousand prime numbers in (?P