Skip to content

impr: Move sort package to tsdown - #2902

Open
reczkok wants to merge 1 commit into
feat/radix-sort-v2from
impr/sort-tsdown
Open

impr: Move sort package to tsdown#2902
reczkok wants to merge 1 commit into
feat/radix-sort-v2from
impr/sort-tsdown

Conversation

@reczkok

@reczkok reczkok commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@reczkok reczkok changed the title impr: Move to tsdown impr: Move sort package to tsdown Aug 21, 2026
@github-actions

github-actions Bot commented Aug 21, 2026

Copy link
Copy Markdown

pkg.pr.new

packages
Ready to be installed by your favorite package manager ⬇️

https://pkg.pr.new/software-mansion/TypeGPU/typegpu@95a51808c0a09b7e641f253822c2f650df11007a

benchmark
view benchmark

commit
view commit

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

  • Migrate @typegpu/sort build tooling from unbuild to tsdown — replaces build.config.ts with a tsdown.config.ts structured identically to the already-merged @typegpu/sdf tsdown migration, and updates package.json (build script, devDependencies, publishConfig paths) and pnpm-lock.yaml.

I verified the migration end-to-end: pnpm --filter @typegpu/sort build succeeds and emits dist/index.js and dist/index.d.ts (plus unbundled submodules), which exactly matches the paths updated in publishConfig. The .mjs.js switch and removal of the .cjs default export are consistent with tsdown's esm-only output and match @typegpu/sdf. No dangling unbuild references remain for this package.

Pullfrog  | Fix it ➔View workflow run | Using DeepSeek Flash (free via Pullfrog for OSS) | 𝕏

@github-actions

github-actions Bot commented Aug 21, 2026

Copy link
Copy Markdown

Bundle size comparison (import * as ... in PR vs import * as ... in target):

🟢 Decreased ➖ Unchanged 🔴 Increased ❔ Unknown
0 325 0 0

import { ... } in PR vs import * as ... in PR (is the library tree-Shakeable?):

Test tsdown
tgpu_init.ts 263.09 kB ($${\color{green}-3.5\%}$$)
tgpu_initFromDevice.ts 262.55 kB ($${\color{green}-3.7\%}$$)
tgpu_resolve.ts 161.75 kB ($${\color{green}-40.7\%}$$)
tgpu_resolveWithContext.ts 161.68 kB ($${\color{green}-40.7\%}$$)
tgpu_bindGroupLayout.ts 62.32 kB ($${\color{green}-77.1\%}$$)
tgpu_mutableAccessor.ts 57.04 kB ($${\color{green}-79.1\%}$$)
tgpu_accessor.ts 57.04 kB ($${\color{green}-79.1\%}$$)
tgpu_privateVar.ts 55.73 kB ($${\color{green}-79.6\%}$$)
tgpu_workgroupVar.ts 55.73 kB ($${\color{green}-79.6\%}$$)
tgpu_const.ts 55.15 kB ($${\color{green}-79.8\%}$$)
tgpu_lazy.ts 54.95 kB ($${\color{green}-79.8\%}$$)
tgpu_fragmentFn.ts 39.68 kB ($${\color{green}-85.4\%}$$)
tgpu_fn.ts 39.62 kB ($${\color{green}-85.5\%}$$)
tgpu_vertexFn.ts 39.50 kB ($${\color{green}-85.5\%}$$)
tgpu_computeFn.ts 39.20 kB ($${\color{green}-85.6\%}$$)
tgpu_vertexLayout.ts 28.33 kB ($${\color{green}-89.6\%}$$)
tgpu_comptime.ts 15.93 kB ($${\color{green}-94.2\%}$$)
tgpu_unroll.ts 1.75 kB ($${\color{green}-99.4\%}$$)
tgpu_slot.ts 1.70 kB ($${\color{green}-99.4\%}$$)

If you wish to run a comparison for other, slower bundlers, run the 'Tree-shake test' from the GitHub Actions menu.

@github-actions

github-actions Bot commented Aug 21, 2026

Copy link
Copy Markdown

Resolution Time Benchmark

---
config:
  themeVariables:
    xyChart:
      plotColorPalette: "#E63946, #3B82F6, #059669"
