Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add benchmark tests for CAST INTEGER/BIGINT to DECIMAL (facebookincub…
…ator#9568) Summary: This PR adds `CAST INTEGER/BITINT to SHORT/LONG DECIMAL` benchmarking test. ``` ============================================================================ [...]hmarks/ExpressionBenchmarkBuilder.cpp relative time/iter iters/s ============================================================================ cast##try_cast_invalid_empty_input 888.87us 1.13K cast##tryexpr_cast_invalid_empty_input 366.60ms 2.73 cast##try_cast_invalid_nan 482.08ms 2.07 cast##tryexpr_cast_invalid_nan 834.13ms 1.20 cast##try_cast_valid 4.52ms 221.42 cast##tryexpr_cast_valid 4.52ms 221.16 cast##cast_valid 4.52ms 221.42 cast##cast_decimal_to_inline_string 2.21ms 451.69 cast##cast_short_decimal 3.14ms 318.79 cast##cast_long_decimal 5.05ms 197.88 cast##cast_large_real_to_scientific_notation 10.45ms 95.74 cast##cast_small_real_to_standard_notation 5.77ms 173.40 cast##cast_small_double_to_scientific_notation 12.60ms 79.39 cast##cast_large_double_to_standard_notation 7.34ms 136.21 cast##cast_timestamp 3.94ms 253.68 cast##cast_real_as_int 404.66us 2.47K cast##cast_decimal_as_bigint 969.12us 1.03K cast##cast_int_as_short_decimal 911.29us 1.10K cast##cast_int_as_long_decimal 925.29us 1.08K cast##cast_bigint_as_short_decimal 906.91us 1.10K cast##cast_bigint_as_long_decimal 922.87us 1.08K ``` The positive relative time implies Velox is slower compared to DuckDb: Here is how the relative time computed: ``` trialResults[actualTrials] = std::make_pair( max(0.0, double(nsecs.count()) / timeIterData.niter - globalBaseline), std::move(timeIterData.userCounters)); ``` Pull Request resolved: facebookincubator#9568 Reviewed By: Yuhta Differential Revision: D62599114 Pulled By: kevinwilfong fbshipit-source-id: 1bad04fd2418d2daa84cb45564ae9dd7f68e5818
- Loading branch information