[
https://issues.apache.org/jira/browse/IMPALA-6069?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Thomas Tauber-Marshall resolved IMPALA-6069.
--------------------------------------------
Resolution: Fixed
Fix Version/s: Impala 2.11.0
commit e94c60833a36728ae9ecbf22c161c0d7f41a7184
Author: Thomas Tauber-Marshall <[email protected]>
Date: Thu Dec 7 11:20:46 2017 -0800
IMPALA-6069: Fix CodegenAnyVal's handling of 'nan'
Previously, CodegenAnyVal used an LLVM function for floating point
comparison that considered 'nan' = 'nan' to be true. This is
inconsistent with the way we handle 'nan' in the non-codegen path,
where we consider 'nan' = 'nan' to be false, leading to inconsisent
results.
This patch fixes CodegenAnyVal to use an LLVM function for floating
point comparison that considers 'nan' = 'nan' to be false.
Testing:
- Added e2e tests for the two scenarios affected by this: CASE and
joins.
Change-Id: I1bb8e5074b3c939927dedc46bc9db63ca24486a1
Reviewed-on: http://gerrit.cloudera.org:8080/8790
Reviewed-by: Tim Armstrong <[email protected]>
Reviewed-by: Michael Ho <[email protected]>
Tested-by: Impala Public Jenkins
> Incorrect handling of Nan with join and codegen
> -----------------------------------------------
>
> Key: IMPALA-6069
> URL: https://issues.apache.org/jira/browse/IMPALA-6069
> Project: IMPALA
> Issue Type: Bug
> Components: Backend
> Affects Versions: Impala 2.11.0
> Reporter: Thomas Tauber-Marshall
> Assignee: Thomas Tauber-Marshall
> Priority: Critical
> Fix For: Impala 2.11.0
>
>
> Repro:
> {noformat}
> > create table test (col0 float);
> > insert into test values (0), (cast('nan' as float));
> > select * from test a, test b where a.col0 = b.col0;
> +------+------+
> | col0 | col0 |
> +------+------+
> | 0 | 0 |
> | NaN | NaN |
> +------+------+
> > set disable_codegen=true;
> > select * from test a, test b where a.col0 = b.col0;
> +------+------+
> | col0 | col0 |
> +------+------+
> | 0 | 0 |
> +------+------+
> {noformat}
> I think the version without codegen is the intended behavior (because 'Nan' =
> 'Nan' is false)
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)