Repository navigation
Render row sources into the writer's block buffer - #1238
Open
quinnj-bot[bot] wants to merge 1 commit into
Open
quinnj-bot[bot] wants to merge 1 commit into
quinnj-bot[bot] wants to merge 1 commit into
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## claude/rowwriter-typed-rows #1238 +/- ##
===============================================================
+ Coverage 96.05% 96.10% +0.05%
===============================================================
Files 9 9
Lines 5885 5885
===============================================================
+ Hits 5653 5656 +3
+ Misses 232 229 -3 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
CSV.write on a row source (a Vector of NamedTuples, a Tables.rows iterator)
appended every cell to a plain Vector{UInt8}, so each digit, delimiter, and
newline went through Vector resize! bookkeeping. Column sources already
render into _WriteBuffer, which reserves storage once and tracks the
logical length itself.
Row sources now use the same block buffer and sink write. Output bytes are
unchanged.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
quinnj-bot
Bot
force-pushed
the
claude/write-rows-block-buffer
branch
from
November 19, 2026 20:35
1e22c3e to
cb6a0cd
Compare
This branch has not been deployed
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.
Why
CSV.writeon a row source, such as aVectorof NamedTuples, appended every cell to a plainVector{UInt8}. Each digit, delimiter, and newline went throughresize!bookkeeping. Column sources already render into_WriteBuffer, which reserves storage once per block and tracks its own length.What changed
_WriteBufferand flush it with_writeblock, the same buffer and sink write that column sources use.Scope
RowWriterstill builds oneStringper row._appendrow!.Blast Radius
Only the row-source path of
CSV.writechanges. The writer tests compare row-source output with the column path, including transforms and sources without a schema, and check that an iterator that throws mid-write still leaves every complete row in the sink.Verification
Vectorof NamedTuples, 1M rows, one core), measured against Render RowWriter rows through the source schema #1237: small integers 179.0 → 147.5 M cycles, 0.83x (range 0.813 to 0.833). The 12-column mixed table measures 1250 → 1072 M cycles, 0.87x (range 0.842 to 1.146; one round ran at a load spike). That is the median of 7 interleaved fresh-process rounds. Column sources andRowWritermeasured 0.99 to 1.00x.🤖 Generated with Claude Code