pingcap / pingcap/tiflash

Redundant BlockInputStream with project expression?

Open
#5,249 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type/question
Dominant language
C++
Stars
1k
Forks
423
Avg merge
1d 15h
Merged PRs (30d)
24

Description

General Question

While building BlockInputStream for join, an ExpressionBlockInputStream with projection will always be built. According to the comment, its aim is to remove useless columns. However, when the input columns are the same as the output columns, it will still be constructed. I think it might be a redundant BlockInputStream in this situation?

The code can be found at https://github.com/pingcap/tiflash/blob/f84d7e37e7c850891048ec3efb2cf80e5a32adb3/dbms/src/Flash/Coprocessor/DAGQueryBlockInterpreter.cpp#L318-L326

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at dbms/src/Flash/Coprocessor/DAGQueryBlockInterpreter.cpp around lines 318-326 and inspect how the join builds ExpressionBlockInputStream with projection. Compare the input and output columns in this path and trace any related stream behavior. Done means determining whether the stream is redundant when the columns match and recording or implementing the expected handling.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
databases
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.