6 ms·
C++ compile and link time. I once worked on a PS3 game that had a 50 minute turnaround time (change code -> compile -> link -> load). No scripting either. Th
by Tistel 11y ago
C++ compile and link time. I once worked on a PS3 game that had a 50 minute turnaround time (change code -> compile -> link -> load). No scripting either. The horror. It was because the company had home brewed a bunch of "optimizations" into the build process.
On the up side it will force you to learn to live edit the game with the debugger to tweak and adjust.
If its C++ and the programmers know the engineering KISS adage it can be ok. I have seen so much horrible needlessly complex C++. So bad you are pleasantly surprised it runs at all. C++ so bad and unpleasant to work on it makes you question why you are a programmer at all.
sigh
Then you write some python, C, ruby or lisp (or scheme, or clojure) and your like: "oh, now I remember why i do this again, this is so much fun!"
I like the simplicity of C too. You can have a good mental model right down the CPU of what is going on. But these days given how fast CPUs are and how much more productive you can be in a high level language (python is 10x more productive than C++, apparently) I think a garbage collected high level language is the way to go.
If I accept their offer, my next job will be using Golang.
- je42 11y agoDon't mix language features with engineering mistakes.
- Tistel 11y agoOh, I agree. Its not the language's fault. You can write a good or bad program in any language. No language can save you on its own. But, as the expression goes: some programming languages give you enough rope to shoot yourself in the foot, other, enough rope to blow off the whole leg. I have done C++ for 14 years. It can be great and fast if you are careful.
- JoeAltmaier 11y agoI use C++ because of the leverage. It automates so much that folks do by hand in C. Like a power tool vs hand tools. I know, lots of folks are nostalgic for handmade crafts using only simple tools. But I'll never go back.
- pcwalton 11y ago> I like the simplicity of C too. You can have a good mental model right down the CPU of what is going on. Not really, with compilers as sophisticated as they are and the spec as liberal with undefined behavior as it is. The C virtual machine that the spec defines is every bit as complex as any other virtual machine. > But these days given how fast CPUs are and how much more productive you can be in a high level language (python is 10x more productive than C++, apparently) I think a garbage collected high level language is the way to go. I totally agree. In fact, I wouldn't use C even for projects where a GC isn't suitable, just because we have alternatives now and it's so difficult to write programs free of basic memory management mistakes we've been making since the 80s.
- bluecalm 11y ago>>Not really, with compilers as sophisticated as they are and the spec as liberal with undefined behavior as it is. The C virtual machine that the spec defines is every bit as complex as any other virtual machine. Having some undefined behavior in your code is just a bug, it has nothing to do with being complicated or compiling to machine code. It's not nearly as complex, in fact there are many people who understand quite well what the code compiles to. You can read the assembly as well and understand it for big parts of the code (oh, it compiled it to that, vectorized this but didn't vectorized that etc.). Try guessing what Java compiles to. It's not even close to the same level of complexity. >>I totally agree. In fact, I wouldn't use C even for projects where a GC isn't suitable, just because we have alternatives The only serious alternative as of today is C++. Rust is a new untested language which no one wrote anything quite serious in yet and which offers a lot of trade-offs in exchange for being safer, everything else is slow as hell.
- pcwalton 11y ago> Having some undefined behavior in your code is just a bug, it has nothing to do with being complicated or compiling to machine code. In theory, yes. In practice, all C/C++ programs have undefined behavior in them, so you have to understand what compilers do to really understand your code. > It's not nearly as complex, in fact there are many people who understand quite well what the code compiles to. Not true in my experience. The only people who really understand it are, by and large, compiler developers. There are very few compiler developers. > Try guessing what Java compiles to. I know what Java compiles to more or less as well as I know what C++ compiles to. The only real difference is in GC (which is quite simple--inline a nursery bump and fall back to a malloc-like slow path if it fails) and ICs, which are a lot less complicated than things like alias-analysis-sensitive load forwarding.