Remix.run Logo
▲ cedws a day ago

Rust is a nice language but it’s so heavy. Since our company switched from Go I’ve had to become used to my laptop being burning hot and stuttering whilst trying to do anything during compilation.

▲TakerofVita a day ago | parent | next [-]

yeah, I've been doing some game dev with rust, and the cost of iteration is hugely higher (though it has been worth it so far). Often a build takes 10min+. Something like this project would help a lot if it supported windows.

It is pretty noticeable if you have agents working in subtrees too, a fresh build in a worktree can be like 20min with bevy

▲_cart a day ago | parent | next [-]

Bevy (the engine itself) actually compiles faster than Godot (the engine itself) on my machine. The difference is that Godot ships the engine pre-compiled. With cached builds / shared builds (and/or dynamic linking) things look much better. (disclosure: I am Bevy's creator). That being said, if you're doing GDScript for game logic (or even C#) in Godot, game logic does still compile much faster in Godot. And the "precompiled Bevy / dynamic linking game logic" pattern in Bevy isn't a standard workflow atm (but with the upcoming editor we're planning on making that easier to set up).

▲cedws 20 hours ago | parent | prev [-]

It doesn’t have to be like this though. Jonathon Blow’s new game compiles at a crazy speed, like under 5s IIRC.

▲jakkos 17 hours ago | parent [-]

Afaik those speeds are only unoptimized non-llvm builds, and the things that make rust compile times slow are llvm and things Jai doesn't do like traits and monomorphization

▲pjmlp 13 hours ago | parent [-]

D and Delphi do generics and monomorphization.

D goes further as it actually has compile time reflection and C++ style templates, even if ldc is slower than dmd, it remains quite fast.

▲LtdJorge a day ago | parent | prev | next [-]

You can limit the threads

▲evulhotdog a day ago | parent | prev | next [-]

I’d gladly accept that for the efficiency and speed gained in prod, knowing I need to have a beefier host to compile it.

▲svachalek 10 hours ago | parent [-]

Go is already massively better than Python on just about any use case, and handily beats most VM languages when startup cost is a consideration. Rust performance over Go is really only noticeable if the application is bound on compute rather than I/O.

▲pjmlp 21 hours ago | parent | prev [-]

If Go devs were more welcoming to 1970's programming language research, there would be even less reasons to use Rust.

Many folks reach for it, because it is the only ML like language that they are aware of, and not necessarily due to the borrow checker.

On the other hand, Rust could have by now, the same kind of interpreters/JIT alternative implementations that OCaml, Standard ML, F#, Scala, Haskell enjoy, some of them for at least 30 years.

▲imtringued 17 hours ago | parent [-]

I'm curious. Is there anything stopping someone from building a Rust to Go compiler?

▲pjmlp 15 hours ago | parent [-]

The problem lies in the details of language semantics, or standard library, that you cannot as easily make use of on Go, some of which might require straight Assembly, or a kind of "Rust on Go runtime" helper library, at which point it is more of an intellectual exercise than anything else.

Think of it as, while you can compile C or C++ to JavaScript with asmjs, eventually WebAssembly was a more saner alternative.