xaizek / etabench (License: GPLv3) (since 2022-09-08)
Benchmark for algorithms that compute I/O ETA
Commit 7087a58cec72e2039de7f7d246ba94b0d1e1a347

Add a README
Author: xaizek
Author date (UTC): 2022-12-30 12:47
Committer name: xaizek
Committer date (UTC): 2022-12-30 13:09
Parent(s): 2917316ff9d5f61b32aaadc5ac7427abe1a4f1b7
Signing key: 99DC5E4DB05F6BE2
Tree: 7b8365be5fa9ca1aca81a555725f4671e0d33a9a
File Lines added Lines deleted
README.md 159 0
File README.md added (mode: 100644) (index 0000000..b9816af)
1 *etabench* is an attempt to make a benchmark for comparing ETA algorithms. This
2 is useful not just to pick the best one with more than just a guess work, but
3 also to improve them by making changes and evaluating their effects.
4
5 ### Prerequisites ###
6
7 * C++ compiler that supports a suitable subset of C++20 (e.g., GCC 11)
8 * [xmake][xmake] build system
9 * (optional) [gnuplot][gnuplot] (for `--plot` and `--montage`)
10 * (optional) [ImageMagick][ImageMagick] (for `--montage`)
11
12 ### Building and running ###
13
14 Simple
15
16 ```
17 $ xmake
18 ```
19
20 in the root directory should be enough. The first time it will ask to confirm
21 installation of library dependencies, agree to continue the build.
22
23 `etabench` executable will be copied to the root directory as part of the build
24 process and can be run without arguments:
25
26 ```
27 $ ./etabench
28 Profile \ Alg #1 #2 #3 #4 #5 #6 #7 #8
29 Constant 96.26:3 55.32:4 100.00:1 100.00:1 100.00:1 100.00:1 99.07:2 100.00:1
30 Raising 15° 90.13:1 49.09:2 14.43:6 11.16:8 17.25:4 14.30:7 15.41:5 19.71:3
31 Raising 30° 90.21:1 58.27:2 11.42:6 11.97:5 13.13:4 11.33:7 9.56:8 14.29:3
32 Raising 45° 82.91:1 63.52:2 8.68:6 9.26:5 9.79:4 8.63:7 6.63:8 10.52:3
33 Raising 60° 81.87:1 68.53:2 11.11:6 11.75:5 12.48:4 11.04:7 8.52:8 13.51:3
34 Raising 75° 73.61:1 68.44:2 12.34:6 13.02:5 13.87:4 12.25:7 9.19:8 14.96:3
35 Falling 15° 76.58:1 37.56:7 66.29:3 63.31:4 63.31:4 60.21:6 61.98:5 70.03:2
36 Falling 30° 76.54:2 78.05:1 57.79:4 52.53:6 52.70:5 50.73:8 52.37:7 61.57:3
37 Falling 45° 75.41:2 79.95:1 55.07:4 47.52:7 47.94:5 46.57:8 47.72:6 57.72:3
38 Falling 60° 71.87:2 86.84:1 56.47:4 47.50:7 47.74:5 47.50:7 47.61:6 57.62:3
39 Falling 75° 67.80:2 96.78:1 59.81:3 49.29:6 50.62:5 49.29:6 47.99:7 58.75:4
40 Saw 57.67:2 58.58:1 31.24:6 33.46:4 34.75:3 31.32:5 24.83:8 28.28:7
41 Square 75.29:7 95.41:1 88.40:4 91.12:3 91.58:2 84.09:6 84.80:5 23.32:8
42 Step 71.91:1 51.94:2 11.69:6 8.85:8 15.10:4 11.53:7 12.81:5 15.81:3
43 Random 79.60:6 65.37:7 98.50:3 98.80:1 86.91:5 98.73:2 95.30:4 38.52:8
44 Replay 86.39:2 85.62:3 79.42:6 81.99:4 63.55:7 80.39:5 92.52:1 19.87:8
45
46 Algorithm ranking
47 1. 78.38% - Acceleration
48 2. 68.70% - Firefox
49 3. 47.67% - Switch
50 4. 45.72% - Window 20 1
51 5. 45.05% - LookBack 20
52 6. 44.87% - Average
53 7. 44.77% - Gravity
54 8. 37.78% - Immediate
55 ```
56
57 ### Selecting algorithms ###
58
59 Pass `--list-algs` to see numbered list of available algorithms. Then use
60 `--algs` to specify subset of algorithms. Argument to `--algs` is a
61 comma-separated list of numbers or special value `*` (all algorithms) or an
62 empty string (default set of algorithms).
63
64 Some algorithms are considerably worse than others and enabling them by default
65 only clutters output and especially the plots. Use `--algs \*` to enable all
66 algorithms.
67
68 ```
69 $ ./etabench --list-algs
70 Algorithms:
71 1. Average
72 2. Immediate
73 3. LookBack 20
74 4. Acceleration
75 5. Switch
76 6. Gravity
77 7. Firefox
78 8. Window 20 1
79 9. Combined[ Average Immediate ]
80 10. ImmChangeLimit
81 11. AveChangeLimit
82 12. Slowness 1
83 13. Exponential 1
84 14. Smoothing 0.10
85 $ ./etabench --algs 4,7,12
86 ```
87
88 ### Selecting profiles ###
89
90 Similar to algorithms, but the options are called `--list-profs` and `--profs`
91 and no profiles are disabled by default.
92
93 ```
94 $ ./etabench --list-profs
95 Profiles:
96 1. Constant
97 2. Raising 15°
98 3. Raising 30°
99 4. Raising 45°
100 5. Raising 60°
101 6. Raising 75°
102 7. Falling 15°
103 8. Falling 30°
104 9. Falling 45°
105 10. Falling 60°
106 11. Falling 75°
107 12. Saw
108 13. Square
109 14. Step
110 15. Random
111 16. Replay
112 $ ./etabench --profs 12,13
113 ```
114
115 ### Plotting to separate files ###
116
117 Running
118
119 ```
120 $ ./etabench --plot plots
121 ```
122
123 will create `plots` directory with a set of directories that correspond to the
124 set of profiles. Each directory will contain a PNG plot and its `gnuplot`
125 source.
126
127 ### Plotting to a single file ###
128
129 Running
130
131 ```
132 $ ./etabench --montage montage.png
133 ```
134
135 will do `--plos /some/temp/dir` and then combine result into a single PNG using
136 `montage` command from ImageMagick.
137
138 ### Debugging ###
139
140 Manually:
141 ```
142 $ ./etabench --profs 6 --algs 4 --verbose
143 ```
144
145 With [gdb]:
146 ```
147 $ xmake f -m debug
148 $ xmake
149 $ gdb --args ./etabench --profs 6 --algs 4
150 ```
151
152 ### License ###
153
154 Version 3 of the GNU General Public License.
155
156 [xmake]: https://xmake.io/#/
157 [gnuplot]: http://www.gnuplot.info/
158 [ImageMagick]: https://imagemagick.org/
159 [gdb]: https://www.sourceware.org/gdb/
Hints

Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://code.reversed.top/user/xaizek/etabench

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@code.reversed.top/user/xaizek/etabench

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a pull request:
... clone the repository ...
... make some changes and some commits ...
git push origin master