From 56ea782a6dcb37481fa29d431d7d671345f30311 Mon Sep 17 00:00:00 2001 From: James Foucar Date: Tue, 17 Oct 2023 09:49:10 -0600 Subject: [PATCH] Jenkins_generic_job: Add --save-timing --- CIME/Tools/jenkins_generic_job | 9 +++++++++ CIME/jenkins_generic_job.py | 12 ++++++++---- 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/CIME/Tools/jenkins_generic_job b/CIME/Tools/jenkins_generic_job index 66dbbdc6e31..0c1a05a128e 100755 --- a/CIME/Tools/jenkins_generic_job +++ b/CIME/Tools/jenkins_generic_job @@ -180,6 +180,12 @@ OR help="Do not fail if there are memleaks", ) + parser.add_argument( + "--save-timing", + action="store_true", + help="Tell create_test to save timings of tests", + ) + parser.add_argument( "--pes-file", help="Full pathname of an optional pes specification file. The file" @@ -259,6 +265,7 @@ OR args.check_throughput, args.check_memory, args.ignore_memleak, + args.save_timing, args.pes_file, args.jenkins_id, args.queue, @@ -289,6 +296,7 @@ def _main_func(description): check_throughput, check_memory, ignore_memleak, + save_timing, pes_file, jenkins_id, queue, @@ -317,6 +325,7 @@ def _main_func(description): check_throughput, check_memory, ignore_memleak, + save_timing, pes_file, jenkins_id, queue, diff --git a/CIME/jenkins_generic_job.py b/CIME/jenkins_generic_job.py index 57432e822e6..e89e7ec2e9c 100644 --- a/CIME/jenkins_generic_job.py +++ b/CIME/jenkins_generic_job.py @@ -279,6 +279,7 @@ def jenkins_generic_job( check_throughput, check_memory, ignore_memleak, + save_timing, pes_file, jenkins_id, queue, @@ -361,16 +362,19 @@ def jenkins_generic_job( create_test_args.append("-j {:d}".format(parallel_jobs)) if walltime is not None: - create_test_args.append(" --walltime " + walltime) + create_test_args.append("--walltime " + walltime) if baseline_root is not None: - create_test_args.append(" --baseline-root " + baseline_root) + create_test_args.append("--baseline-root " + baseline_root) if pes_file is not None: - create_test_args.append(" --pesfile " + pes_file) + create_test_args.append("--pesfile " + pes_file) if queue is not None: - create_test_args.append(" --queue " + queue) + create_test_args.append("--queue " + queue) + + if save_timing: + create_test_args.append("--save-timing") create_test_cmd = "./create_test " + " ".join(create_test_args)