[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Alexey Serbin has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/21396 ) Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. [g++11] Fix DecrementIntCell for g++10 and g++11 There seems to be a compiler bug, that optimizes out the safety check for INT_MIN in the DecrementIntCell function. It appears on RHEL 9.2 with g++ 11.4.1. Only in Release build. For more infoi, see: https://stackoverflow.com/questions/78424303/g-optimizes-away-check-for-int-min-in-release-build The issue seems to be fixed in g++12 and not yet present in g++9. Solution: Slightly change the function to ensure it is compiled correctly. This modification should not alter the correct optimized code. Basically, any change where the compiler cannot perform the two optimization steps (in this order) should address the issue: + if (x == INT_MIN) x = INT_MAX; else x -= 1; > x -= 1 (this is equivalent on the x86 platform). + if (x - 1 < x) > if (true) (this equivalence holds only at the mathematical level). Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Reviewed-on: http://gerrit.cloudera.org:8080/21396 Tested-by: Alexey Serbin Reviewed-by: Alexey Serbin --- M src/kudu/common/key_util.cc 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Alexey Serbin: Looks good to me, approved; Verified -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 4 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Alexey Serbin Gerrit-Reviewer: Kudu Jenkins (120)
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Alexey Serbin has posted comments on this change. ( http://gerrit.cloudera.org:8080/21396 ) Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. Patch Set 3: Code-Review+2 -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 3 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Alexey Serbin Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Comment-Date: Fri, 03 May 2024 18:02:57 + Gerrit-HasComments: No
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Alexey Serbin has removed a vote on this change. Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. Removed Verified-1 by Kudu Jenkins (120) -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: deleteVote Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 3 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Alexey Serbin Gerrit-Reviewer: Kudu Jenkins (120)
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Alexey Serbin has posted comments on this change. ( http://gerrit.cloudera.org:8080/21396 ) Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. Patch Set 3: Verified+1 unrelated test failures: * KUDU-3216 -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 3 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Alexey Serbin Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Comment-Date: Fri, 03 May 2024 18:01:27 + Gerrit-HasComments: No
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Kudu Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/21396 ) Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. Patch Set 3: Verified-1 Build Failed http://jenkins.kudu.apache.org/job/pre_commit/97/ : FAILURE -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 3 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Alexey Serbin Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Comment-Date: Fri, 03 May 2024 18:00:06 + Gerrit-HasComments: No
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Kudu Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/21396 ) Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. Patch Set 3: Build Started http://jenkins.kudu.apache.org/job/pre_commit/97/ -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 3 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Alexey Serbin Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Comment-Date: Fri, 03 May 2024 17:03:11 + Gerrit-HasComments: No
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Kudu Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/21396 ) Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. Patch Set 2: Verified-1 Build Failed http://jenkins.kudu.apache.org/job/pre_commit/96/ : FAILURE -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 2 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Alexey Serbin Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Comment-Date: Fri, 03 May 2024 16:11:06 + Gerrit-HasComments: No
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Hello Alexey Serbin, Kudu Jenkins, I'd like you to reexamine a change. Please visit http://gerrit.cloudera.org:8080/21396 to look at the new patch set (#2). Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. [g++11] Fix DecrementIntCell for g++10 and g++11 There seems to be a compiler bug, that optimizes out the safety check for INT_MIN in the DecrementIntCell function. It appears on RHEL 9.2 with g++ 11.4.1. Only in Release build. For more infoi, see: https://stackoverflow.com/questions/78424303/g-optimizes-away-check-for-int-min-in-release-build The issue seems to be fixed in g++12 and not yet present in g++9. Solution: Slightly change the function to ensure it is compiled correctly. This modification should not alter the correct optimized code. Basically, any change where the compiler cannot perform the two optimization steps (in this order) should address the issue: + if (x == INT_MIN) x = INT_MAX; else x -= 1; > x -= 1 (this is equivalent on the x86 platform). + if (x - 1 < x) > if (true) (this equivalence holds only at the mathematical level). Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 --- M src/kudu/common/key_util.cc 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/96/21396/2 -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: newpatchset Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 2 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Alexey Serbin Gerrit-Reviewer: Kudu Jenkins (120)
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Kudu Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/21396 ) Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. Patch Set 2: Build Started http://jenkins.kudu.apache.org/job/pre_commit/96/ -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 2 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Alexey Serbin Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Comment-Date: Fri, 03 May 2024 14:51:31 + Gerrit-HasComments: No
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Kudu Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/21396 ) Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. Patch Set 1: Verified-1 Build Failed http://jenkins.kudu.apache.org/job/pre_commit/95/ : FAILURE -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 1 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Alexey Serbin Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Comment-Date: Fri, 03 May 2024 13:31:35 + Gerrit-HasComments: No
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Zoltan Martonka has uploaded this change for review. ( http://gerrit.cloudera.org:8080/21396 Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. [g++11] Fix DecrementIntCell for g++10 and g++11 There seems to be a compiler bug, that optimizes out the safety check for INT_MIN in the DecrementIntCell function. It appears on RHEL 9.2 with g++ 11.4.1. Only in Release build. For more infoi, see: https://stackoverflow.com/questions/78424303/g-optimizes-away-check-for-int-min-in-release-build The issue seems to be fixed in g++12 and not yet present in g++9. Solution: Slightly change the function to ensure it is compiled correctly. This modification should not alter the correct optimized code. Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 --- M src/kudu/common/key_util.cc 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/96/21396/1 -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: newchange Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 1 Gerrit-Owner: Zoltan Martonka
[kudu-CR] [g++11] Fix DecrementIntCell for g++10 and g++11
Kudu Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/21396 ) Change subject: [g++11] Fix DecrementIntCell for g++10 and g++11 .. Patch Set 1: Build Started http://jenkins.kudu.apache.org/job/pre_commit/95/ -- To view, visit http://gerrit.cloudera.org:8080/21396 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Ia3cea2849a88c4d7e2587ceb805cd3258652e3c5 Gerrit-Change-Number: 21396 Gerrit-PatchSet: 1 Gerrit-Owner: Zoltan Martonka Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Comment-Date: Fri, 03 May 2024 12:15:35 + Gerrit-HasComments: No