aboutsummaryrefslogtreecommitdiff
path: root/mllib
diff options
context:
space:
mode:
authorDavies Liu <davies@databricks.com>2015-11-19 17:14:10 -0800
committerReynold Xin <rxin@databricks.com>2015-11-19 17:14:10 -0800
commitee21407747fb00db2f26d1119446ccbb20c19232 (patch)
tree60efa669e9da9e278d16484725d5eaa5ffd7b3ad /mllib
parentb2cecb80ece59a1c086d4ae7aeebef445a4e7299 (diff)
downloadspark-ee21407747fb00db2f26d1119446ccbb20c19232.tar.gz
spark-ee21407747fb00db2f26d1119446ccbb20c19232.tar.bz2
spark-ee21407747fb00db2f26d1119446ccbb20c19232.zip
[SPARK-11864][SQL] Improve performance of max/min
This PR has the following optimization: 1) The greatest/least already does the null-check, so the `If` and `IsNull` are not necessary. 2) In greatest/least, it should initialize the result using the first child (removing one block). 3) For primitive types, the generated greater expression is too complicated (`a > b ? 1 : (a < b) ? -1 : 0) > 0`), should be as simple as `a > b` Combine these optimization, this could improve the performance of `ss_max` query by 30%. Author: Davies Liu <davies@databricks.com> Closes #9846 from davies/improve_max.
Diffstat (limited to 'mllib')
0 files changed, 0 insertions, 0 deletions