Skip to content

Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks#87231

Merged
azat merged 4 commits intoClickHouse:masterfrom
azat:squashing-convert-to-full-column
Sep 22, 2025
Merged

Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks#87231
azat merged 4 commits intoClickHouse:masterfrom
azat:squashing-convert-to-full-column

Conversation

@azat
Copy link
Copy Markdown
Member

@azat azat commented Sep 17, 2025

Changelog category (leave one):

  • Bug Fix (user-visible misbehavior in an official stable release)

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

Fix "Too large size passed to allocator" LOGICAL_ERROR in JOIN due to mixed const and non-const blocks

The first patch in the series fixes this LOGICAL_ERROR, second one removes explicit materialization from INSERT and update the test, the third removes explicit materialization from views.

Follow-up for: #72226 (cc @vdimir )
Partial revert of: #86230

…t and non-const blocks

It is possible to get const and non-const block after JOIN, so let's
improve ClickHouse#72226 to convert column to full if the serilizations does not
match, and add a test.
@azat azat requested a review from vdimir September 17, 2025 11:40
@clickhouse-gh
Copy link
Copy Markdown
Contributor

clickhouse-gh bot commented Sep 17, 2025

Workflow [PR], commit [af996ed]

Summary:

job_name test_name status info comment
Stateless tests (amd_binary, ParallelReplicas, s3 storage, parallel) failure
03580_s3queue_settings_store FAIL
Exception in test runner FAIL
Killed by signal (in clickhouse-server.log or clickhouse-server.err.log) FAIL
Fatal messages (in clickhouse-server.log or clickhouse-server.err.log) FAIL
Stress test (amd_msan) failure
Server died FAIL
Hung check failed, possible deadlock found (see hung_check.log) FAIL
Killed by signal (in clickhouse-server.log) FAIL
Fatal message in clickhouse-server.log (see fatal_messages.txt) FAIL
Killed by signal (output files) FAIL
Found signal in gdb.log FAIL

@clickhouse-gh clickhouse-gh bot added the pr-bugfix Pull request with bugfix, not backported by default label Sep 17, 2025
@azat azat added the pr-must-backport Pull request should be backported intentionally. Use this label with great care! label Sep 17, 2025
@vdimir vdimir self-assigned this Sep 22, 2025
@azat azat enabled auto-merge September 22, 2025 15:31
@azat azat added this pull request to the merge queue Sep 22, 2025
Merged via the queue into ClickHouse:master with commit 8917a68 Sep 22, 2025
120 of 123 checks passed
@azat azat deleted the squashing-convert-to-full-column branch September 22, 2025 20:25
@robot-clickhouse-ci-2 robot-clickhouse-ci-2 added the pr-synced-to-cloud The PR is synced to the cloud repo label Sep 22, 2025
@robot-ch-test-poll1 robot-ch-test-poll1 added pr-backports-created-cloud deprecated label, NOOP pr-must-backport-synced The `*-must-backport` labels are synced into the cloud Sync PR labels Sep 22, 2025
robot-clickhouse added a commit that referenced this pull request Sep 22, 2025
Cherry pick #87231 to 25.7: Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks
robot-clickhouse added a commit that referenced this pull request Sep 22, 2025
…in JOIN due to mixed const and non-const blocks
robot-clickhouse added a commit that referenced this pull request Sep 22, 2025
Cherry pick #87231 to 25.8: Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks
robot-clickhouse added a commit that referenced this pull request Sep 22, 2025
…in JOIN due to mixed const and non-const blocks
robot-clickhouse added a commit that referenced this pull request Sep 22, 2025
Cherry pick #87231 to 25.9: Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks
robot-clickhouse added a commit that referenced this pull request Sep 22, 2025
…in JOIN due to mixed const and non-const blocks
clickhouse-gh bot added a commit that referenced this pull request Sep 22, 2025
Backport #87231 to 25.7: Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks
clickhouse-gh bot added a commit that referenced this pull request Sep 22, 2025
Backport #87231 to 25.8: Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks
azat added a commit that referenced this pull request Sep 23, 2025
Backport #87231 to 25.9: Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks
robot-clickhouse added a commit that referenced this pull request Sep 23, 2025
Cherry pick #87231 to 25.6: Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks
robot-clickhouse added a commit that referenced this pull request Sep 23, 2025
…in JOIN due to mixed const and non-const blocks
@robot-ch-test-poll3 robot-ch-test-poll3 added the pr-backports-created Backport PRs are successfully created, it won't be processed by CI script anymore label Sep 23, 2025
clickhouse-gh bot added a commit that referenced this pull request Sep 23, 2025
Backport #87231 to 25.6: Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks
azat added a commit that referenced this pull request Sep 23, 2025
…25.9/87449

* u/backport/25.9/87449:
  Backport #87426 to 25.9: Ignore only not found errors for s3_plain_rewritable (and some other S3 code)
  Backport #87231 to 25.9: Fix "Too large size passed to allocator" UB in JOIN due to mixed const and non-const blocks
  Backport #87198 to 25.9: Disable the setting by default
  Backport #87392 to 25.9: Fix EmbeddedRocksDB upgrade
  Backport #87140 to 25.9: fix: fix server level max temporary size limit
  Backport #87178 to 25.9: PR: fix LEFT/INNER ... RIGHT ... JOINS chain
  Update autogenerated version to 25.10.1.1 and contributors
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-backports-created Backport PRs are successfully created, it won't be processed by CI script anymore pr-backports-created-cloud deprecated label, NOOP pr-bugfix Pull request with bugfix, not backported by default pr-must-backport Pull request should be backported intentionally. Use this label with great care! pr-must-backport-synced The `*-must-backport` labels are synced into the cloud Sync PR pr-synced-to-cloud The PR is synced to the cloud repo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants