It's the usual story with web APIs, the implementation probably has resource quotas to keep applications from accidentally or deliberately doing denial of service, but you the developer targeting that implementation aren't allowed to know what the quotas are. You just have to make an educated guess at how much you can get away with and hope for the best. WebAssembly has a similar issue where consuming too much memory will get your app killed, but there's no reliable way to know how much is "too much" until it's too late.
Re:I want to talk about WebGPU
by ben-schaaf on Wednesday May 03, 2023 @08:30AM
(#35801571)
There are some limits you can query from the adapter: https://developer.mozilla.org/en-US/docs/Web/API/GPUSupporte...
Those limits only tell you how big each individual GPU allocation can be, not how much you can allocate total before the browser puts a bullet in your context.
Re:I want to talk about WebGPU
by codedokode on Wednesday May 03, 2023 @09:51AM
(#35802396)
Based on previous experience I assume there are no quotas and the webpage can hang your system. I had Google Street View hang a whole Linux system by using too much memory and Firefox did nothing to prevent this.
Re:I want to talk about WebGPU
by BlueTemplar on Wednesday May 03, 2023 @06:42PM
(#35808805)
What if you are using it in a native app rather than a browser/Electron ?
That's probably already possible with just a huge HTML page? At least on my system, if I create such a page and open it via a file:// URL, firefox will happily gobble up memory.
This is the case with AWS's Go SDK for EC2: https://docs.aws.amazon.com/sdk-for-go/api/service/ec2/
No matter what PC I use, I can't open that website...
I don't know who would make such a monstrous HTML page UT I'm pleasantly surprised that once it loaded my phone can interact with it just fine.
Someone should probably tell Amazon that hyperlinks allow linking to other HTML documents, though, because that's a ridiculously long page.
My PC hangs for some time as well
I thought FF should not allow that to happen?
holy crap this document is awful, crashed my browser
Re:I want to talk about WebGPU
by red_trumpet on Wednesday May 03, 2023 @09:42AM
(#35802282)
Works nicely on my Firefox (Kubuntu 22.04), but Chromium is troubled. Doesn't scroll smoothly...
FF on Windows 11, no problem.
Re:I want to talk about WebGPU
by SpaghettiCthulu on Wednesday May 03, 2023 @10:06AM
(#35802562)
Works perfectly fine on Firefox for Android. I'm able to scroll and view everything even before the styling has finished loading.
Re:I want to talk about WebGPU
by heinrich5991 on Wednesday May 03, 2023 @10:17AM
(#35802680)
Firefox seems to fare okay on that website. Chrome usually struggles more with huge websites IME.
Re:I want to talk about WebGPU
by mrguyorama on Wednesday May 03, 2023 @12:50PM
(#35804630)
Firefox on a garbage macbook: Site loads in a few seconds and causes no problems. It's just a bunch of text and hyperlinks, why would that be a problem?
Re:I want to talk about WebGPU
by BlueTemplar on Wednesday May 03, 2023 @06:46PM
(#35808844)
It opened (after a while) on mobile Firefox on a Galaxy S7...
Uhhh... and at some point it segfaults if I try to load 5 GB of HTML?
[ 7527.750745] HTML5 Parser[14186]: segfault at 0 ip 0000556be8b79cef sp 00007fbdb1570420 error 6 in firefox[556be8b77000+9c000]
Re:I want to talk about WebGPU
by SpaghettiCthulu on Wednesday May 03, 2023 @10:06AM
(#35802570)
That's definitely a bug. Have you reported it?
It's quite easy to almost lock up a computer by doing high intensity GPU work.