FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Optimize compute dispatch and buffer upload by tychedelia · Pull Request #255 · processing/libprocessing · GitHub

Repository navigation

Optimize compute dispatch and buffer upload - #255

Merged
catilac merged 1 commit into
mainfrom
compute-perf
Oct 5, 2026
Merged

catilac merged 1 commit into
mainfrom
compute-perf

Conversation

Copy link
Copy Markdown
Member

Currently, every compute dispatch runs a full app.update() to be maximally pessimistic about changes to GPU resources that may not have been flushed to the GPU yet. For many particle sims which chain dispatches together this is exceedingly wasteful. This adds a new compute_dispatch_no_update which simply does the dispatch if the user is sure that there have been no un-flushed writes in the meantime.

Also changes how we do buffer uploads. Previously, we would block on a full readback to sync the buffer into CPU memory. Now, we just write directly into the GPU buffer. This is fine, because reads still incur the full sync but if the user only writes but never reads we can stay on the fast path and let the CPU side buffer get out of sync.

catilac merged commit b6e562f into main Oct 5, 2026
4 of 5 checks passed
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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants


Back | FazBrowse Home | New Git URL