News for hackers. Stuff that matters.
Re:Comparing Parallel Rust and C++ by Razengan on Thursday November 07, 2019 @07:40AM (#21472637)
> I know I'm in a weird minority (most of the people who think like I do seem to be game engine developers).

As an amateur game engine developer, I'm probably in a weird minority for abhorring C/C++/C#/Canything. :)

I love Swift, and Rust or Dart would be my next choices if Swift wasn't available.

With first-class support for native APIs which do most of the work anyway, performance has not been a concern for me on Swift. I see only benefits, like making it hard for some types of bugs to creep in and code that is pleasant to read and a joy to write (though you can write beautiful/ugly code in any language, of course.)

Re:Comparing Parallel Rust and C++ by bulldoa on Thursday November 07, 2019 @01:14PM (#21475691)
Not well verse in the subject, do people develop game engine in garbage collected languages? Intuitively I would think game engine requires absolute performance
Re:Comparing Parallel Rust and C++ by gameswithgo on Thursday November 07, 2019 @01:41PM (#21475984)
Sometimes. And sometimes the core engine may be in C++ but the game logic is in C# (Unity).

There are plenty of games whose performance demands are not so high, that a GC language can work fine. There are also many examples of realtime 3d games, that used garbage collection, and were extremely successful (minecraft, subnautica). These were high quality games, though both do suffer from performance downsides, related at least indirectly to using GC languages.

Re:Comparing Parallel Rust and C++ by mratsim on Thursday November 07, 2019 @04:15PM (#21477337)
There is a growing community of game developers using Nim.

But Nim doesn't have a single GC, it has multiple and the default one can be compiled with real-time latency constraints so that you can use to make sure that you don't stop the world for less than 1/200 of a second for example.

Plus the GC is per type, you can mix raw pointers for manually managed memory and references for GC-managed objects. The GC can only be triggerred in code paths with references.

Re:Comparing Parallel Rust and C++ by nwallin on Friday November 08, 2019 @12:35AM (#21480186)
Game engines absolutely not. They're almost all written in C++ with exceptions and RTTI disabled and no STL. Gamdev C++ can better be thought of as C+. It's kinda sorta not the same language.

However, a lot of game engines use GC languages to operate game logic. Lots of them use Lua, unity uses c#. The ubiquity of Lua in gamedev has resulted in luajit being shockingly good if you're pushing around a bunch of floats.

Re:Comparing Parallel Rust and C++ by Razengan on Thursday November 07, 2019 @08:32PM (#21479282)
For things like the latest Doom or pushing 3D hardware to its limits, I'd think no.

I can't say how far you could get in pure Swift for 3D engines, but for 2D games Swift is more than good enough, and you can always interop with C/C++ when you really need to.