zhouqingqing / qpmodel

A Relational Optimizer and Executor
MIT License
64 stars 18 forks source link

[Exec] issue collections #190

Open zhouqingqing opened 3 years ago

zhouqingqing commented 3 years ago
  1. wasted row construction in join operation:

we have this pattern in join:

                            n = ExecProject(new Row(v.row_, r));

and in ExecProject(Row input)

        {
            Row r = new Row(output.Count);
 ...
            return r;
        }

So we construct result row twice. If ExecProject can take (Row left, Row right) as input, we don't have to waste one construction. Notes a straightforward idea may need changes in algebrizer ordinal resolution, but it might be possible to do it without touching algebrizer.

  1. enhance distributed profiling:

(actual rows = 100, loops = 10) => (actual rows = 93..105, loops = 10)

we can further print details if with EXPLAIN VERBOSE

(actual rows = 93..105, loops = 10)
    thread 1: actual rows = 98
    thread 2: actual rows = 105
    ...
    thread 10: actual rows = 100