Commit Graph

1233 Commits

Author SHA1 Message Date
Dmitry Novik
65121b712e Merge remote-tracking branch 'origin/master' into enable-analyzer 2024-03-26 19:02:30 +01:00
Dmitry Novik
8bd49aa303 Try to fix perf tests 2024-03-25 17:06:42 +01:00
Yarik Briukhovetskyi
20a45b4073
Merge pull request #61564 from liuneng1994/optimize_in_single_value
New analyzer pass to optimize in single value
2024-03-25 12:53:01 +01:00
李扬
be68b21de4
Merge branch 'ClickHouse:master' into opt_memcpy_small 2024-03-21 11:27:10 +08:00
Raúl Marín
6c7be89c61
Merge pull request #61100 from Algunenano/experiment_int128
30x faster printing for 256-bit integers
2024-03-20 12:32:26 +01:00
liuneng
a29d4f5db2 fix bug 2024-03-20 10:24:57 +08:00
liuneng
532d72a7d8 add test case 2024-03-19 17:30:16 +08:00
Raúl Marín
4626a0b3a1 Merge remote-tracking branch 'blessed/master' into experiment_int128 2024-03-18 16:10:32 +01:00
Robert Schulze
f02db275c5
Merge remote-tracking branch 'rschu1ze/master' into dotProduct-memcpy 2024-03-18 09:26:29 +00:00
李扬
9296be3747
Merge branch 'ClickHouse:master' into opt_memcpy_small 2024-03-18 10:35:09 +08:00
Sema Checherinda
025ad9791c
Merge pull request #58879 from azat/small-block-lock-contention
Improve query performance in case of very small blocks
2024-03-13 17:08:37 +01:00
Raúl Marín
cc92b8ffc5 Merge remote-tracking branch 'blessed/master' into experiment_int128 2024-03-13 13:57:41 +01:00
taiyang-li
dc9548d31b add perf test 2024-03-13 18:57:33 +08:00
Raúl Marín
45efa69189 Add perf tests 2024-03-08 15:17:59 +01:00
Robert Schulze
245ea0c186
Implement const/non-const shortcut 2024-03-06 16:56:01 +00:00
taiyang-li
8b2e163d76 Merge remote-tracking branch 'origin/master' into opt_multiif_decimal 2024-03-05 17:17:10 +08:00
Nikita Taranov
bcd3ad01de
Merge pull request #55809 from amosbird/alt-51399
Improve the performance of serialized aggregation method when involving multiple [nullable] columns
2024-03-01 22:44:56 +01:00
Amos Bird
3b04f5c605
Improve the performance of serialized aggregation method when involving multiple [nullable] columns. 2024-02-29 21:48:15 +08:00
taiyang-li
f7d1739808 fix failed uts 2024-02-29 15:00:09 +08:00
Raúl Marín
c1c4a8c02a Merge remote-tracking branch 'blessed/master' into argmin_optimization 2024-02-27 12:49:18 +01:00
Azat Khuzhin
a34f42ca22 Remove lock from the ReadProgressCallback
It looks redundant (added in 5ef51ed), though it has "fix tests" in the
log message, but CI reports is not available for the commits from that
PR [1], so let's try.

  [1]: https://github.com/ClickHouse/ClickHouse/pull/37543

Also this can be a big problem, since the code under that lock
(throttling or quotas with previous implementation that uses
boost::atomic_shared_ptr) may sleep.

Some numbers:

    run                     | time
    ------------------------|------
    max_threads=100 before  | 23.1
    max_threads=100 after   | 15.1
    max_threads=4500 before | 4.5
    max_threads=4500 after  | 2.3

