Re:Multicore programming "remains the province of an elite few"
by allenbrunson on Friday March 21, 2008 @03:10PM
(#142684)
multi-threaded programming is a lot harder than it looks. that's true of a number of things, like opengl, but most programming subjects can be mastered by the usual bumble-along-and-break-things method that i suspect many of us use.
that's not so true for multi-threaded problems. newbies are likely to create bugs that only show up under heavy load and are nearly impossible to recreate and debug. it was enough to scare me away from multi-threaded programming for many years.
now i know that the solution is extreme discipline. don't share objects between threads, create locks sparingly, have threads communicate with each other only through queues or other well-defined interfaces, etc.
but my knowledge of the subject is pretty old-skule. every now and then i read something about memory barriers, lock-free programming methods, and so on, that make me think other people might have a better way.
that's not so true for multi-threaded problems. newbies are likely to create bugs that only show up under heavy load and are nearly impossible to recreate and debug. it was enough to scare me away from multi-threaded programming for many years.
now i know that the solution is extreme discipline. don't share objects between threads, create locks sparingly, have threads communicate with each other only through queues or other well-defined interfaces, etc.
but my knowledge of the subject is pretty old-skule. every now and then i read something about memory barriers, lock-free programming methods, and so on, that make me think other people might have a better way.