@Override
  public void onResultCalculated(Object result, Range range) {
    this.previousSum = computeValue(sum);
    this.previousCount = nonNullGroupCount;
    this.previousRange = range;
  }
This optimization is the vectorized counterpart of HIVE-15617.
ql/src/java/org/apache/hadoop/hive/ql/exec/vector/ptf/VectorPTFEvaluatorAbstractAvg.java