qpmodel
qpmodel copied to clipboard
codegen todo items
- not all operators are implemented
- research an inter-op implementation framework to support half codegen and half interpreted plan (Expr already support it)
- ~~Row copy avoidance: a major source is join where we merge two rows into one. This can be avoided if we allow two rows interface but could complicate code much~~ (removed as it is not a simple codegen issue).
Research items:
- CodeGen still template based, which is difficult to maintain (though better than llvm). LMS is not limited to Scala, Python also have one (https://github.com/jmd1011/snek-LMS) - is it possible to do similar for C/C++ to make codegen easier?
@zhouruiapple you can start with more PhysicNode coverage.
@zhouqingqing got it.
@zhouqingqing We usually express logical plans in relational algebra to analyse sql semantics. But we express logical plans in the following way.
{Agg(filter((a Inner (c Inner b))): a.a1[0]>b.b1[0] and a.a2[1]>c.c2[1])}
Is there any guidance or reference to help me understand the above expression? Looks like recursive descent analysis as syntax parsing. But I want to understand the theory of logic plan.
But we express logical plans in the following way
Where did you get this? Is this some ToString() output? ToString() is a simplified output of actual plan.
See how we construct a plan at : https://github.com/zhouqingqing/qpmodel/blob/master/qpmodel/Plan.cs::CreateSinglePlan().
@zhouqingqing So this is just ToString() output in LISP format. OK, I understand, thanks.