-
Notifications
You must be signed in to change notification settings - Fork 165
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
Significant latency on Windows when drawing shapes from deck8.6/nebula1.x onwards #852
Comments
Not sure if this helps, but ff it is just an initial freeze, and perf is good after that... I have seen issues a couple of years ago where the WebGL shaders could take 1-2 seconds to compile and link on Windows systems where the same operation would take milliseconds on Macs. Also noting that PathLayer is deck's most complex shader, and that is where the freezes were most pronounced. Per some discussions with the ANGLE/Chrome folks, the reason was suspected to be some complications in the mapping of WebGL APIs to the underlying Direct3D APIs. I assumed that this was machine specific, but it sounds like that is a persistent issue. Some experimentation with the shader showed that this compilation/linking time is quite sensitive to the contents of the shader. Changing a line could drop the time from 2s to 1s. If that is still the issue, fixing it is a challenge as the deck.gl maintainers are not working on windows machines, so any day-to-day edits to those shaders could regress the compilation performance. However, it is possible that the issue is made more pronounced by the checking of shader compile and link status - it may trigger a GPU pipeline stall, freezing the browser. You could potentially comment these checks out in your
If it does, we could make those checks optional via some deck prop or global flag, giving you a path to some relief. I think there is an async shader compilation extension in WebGL now: , but it would be a little tricky to integrate. |
Appreciate the detailed response and suggesting some starting points, makes sense that it could be a d3d/gl translation thing. Commenting those blocks ^ didn't have a noticeable effect but we'll take some time early next year to look at everything beyond the surface. |
Describe the bug
Significant latency when performing certain actions on Windows 10 & 11 across many machines and at least several browsers (Firefox, Chrome, Edge), from nebula@1+. I have tested personally on a stripped back version with the bare essentials and verified with many customers. My own test machine has a GTX2060, 11th gen i7, 16GB ram & runs Windows 11. My Mac M1 and a few Intel Macs do not seem to have this problem.
Actual Result
Expected Result
Reproduce Steps
Note I am building this with a basic Vite setup. Happy to post repo if convenient.
main.js (minimal repro)
Dependencies with less delay on Windows
Dependencies with significant delay, also appears to be present in all combinations of later versions of @deck.gl/* + @nebula.gl/* I have tried.
The text was updated successfully, but these errors were encountered: