| 101 | |
| 102 | template <typename Tag, typename Storage> |
| 103 | double compare_6d(unsigned n, int distrib) { |
| 104 | auto r = random_array(n, distrib); |
| 105 | |
| 106 | auto best = std::numeric_limits<double>::max(); |
| 107 | for (unsigned k = 0; k < 20; ++k) { |
| 108 | auto h = |
| 109 | make_s(Tag(), Storage(), axis::regular<>(10, 0, 1), axis::regular<>(10, 0, 1), |
| 110 | axis::regular<>(10, 0, 1), axis::regular<>(10, 0, 1), |
| 111 | axis::regular<>(10, 0, 1), axis::regular<>(10, 0, 1)); |
| 112 | |
| 113 | auto t = clock(); |
| 114 | for (unsigned i = 0; i < n / 6; ++i) { |
| 115 | h(r[6 * i], r[6 * i + 1], r[6 * i + 2], r[6 * i + 3], r[6 * i + 4], r[6 * i + 5]); |
| 116 | } |
| 117 | t = clock() - t; |
| 118 | best = std::min(best, double(t) / CLOCKS_PER_SEC); |
| 119 | } |
| 120 | |
| 121 | return best; |
| 122 | } |
| 123 | |
| 124 | int main() { |
| 125 | const unsigned nfill = 6000000; |
nothing calls this directly
no test coverage detected