Skip to content

Stop RunEnd pushdown from failing on unused runs - #11690

Draft
connortsui20 wants to merge 1 commit into
developfrom
ct/runend-unreferenced-runs
Draft

connortsui20 wants to merge 1 commit into
developfrom
ct/runend-unreferenced-runs

Conversation

@connortsui20

@connortsui20 connortsui20 commented Nov 20, 2026 •

Copy link
Copy Markdown
Member

RunEnd pushes a cast or a scalar function into its values, so it runs on every run, including runs that the offset and length skip. A cast or function that can fail then fails on a value that no row exposes. For example, checked_add on an i8 column fails on a hidden 127, and a cast to non-nullable fails on a hidden null run.

Reduce rules have no execution context, so they can't search the ends for the visible runs. They push down a cast or function that can fail only when cached statistics of the ends prove that every run is visible. Otherwise a new RunEnd cast kernel trims the runs at execution time, and other functions execute on the decoded array.

When the ends have no cached min and max, a function that can fail over a RunEnd column no longer pushes down into the runs. Casts that can't fail, such as a lossless widening, still push down.

Prepared with AI assistance.

Signed-off-by: Connor Tsui <connor.tsui20@gmail.com>
@codspeed

codspeed Bot commented Nov 20, 2026

Copy link
Copy Markdown

Merging this PR will degrade performance by 29.94%

1 warning

⚠️ Walltime results may be unreliable

Some benchmarks used the Walltime instrument outside CodSpeed Macro Runners, which can make the results inconsistent.

Learn more about Macro Runners

See affected benchmarks

❌ 1 regressed benchmark
✅ 1981 untouched benchmarks
⏩ 58 skipped benchmarks1

Warning

Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Mode Benchmark BASE HEAD Efficiency
❌ CPU Simulation filter_random_by_random[10000] 7.3 µs 10.5 µs -29.94%

Tip

Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.


Comparing ct/runend-unreferenced-runs (8ab5dfe) with develop (3a66a6b)

Open in CodSpeed

Footnotes

  1. 58 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog/fix A bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant