diff --git a/dbms/tests/performance/functions_geo.xml b/dbms/tests/performance/functions_geo.xml
index 1a13262d52f..a4233b2fe57 100644
--- a/dbms/tests/performance/functions_geo.xml
+++ b/dbms/tests/performance/functions_geo.xml
@@ -1,21 +1,20 @@
- once
+ loop
- 1000
5000
- SELECT count() FROM system.numbers WHERE NOT ignore(geohashEncode((number % 150)*1.1 - 75, (number * 3.14 % 300)*1.1 - 150))
- SELECT count() FROM system.numbers WHERE NOT ignore(geohashDecode(toString(number % 1000000)))
+ SELECT count() FROM numbers(1000000) WHERE NOT ignore(geohashEncode((number % 150)*1.1 - 75, (number * 3.14 % 300)*1.1 - 150))
+ SELECT count() FROM numbers(1000000) WHERE NOT ignore(geohashDecode(toString(number % 1000000)))
- SELECT count() FROM system.numbers WHERE NOT ignore(geohashEncode(1.0/rand(), 2.0/rand()))
- SELECT count() FROM system.numbers WHERE NOT ignore(geohashDecode(toString(rand() % 1000000)))
+ SELECT count() FROM numbers(1000000) WHERE NOT ignore(geohashEncode(1.0/rand(), 2.0/rand()))
+ SELECT count() FROM numbers(1000000) WHERE NOT ignore(geohashDecode(toString(rand() % 1000000)))
- SELECT count() FROM system.numbers WHERE NOT ignore(geohashEncode(number + 91.0, number + 181.0))
- SELECT count() FROM system.numbers WHERE NOT ignore(geohashDecode(hex(number)))
+ SELECT count() FROM numbers(1000000) WHERE NOT ignore(geohashEncode(number + 91.0, number + 181.0))
+ SELECT count() FROM numbers(1000000) WHERE NOT ignore(geohashDecode(hex(number)))
diff --git a/dbms/tests/performance/great_circle_dist.xml b/dbms/tests/performance/great_circle_dist.xml
index 99382543d60..3edfc2c8008 100644
--- a/dbms/tests/performance/great_circle_dist.xml
+++ b/dbms/tests/performance/great_circle_dist.xml
@@ -1,16 +1,15 @@
- once
+ loop
- 1000
10000
- SELECT count() FROM system.numbers WHERE NOT ignore(greatCircleDistance((rand(1) % 360) * 1. - 180, (number % 150) * 1.2 - 90, (number % 360) + toFloat64(rand(2)) / 4294967296 - 180, (rand(3) % 180) * 1. - 90))
+ SELECT count() FROM numbers(1000000) WHERE NOT ignore(greatCircleDistance((rand(1) % 360) * 1. - 180, (number % 150) * 1.2 - 90, (number % 360) + toFloat64(rand(2)) / 4294967296 - 180, (rand(3) % 180) * 1. - 90))
- SELECT count() FROM system.numbers WHERE NOT ignore(greatCircleDistance(55. + toFloat64(rand(1)) / 4294967296, 37. + toFloat64(rand(2)) / 4294967296, 55. + toFloat64(rand(3)) / 4294967296, 37. + toFloat64(rand(4)) / 4294967296))
+ SELECT count() FROM numbers(1000000) WHERE NOT ignore(greatCircleDistance(55. + toFloat64(rand(1)) / 4294967296, 37. + toFloat64(rand(2)) / 4294967296, 55. + toFloat64(rand(3)) / 4294967296, 37. + toFloat64(rand(4)) / 4294967296))
diff --git a/dbms/tests/performance/group_array_moving_sum.xml b/dbms/tests/performance/group_array_moving_sum.xml
index 504a8b133a1..6939989c5b4 100644
--- a/dbms/tests/performance/group_array_moving_sum.xml
+++ b/dbms/tests/performance/group_array_moving_sum.xml
@@ -7,32 +7,31 @@
30000
- 6000
60000
- CREATE TABLE moving_sum_1m(k UInt64, v UInt64) ENGINE = MergeTree ORDER BY k
- CREATE TABLE moving_sum_10m(k UInt64, v UInt64) ENGINE = MergeTree ORDER BY k
+ CREATE TABLE moving_sum_100m(k UInt64, v UInt64) ENGINE = MergeTree ORDER BY k
+ CREATE TABLE moving_sum_1000m(k UInt64, v UInt64) ENGINE = MergeTree ORDER BY k
- INSERT INTO moving_sum_1m SELECT number%100, rand() from numbers(1000000)
- INSERT INTO moving_sum_10m SELECT number%100, rand() from numbers(10000000)
+ INSERT INTO moving_sum_100m SELECT number%100, rand() from numbers(100000000)
+ INSERT INTO moving_sum_1000m SELECT number%100, rand() from numbers(1000000000)
- SELECT k,groupArrayMovingSum(10)(v) FROM moving_sum_1m GROUP BY k
- SELECT k,groupArrayMovingSum(10)(v) FROM moving_sum_1m WHERE k in (49, 50, 51) GROUP BY k
- SELECT k,groupArrayMovingSum(1000)(v) FROM moving_sum_1m GROUP BY k
- SELECT k,groupArrayMovingSum(1000)(v) FROM moving_sum_1m WHERE k in (49, 50, 51) GROUP BY k
- SELECT k,groupArrayMovingSum(10000)(v) FROM moving_sum_1m GROUP BY k
- SELECT k,groupArrayMovingSum(10000)(v) FROM moving_sum_1m WHERE k in (49, 50, 51) GROUP BY k
+ SELECT k,groupArrayMovingSum(10)(v) FROM moving_sum_100m GROUP BY k FORMAT Null
+ SELECT k,groupArrayMovingSum(10)(v) FROM moving_sum_100m WHERE k in (49, 50, 51) GROUP BY k FORMAT Null
+ SELECT k,groupArrayMovingSum(1000)(v) FROM moving_sum_100m GROUP BY k FORMAT Null
+ SELECT k,groupArrayMovingSum(1000)(v) FROM moving_sum_100m WHERE k in (49, 50, 51) GROUP BY k FORMAT Null
+ SELECT k,groupArrayMovingSum(10000)(v) FROM moving_sum_100m GROUP BY k FORMAT Null
+ SELECT k,groupArrayMovingSum(10000)(v) FROM moving_sum_100m WHERE k in (49, 50, 51) GROUP BY k FORMAT Null
- SELECT k,groupArrayMovingSum(10)(v) FROM moving_sum_10m GROUP BY k
- SELECT k,groupArrayMovingSum(10)(v) FROM moving_sum_10m WHERE k in (49, 50, 51) GROUP BY k
- SELECT k,groupArrayMovingSum(1000)(v) FROM moving_sum_10m GROUP BY k
- SELECT k,groupArrayMovingSum(1000)(v) FROM moving_sum_10m WHERE k in (49, 50, 51) GROUP BY k
- SELECT k,groupArrayMovingSum(10000)(v) FROM moving_sum_10m GROUP BY k
- SELECT k,groupArrayMovingSum(10000)(v) FROM moving_sum_10m WHERE k in (49, 50, 51) GROUP BY k
+ SELECT k,groupArrayMovingSum(10)(v) FROM moving_sum_1000m GROUP BY k FORMAT Null
+ SELECT k,groupArrayMovingSum(10)(v) FROM moving_sum_1000m WHERE k in (49, 50, 51) GROUP BY k FORMAT Null
+ SELECT k,groupArrayMovingSum(1000)(v) FROM moving_sum_1000m GROUP BY k FORMAT Null
+ SELECT k,groupArrayMovingSum(1000)(v) FROM moving_sum_1000m WHERE k in (49, 50, 51) GROUP BY k FORMAT Null
+ SELECT k,groupArrayMovingSum(10000)(v) FROM moving_sum_1000m GROUP BY k FORMAT Null
+ SELECT k,groupArrayMovingSum(10000)(v) FROM moving_sum_1000m WHERE k in (49, 50, 51) GROUP BY k FORMAT Null
- DROP TABLE IF EXISTS moving_sum_10m
- DROP TABLE IF EXISTS moving_sum_1m
+ DROP TABLE IF EXISTS moving_sum_1000m
+ DROP TABLE IF EXISTS moving_sum_100m
diff --git a/dbms/tests/performance/h3.xml b/dbms/tests/performance/h3.xml
index 7381f559a0f..3a6d5940d0d 100644
--- a/dbms/tests/performance/h3.xml
+++ b/dbms/tests/performance/h3.xml
@@ -1,14 +1,13 @@
- once
+ loop
- 2000
10000
- SELECT count() FROM system.numbers WHERE NOT ignore(geoToH3(37.62 + rand(1) / 0x100000000, 55.75 + rand(2) / 0x100000000, 15))
+ SELECT count() FROM numbers(100000) WHERE NOT ignore(geoToH3(37.62 + rand(1) / 0x100000000, 55.75 + rand(2) / 0x100000000, 15))
diff --git a/dbms/tests/performance/if_array_num.xml b/dbms/tests/performance/if_array_num.xml
index 417b82a9d0c..d4c9c29dd99 100644
--- a/dbms/tests/performance/if_array_num.xml
+++ b/dbms/tests/performance/if_array_num.xml
@@ -1,18 +1,17 @@
- once
+ loop
- 1000
10000
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? [1, 2, 3] : [4, 5])
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? [1, 2, 3] : materialize([4, 5]))
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? materialize([1, 2, 3]) : materialize([4, 5]))
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? [1, 2, 3] : [400, 500])
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? [1, 2, 3] : materialize([400, 500]))
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? materialize([1, 2, 3]) : materialize([400, 500]))
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? [1, 2, 3] : [4, 5])
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? [1, 2, 3] : materialize([4, 5]))
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? materialize([1, 2, 3]) : materialize([4, 5]))
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? [1, 2, 3] : [400, 500])
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? [1, 2, 3] : materialize([400, 500]))
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? materialize([1, 2, 3]) : materialize([400, 500]))
diff --git a/dbms/tests/performance/if_array_string.xml b/dbms/tests/performance/if_array_string.xml
index e1d8485adc2..235051fc905 100644
--- a/dbms/tests/performance/if_array_string.xml
+++ b/dbms/tests/performance/if_array_string.xml
@@ -1,18 +1,17 @@
- once
+ loop
- 1000
10000
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? ['Hello', 'World'] : ['a', 'b', 'c'])
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? materialize(['Hello', 'World']) : ['a', 'b', 'c'])
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? ['Hello', 'World'] : materialize(['a', 'b', 'c']))
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? materialize(['Hello', 'World']) : materialize(['a', 'b', 'c']))
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? materialize(['', '']) : emptyArrayString())
- SELECT count() FROM system.numbers WHERE NOT ignore(rand() % 2 ? materialize(['https://github.com/ClickHouse/ClickHouse/pull/1070', 'https://www.google.ru/search?newwindow=1&site=&source=hp&q=zookeeper+wire+protocol+exists&oq=zookeeper+wire+protocol+exists&gs_l=psy-ab.3...330.6300.0.6687.33.28.0.0.0.0.386.4838.0j5j9j5.19.0....0...1.1.64.psy-ab..14.17.4448.0..0j35i39k1j0i131k1j0i22i30k1j0i19k1j33i21k1.r_3uFoNOrSU']) : emptyArrayString())
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? ['Hello', 'World'] : ['a', 'b', 'c'])
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? materialize(['Hello', 'World']) : ['a', 'b', 'c'])
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? ['Hello', 'World'] : materialize(['a', 'b', 'c']))
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? materialize(['Hello', 'World']) : materialize(['a', 'b', 'c']))
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? materialize(['', '']) : emptyArrayString())
+ SELECT count() FROM numbers(10000000) WHERE NOT ignore(rand() % 2 ? materialize(['https://github.com/ClickHouse/ClickHouse/pull/1070', 'https://www.google.ru/search?newwindow=1&site=&source=hp&q=zookeeper+wire+protocol+exists&oq=zookeeper+wire+protocol+exists&gs_l=psy-ab.3...330.6300.0.6687.33.28.0.0.0.0.386.4838.0j5j9j5.19.0....0...1.1.64.psy-ab..14.17.4448.0..0j35i39k1j0i131k1j0i22i30k1j0i19k1j33i21k1.r_3uFoNOrSU']) : emptyArrayString())