Benchmark project is here.
All tests were run on a machine with the following specifications:
3 GHz 6-Core Intel Core i5, 40GB 2667 MHz DDR4
All results are presented in seconds.
- iOverlay(Rust) v1.6.1 (multithreading on/off)
- iOverlay(Swift) v1.13.0
- Clipper2(C++) v1.4.0
Squares | iOverlay(Swift) | iOverlay(Rust) MT off | iOverlay(Rust) MT on | Clipper2(C++) |
5 | 0.000014 | 0.000007 | 0.000007 | 0.000007 |
25 | 0.000100 | 0.000038 | 0.000038 | 0.000038 |
113 | 0.000589 | 0.000204 | 0.000206 | 0.000208 |
481 | 0.004105 | 0.001125 | 0.001137 | 0.001017 |
1985 | 0.012643 | 0.005292 | 0.005314 | 0.005182 |
8065 | 0.055664 | 0.024419 | 0.025238 | 0.024013 |
32513 | 0.234840 | 0.113552 | 0.108039 | 0.154054 |
130561 | 0.993920 | 0.513955 | 0.471003 | 1.067439 |
523265 | 4.410302 | 2.320560 | 2.169407 | 8.346041 |
2095105 | 18.451646 | 9.763142 | 9.021474 | 73.312335 |
8384513 | 78.719305 | 41.735110 | 37.344582 | 644.337867 |
Squares | iOverlay(Swift) | iOverlay(Rust) MT off | iOverlay(Rust) MT on | Clipper2(C++) |
5 | 0.000009 | 0.000004 | 0.000004 | 0.000005 |
25 | 0.000041 | 0.000016 | 0.000016 | 0.000021 |
113 | 0.000204 | 0.000077 | 0.000076 | 0.000097 |
481 | 0.001052 | 0.000400 | 0.000406 | 0.000457 |
1985 | 0.004978 | 0.001965 | 0.001959 | 0.002114 |
8065 | 0.021336 | 0.009956 | 0.009912 | 0.010783 |
32513 | 0.089523 | 0.045412 | 0.044751 | 0.056281 |
130561 | 0.375594 | 0.194658 | 0.189546 | 0.369146 |
523265 | 1.663087 | 0.885775 | 0.860105 | 2.695334 |
2095105 | 6.947932 | 3.759691 | 3.627623 | 20.665812 |
8384513 | 28.777569 | 16.449567 | 15.293312 | 167.966801 |
Lines | iOverlay(Swift) | iOverlay(Rust) MT off | iOverlay(Rust) MT on | Clipper2(C++) |
4 | 0.000014 | 0.000006 | 0.000006 | 0.000004 |
8 | 0.000049 | 0.000018 | 0.000018 | 0.000012 |
16 | 0.000195 | 0.000063 | 0.000064 | 0.000043 |
32 | 0.001295 | 0.000258 | 0.000259 | 0.000176 |
64 | 0.004994 | 0.001267 | 0.001258 | 0.000749 |
128 | 0.021239 | 0.005021 | 0.005830 | 0.003441 |
256 | 0.091427 | 0.025601 | 0.026613 | 0.018417 |
512 | 0.255989 | 0.131983 | 0.123238 | 0.115229 |
1024 | 1.146842 | 0.538035 | 0.557338 | 0.759640 |
2048 | 4.808548 | 2.592261 | 2.306600 | 5.595165 |
4096 | 20.190101 | 10.937208 | 9.588313 | 45.934461 |
Links | iOverlay(Swift) | iOverlay(Rust) MT off | iOverlay(Rust) MT on | Clipper2(C++) |
2 | 0.000006 | 0.000003 | 0.000003 | 0.000002 |
4 | 0.000010 | 0.000005 | 0.000005 | 0.000004 |
8 | 0.000019 | 0.000010 | 0.000010 | 0.000007 |
16 | 0.000040 | 0.000020 | 0.000020 | 0.000014 |
32 | 0.000095 | 0.000050 | 0.000049 | 0.000031 |
64 | 0.000218 | 0.000133 | 0.000133 | 0.000083 |
128 | 0.000490 | 0.000305 | 0.000305 | 0.000202 |
256 | 0.001105 | 0.000699 | 0.000702 | 0.000476 |
512 | 0.003385 | 0.001723 | 0.001673 | 0.001195 |
1024 | 0.006174 | 0.003801 | 0.003693 | 0.002941 |
2048 | 0.013200 | 0.008436 | 0.008434 | 0.007578 |
4096 | 0.026065 | 0.016422 | 0.016581 | 0.020287 |
8192 | 0.055944 | 0.034739 | 0.034528 | 0.054647 |
16384 | 0.112375 | 0.068730 | 0.068337 | 0.181050 |
32768 | 0.237412 | 0.146693 | 0.144771 | 0.606854 |
65536 | 0.473847 | 0.297990 | 0.295959 | 2.013809 |
131072 | 0.981729 | 0.632649 | 0.631458 | 6.547658 |
262144 | 1.979541 | 1.292599 | 1.299418 | 21.171540 |
524288 | 4.101912 | 2.703499 | 2.704447 | 72.147615 |
1048576 | 8.254108 | 5.407953 | 5.457118 | 259.866180 |
Squares | iOverlay(Swift) | iOverlay(Rust) MT off | iOverlay(Rust) MT on | Clipper2(C++) |
8 | 0.000016 | 0.000006 | 0.000006 | 0.000008 |
32 | 0.000062 | 0.000023 | 0.000023 | 0.000028 |
128 | 0.000276 | 0.000104 | 0.000105 | 0.000112 |
512 | 0.001306 | 0.000544 | 0.000545 | 0.000507 |
2048 | 0.005543 | 0.002436 | 0.002413 | 0.002454 |
8192 | 0.023805 | 0.011186 | 0.011143 | 0.012364 |
32768 | 0.104822 | 0.054641 | 0.053747 | 0.076850 |
131072 | 0.445712 | 0.243877 | 0.232455 | 0.568316 |
524288 | 1.862371 | 0.995490 | 0.978971 | 4.142673 |
2097152 | 7.657815 | 4.160511 | 4.089460 | 33.165570 |
8388608 | 30.833973 | 17.234603 | 16.098006 | 265.387333 |
Squares | iOverlay(Swift) | iOverlay(Rust) MT off | iOverlay(Rust) MT on | Clipper2(C++) |
4 | 0.000022 | 0.000010 | 0.000010 | 0.000012 |
8 | 0.000045 | 0.000019 | 0.000019 | 0.000023 |
16 | 0.000098 | 0.000039 | 0.000038 | 0.000050 |
32 | 0.000238 | 0.000084 | 0.000083 | 0.000118 |
64 | 0.000624 | 0.000216 | 0.000210 | 0.000291 |
128 | 0.001853 | 0.000589 | 0.000593 | 0.000806 |
256 | 0.002398 | 0.001964 | 0.001883 | 0.003415 |
512 | 0.005013 | 0.002736 | 0.002724 | 0.015989 |
1024 | 0.011067 | 0.005108 | 0.005558 | 0.081267 |
2048 | 0.023194 | 0.011339 | 0.010744 | 0.461883 |
4096 | 0.050601 | 0.026789 | 0.026263 | 2.347209 |
8192 | 0.111691 | 0.052864 | 0.053851 | 10.612424 |
16384 | 0.252357 | 0.134364 | 0.137991 | 46.205474 |
32768 | 0.581991 | 0.292781 | 0.287206 | 251.260857 |
65536 | 1.368794 | 0.781251 | 0.767102 | 3502.233611 |
131072 | 3.250746 | 1.688798 | 1.640510 | ---- |
262144 | 8.529555 | 4.809529 | 4.726510 | ---- |
524288 | 21.177892 | 10.273028 | 10.513923 | ---- |