Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

What performance benefits a low level language can give to the engine, when the game is dependent on the GPU?

share|improve this question

closed as not constructive by Sam Hocevar, Jari Komppa, Byte56, Maik Semder, bummzack Mar 29 '13 at 10:11

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.

3  
This question really lacks acceptability of premises. A lot of the games I know are CPU bound. –  Sam Hocevar Mar 28 '13 at 9:52
4  
Maybe they would be CPU bound otherwise ;-) –  danijar Mar 28 '13 at 9:56
    
Even with a GPU bound game (and not all are) using less CPU cycles is a good idea. Worst case the game is slightly faster and use less power. Best case is on a APU with a shared heat budget for the CPU and the GPU part, thus allowing the GPU parts to run faster. –  Hennes Mar 28 '13 at 11:04
    
What do you base this on? this is not true. –  Tordin Mar 28 '13 at 11:09
2  
Evidence to the contrary: Dwarf fortress. Or any other heavy simulation game. –  Byte56 Mar 28 '13 at 13:47

2 Answers 2

You cannot generalize that "games are GPU bound". I assume that there are many engines out there for the other case. Otherwise what would we need GPGPU techniques like CUDA or compute shaders for? They outsource computations from the CPU to the GPU.

But speaking for engines for which your statement is correct, there can be several reasons to choose low level programming languages like C or C++.

Games are written in these languages since many years. Therefore you have plenty of game development related libraries available. Moreover, these low level languages are industry standard. Therefore professional developers use them in most of their projects. If a company want to sell a game, there is no time to train the whole team in a new language.

Another reason can be that these developers just prefer these languages because they know them well. Why should a experienced game developer start using Python for his new engine if it is slower and he is already an expert in C++?

share|improve this answer

Graphic APIs like OpenGL or Direct3d traditionally have APIs which are quite data-driven. They expect to be fed with vertices and textures as arrays of Plain-Old-Data.

A programming language like C (and as an extension C++), which is also very close to the actual representation of the data in memory and doesn't abstract it as much as, for example, Java or Python, have a design philosophy which is much more closer to that of these APIs. As a result, the interface between graphics API and program code usually feels more natural in C/C++. This allows to use them much more efficiently without creating too unreadable code.

share|improve this answer

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