ClickHouse's Hash Join Stores the Right Table as 64-bit Row Words
The ClickHouse hash join keeps the right table as blocks and stores one tagged 64-bit row word per hash-table cell.
The ClickHouse hash join keeps the right table as blocks and stores one tagged 64-bit row word per hash-table cell.
ClickHouse’s merge join advances two sorted cursors in lockstep and uses a fused compare-and-run-search to skip whole equal-key runs.
ClickHouse’s TCP handler interleaves sending results with reading the next command on a timer, piggybacking logs and progress onto the output stream.
ClickHouse’s thread pool wakes the most recently idle thread, and its counters are sharded per CPU so that counting never costs a cache-line ping-pong.
ClickHouse’s throttler is a token bucket that sleeps for the token deficit and parks the caller’s CPU lease so the wait need not consume concurrency budget.