I read in many posts that Julia is faster than many languages especially C++, What's the future of Julia in game development industry ? Will it replace all legacy C++ ?

  • 2
    \$\begingroup\$ I'm sorry, but predictions for the future are not a good topic for question&answer websites. We wouldn't know which answers are correct or incorrect until the predictions come true, and then we won't need them anymore. If you want to read some wild estimations, you might want to ask this on a more discussion-oriented website. \$\endgroup\$ – Philipp Apr 9 '18 at 10:31
  • \$\begingroup\$ I've never seen anyone use Julia for game development purposes \$\endgroup\$ – Bálint Apr 9 '18 at 10:56
  • 1
    \$\begingroup\$ "I read in many posts that Julia is faster than many languages especially C++" - you can read that Java is faster than C++ as well ...and it is true if you have the C++ implementation botched up enough. Their site claims that it is "Good performance, approaching that of statically-compiled languages like C". Nearly as good does not sound superior. \$\endgroup\$ – wondra Apr 9 '18 at 16:02

As far as I am aware, Julia is not used at all in the games industry, except as a hobby language.

Firstly, you need to consider that all AAA games and AAA game engines are written in C/C++. These engines have full platform abstraction, so that you can write a game and it will run on a PC or PS4. Doing this in Julia, requires starting from scratch, which means an enormous cost for a company like Epic, in terms of learning hours (for the coders to be as competent in Julia as they are with C/C++), and actual man hours to do the actual writing of the engine. Then users of that engine also need to learn Julia to make games. Have fun justifying that to the literally hundreds of thousands of people using Unreal.

This is both unreasonably expensive, and unnecessary, when a perfectly good engine already exists, in a language that all the coders are already proficient with. In short, such an exercise would be wasteful, and provide no tangible benefit.

Secondly, All game engine coders are educated to write C/C++ from year 1. Graphics programmers are taught using the C++ DirectX or OpenGL API. Some branch out into web/mobile development and OpenGL_ES, but the vast bulk continue using C++ and the API they were taught to use. Due to the frankly enormous number of coders who were taught and continue to use C/C++, there is considerable resistance to change. It's hard to convince a dozen coders to abandon their primary language (let alone tens, or hundreds of thousands), in favour of one that is unproven in a commercial game environment.

Thirdly, C++ as a fully established(for several decades), and proven game worthy language, has thousands of tested, fully supported libraries to allow the easy writing of games, for multiple platforms. I will guarantee you Julia has nowhere near that kind of support.

Finally, your claim that it is faster than C is not quite right. IBM have tested the computational speed of C, Cython, and Julia. In smaller scale matrix operations (common in games), Julia is indeed faster, but as the problems scale up, both C and Cython catch up in performance, until the difference is negligible.

So a language which has comparable performance, with vast support, a large professional talent base, and is directly supported for game dev, by both Microsoft and Khronos, compared to a language which has virtually none of that except a bit better performance.

I will also add that when writing code in C++, if you desperately need performance in a small block of code, you can always just write the code in assembly language, and insert a pre-processor directive to use the asm compiler, the result of which would be faster than Julia, if such performance gains were ever necessary.

But in practical truth, the vast bulk of your performance gains will be from how well you write your algorithms, which will always be affected by how well you know the language, and the fact is, more game programmers know C/C++ and so you are far more likely to get a well written game in C++ than you are in Julia.

C++ is not going to be supplanted by any other language in the game industry.

  • 5
    \$\begingroup\$ Please avoid answering off-topic/too broad/discussion oriented questions, as they reward bad behaviour on the site. Flag them instead. \$\endgroup\$ – Vaillancourt Apr 9 '18 at 14:54

Not the answer you're looking for? Browse other questions tagged or ask your own question.