Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vectorize filter generation of ColumnNullable in FilterDescription #45962

Merged
merged 1 commit into from
Feb 7, 2023

Conversation

ZhiguoZh
Copy link
Contributor

@ZhiguoZh ZhiguoZh commented Feb 2, 2023

This commit achieved the data parallelism for filter generations of the nullable columns by replacing the logical AND operator with the bitwise one, which could be auto-vectorized by the compiler.

Changelog category (leave one):

  • Performance Improvement

Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):

This change could effectively reduce the overhead of obtaining the filter from ColumnNullable(UInt8) and improve the overall query performance. To evaluate the impact of this change, we adopted TPC-H benchmark but revised the column types from non-nullable to nullable, and we measured the QPS of its queries as the performance indicator.

We found with this change, Q07 and Q10, which spend 1.3% and 2.9% of total cycles in FilterDescription, could be improved by 1.80% and 1.95% respectively.

Information about CI checks: https://clickhouse.com/docs/en/development/continuous-integration/

@robot-ch-test-poll2 robot-ch-test-poll2 added the pr-performance Pull request with some performance improvements label Feb 2, 2023
@nickitat nickitat self-assigned this Feb 2, 2023
@nickitat nickitat added the can be tested Allows running workflows for external contributors label Feb 2, 2023
@ZhiguoZh
Copy link
Contributor Author

ZhiguoZh commented Feb 3, 2023

Hi Nikita, thanks for your review! And it seems that the failed tests were not related to this change. Could you help me take a look? Thanks!

@nickitat

@nickitat
Copy link
Member

nickitat commented Feb 3, 2023

01632_tinylog_read_write - failed because io_uring read method doesn't work
02540_date_column_consistent_insert_behaviour - flaky

This commit achieved the data parallelism for filter generations of
the nullable columns by replacing the logical AND operator with the
bitwise one, which could be auto-vectorized by the compiler.
@ZhiguoZh
Copy link
Contributor Author

ZhiguoZh commented Feb 7, 2023

Hi Nikita and Robert, I've added a comment in the patch and found the failed checks were unrelated to this implementation change. Thanks!

@nickitat @rschu1ze

@nickitat nickitat merged commit b43ffb9 into ClickHouse:master Feb 7, 2023
yokofly added a commit to timeplus-io/proton that referenced this pull request Jan 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
can be tested Allows running workflows for external contributors pr-performance Pull request with some performance improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants