You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@impala.apache.org by "Jim Apple (Code Review)" <ge...@cloudera.org> on 2019/02/10 05:23:01 UTC
[Impala-ASF-CR] IMPALA-5031: signed overflow is undefined behavior
Jim Apple has uploaded this change for review. ( http://gerrit.cloudera.org:8080/12426
Change subject: IMPALA-5031: signed overflow is undefined behavior
......................................................................
IMPALA-5031: signed overflow is undefined behavior
Tis patch fixes a signed overflow in the test
StringToDecimal.LargeDecimals. The interesting part of the backtrace
is:
util/string-parser.h:397:14: runtime error: signed integer overflow:
0x4b3b4ca85a86c47a098a223fffffffff * 10 cannot be represented in
type '__int128'
#0 void StringParser::ApplyExponent<__int128>(int, int,
signed char, __int128*, int*, int*) util/string-parser.h:397:14
#1 DecimalValue<__int128> StringParser::StringToDecimal<__int128>
(char const*, int, int, int, bool, StringParser::ParseResult*)
util/string-parser.h:221:5
#2 void VerifyParse<__int128>(string const&, int, int, bool,
DecimalValue<__int128> const&, StringParser::ParseResult)
runtime/decimal-test.cc:53:25
#3 void VerifyParse<__int128>(string const&, int, int,
DecimalValue<__int128> const&, StringParser::ParseResult)
runtime/decimal-test.cc:65:3
#4 StringToDecimal_LargeDecimals_Test::TestBody()
runtime/decimal-test.cc:443:3
Change-Id: Ifb4effa291e1e4dac62b84251c74c483d99b06e7
---
M be/src/util/string-parser.h
1 file changed, 2 insertions(+), 1 deletion(-)
git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/26/12426/1
--
To view, visit http://gerrit.cloudera.org:8080/12426
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifb4effa291e1e4dac62b84251c74c483d99b06e7
Gerrit-Change-Number: 12426
Gerrit-PatchSet: 1
Gerrit-Owner: Jim Apple <jb...@apache.org>
[Impala-ASF-CR] IMPALA-5031: signed overflow is undefined behavior
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12426 )
Change subject: IMPALA-5031: signed overflow is undefined behavior
......................................................................
Patch Set 2:
Build started: https://jenkins.impala.io/job/gerrit-verify-dryrun/3758/ DRY_RUN=false
--
To view, visit http://gerrit.cloudera.org:8080/12426
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ifb4effa291e1e4dac62b84251c74c483d99b06e7
Gerrit-Change-Number: 12426
Gerrit-PatchSet: 2
Gerrit-Owner: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Mon, 11 Feb 2019 20:38:19 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-5031: signed overflow is undefined behavior
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12426 )
Change subject: IMPALA-5031: signed overflow is undefined behavior
......................................................................
Patch Set 2: Verified+1
--
To view, visit http://gerrit.cloudera.org:8080/12426
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ifb4effa291e1e4dac62b84251c74c483d99b06e7
Gerrit-Change-Number: 12426
Gerrit-PatchSet: 2
Gerrit-Owner: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Tue, 12 Feb 2019 00:44:22 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-5031: signed overflow is undefined behavior
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/12426 )
Change subject: IMPALA-5031: signed overflow is undefined behavior
......................................................................
IMPALA-5031: signed overflow is undefined behavior
Tis patch fixes a signed overflow in the test
StringToDecimal.LargeDecimals. The interesting part of the backtrace
is:
util/string-parser.h:397:14: runtime error: signed integer overflow:
0x4b3b4ca85a86c47a098a223fffffffff * 10 cannot be represented in
type '__int128'
#0 void StringParser::ApplyExponent<__int128>(int, int,
signed char, __int128*, int*, int*) util/string-parser.h:397:14
#1 DecimalValue<__int128> StringParser::StringToDecimal<__int128>
(char const*, int, int, int, bool, StringParser::ParseResult*)
util/string-parser.h:221:5
#2 void VerifyParse<__int128>(string const&, int, int, bool,
DecimalValue<__int128> const&, StringParser::ParseResult)
runtime/decimal-test.cc:53:25
#3 void VerifyParse<__int128>(string const&, int, int,
DecimalValue<__int128> const&, StringParser::ParseResult)
runtime/decimal-test.cc:65:3
#4 StringToDecimal_LargeDecimals_Test::TestBody()
runtime/decimal-test.cc:443:3
Change-Id: Ifb4effa291e1e4dac62b84251c74c483d99b06e7
Reviewed-on: http://gerrit.cloudera.org:8080/12426
Reviewed-by: Jim Apple <jb...@apache.org>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
M be/src/util/string-parser.h
1 file changed, 2 insertions(+), 1 deletion(-)
Approvals:
Jim Apple: Looks good to me, approved
Impala Public Jenkins: Verified
--
To view, visit http://gerrit.cloudera.org:8080/12426
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ifb4effa291e1e4dac62b84251c74c483d99b06e7
Gerrit-Change-Number: 12426
Gerrit-PatchSet: 3
Gerrit-Owner: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
[Impala-ASF-CR] IMPALA-5031: signed overflow is undefined behavior
Posted by "Tim Armstrong (Code Review)" <ge...@cloudera.org>.
Tim Armstrong has posted comments on this change. ( http://gerrit.cloudera.org:8080/12426 )
Change subject: IMPALA-5031: signed overflow is undefined behavior
......................................................................
Patch Set 1:
I need to take a look to make sure that there's not a more serious bug here - generally the decimal code should be avoiding overflows in the first place.
--
To view, visit http://gerrit.cloudera.org:8080/12426
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ifb4effa291e1e4dac62b84251c74c483d99b06e7
Gerrit-Change-Number: 12426
Gerrit-PatchSet: 1
Gerrit-Owner: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Mon, 11 Feb 2019 18:06:12 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-5031: signed overflow is undefined behavior
Posted by "Jim Apple (Code Review)" <ge...@cloudera.org>.
Jim Apple has posted comments on this change. ( http://gerrit.cloudera.org:8080/12426 )
Change subject: IMPALA-5031: signed overflow is undefined behavior
......................................................................
Patch Set 2: Code-Review+2
rebase carry tim's +2
--
To view, visit http://gerrit.cloudera.org:8080/12426
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ifb4effa291e1e4dac62b84251c74c483d99b06e7
Gerrit-Change-Number: 12426
Gerrit-PatchSet: 2
Gerrit-Owner: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Mon, 11 Feb 2019 20:37:49 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-5031: signed overflow is undefined behavior
Posted by "Tim Armstrong (Code Review)" <ge...@cloudera.org>.
Tim Armstrong has posted comments on this change. ( http://gerrit.cloudera.org:8080/12426 )
Change subject: IMPALA-5031: signed overflow is undefined behavior
......................................................................
Patch Set 1: Code-Review+2
Ok, it looks like the code catches the overflow when the caller checks precision and scale.
--
To view, visit http://gerrit.cloudera.org:8080/12426
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ifb4effa291e1e4dac62b84251c74c483d99b06e7
Gerrit-Change-Number: 12426
Gerrit-PatchSet: 1
Gerrit-Owner: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Mon, 11 Feb 2019 18:56:56 +0000
Gerrit-HasComments: No
[Impala-ASF-CR] IMPALA-5031: signed overflow is undefined behavior
Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/12426 )
Change subject: IMPALA-5031: signed overflow is undefined behavior
......................................................................
Patch Set 1:
Build Successful
https://jenkins.impala.io/job/gerrit-code-review-checks/2063/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.
--
To view, visit http://gerrit.cloudera.org:8080/12426
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ifb4effa291e1e4dac62b84251c74c483d99b06e7
Gerrit-Change-Number: 12426
Gerrit-PatchSet: 1
Gerrit-Owner: Jim Apple <jb...@apache.org>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Sun, 10 Feb 2019 06:03:30 +0000
Gerrit-HasComments: No