Live data from Hacker News

Game Jam 2 Results

wasm4.org

51–60 of 193 posts

Re: Game Jam 2 Results

#51

All WASM related stuff seems lacking of know-how of WebAssembly itself. I want the promise of "language-agnostic". For example, I have AST, I want to generate WebAssembly (either text or binary format, lets start with .wat), there's only a couple articles I found talks about how to map string to wasm's memory or table. Current situation is it's not language-agnostic as movement, it's just c/rust mostly. So wasm-4 see…

Are you trying to say web assembly is not well documented, or are you commenting on the state of tooling? It seems to me that most compiled languages can target wasm these days (eg c, c++, zig, rust, go, .net)

The specifications are open and detailed [1]. Specifications like that can be daunting to consume if you want a place to start from instead of a complete overview of the landscape, but there are tutorials in pure web assembly if you want to get started.

[1]: https://webassembly.github.io/spec/core/text/instructions.ht...

Re: Game Jam 2 Results

#52
post #17

Other notable things from the game jam other than Zig being the most popular: it's mostly developers aged 15-24 (hopefully they split that up into 15-19 and 20-24 next time around), and mostly from Europe. WASM-4 seems to be a technically limited "console" (64kb of RAM, 160x160 console), so it's even more of a niche than just doing game dev for WASM.

If I were a Zig advocate I would advertise [Z]ig as the programming of future starting from gen Z, new blood of developers.

Generation Zig? I like it.

Even though I'm technically a millennial… but if the next gen start using Zig instead of JavaScript for everything, I'm on board.

Re: Game Jam 2 Results

#53

Earlier quoted context omitted.

More disrupting than a really slow compiler?

Yes. If Zig takes 100ms to compile, and Rust takes 2s, but you just spent 20 seconds commenting unused vars in your Zig code, then the slow compiler comes out ahead. It's a great example of how good UX can be more important than raw performance numbers.

Yes, but you comment out unused variable once per variable (you can leave those underscores in and clear them out before release). The 2s happens every time you compile. The badness of slow compiles is non-linear, too. As you start to get to 30s, the likelihood that you check Facebook, Twitter, or hn goes up. At least when you're underscoring unused vars you're doing something active.

If it gets to 2-5 minutes the likelihood that you stop writing tests and rely on the compiler for bugfreeness goes up - or the likelihood that you create debt by increasing the complexity of your code organization.

Re: Game Jam 2 Results

#54
post #17

Other notable things from the game jam other than Zig being the most popular: it's mostly developers aged 15-24 (hopefully they split that up into 15-19 and 20-24 next time around), and mostly from Europe. WASM-4 seems to be a technically limited "console" (64kb of RAM, 160x160 console), so it's even more of a niche than just doing game dev for WASM.

It's great that young programmers are getting into these low-level things! In the early days of Wasm I was hoping we could put together a "wasm 4k demo" competition, but alas, funding these things is more complicated than it would appear. I'm glad this competition happened, and such cool results!

Re: Game Jam 2 Results

#55

All WASM related stuff seems lacking of know-how of WebAssembly itself. I want the promise of "language-agnostic". For example, I have AST, I want to generate WebAssembly (either text or binary format, lets start with .wat), there's only a couple articles I found talks about how to map string to wasm's memory or table. Current situation is it's not language-agnostic as movement, it's just c/rust mostly. So wasm-4 see…

This is good feedback for the Wasm community.

Right now I am teaching a VM course on the back-half of the Wasm equation: how to build an engine for Wasm. The course is about more than Wasm, of course, so there is a lot of content about JVMs and dynamic object models, but the projects are based around Wasm.

In the future I envision university compiler courses getting divided into two halves, either as one course with two halves, or two full courses. The first course/half would be entirely frontend: parsing, semantic analysis, IR, translation, lowering--and the target would be WebAssembly. The second course/half would be all about compiling Wasm to machine code. If the second course wanted to go more in the VM/runtime direction, vs focusing on compilation, it could include the upcoming GC extension or a custom extension to have objects.

I think Wasm is the future of code formats and languages, so I'd like to move the needle here for PL implementors.

Re: Game Jam 2 Results

#57

Earlier quoted context omitted.

Yes. If Zig takes 100ms to compile, and Rust takes 2s, but you just spent 20 seconds commenting unused vars in your Zig code, then the slow compiler comes out ahead. It's a great example of how good UX can be more important than raw performance numbers.

Yes, but you comment out unused variable once per variable (you can leave those underscores in and clear them out before release). The 2s happens every time you compile . The badness of slow compiles is non-linear, too. As you start to get to 30s, the likelihood that you check Facebook, Twitter, or hn goes up. At least when you're underscoring unused vars you're doing something active . If it gets to 2-5 minutes the…

Strawman. Incremental compile times don't hit 2-5 minutes in either language, otherwise it obviously wouldn't be viable for real-world use.

And juggling variables was an ongoing ordeal when I tried. I can't imagine how you would work on code without changing any of the variables.

Re: Game Jam 2 Results

#58
post #18
post #5

Earlier quoted context omitted.

Hah, Chevy Spark, and it's a gasoline car! I usually put "SPARK2014 programming" or "SPARK2014 Ada" in my searches. I used to get annoyed by all of the Apache Spark stuff that came up, but that seems to have waned a bit this past year or two. Vermont Technical College (VTC) used SPARK2014 to program their CubeSat and the book, "Building High Integrity Applications with SPARK"[1] is a great intro to it in a nice conte…

Gasoline cars have sparkplugs, so it's not really a strange association. At least not in my opinion. In fact, I guess in gas cars sparks are "better" since they are engineered in, and doing useful work.

I didn't say it was strange. I found it amusing that this is what came up during the other person's search for SPARK2014, and yes, thinking it sounded like a suitable electric vehicle name. Chevy called their electric offering Volt, and Volts are in the battery in a gas car too, but I think you get the picture.

Re: Game Jam 2 Results

#59

Earlier quoted context omitted.

Wow sounds like you really need to clean up your codebase. Seriously, I have never had this problem while coding in Go, and I'm a very very sloppy coder.

As other said, it is not a good practice so inline all the code, I prefer well named variables, and I assume you can find examples in your code where you have a local variable that depends of a function parameter. Funny enough I was correcting my son c++ homework yesterday, he had a complex if statement like if (somefunction(m,n, y[j]) == m[j]) and I made him make a local variable to make it clear what is happening.…

I'm not so sure about that one, despite clearly being in the company of people who feel attacked, I'm not the one attacking people here. I'm commenting on code practices, and baffled at other people's rage about the compiler demanding that you don't have unused variables, but I haven't attacked anyone.

Re: Game Jam 2 Results

#60
post #30

Earlier quoted context omitted.

Of course I have encountered dependent variables, but if I have a long chain of unused variables that means that either that code is ready to go, or the code organization needs refactoring.

You seem to be missing the whole point being made — they are unused because of (temporary) changes during prototyping .

Ah yes, prototyping. The stage of coding where one has lots of snippets of code meant for trying things out quickly. Definitely a context full of long chains of dependent variables.
Post reply on HN