Query:

    select sum(number) from numbers_mt(2000000) settings max_threads=X, max_block_size = 1

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2024-02-22 18:00:55 +01:00
Robert Schulze
ae597d86dd
Merge remote-tracking branch 'rschu1ze/master' into vector-dot-product 2024-02-22 10:16:28 +00:00
Azat Khuzhin
a4f765cae7
Improve performance of SELECTs with active mutations (#59531)
* Configure keeper for perf tests

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>

* Improve performance of SELECTs with active mutations

getAlterMutationCommandsForPart() can be a hot path for query execution
when there are pending mutations.

- LOG_TEST - it is not only check one bool, but actually a bunch of
  atomics as well.

- Return std::vector over std::map (map is not required there) - no
  changes in performance.

- Copy only RENAME_COLUMN (since only this mutation is required by
  AlterConversions).

And here are results:

run|result
-|-
SELECT w/o ALTER|queries: 1565, QPS: 355.259, RPS: 355.259
SELECT w/ ALTER unpatched|queries: 2099, QPS: 220.623, RPS: 220.623
SELECT w/ ALTER and w/o LOG_TEST|queries: 2730, QPS: 235.859, RPS: 235.859
SELECT w/ ALTER and w/o LOG_TEST and w/ RENAME_COLUMN only|queries: 2995, QPS: 290.982, RPS: 290.982

But there are still room for improvements, at least MergeTree engines
could implement getStorageSnapshotForQuery().

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>

* Add AlterConversions::supportsMutationCommandType(), flatten vector<vector<MutationCommand>>

* Work around what appears to be a clang static analysis bug

---------

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
Co-authored-by: Michael Kolupaev <michael.kolupaev@clickhouse.com>
2024-02-22 08:51:10 +00:00
Kruglov Pavel
10535132c3
Merge pull request #59385 from Avogar/fix-bad-types-check
Fix validating suspicious/experimental types in nested types
2024-02-21 14:38:01 +01:00
Robert Schulze
7d354164a5
Add performance test for dotProduct() 2024-02-20 21:41:10 +00:00
taiyang-li
2d6b4b400c Merge remote-tracking branch 'origin/master' into opt_sum_decimal 2024-02-19 12:25:22 +08:00
avogar
109720d162 Merge branch 'master' of github.com:ClickHouse/ClickHouse into fix-bad-types-check 2024-02-15 12:10:49 +00:00
Raúl Marín
11519f949b
Merge pull request #59731 from kitaisreal/asof-join-try-sort-with-radix-sort
ASOF JOIN use trySort with RadixSort
2024-02-14 15:54:22 +01:00
avogar
64779835fa Update tests 2024-02-14 12:48:05 +00:00
李扬
90d07ba82c
Trivial optimize of function coalesce. (#59627)
* reuse result of functionfactory::get

* add perf test

* Update src/Functions/coalesce.cpp

Co-authored-by: János Benjamin Antal <antaljanosbenjamin@users.noreply.github.com>

* change as requested

---------

Co-authored-by: János Benjamin Antal <antaljanosbenjamin@users.noreply.github.com>
2024-02-14 11:29:45 +01:00
Maksim Kita
2caf3f0fbb Fixed tests 2024-02-13 15:41:17 +03:00
Maksim Kita
a359ceecb5 ASOF JOIN use trySort with RadixSort 2024-02-13 15:41:17 +03:00
Raúl Marín
d17b0867e6 Merge remote-tracking branch 'blessed/master' into argmin_optimization 2024-02-09 13:08:23 +01:00
taiyang-li
549b77021d add some perf tests 2024-02-04 15:55:22 +08:00
taiyang-li
ddc6aad8ff merge master 2024-02-01 10:58:33 +08:00
Raúl Marín
f67bff12b7
Merge pull request #59148 from bigo-sg/improve_if_with_floating
Continue optimizing branch miss of if function when result type is float*/decimal*/int*
2024-01-31 12:42:06 +01:00
taiyang-li
2ad7607bad opt if when input type is map 2024-01-31 17:33:47 +08:00
Maksim Kita
20c1f0c18f Revert "Revert "Add new aggregation function groupArraySorted()"" 2024-01-30 17:15:29 +03:00
Raúl Marín
cda39e64e4 Perf: Only consider XML files 2024-01-29 17:47:50 +01:00
Raúl Marín
6a2fcb778f Restore comment 2024-01-29 13:07:30 +01:00
Raúl Marín
c79a151cca Simplify query_run_metric_arrays in perf tests 2024-01-29 13:00:49 +01:00
taiyang-li
49fc8a7099 Merge branch 'master' into improve_if_with_floating 2024-01-29 11:02:05 +08:00
Azat Khuzhin
44e42052b1 Fix perf tests after sumMap starts to filter out -0.
Before perf tests was relying on the following:

    SELECT sumMap(['foo', 'bar'], [-0., -0.])

    ┌─sumMap(['foo', 'bar'], [-0., -0.])─┐
    │ (['bar','foo'],[-0,-0])            │
    └────────────────────────────────────┘

While it got changed, and now:

    ┌─sumMap(['foo', 'bar'], [-0., -0.])─┐
    │ ([],[])                            │
    └────────────────────────────────────┘

But it works for nan:

    SELECT sumMap(['foo', 'bar'], [nan, nan])

    ┌─sumMap(['foo', 'bar'], [nan, nan])─┐
    │ (['bar','foo'],[nan,nan])          │
    └────────────────────────────────────┘

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2024-01-27 13:14:07 +01:00
taiyang-li
56db02c953 Merge branch 'master' into improve_if_with_floating 2024-01-26 19:21:49 +08:00
taiyang-li
e8629cf4f5 add another perf and tests 2024-01-25 18:02:55 +08:00
taiyang-li
a657a2631f add perf tests 2024-01-24 19:58:07 +08:00
Robert Schulze
a4c6f87fb9
Further reduce runtime of norm_distance.xml 2024-01-23 10:52:52 +00:00
Raúl Marín
1e00dec997 Merge remote-tracking branch 'blessed/master' into argmin_optimization 2024-01-22 14:56:55 +01:00
Dmitry Novik
a18a8d8ea3
Merge pull request #59009 from nickitat/uniq_optimisation_for_distributed
`uniqExact` state parallel merging for distributed queries
2024-01-22 14:05:02 +01:00
Nikita Taranov
2b5482be8c add perf test 2024-01-19 17:57:11 +01:00