Skip to content

Native incremental update to bundle graph for packaging#1034

Merged
vykimnguyen merged 6 commits intomainfrom
native-incremental-bundling
Feb 24, 2026
Merged

Native incremental update to bundle graph for packaging#1034
vykimnguyen merged 6 commits intomainfrom
native-incremental-bundling

Conversation

@vykimnguyen
Copy link
Copy Markdown
Contributor

@vykimnguyen vykimnguyen commented Feb 18, 2026

Motivation

Adds incremental bundling optimisation for packaging so that we don’t have to load the full bundle graph if only the contents of an asset has changed → just update the changed asset node in the bundle graph

Changes

Describe the solution and changes you have made

Checklist

  • Existing or new tests cover this change
  • There is a changeset for this change, or one is not required
  • Added documentation for any new features to the docs/ folder

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Feb 18, 2026

🦋 Changeset detected

Latest commit: ef74a2f

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 113 packages
Name Type
@atlaspack/ssr-app-example Patch
@atlaspack/core Patch
@atlaspack/rust Patch
@atlaspack/config-default Patch
@atlaspack/config-webextension Patch
atlaspack Patch
@atlaspack/cli Patch
@atlaspack/e2e-tests Patch
@atlaspack/register Patch
@atlaspack/test-utils Patch
@atlaspack/inspector Patch
@atlaspack/bundle-stats Patch
@atlaspack/packaging-test-harness Patch
@atlaspack/query Patch
@atlaspack/optimizer-image Patch
@atlaspack/reporter-bundle-stats Patch
@atlaspack/transformer-html Patch
@atlaspack/transformer-image Patch
@atlaspack/transformer-js Patch
@atlaspack/inspector-frontend Patch
@atlaspack/bundler-default Patch
@atlaspack/cache Patch
@atlaspack/fs Patch
@atlaspack/logger Patch
@atlaspack/source-map Patch
@atlaspack/utils Patch
@atlaspack/link Patch
@atlaspack/optimizer-inline-requires Patch
@atlaspack/packager-js Patch
@atlaspack/transformer-compiled-css-in-js Patch
@atlaspack/transformer-postcss Patch
@atlaspack/transformer-svg Patch
@atlaspack/transformer-tokens Patch
@atlaspack/node-resolver-core Patch
@atlaspack/package-manager Patch
@atlaspack/profiler Patch
@atlaspack/workers Patch
@atlaspack/watcher-watchman-js Patch
@atlaspack/types-internal Patch
@atlaspack/optimizer-css Patch
@atlaspack/optimizer-cssnano Patch
@atlaspack/optimizer-swc Patch
@atlaspack/optimizer-terser Patch
@atlaspack/packager-css Patch
@atlaspack/transformer-babel Patch
@atlaspack/transformer-compiled-external Patch
@atlaspack/transformer-compiled Patch
@atlaspack/transformer-css Patch
@atlaspack/transformer-less Patch
@atlaspack/transformer-sass Patch
@atlaspack/transformer-typescript-tsc Patch
@atlaspack/transformer-typescript-types Patch
@atlaspack/optimizer-blob-url Patch
@atlaspack/optimizer-data-url Patch
@atlaspack/optimizer-svgo Patch
@atlaspack/packager-html Patch
@atlaspack/packager-raw-url Patch
@atlaspack/packager-svg Patch
@atlaspack/packager-webextension Patch
@atlaspack/packager-xml Patch
@atlaspack/reporter-build-metrics Patch
@atlaspack/reporter-bundle-analyzer Patch
@atlaspack/reporter-cli Patch
@atlaspack/reporter-dev-server Patch
@atlaspack/reporter-json Patch
@atlaspack/reporter-lsp Patch
@atlaspack/reporter-sourcemap-visualiser Patch
@atlaspack/reporter-tracer Patch
@atlaspack/resolver-glob Patch
@atlaspack/runtime-browser-hmr Patch
@atlaspack/runtime-js Patch
@atlaspack/runtime-react-refresh Patch
@atlaspack/runtime-service-worker Patch
@atlaspack/runtime-webextension Patch
@atlaspack/transformer-posthtml Patch
@atlaspack/transformer-react-refresh-wrap Patch
@atlaspack/transformer-webextension Patch
@atlaspack/transformer-webmanifest Patch
@atlaspack/validator-eslint Patch
@atlaspack/validator-typescript Patch
@atlaspack/resolver-default Patch
@atlaspack/resolver-tesseract Patch
@atlaspack/types Patch
@atlaspack/codeframe Patch
@atlaspack/graph Patch
@atlaspack/plugin Patch
@atlaspack/reporter-bundle-buddy Patch
@atlaspack/transformer-xml Patch
@atlaspack/ts-utils Patch
@atlaspack/packager-ts Patch
@atlaspack/transformer-jsonld Patch
@atlaspack/bundler-library Patch
@atlaspack/compressor-brotli Patch
@atlaspack/compressor-gzip Patch
@atlaspack/compressor-raw Patch
@atlaspack/namer-default Patch
@atlaspack/optimizer-htmlnano Patch
@atlaspack/packager-raw Patch
@atlaspack/packager-wasm Patch
@atlaspack/reporter-compiled-css-in-js-migration-map Patch
@atlaspack/reporter-conditional-manifest Patch
@atlaspack/transformer-glsl Patch
@atlaspack/transformer-graphql Patch
@atlaspack/transformer-inline-string Patch
@atlaspack/transformer-inline Patch
@atlaspack/transformer-json Patch
@atlaspack/transformer-mdx Patch
@atlaspack/transformer-pug Patch
@atlaspack/transformer-raw Patch
@atlaspack/transformer-svg-react Patch
@atlaspack/transformer-toml Patch
@atlaspack/transformer-worklet Patch
@atlaspack/transformer-yaml Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 18, 2026

