Codegen is a common technique for performance. You can find its history from some research work (e.g. [1]).
[1] “Efficiently Compiling Efficient Query Plans for Modern Hardware,” PVLDB, vol. 4, no. 9, pp. 539–550, 2011 https://www.vldb.org/pvldb/vol4/p539-neumann.pdf 徐泷泽 <15258826...@qq.com> 于2020年5月14日周四 上午2:54写道: > Hi buddies ! > Our team is working on developing a mulit data source sql engine use > Calcite.But something confuse us, why calcite generate Java code > dynamicly on SQL query, it seen have performance issues in my opinion. > And building dynamic code object is very hard,the code is unreadable and > hard to understood, futhermore we can not debug it. > > > i wander why it was designed like that, what advantage of that .we > search on internet, > but nobody can realy explain it(may be we not goot at search, and poor > english). > so anybody can tell me the history of this, or give us some article. > > > applogize for my poor english, hope you know what i'm taking aboult. > thank you very very very much !