diff options
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/contrib/build-perf-test-wrapper.sh | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/scripts/contrib/build-perf-test-wrapper.sh b/scripts/contrib/build-perf-test-wrapper.sh index 8eb4fdbc6c..2fb4b1119a 100755 --- a/scripts/contrib/build-perf-test-wrapper.sh +++ b/scripts/contrib/build-perf-test-wrapper.sh | |||
@@ -26,19 +26,23 @@ Usage: $script [-h] [-c COMMITISH] [-C GIT_REPO] | |||
26 | Optional arguments: | 26 | Optional arguments: |
27 | -h show this help and exit. | 27 | -h show this help and exit. |
28 | -c COMMITISH test (checkout) this commit | 28 | -c COMMITISH test (checkout) this commit |
29 | -C GIT_REPO commit results into Git | ||
29 | EOF | 30 | EOF |
30 | } | 31 | } |
31 | 32 | ||
32 | 33 | ||
33 | # Parse command line arguments | 34 | # Parse command line arguments |
34 | commitish="" | 35 | commitish="" |
35 | while getopts "hc:" opt; do | 36 | results_repo="" |
37 | while getopts "hc:C:" opt; do | ||
36 | case $opt in | 38 | case $opt in |
37 | h) usage | 39 | h) usage |
38 | exit 0 | 40 | exit 0 |
39 | ;; | 41 | ;; |
40 | c) commitish=$OPTARG | 42 | c) commitish=$OPTARG |
41 | ;; | 43 | ;; |
44 | C) results_repo=`realpath "$OPTARG"` | ||
45 | ;; | ||
42 | *) usage | 46 | *) usage |
43 | exit 1 | 47 | exit 1 |
44 | ;; | 48 | ;; |
@@ -73,13 +77,14 @@ base_dir="$git_topdir/build-perf-test" | |||
73 | build_dir="$base_dir/build-$git_rev-$timestamp" | 77 | build_dir="$base_dir/build-$git_rev-$timestamp" |
74 | results_dir="$base_dir/results-$git_rev-$timestamp" | 78 | results_dir="$base_dir/results-$git_rev-$timestamp" |
75 | globalres_log="$base_dir/globalres.log" | 79 | globalres_log="$base_dir/globalres.log" |
80 | machine="qemux86" | ||
76 | 81 | ||
77 | mkdir -p "$base_dir" | 82 | mkdir -p "$base_dir" |
78 | source ./oe-init-build-env $build_dir >/dev/null || exit 1 | 83 | source ./oe-init-build-env $build_dir >/dev/null || exit 1 |
79 | 84 | ||
80 | # Additional config | 85 | # Additional config |
81 | auto_conf="$build_dir/conf/auto.conf" | 86 | auto_conf="$build_dir/conf/auto.conf" |
82 | echo 'MACHINE = "qemux86"' > "$auto_conf" | 87 | echo "MACHINE = \"$machine\"" > "$auto_conf" |
83 | echo 'BB_NUMBER_THREADS = "8"' >> "$auto_conf" | 88 | echo 'BB_NUMBER_THREADS = "8"' >> "$auto_conf" |
84 | echo 'PARALLEL_MAKE = "-j 8"' >> "$auto_conf" | 89 | echo 'PARALLEL_MAKE = "-j 8"' >> "$auto_conf" |
85 | echo "DL_DIR = \"$base_dir/downloads\"" >> "$auto_conf" | 90 | echo "DL_DIR = \"$base_dir/downloads\"" >> "$auto_conf" |
@@ -93,7 +98,10 @@ fi | |||
93 | # Run actual test script | 98 | # Run actual test script |
94 | if ! oe-build-perf-test --out-dir "$results_dir" \ | 99 | if ! oe-build-perf-test --out-dir "$results_dir" \ |
95 | --globalres-file "$globalres_log" \ | 100 | --globalres-file "$globalres_log" \ |
96 | --lock-file "$base_dir/oe-build-perf.lock"; then | 101 | --lock-file "$base_dir/oe-build-perf.lock" \ |
102 | --commit-results "$results_repo" \ | ||
103 | --commit-results-branch "{tester_host}/{git_branch}/$machine" \ | ||
104 | --commit-results-tag "{tester_host}/{git_branch}/$machine/{git_commit_count}-g{git_commit}/{tag_num}"; then | ||
97 | echo "oe-build-perf-test script failed!" | 105 | echo "oe-build-perf-test script failed!" |
98 | exit 1 | 106 | exit 1 |
99 | fi | 107 | fi |