private int cmpDataSize(TableScanOperator o1, TableScanOperator o2) {
      long ds1 = o1.getStatistics() == null ? -1 : o1.getStatistics().getDataSize();
      long ds2 = o2.getStatistics() == null ? -1 : o2.getStatistics().getDataSize();
      if (ds1 == ds2) {
        return 0;
      }
      if (ds1 < ds2) {
        return 1;
      } else {
        return -1;
      }
    }
Orders TS operators in decreasing order by "weight".
ql/src/java/org/apache/hadoop/hive/ql/optimizer/SharedWorkOptimizer.java