Rust Package Changeset Check

✅ The @atlaspack/rust package has been included in your changeset. Your Rust changes will be published.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 18, 2026

📊 Type Coverage Report

Coverage Comparison

Metric Baseline Current Change
Coverage Percentage 92.21% 92.21% ➡️ 0.00%
Correctly Typed 219,965 220,070 +105
Total Expressions 238,532 238,640 +108
Untyped Expressions 18,567 18,570 +3

Files with Most Type Issues (Top 15)

File Issues Affected Lines
packages/core/integration-tests/test/javascript.ts 1152 745
packages/core/integration-tests/test/cache.ts 884 625
packages/core/integration-tests/test/scope-hoisting.ts 622 489
packages/utils/node-resolver-core/test/resolver.ts 476 177
packages/core/integration-tests/test/html.ts 468 294
packages/core/integration-tests/test/sourcemaps.ts 364 182
packages/core/test-utils/src/utils.ts 330 205
packages/core/integration-tests/test/incremental-bundling.ts 298 206
packages/core/core/src/dumpGraphToGraphViz.ts 251 108
packages/core/integration-tests/test/transpilation.ts 230 139
packages/core/integration-tests/test/output-formats.ts 227 161
packages/transformers/webextension/src/WebExtensionTransformer.ts 210 80
packages/core/core/src/requests/BundleGraphRequestRust.ts 194 67
packages/core/integration-tests/test/css-modules.ts 191 107
packages/core/core/src/requests/TargetRequest.ts 190 133

This report was generated by the Type Coverage GitHub Action

Comment thread packages/core/core/src/BundleGraph.ts Outdated
Comment thread crates/atlaspack/src/atlaspack.rs Outdated
@vykimnguyen vykimnguyen force-pushed the native-incremental-bundling branch from 90aa100 to 3a4ad74 Compare February 19, 2026 00:11
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 19, 2026

📊 Benchmark Results

No significant performance changes detected.

📊 Benchmark Results

Overall Performance

Test Duration JS Memory Peak Native Memory Peak vs Baseline Status
Three.js Real Repository (JS) 15.59s 1.95GB 2.08GB -0.46% duration, -9.35% JS memory 🟡 Neutral
Three.js Real Repository (V3) 22.70s 3.17GB 3.50GB +1.66% duration, -3.08% JS memory 🟡 Neutral

