Live data from Hacker News

Show HN: Shadeup – A language that makes WebGPU easier

shadeup.dev

41–50 of 57 posts

Re: Show HN: Shadeup – A language that makes WebGPU easier

#41
post #34

Earlier quoted context omitted.

A single code base for both native & web? Not having to write Javascript on the web?

Only if you enjoy coding to 2015 hardware specifications in 2024, leaving the rest of the hardware out.

I think you are confusing WebGPU with WebGL?

WebGPU standard process only started in 2021, and is still undergoing revisions.

Re: Show HN: Shadeup – A language that makes WebGPU easier

#42

Earlier quoted context omitted.

Don’t be fooled by “web” in the name. Just like WebAssembly is/will be a better JVM, WebGPU is already posed to be a better OpenGL/Vulkan. It is a full graphics API unconstrained by browser implementations, and available without a browser runtime.

I am curious, in what ways is WebGPU better than Vulkan or Metal? From my point of view, WebGPU going back to an interpreted shading language like OpenGL makes it conceptually closer to JavaScript than WebAssembly.

I gave up on Vulkan simply because it's too overengineered and cumbersome. WebGPU, on the other hand, is relatively easy to use, even though it is build on many of the same concepts.

Re: Show HN: Shadeup – A language that makes WebGPU easier

#43
post #34

Earlier quoted context omitted.

Only if you enjoy coding to 2015 hardware specifications in 2024, leaving the rest of the hardware out.

I think you are confusing WebGPU with WebGL? WebGPU standard process only started in 2021, and is still undergoing revisions.

OP is right. WebGPU is targeted towards the lowest common denominator, which is fairly old mobile phones. It therefore doesn't support modern features and is basically an outdated graphics API by design.

Re: Show HN: Shadeup – A language that makes WebGPU easier

#44
post #39
post #27

Earlier quoted context omitted.

I think the main feature that's exciting for me is the gpgpu potential. Even just looking at the ability to accelerate llms in the browser on any device without an installation is awesome For example: fleetwood.dev has a really cool project that does audio transcription in browser on the GPU: https://whisper-turbo.com/#

We could have had that already in WebGL if it wasn't for Chrome team botching Intel's work on OpenGL ES compute shaders being available in WebGL. https://registry.khronos.org/webgl/specs/latest/2.0-compute/ https://github.com/9ballsyndrome/WebGL_Compute_shader/issues...

Hah that was me ~12 years ago trying to get WebCL (OpenCL) through the same gate keepers. Meanwhile, in Python, we are doing multi-node multi-GPU. Maybe OpenAI's and soon Apple's success with LLMs will change the economics for them.

Re: Show HN: Shadeup – A language that makes WebGPU easier

#45

Earlier quoted context omitted.

I think you are confusing WebGPU with WebGL? WebGPU standard process only started in 2021, and is still undergoing revisions.

OP is right. WebGPU is targeted towards the lowest common denominator, which is fairly old mobile phones. It therefore doesn't support modern features and is basically an outdated graphics API by design.

Care to give an example? From my viewpoint as a WebGPU user, we consistently get access to new GPU features with every refresh. E.g: https://developer.chrome.com/blog/webgpu-io2023

You just have to set limits correctly when you initialize a GPU instance in order to have access to the new features.

Re: Show HN: Shadeup – A language that makes WebGPU easier

#46
post #39

Earlier quoted context omitted.

We could have had that already in WebGL if it wasn't for Chrome team botching Intel's work on OpenGL ES compute shaders being available in WebGL. https://registry.khronos.org/webgl/specs/latest/2.0-compute/ https://github.com/9ballsyndrome/WebGL_Compute_shader/issues...

Hah that was me ~12 years ago trying to get WebCL (OpenCL) through the same gate keepers. Meanwhile, in Python, we are doing multi-node multi-GPU. Maybe OpenAI's and soon Apple's success with LLMs will change the economics for them.

Much appreciated for the efforts.

This is why I don't like Khronos APIs, even when actually those are the ones I know relatively well, the way they work end up being a much worse experience than writting backend specific plugins ourselves with much better tooling, also the extension spaghetti ultimately doesn't save us from multiple code paths anyway, given the differences between some of those extensions.

