Uploaded image for project: 'Apache Drill'
  1. Apache Drill
  2. DRILL-1095 Add support for large number of columns in queries
  3. DRILL-1167

Split large runtime generated functions into a chain of functions

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 0.4.0
    • 0.4.0
    • Execution - Codegen
    • None

    Description

      Since a Java function can not grow beyond 64kb (of byte code), it would be useful to split such functions into multiple functions and invoke them as a chain.

      For example, the following function

      public boolean doEval() {
        //block 0:
        {
          ...
        }
      ...
        //block m-1:
        {
          ...
        }
        //block m:
        {
          ...
        }
      ...
        //block n:
        {
          ...
        }
        {
          return true;
        }
      }
      

      Can be re-written as:

      public boolean doEval() {
        //block 0:
        {
          ...
        }
      ...
        //block m-1:
        {
          ...
        }
        return doEval0();
      }
      
      public boolean doEval0() {
        //block m:
        {
          ...
        }
      ...
        //block n:
        {
          ...
        }
        {
          return true;
        }
      }
      

      Attachments

        Activity

          People

            adityakishore Aditya Kishore
            adityakishore Aditya Kishore
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: