DEV Community

Discussion on: Most Apps Are Slower Than They Need to Be — Here’s Why (Live Demo🛸)

Collapse
 
francistrdev profile image
FrancisTRᴅᴇᴠ (っ◔◡◔)っ

This is a great post! I am not familiar with WebAssembly and kind of with WebGPU, but this gave me a basic understanding the importance of it when it comes to mainly performance!

Speaking of performance, how would you determine that you reach your limit and in which therefore need WebAssembly or WebGPU? I can imagine some people will use it right off the bat but if we are talking about needing it, what do I look for and how do I measure it?

Thanks! Hope this makes sense. I might be overthinking the question and that it might be already be answered in the post, but I start asking this since you mentioned "But the moment you start hitting performance limits, or your problem shifts from “moving data around” to “actually computing things”… you might realize that the platform already had the solution all along."

Collapse
 
sylwia-lask profile image
Sylwia Laskowska

Thanks, that’s a great question 🙂

I wouldn’t start with WebAssembly or WebGPU right away. First, I’d check where the real bottleneck is. In many apps it’s still the network, too much data or too many requests, and in that case these tools won’t help.

What I look for is whether the app becomes compute-bound. If the UI starts lagging, animations drop frames, or the main thread is busy for too long, that’s usually a sign. Then I’d profile and see which part of the code is actually expensive.

WASM makes sense for CPU-heavy tasks like data processing or transformations. WebGPU is more for massively parallel work like physics, graphics, or large-scale computations.

So the key is profiling first. If the problem is really about computation and not data transfer, that’s the moment when these tools start to make sense 👍