Sponsored By

Feature: 'The Transition to Concurrency'

For today's <a href="http://gamasutra.com/features/20070405/knudsen_01.shtml">technical Gamasutra feature</a>, Flux Studios co-founder Kristian Dupont Knudsen guides weary programmers into the practice of concurrency, outlining specific techniques, provi

Brandon Boyer

April 5, 2007

2 Min Read

For today's technical Gamasutra feature, Flux Studios co-founder Kristian Dupont Knudsen guides weary programmers into the practice of concurrency, outlining specific techniques, providing code examples, and more. In this excerpt, Knudsen, who suggests the Erlang and OCaml as languages for dealing with concurrent programming, explains why programmers should even consider moving away from C++ at all: "If you are interested in performance, chances are you are writing server code, embedded code or maybe game code like I am. And if that is the case, chances are that you are writing C or C++, and you are probably skeptical about other languages. In the end, they're all Turing-complete, right? So what could any language offer that you can't simulate? Well you're right of course - there is nothing you can't achieve by simulating it. You can use or come up with design patterns that help you with everything. After all, design patterns are often described as language features that haven't (yet) been implemented. You can write object oriented code in C, simulating inheritance and virtual methods and everything but at the cost of increased complexity. Simulating functional programming in C is a pain. With C++ it is a slightly more bearable pain, but a pain nevertheless. But even if you accept the fact that there may be better suited languages for the task, you may not have that option. No programmer is an island - you have to work with other programmers, you probably have management to respond to and changing languages is not a trivial decision. Plus, for many platforms, the C++ compiler is the only thing available. " You can now read the full Gamasutra feature with more from Knudson on what you need to know now about concurrent programming, especially immutability, persistent data structures and active objects (no registration required, please feel free to link to this column from external websites).

About the Author(s)

Brandon Boyer

Blogger

Brandon Boyer is at various times an artist, programmer, and freelance writer whose work can be seen in Edge and RESET magazines.

Daily news, dev blogs, and stories from Game Developer straight to your inbox

You May Also Like