🔍 Detailed Phase Analysis

Three.js Real Repository (JS)

Phase Duration (avg) Duration (p95) Memory Peak (avg) Memory Peak (p95)
resolving 7.38s 8.06s 1.33GB 1.61GB
transforming 7.37s 7.99s 1.34GB 1.62GB
bundling 7.17s 7.77s 1.34GB 1.62GB
bundled 6.80s 7.41s 1.47GB 1.73GB
packaging 4.66s 5.07s 1.57GB 1.83GB
optimizing 4.51s 4.88s 1.95GB 2.12GB

Three.js Real Repository (V3)

Phase Duration (avg) Duration (p95) Memory Peak (avg) Memory Peak (p95)
bundling 13.32s 22.21s 2.45GB 2.87GB
bundled 12.91s 21.89s 2.62GB 3.04GB
packaging 6.18s 7.01s 2.75GB 3.10GB
optimizing 6.03s 6.89s 3.17GB 3.50GB

💾 Unified Memory Analysis

Three.js Real Repository (JS) Memory Statistics

Memory Type Metric Min Mean Median P95 P99 Max Std Dev
JavaScript RSS 1.30GB 1.76GB 1.81GB 2.12GB 2.12GB 2.12GB 259.15MB
Heap Used 80.68MB 87.59MB 90.94MB 101.88MB 101.88MB 101.88MB 6.97MB
Heap Total 96.10MB 113.31MB 102.35MB 148.58MB 148.58MB 148.58MB 16.82MB
External 38.88MB 127.60MB 173.02MB 190.37MB 190.37MB 190.37MB 66.36MB
Native (Rust) Physical Memory 1.54GB 1.74GB 1.75GB 1.98GB 2.08GB 2.08GB 147.63MB
Virtual Memory 29.81GB 30.48GB 30.51GB 30.76GB 30.83GB 30.89GB 197.31MB

Sample Counts: JS: 14, Native: 247

Three.js Real Repository (V3) Memory Statistics

Memory Type Metric Min Mean Median P95 P99 Max Std Dev
JavaScript RSS 2.14GB 2.89GB 2.99GB 3.50GB 3.50GB 3.50GB 399.31MB
Heap Used 77.52MB 78.05MB 78.02MB 79.37MB 79.37MB 79.37MB 0.46MB
Heap Total 84.70MB 93.34MB 89.20MB 119.70MB 119.70MB 119.70MB 10.82MB
External 179.70MB 182.60MB 185.49MB 185.49MB 185.49MB 185.49MB 2.89MB
Native (Rust) Physical Memory 2.80GB 3.04GB 3.07GB 3.37GB 3.50GB 3.50GB 189.12MB
Virtual Memory 30.69GB 32.94GB 33.48GB 33.76GB 33.88GB 33.88GB 1.07GB

Sample Counts: JS: 14, Native: 315

🖥️ Environment

  • Node.js: v22.17.0
  • Platform: linux (x64)
  • CPU: AMD EPYC 7763 64-Core Processor
  • Total Memory: 15.62GB
  • Git SHA: ef74a2f
  • Branch: native-incremental-bundling
  • Timestamp: 2026-02-23T23:25:08.947Z

@vykimnguyen vykimnguyen force-pushed the native-incremental-bundling branch from 54a2671 to ef74a2f Compare February 23, 2026 22:58
@vykimnguyen vykimnguyen marked this pull request as ready for review February 23, 2026 22:59
@vykimnguyen vykimnguyen requested a review from a team as a code owner February 23, 2026 22:59
@vykimnguyen vykimnguyen changed the title [WIP] Native incremental bundling Native incremental update to bundle graph for packaging Feb 23, 2026
@vykimnguyen vykimnguyen merged commit 93ec107 into main Feb 24, 2026
63 of 67 checks passed
@vykimnguyen vykimnguyen deleted the native-incremental-bundling branch February 24, 2026 01:56
@atlaspack-ci atlaspack-ci Bot mentioned this pull request Feb 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants