src: avoid copying SEA snapshot data - #65876
Merged
nodejs-github-bot merged 1 commit intoSep 14, 2026
Merged
Conversation
Collaborator
|
Review requested:
|
Contributor
|
Welcome to Node.js, and thank you for your first contribution! Before review, please take a moment to read:
Please make sure every commit is signed off. For a first pull request, GitHub Actions require collaborator approval and Jenkins CI must be started by a collaborator or triager, so an initial wait is normal. |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #65876 +/- ##
==========================================
- Coverage 89.99% 89.99% -0.01%
==========================================
Files 785 785
Lines 269347 269358 +11
Branches 51307 51313 +6
==========================================
+ Hits 242395 242403 +8
- Misses 17452 17459 +7
+ Partials 9500 9496 -4
🚀 New features to boost your workflow:
|
panva
approved these changes
Sep 8, 2026
This comment has been minimized.
This comment has been minimized.
Member
|
cc @nodejs/single-executable |
This comment has been minimized.
This comment has been minimized.
panva
approved these changes
Sep 12, 2026
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Signed-off-by: Colin McDonnell <3084745+colinhacks@users.noreply.github.com>
panva
approved these changes
Sep 13, 2026
This comment has been minimized.
This comment has been minimized.
gurgunday
approved these changes
Sep 13, 2026
Collaborator
Collaborator
|
Landed in 20024a6 |
aduh95
pushed a commit
that referenced
this pull request
Sep 16, 2026
Signed-off-by: Colin McDonnell <3084745+colinhacks@users.noreply.github.com> PR-URL: #65876 Reviewed-By: Filip Skokan <panva.ip@gmail.com> Reviewed-By: Gürgün Dayıoğlu <hey@gurgun.day>
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.
Description
SEA snapshots live in a resource mapped from the executable. Node.js currently copies the V8 startup data out of that resource when it loads the snapshot.
This change lets V8 read the data in place. Snapshots loaded from a file or through the embedder API still use a copy because those buffers may not live long enough.
Benchmark
Median of 240 launches in randomized order, after 30 warmups. Linux x64 on an Intel Xeon Platinum 8481C. Both executables were built from
6f41e415639b5ec3dd816e44945cc73b4d7651e3.Validation
make lint-cpppython3 tools/test.py --mode=release seamake -j22 test-onlyAI disclosure: I used a coding agent for the investigation, patch, benchmarks, and PR text. It checked the resource lifetime against the source, built Node.js, and ran the tests above. I approved the PR and will handle review comments myself.