Repository navigation
[VL] Fix GCC 11 compilation of S3 bucket config parsing - #13664
Merged
philo-he merged 3 commits intoNov 20, 2026
Merged
Conversation
Bound the suffix substring explicitly while preserving dotted bucket parsing and exact suffix matching. Extend coverage for the minimum bucket-name boundary and suffix near misses. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues remain for the GCC 11 S3 configuration parsing fix.
No open issues 🎉
What changed in this PR
Addresses the GCC 11 compilation failure in Velox S3 configuration parsing while preserving dotted-bucket support introduced in #13646.
Changes:
- Explicitly bounds the suffix substring comparison without changing parsing behavior or warning flags.
- Extends regression tests with a one-character bucket name and suffix near misses.
| File | Description |
|---|---|
cpp/velox/utils/ConfigExtractor.cc |
Supplies the explicit suffix length to avoid GCC 11’s overread diagnostic. |
cpp/velox/tests/GlutenS3FileSystemTest.cc |
Adds boundary and malformed-suffix cases; updates the expected configuration count. |
Review effort: Balanced
Add one CI-only comment to build/mvn so the existing weekly workflow path filter selects this PR. Maven behavior and the workflow remain unchanged. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
pratham76
approved these changes
Nov 18, 2026
Contributor
Contributor
Author
zhouyuan
reviewed
Nov 19, 2026
Member
|
@felipepessoto Thanks for the patch! There is a failure on weekly Macos build, could you please also fix it? |
Contributor
Author
|
Remove the comment-only build/mvn change now that the S3 fix has been reviewed. Restore the wrapper to its original contents without changing Maven behavior. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
zhouyuan
approved these changes
Nov 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes are proposed in this pull request?
Follow up on #13646 without reverting its dotted-bucket S3A configuration support.
Pass
suffix.size()explicitly to the suffixstring_view::substrcomparison. The existing length guard and computed position already identify exactly this range; supplying its length avoids the defaultnpossubstring path that GCC 11 propagates into the comparison. Keep the bucket-name parsing, longest-match selection, malformed-key handling, and all warning flags unchanged.Extend
GlutenS3FileSystemTest.extractsPerBucketConfigswith the one-character bucket boundary and suffix near misses (same-length mismatch, trailing dot, and trailing extra option).The regression was observed in the Ubuntu 22.04 weekly native build: GCC 11 reports
__builtin_memcmp_eqwith bound18446744073709551615at the new suffix comparison and fails with-Werror=stringop-overread.How was this patch tested?
weekly-build-on-macos is expected to fail, it is already failing before these changes: https://github.com/apache/gluten/actions/runs/43755616164/job/132938935814, and is addressed by [VL] Backport Flex lexer compatibility for macOS #13665
Reproduced the exact diagnostic in an Ubuntu 22.04 Docker container using the same GCC/G++ package as the failing job:
11.4.0-1ubuntu1~22.04.3. A standalone reduction extracts the production suffix table, parser lambda, and bucket-conversion loop. With-O3 -std=gnu++20 -DENABLE_S3 -Wall -Wextra -Werror, the original code fails and the patched workspace code compiles cleanly. No warning suppression is used.Checked 120 recognized key mappings across eight bucket-name strings, plus 15 malformed-key cases. The original parser at
-O0, patched parser at-O3, and patched parser with AddressSanitizer/UndefinedBehaviorSanitizer all pass these checks.Ran
dev/format-cpp-code.shwith clang-format 15.0.7, the repository license-header checker on both changed files, andgit diff --check.This is a reduced compiler/behavior regression check, not a full Gluten/Velox build. The native dependency/build tree is absent from this Windows worktree, so the integrated S3 test suite has not been run locally. A temporary comment-only
build/mvnchange triggered the weekly matrix for this PR and has now been removed; Maven behavior and the workflow's triggers are unchanged.Was this patch authored or co-authored using generative AI tooling?
Generated-by: GitHub Copilot 1.0.106-8.unstable.r43566476370.g869eef3 (GPT-6 Astra)