dub icon indicating copy to clipboard operation
dub copied to clipboard

dub.sh home page globe spikes GPU to 100%

Open stashymane opened this issue 4 years ago • 19 comments

image

The globe's canvas is set to 2000x2000 size regardless of my screen res (1080p), I don't think that's necessary. Also perhaps a bit of optimization.

stashymane avatar Sep 22 '22 17:09 stashymane

I can also confirm this, it is absolutely murdering my browser.

BitesizedLion avatar Sep 22 '22 17:09 BitesizedLion

Looking into this, it looks like it could be related to the globe animation 🤔

Related comment: https://github.com/shuding/cobe/issues/39#issuecomment-1228296175

steven-tey avatar Sep 22 '22 19:09 steven-tey

This should be fixed by https://github.com/steven-tey/dub/pull/13 👍

Let me know if the performance is still bad for y'all @stashymane @BitesizedLion! :)

steven-tey avatar Sep 22 '22 20:09 steven-tey

Just experienced this on Win11 & Chrome 105.0.5195.127 going to the domain, has this fix been pushed publicly?

Tab loads, then slows to a crawl, then stops all together. Locks up my browser, attempting to close the tab requires patience before Chrome nukes it and then systems back to operating fine.

chris-pikul avatar Sep 23 '22 00:09 chris-pikul

Despite a slight improvement in performance, the website still lags.

Using Chrome 105.0.5195.127 and Firefox 105.0 on Windows 11. (64-bit)

annleefores avatar Sep 23 '22 03:09 annleefores

GPU is no longer at 90%, it's at 60% 😬 For context, games like CS:GO run my GPU at 40% :)

stashymane avatar Sep 23 '22 08:09 stashymane

It no longer kills my browser entirely, but still has higher usage than what a homepage should (imo)

BitesizedLion avatar Sep 23 '22 11:09 BitesizedLion

@chris-pikul @AnnleeFores @stashymane @BitesizedLion Okay y'all, I just pushed this commit that should optimize the globe for different device GPU cores: https://github.com/steven-tey/dub/commit/9518ca1b0a44554ca10b30018eb76d8880d3254a

Can you check and let me know if it's still blowing up your GPUs?

If it is, can you go into Chrome console and enter navigator.hardwareConcurrency and tell me what value it returns?

steven-tey avatar Sep 23 '22 14:09 steven-tey

Uses 30-35% on chrome Uses 60% on firefox

image

BitesizedLion avatar Sep 23 '22 14:09 BitesizedLion

Also isn't navigator.hardwareConcurrency for CPU?

BitesizedLion avatar Sep 23 '22 14:09 BitesizedLion

@BitesizedLion dang it looks like you're right!

I'm gonna keep this for now but if y'all can think of a better approach (by detecting GPU cores) let me know!

Otherwise I might just reduce the DPR value to 0.75 – it doesn't look too shabby either :)

steven-tey avatar Sep 23 '22 14:09 steven-tey

image

annleefores avatar Sep 23 '22 14:09 annleefores

Tested on two PCs, both on Windows 11 Pro (64bit).

GPU: Integrated (Intel)
navigator.hardwareConcurrency = 6
GPU: RTX 3050
navigator.hardwareConcurrency = 16

Almost the same behavior. As expected, the website is much more usable on the second PC.

georgejipa avatar Sep 23 '22 15:09 georgejipa

I am still facing the same. Here is a SS Screenshot (454)

Gladson-Lalu avatar Sep 24 '22 18:09 Gladson-Lalu

Each time I visit the home page I delete the globe canvas. It helps a lot. I think the globe isn't necessary. Maybe make it optional to see?

roman-koshchei avatar Sep 26 '22 06:09 roman-koshchei

Hey everyone! I just pushed this PR that adds a fallback video for devices that don't have proper support for WebGL – let me know if this helps!

steven-tey avatar Sep 26 '22 15:09 steven-tey

Hey everyone! I just pushed this PR that adds a fallback video for devices that don't have proper support for WebGL – let me know if this helps!

Hey, still same issue for me, my GPU runs at 5-10% usually when I open dub.sh it spikes up to 60%+ when I have the tab opened

SaiyaDev avatar Sep 26 '22 23:09 SaiyaDev

This issue has been largely resolved so I'm going to close this for now!

Apologies again for the performance issues 🙏

steven-tey avatar Oct 05 '22 03:10 steven-tey

To be honest, so far the homepage of this website is still too laggy on my chrome.

eyeix avatar Feb 11 '23 05:02 eyeix