diff --git a/arrow/Cargo.toml b/arrow/Cargo.toml index 2346ced787b2..f23217bdc9b9 100644 --- a/arrow/Cargo.toml +++ b/arrow/Cargo.toml @@ -51,6 +51,7 @@ flatbuffers = "^0.8" hex = "0.4" prettytable-rs = { version = "0.8.0", optional = true } lexical-core = "^0.7" +multiversion = "0.6.1" [features] default = [] diff --git a/arrow/src/compute/kernels/aggregate.rs b/arrow/src/compute/kernels/aggregate.rs index d0e3f22f5417..a01b29e7b09b 100644 --- a/arrow/src/compute/kernels/aggregate.rs +++ b/arrow/src/compute/kernels/aggregate.rs @@ -17,6 +17,7 @@ //! Defines aggregations over Arrow arrays. +use multiversion::multiversion; use std::ops::Add; use crate::array::{ @@ -103,6 +104,8 @@ pub fn min_string( } /// Helper function to perform min/max lambda function on values from a numeric array. +#[multiversion] +#[clone(target = "x86_64+avx")] fn min_max_helper(array: &PrimitiveArray, cmp: F) -> Option where T: ArrowNumericType,