From f0b4ceada7a4f5cf011fa88c3651a62394ae4eb1 Mon Sep 17 00:00:00 2001 From: nutelllia Date: Wed, 21 Feb 2024 14:20:58 +0100 Subject: [PATCH 1/8] Add time as a parameter to total-data.json --- scripts/add-data.sh | 2 ++ scripts/display_results.sh | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/add-data.sh b/scripts/add-data.sh index 5bacee49..2d33a596 100755 --- a/scripts/add-data.sh +++ b/scripts/add-data.sh @@ -6,6 +6,7 @@ LABEL="" CPU="" ENERGY="" POWER="" +TIME="" # Parse named parameters while [[ $# -gt 0 ]]; do @@ -56,6 +57,7 @@ NEW_STEP=$(cat < Date: Wed, 21 Feb 2024 14:29:45 +0100 Subject: [PATCH 2/8] Add time parameter parsing --- scripts/add-data.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/scripts/add-data.sh b/scripts/add-data.sh index 2d33a596..c408a721 100755 --- a/scripts/add-data.sh +++ b/scripts/add-data.sh @@ -38,6 +38,11 @@ while [[ $# -gt 0 ]]; do shift # past argument shift # past value ;; + -t|--time) + TIME="$2" + shift # past argument + shift # past value + ;; *) # unknown option echo "Unknown option: $1" exit 1 From 4519062f13f64147da8e35ec9c9b59a662e6c639 Mon Sep 17 00:00:00 2001 From: nutelllia Date: Wed, 21 Feb 2024 14:34:50 +0100 Subject: [PATCH 3/8] Fix typo --- scripts/display_results.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/display_results.sh b/scripts/display_results.sh index 4fa8c9a9..af10f4f5 100755 --- a/scripts/display_results.sh +++ b/scripts/display_results.sh @@ -146,7 +146,7 @@ function display_results { echo "show create-and-add-meta.sh output" echo "--file $total_data_file --repository $repo_enc --branch $branch_enc --workflow $WORKFLOW_ID --run_id $run_id_enc" source "$(dirname "$0")/create-and-add-meta.sh" --file "${total_data_file}" --repository "${repo_enc}" --branch "${branch_enc}" --workflow "$WORKFLOW_ID" --run_id "${run_id_enc}" - source "$(dirname "$0")/add-data.sh" --file "${total_data_file}" --label "TOTAL" --cpu "${cpu_avg}" --energy "${total_energy}" --power "${power_avg}" --time "${time} + source "$(dirname "$0")/add-data.sh" --file "${total_data_file}" --label "TOTAL" --cpu "${cpu_avg}" --energy "${total_energy}" --power "${power_avg}" --time "${time}" } From a90bc2d19e92620486c9c75e54f58815b8b2d66c Mon Sep 17 00:00:00 2001 From: nutelllia Date: Wed, 21 Feb 2024 14:47:08 +0100 Subject: [PATCH 4/8] Add debugging lines --- scripts/add-data.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/scripts/add-data.sh b/scripts/add-data.sh index c408a721..9f730664 100755 --- a/scripts/add-data.sh +++ b/scripts/add-data.sh @@ -62,11 +62,14 @@ NEW_STEP=$(cat < tmp.$$.json && mv tmp.$$.json "$FILE" From c30689481c996cb7f8c569b8042e278302d3010d Mon Sep 17 00:00:00 2001 From: nutelllia Date: Wed, 21 Feb 2024 14:53:23 +0100 Subject: [PATCH 5/8] Fix typo --- scripts/add-data.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/add-data.sh b/scripts/add-data.sh index 9f730664..4f72147a 100755 --- a/scripts/add-data.sh +++ b/scripts/add-data.sh @@ -61,7 +61,7 @@ NEW_STEP=$(cat < Date: Wed, 21 Feb 2024 15:11:30 +0100 Subject: [PATCH 6/8] Remove debugging lines --- scripts/add-data.sh | 3 --- 1 file changed, 3 deletions(-) diff --git a/scripts/add-data.sh b/scripts/add-data.sh index 4f72147a..23127e7e 100755 --- a/scripts/add-data.sh +++ b/scripts/add-data.sh @@ -67,9 +67,6 @@ NEW_STEP=$(cat < tmp.$$.json && mv tmp.$$.json "$FILE" From 6e074557be4688650cbef89f4f7e3654fa5a5649 Mon Sep 17 00:00:00 2001 From: nutelllia Date: Wed, 21 Feb 2024 15:16:01 +0100 Subject: [PATCH 7/8] Add time as parameter in make_measurement --- scripts/make_measurement.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/make_measurement.sh b/scripts/make_measurement.sh index ee30aa48..41fcf877 100755 --- a/scripts/make_measurement.sh +++ b/scripts/make_measurement.sh @@ -122,7 +122,7 @@ function make_measurement() { echo "--file $lap_data_file --repository $repo_enc --branch $branch_enc --workflow $WORKFLOW_ID --run_id $run_id_enc" source "$(dirname "$0")/create-and-add-meta.sh" --file "${lap_data_file}" --repository "${repo_enc}" --branch "${branch_enc}" --workflow "$WORKFLOW_ID" --run_id "${run_id_enc}" - source "$(dirname "$0")/add-data.sh" --file "${lap_data_file}" --label "$label" --cpu "${cpu_avg}" --energy "${total_energy}" --power "${power_avg}" + source "$(dirname "$0")/add-data.sh" --file "${lap_data_file}" --label "$label" --cpu "${cpu_avg}" --energy "${total_energy}" --power "${power_avg}" --time "${time}" killall -9 -q /tmp/eco-ci/demo-reporter || true /tmp/eco-ci/demo-reporter | tee -a /tmp/eco-ci/cpu-util-total.txt > /tmp/eco-ci/cpu-util.txt & From 3f407abfca265dc2d37f2cf889b569a3589f8479 Mon Sep 17 00:00:00 2001 From: nutelllia Date: Wed, 21 Feb 2024 15:22:56 +0100 Subject: [PATCH 8/8] Fix typo --- scripts/add-data.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/add-data.sh b/scripts/add-data.sh index 23127e7e..0a1f39c1 100755 --- a/scripts/add-data.sh +++ b/scripts/add-data.sh @@ -62,7 +62,7 @@ NEW_STEP=$(cat <