To pick your example, something like PyTorch ends up being a much better developer experience, similar to game engines, than relying on Khronos APIs.

Re: Show HN: Shadeup – A language that makes WebGPU easier

#47

Earlier quoted context omitted.

OP is right. WebGPU is targeted towards the lowest common denominator, which is fairly old mobile phones. It therefore doesn't support modern features and is basically an outdated graphics API by design.

Care to give an example? From my viewpoint as a WebGPU user, we consistently get access to new GPU features with every refresh. E.g: https://developer.chrome.com/blog/webgpu-io2023 You just have to set limits correctly when you initialize a GPU instance in order to have access to the new features.

Mesh shaders, raytracing, DirectStorage, GPU work graphs, C++ features on shading languages, some of the post 2015 features that aren't coming to WebGPU any time soon.

Re: Show HN: Shadeup – A language that makes WebGPU easier

#48

Earlier quoted context omitted.

Don’t be fooled by “web” in the name. Just like WebAssembly is/will be a better JVM, WebGPU is already posed to be a better OpenGL/Vulkan. It is a full graphics API unconstrained by browser implementations, and available without a browser runtime.

I am curious, in what ways is WebGPU better than Vulkan or Metal? From my point of view, WebGPU going back to an interpreted shading language like OpenGL makes it conceptually closer to JavaScript than WebAssembly.

I wrote a big visualization application with WebGPU and I'm happy with the choice. It's much cleaner than OpenGL, without as much complexity as Vulkan or Metal. It runs on Mac & Linux, and I got a demo version working in the browser with emscripten fairly easily. It doesn't have the trouble with OpenGL version compatibility that used to make supporting multiple platforms a hassle.

I'm not sure what's 'interpreted' about it. On Mac, the wgpu-native driver transcodes to the Metal shading language and it gets compiled.

Re: Show HN: Shadeup – A language that makes WebGPU easier

#49
post #47

Earlier quoted context omitted.

Care to give an example? From my viewpoint as a WebGPU user, we consistently get access to new GPU features with every refresh. E.g: https://developer.chrome.com/blog/webgpu-io2023 You just have to set limits correctly when you initialize a GPU instance in order to have access to the new features.

Mesh shaders, raytracing, DirectStorage, GPU work graphs, C++ features on shading languages, some of the post 2015 features that aren't coming to WebGPU any time soon.

The features you mention are mostly applications of compute shaders, which are fully capable of being written in WebGPU, as WebGPU supports buffer -> buffer compute shaders when the underlying GPU supports it.

I've personally implemented mesh shaders in my own project, and there are plenty of examples of WebGPU real time raytracers out there. DirectStorage I had to google and it looks like a Windows DMA framework for loading assets directly to GPU ram? That's not even in scope for WebGPU, and would be handled by platform libraries. Linux has supported it for ages.

Seriously I get the impression from your posts that really don't have any experience with WebGPU at all, and are basing your understanding off of misinformation circulating in other communities. Especially with your continued nonsensical statements about not supporting "post-2015 features." 2015-era chipsets are a minimum supported feature set, not a maximum.

Please just take the L and read up to inform yourself about WebGPU before criticizing it more.

Re: Show HN: Shadeup – A language that makes WebGPU easier

#50
post #47

Earlier quoted context omitted.

Mesh shaders, raytracing, DirectStorage, GPU work graphs, C++ features on shading languages, some of the post 2015 features that aren't coming to WebGPU any time soon.

The features you mention are mostly applications of compute shaders, which are fully capable of being written in WebGPU, as WebGPU supports buffer -> buffer compute shaders when the underlying GPU supports it. I've personally implemented mesh shaders in my own project, and there are plenty of examples of WebGPU real time raytracers out there. DirectStorage I had to google and it looks like a Windows DMA framework for…

I bet those implementation of yours weren't done in WebGPU actually running on the browser, otherwise I would greatly appreciate being corrected with an URL.

DirectStorage started as a Windows feature, is actually quite common in game consoles, and there is ongoing work to expose similar functionality in Vulkan.

Yes, I do have WebGPU experience and have already contributed to BabylonJS a couple of times.

Maybe I do actually know one or two things about graphics APIs.

Post reply on HN