OLD | NEW |
1 #!/bin/bash | 1 #!/bin/bash |
2 | 2 |
3 # Copyright 2013 The Chromium Authors. All rights reserved. | 3 # Copyright 2013 The Chromium Authors. All rights reserved. |
4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
6 | 6 |
7 # Produce metrics analyzing the output of a stress test | 7 # Produce metrics analyzing the output of a stress test |
8 | 8 |
9 source "$(dirname ${0})/stress_test_common" | 9 source "$(dirname ${0})/stress_test_common" |
10 | 10 |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 exit 1 | 46 exit 1 |
47 fi | 47 fi |
48 | 48 |
49 cat <<EOF | 49 cat <<EOF |
50 $(count_result "PASS_COURGETTE") successful courgette patches | 50 $(count_result "PASS_COURGETTE") successful courgette patches |
51 $(count_result "FAIL_COURGETTE") failed courgette patches | 51 $(count_result "FAIL_COURGETTE") failed courgette patches |
52 $(count_result "FAIL_DISASSEMBLE") failed to disassemble/assemble | 52 $(count_result "FAIL_DISASSEMBLE") failed to disassemble/assemble |
53 $(count_result "PASS_BSDIFF") succesful bsdiff patches | 53 $(count_result "PASS_BSDIFF") succesful bsdiff patches |
54 $(count_result "FAIL_BSDIFF") failed bsdiff patches | 54 $(count_result "FAIL_BSDIFF") failed bsdiff patches |
55 $(count_result "BEST_COURGETTE") patch(es) where courgette is smaller (bz2) | 55 $(count_result "BEST_COURGETTE") patch(es) where courgette is smaller (bz2) |
56 $(count_result "BEST_BSDIFF") patch(es) where bsdiff is smaller (xz) | 56 $(count_result "BEST_BSDIFF") patch(es) where bsdiff is smaller (bz2) |
57 $(count_result "BEST_TIE") patch(es) where both are the same size (bz2) | 57 $(count_result "BEST_TIE") patch(es) where both are the same size (bz2) |
58 $(count_result "XZBEST_COURGETTE") patch(es) where courgette (xz) is smaller | 58 $(count_result "XZBEST_COURGETTE") patch(es) where courgette (xz) is smaller |
59 $(count_result "XZBEST_BSDIFF") patch(es) where bsdiff is smaller (xz) | 59 $(count_result "XZBEST_BSDIFF") patch(es) where bsdiff is smaller (xz) |
60 $(count_result "XZBEST_TIE") patch(es) where both are the same size (xz) | 60 $(count_result "XZBEST_TIE") patch(es) where both are the same size (xz) |
61 EOF | 61 EOF |
62 | 62 |
63 # Log file has the format "^SIZE courgette=... bsdiff=..." | 63 # Log file has the format "^SIZE courgette=... bsdiff=..." |
64 local courgette_total="$(cat "${log}" \ | 64 local courgette_total="$(cat "${log}" \ |
65 | grep "^SIZE " \ | 65 | grep "^SIZE " \ |
66 | cut -d' ' -f2 \ | 66 | cut -d' ' -f2 \ |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 | awk '{printf "%.2f\n", $0}')" | 115 | awk '{printf "%.2f\n", $0}')" |
116 echo "${pct_savings}% savings (xz)" | 116 echo "${pct_savings}% savings (xz)" |
117 | 117 |
118 echo "$(compute_percentiles "TIME_GEN")to generate a patch (50th 90th 100th)" | 118 echo "$(compute_percentiles "TIME_GEN")to generate a patch (50th 90th 100th)" |
119 echo "$(compute_percentiles "TIME_APPLY")to apply a patch (50th 90th 100th)" | 119 echo "$(compute_percentiles "TIME_APPLY")to apply a patch (50th 90th 100th)" |
120 echo "$(compute_percentiles "TIME_BSDIFF")for bsdiff (50th 90th 100th)" | 120 echo "$(compute_percentiles "TIME_BSDIFF")for bsdiff (50th 90th 100th)" |
121 echo "$(compute_percentiles "TIME_BSPATCH")for bspatch (50th 90th 100th)" | 121 echo "$(compute_percentiles "TIME_BSPATCH")for bspatch (50th 90th 100th)" |
122 } | 122 } |
123 | 123 |
124 main "${@}" | 124 main "${@}" |
OLD | NEW |