Skip to content

TSL: Auto-cache atomic* nodes #30972

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Apr 22, 2025
Merged

TSL: Auto-cache atomic* nodes #30972

merged 2 commits into from
Apr 22, 2025

Conversation

sunag
Copy link
Collaborator

@sunag sunag commented Apr 22, 2025

Related issue: #30971

Description

This avoids double-adding by adding assign() multiple times without using .toConst() or .toVar().

@sunag sunag marked this pull request as ready for review April 22, 2025 06:01
@sunag sunag added this to the r176 milestone Apr 22, 2025
Copy link

📦 Bundle size

Full ESM build, minified and gzipped.

Before After Diff
WebGL 336.33
78.33
336.33
78.33
+0 B
+0 B
WebGPU 547.22
151.68
547.3
151.71
+82 B
+33 B
WebGPU Nodes 546.57
151.52
546.66
151.55
+82 B
+33 B

🌳 Bundle size after tree-shaking

Minimal build including a renderer, camera, empty scene, and dependencies.

Before After Diff
WebGL 465.78
112.28
465.78
112.28
+0 B
+0 B
WebGPU 621.61
168.13
621.69
168.15
+82 B
+20 B
WebGPU Nodes 576.48
157.44
576.56
157.46
+82 B
+20 B

@sunag sunag merged commit 6a74721 into mrdoob:dev Apr 22, 2025
12 checks passed
@sunag sunag deleted the dev-auto-cache branch April 22, 2025 06:33
RuthySheffi pushed a commit to RuthySheffi/three.js that referenced this pull request Jun 5, 2025
* auto-cache

* Update AtomicFunctionNode.js
RuthySheffi pushed a commit to RuthySheffi/three.js that referenced this pull request Jun 5, 2025
* auto-cache

* Update AtomicFunctionNode.js
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.

1 participant