Email or username:

Password:

Forgot your password?
Top-level
Brion Vibber :blobcatcoffee:​

@mcc

i'm dead. i'm dying. this is *chef's kiss*

"Browser vendors, in that spurt of weird hubris that gave us the original WebAudio API, adapted OpenGL ES into JavaScript as "WebGL", which makes no sense because as mentioned OpenGL ES was all about packing bytes into arrays full of geometry and JavaScript doesn't have direct memory access or even integers, but they added packed binary arrays to the language and did it anyway."

7 comments
mcc

@brion IT WAS KIND OF WEIRD IN MY OPINION

Brion Vibber :blobcatcoffee:​

@mcc

"WebGPU caters to the kind of person who thinks it might be fun to write their own raymarcher, without requiring every programmer to be the kind of person who thinks it would be fun to write their own implementation of malloc."

<3 <3 <3

pyro

@brion @mcc even as exactly the kind of weirdo who would find it interesting to write their own malloc, god do I despise how much you have to do in vulkan just to render a triangle

mcc

@pyro @brion I've implemented malloc! It wasn't really that interesting. I would be mildly annoyed if an API required me to do it again.

Now, implementing a linear allocator with compacting GC… THAT'S interesting. >_>

pyro

@mcc I ended up writing my own reference counted allocator for a virtual machine project several years ago now, and it was fun to learn with but *awful* performance-wise (which is probably to be expected). still, if I were to work on a project that required GC again, that sounds like a fun rabbit hole to get sucked into!

Dan Cassidy 🦌

@brion @mcc I'm pretty sure that Mozilla at least were already thinking about asm.js, which was later replaced by WebAssembly. They're pretty good at pushing the platform forward in ways that look like really weird choices when examined as piecemeal changes but make a lot of sense in the context of the whole.

Dan Cassidy 🦌

@brion @mcc Also FWIW there was precedent in ActionScript 3, which adopted a similar design for Molehill/Stage3D, and remember AS3 was going to form the basis of ES4 until Microsoft nixed it. And AS3 had a bytecode VM, which would have been included in browsers as part of ES4.
(In hindsight I'm glad we got ES6 and WebASM instead but that's where a lot of these things originate.)

Go Up