Repository navigation
Layer stacks, previews and most brush strokes stay on the GPU: no fixed GPU size caps, no fixed memory limit in Auto #971
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
Open
vangel76
wants to merge
69
commits into
storytold:main
Choose a base branch
from
vangel76:tc-404-gpu
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+12,566
−1,261
Open
Changes from 3 commits
Commits
Show all changes
69 commits
Select commit
Hold shift + click to select a range
422f8e9
GPU memory: device limits and a memory budget instead of fixed GPU by…
vangel76 3e81d49
GPU memory: keep pipelines on retry, count capture inputs, budget in …
vangel76 04381ef
Test the micro map's metadata row against the device's texture size
vangel76 6ca186a
GPU memory: no fixed size in Auto, cached inputs grow until the GPU r…
vangel76 db265c3
Headless renders composite on the GPU; aux textures follow the displa…
vangel76 73608c5
Paint visibility depth on the GPU through an engine depth device, wit…
vangel76 00f36c8
Review: bounded CPU overlays at the renderer's set shift, mask previe…
vangel76 a7ef4b4
Fix the GPU depth readback and pass device and queue together
vangel76 6758d9d
Headless renders composite on the CPU on software and GL adapters, as…
vangel76 dc8706d
Aux views on the GPU at each set's display size; GPU errors are shown…
vangel76 78a7d01
Review: aux sources wrap into texture layers, quick mask memory retry…
vangel76 c3aa272
GPU brush readback and path tracing errors are shown, not redone on t…
vangel76 c1c9093
GPU paint uploads hold what the device binds, not a fixed 64 MB
vangel76 ffd423a
Projector depth grids rasterize on the GPU at full resolution
vangel76 ebf4bbc
Review: update windows keep their working size, depth raster ties sca…
vangel76 a6aba5b
The projector depth test readback returns its errors
vangel76 7e125b2
GPU brush start errors fail the stroke; only refusals paint on the CPU
vangel76 32a5845
Shelf filter and orb material previews composite on the GPU
vangel76 ccc28c9
Review: every library filter preview checked on the GPU, display map …
vangel76 7b3ac11
Paint upload windows follow the device; CPU projector depth keeps the…
vangel76 03ee492
Layer thumbnails composite on the GPU at a reduced size with their co…
vangel76 758e892
Review: neutral fills show in flat thumbnails, thumbnail errors repor…
vangel76 64dc6da
The material overview composites on the GPU off the UI thread; previe…
vangel76 dfb1f72
The GPU memory retry halves the paint window instead of asking for th…
vangel76 9213cb1
Library alphas generate on the GPU at the texture set's size
vangel76 8a2e5fa
Review: library tips sized by the brush and generated in bands, faile…
vangel76 1cae914
Merge upstream/main (shared-UV painting #869) into tc-404-gpu
vangel76 0f0a2ae
Shared-UV meshes paint on the GPU brush: every surface of a texel is …
vangel76 71af07c
GPU strokes leave the library alpha to the device instead of renderin…
vangel76 fc1ffa9
Resize repaints recorded strokes through the GPU brush; a GPU error f…
vangel76 149ade8
Review: CPU tip after a mid-stroke switch, resize replay on the GPU b…
vangel76 02af0c0
Keep the resize brush device out of web builds
vangel76 4d239a7
Mask stencils paint on the GPU brush: the stencil's stored gray times…
vangel76 122df11
Clone strokes paint on the GPU brush: dabs weighed by the source, car…
vangel76 4860e7d
Brush material strokes paint their alpha on the GPU brush; the patter…
vangel76 bac31db
Review: clone values filled per tile and channel, clone test strokes …
vangel76 50a11bc
The brush material pickup test expects the GPU brush
vangel76 36bfff1
Smudge strokes paint on the GPU brush: one pass per stamp, carried va…
vangel76 988f040
Review: a split smudge stamp deposits every chunk before copying back…
vangel76 b3a2900
Smudge sources composite on the GPU: the compositor writes the brush'…
vangel76 dbd959a
Review: only a source refusal composites the smudge source on the CPU…
vangel76 36e75e6
Mask smudge strokes paint on the GPU brush; a stamp centered on a tex…
vangel76 5aac1f0
Clone sources composite on the GPU: the brush reads the composite, a …
vangel76 c1eceda
Review: the clone readback is tested on packed scalars and at the set…
vangel76 bd60787
Clone and smudge strokes show live from the device's textures: no rea…
vangel76 2a8ef25
A brush material's source composites under its own cache key, so a pa…
vangel76 de63462
A GPU oracle for tied smudge centers on a mesh whose surfaces share UVs
vangel76 5356b64
Pickup source names cover clones as well as smudges
vangel76 b9d9bd4
Review: the readback at the stroke's end is chunked as the alpha read…
vangel76 87132a7
GPU-composited sets show the material overview on cold start; a dropp…
vangel76 1a454d9
A reduced composite without padding or filter fields uploads only the…
vangel76 8bf8c43
The overview test lets the composite replace the overview; the sample…
vangel76 bd61a18
Picking the clone or smudge tool compiles the live stroke's brush var…
vangel76 2221154
A preview GPU error is logged once per distinct error; the preview an…
vangel76 1317955
Review: remembered pipeline variants are forgotten with replaced sets…
vangel76 507f906
Sets whose UV or baked inputs exceed the device composite on the GPU …
vangel76 824c29b
Review: banded inputs hold one row more for bilinear and slope reads;…
vangel76 25e728b
Merge upstream/main (#846 smudge reads its layer, #939, #520, #406, #…
vangel76 fc928b4
Review: CPU routes for per-channel pickups are logged, a refused sour…
vangel76 32af9a3
Web builds: the immediate compose and the preview device setter are n…
vangel76 620c40f
Review round 3: memory accounting, error scopes and caches follow dev…
vangel76 de4ea38
A 3D path with points hidden from the camera paints on the GPU brush:…
vangel76 59dd4f1
Own-paint smudge and layer clones with per-channel coverage paint on …
vangel76 0d51777
A live smudge of a layer's own paint shows each channel by its own al…
vangel76 cf933ab
Smudge resolve binds the smudge uniform; the clone offset keeps the R…
vangel76 816ad0f
The hidden-point path oracle picks its points before turning the camera
vangel76 cdf9a1d
The live pickup oracle has a second channel whose own alpha stays bel…
vangel76 e1a9e52
fmt
vangel76 da3302b
Clippy: the per-channel source has a type name
vangel76 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
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
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
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
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
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
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Count resident UV inputs in the configured memory budget.
A full 4K
Rg32UintUV surface uses 128 MiB before its vertex buffer. With a 128 MiB budget, two live sets can keep both surfaces becausecached_bytescounts neither.release_inputsalso leaves the surface cache untouched, so an eviction triggered by another input does not free those surfaces.Account for UV surfaces, vertices, and coverage in the budget. Track which sets reference each grid so eviction releases an older set's inputs without dropping a grid still used by the current set.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in gpu_compositor.rs: the UV surfaces (with their vertices) and coverage buffers a set's composite reads now count toward the chosen megabyte cap, and eviction frees them with the set's other inputs, keeping any grid the current set also reads. Auto still has no limit of its own. Test:
a_chosen_budget_counts_and_evicts_uv_surfaces.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Analysis chain
Script executed:
Length of output: 66236
Script executed:
Length of output: 8887
@vangel76The change counts UV inputs and retains grids used by the current set. One accounting issue remains.At
gpu_compositor.rsLine 842, surface and coverage can reference the same grid.cached_bytesthen counts that grid twice. The same grid can also be counted once per texture set. This can evict cached inputs before the budget is actually reached.Please count each resident grid once and add a test with shared surface and coverage references. The new test inserts one distinct grid per set, so it does not cover that case. I’m not marking the finding as addressed yet.
If you found this review helpful, would you consider giving us a shout-out on X?
Thank you for using CodeRabbit!
You are interacting with an AI system.