---
xychart
  title "Random Branching (🔴 PR | 🔵 main | 🟢 release)"
  x-axis "max depth" [1, 2, 3, 4, 5, 6, 7, 8]
  y-axis "time (ms)"
  line [1.10, 2.16, 4.64, 6.83, 7.89, 14.42, 24.91, 28.91]
  line [0.97, 2.03, 4.26, 7.10, 8.47, 13.53, 26.24, 24.62]
  line [1.03, 2.06, 4.93, 7.19, 8.03, 14.42, 24.84, 26.11]
Loading
---
config:
  themeVariables:
    xyChart:
      plotColorPalette: "#E63946, #3B82F6, #059669"
---
xychart
  title "Linear Recursion (🔴 PR | 🔵 main | 🟢 release)"
  x-axis "max depth" [1, 2, 3, 4, 5, 6, 7, 8]
  y-axis "time (ms)"
  line [0.35, 0.57, 0.77, 0.87, 1.19, 1.34, 1.53, 1.71]
  line [0.32, 0.53, 0.74, 0.86, 1.11, 1.13, 1.41, 1.52]
  line [0.33, 0.56, 0.78, 0.89, 1.18, 1.21, 1.46, 1.60]
Loading
---
config:
  themeVariables:
    xyChart:
      plotColorPalette: "#E63946, #3B82F6, #059669"
---
xychart
  title "Full Tree (🔴 PR | 🔵 main | 🟢 release)"
  x-axis "max depth" [1, 2, 3, 4, 5, 6, 7, 8]
  y-axis "time (ms)"
  line [0.93, 2.09, 3.87, 7.32, 13.06, 28.18, 59.76, 120.76]
  line [0.85, 2.32, 3.77, 7.53, 13.50, 28.05, 58.23, 117.27]
  line [0.90, 2.14, 3.57, 7.27, 13.17, 27.96, 58.66, 119.87]
Loading

Copilot AI lite review requested due to automatic review settings August 24, 2026 11:04

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR migrates the @typegpu/sort package build pipeline from unbuild to tsdown, aligning it with other packages in the monorepo that already use tsdown + unplugin-typegpu/rolldown.

Changes:

  • Switch packages/typegpu-sort build script from unbuild to tsdown and add a tsdown.config.ts.
  • Update @typegpu/sort publish outputs to ESM (dist/index.js) consistent with other tsdown-built packages.
  • Update the lockfile to reflect the new build dependency (tsdown) and remove unbuild.

Reviewed changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated 1 comment.

File Description
pnpm-lock.yaml Adds tsdown (and removes unbuild) in the dependency graph; also records eslint@9.39.2 as deprecated.
packages/typegpu-sort/tsdown.config.ts Introduces tsdown build configuration using unplugin-typegpu/rolldown.
packages/typegpu-sort/package.json Switches build tooling to tsdown and updates published entrypoints to dist/index.js.
packages/typegpu-sort/build.config.ts Removes the prior unbuild configuration.
Files not reviewed (1)
  • pnpm-lock.yaml: Generated file

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread pnpm-lock.yaml
eslint@9.39.2:
resolution: {integrity: sha512-LEyamqS7W5HB3ujJyvi0HQK/dtVINZvd5mAAp9eT5S/ujByGjiZLCzPcHVzuXbpJDJF/cxwHlfceVUDZ2lnSTw==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
deprecated: This version is no longer supported. Please see https://eslint.org/version-support for other options.

@aleksanderkatan aleksanderkatan left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure!

{
"name": "@typegpu/sort",
"version": "0.11.0",
"private": true,

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How far away are we from releasing this package? Will it be ready after this stack is merged?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess so

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

  • Re-applied the @typegpu/sort unbuild→tsdown migration — the new single commit 95a5180c reproduces the exact migration already reviewed and approved at d7c54aa5/3d2956d7: deletes build.config.ts, adds tsdown.config.ts (byte-identical to the merged typegpu-sdf config), updates package.json (build script, devDeps, esm ./dist/index.js publish paths), and updates pnpm-lock.yaml.

I verified the incremental delta is effectively nil: tsdown.config.ts and package.json are byte-identical to the previously reviewed-and-approved state, and the PR-scope diff vs base is only this 4-file migration (commitCount 1). No new concerns relative to the prior ✅ No new issues found. review.

Pullfrog  | View workflow run | Using DeepSeek Flash (free via Pullfrog for OSS) | 𝕏

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.

3 participants