Cut per-field allocations in the byte parser, add Swift 6.4 CI - #7
Merged
Merged
Conversation
RISCfuture
force-pushed
the
swift-6.4/modernization
branch
2 times, most recently
from
September 14, 2026 23:06
1719b55 to
ea669f3
Compare
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EbZbx5D2gGeXT8UxuiKEdq
Decode CIFP fields through UTF8Span over the slice's own storage instead of copying each field into an Array first. `toString()`/`toRawString()` run on roughly 101 call sites per record across hundreds of thousands of records, so the per-field allocation dominated the string side of parsing; the new form is about 2.3x faster on a field-decode microbenchmark and produces byte-identical output (verified exhaustively over all one- and two-byte sequences plus 400k random and ASCII-biased fields, and end-to-end against a 60k-record synthetic corpus under SWIFT_DETERMINISTIC_HASHING). Give both async line reader iterators typed throws. The file-backed reader now throws `CIFPError.streamError`, wrapping the underlying `FileHandle` failure, which makes `CIFP(url:)` match its documented contract of throwing `CIFPError`. The generic byte-sequence reader propagates its source's `Failure` type, so a non-throwing source now yields a non-throwing sequence. Add Swift 6.4 CI legs on macOS and Linux, and drop the matrix policy comment that flagged the bump as pending. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EbZbx5D2gGeXT8UxuiKEdq
`main` lowered this package's floor to what its code there requires. The byte-parsing work on this branch uses `UTF8Span`, which is macOS 26, so the branch declares the floor its own code needs. Merging this therefore raises the floor. That is the trade the branch asks for and it should be decided on the merge, not worked around in the source. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EbZbx5D2gGeXT8UxuiKEdq
Enable `.strictMemorySafety()` (SE-0458) alongside the existing upcoming feature flags and audit every unsafe construct it surfaces, marking each with the `unsafe` expression marker. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EbZbx5D2gGeXT8UxuiKEdq
RISCfuture
force-pushed
the
swift-6.4/modernization
branch
from
September 15, 2026 03:08
0dbf369 to
42522b0
Compare
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.
toString()/toRawString()each calledArray(self), across ~101 sites and hundreds of thousands of records.The 229
.slice(sites are deliberately untouched: that helper returns its subsequence across a function boundary, which would require@lifetime— still experimental in 6.4. Parse output verified byte-identical.🤖 Generated with Claude Code
https://claude.ai/code/session_01EbZbx5D2gGeXT8UxuiKEdq