@W3bbo: Trust me, I know the difference between multi-processing and multi-threading, both of which, BTW, are done by the OS and not the hardware. What Wikipedia is referring to is hardware support for optimizing the context switching logic required, which is related, but not the same thing. The hardware is still NOT multi-threaded (again, with hyper threading being a complex concept to pin down in this categorization).
The problems that exist in single processing systems have to do with race conditions. Put simply, when you have a race condition you have some probability of shared state access not occuring in the order in which you'd expect. The probability will vary based on numerous factors, many of which you can't really account for, but one of which happens to be whether or not threads actually run concurrently (which increases the probability of the race failing). IOW, the bugs/problems exist in the code regardless, but the race may never (or rarely) manifest as an error at run time when run on a single processor machine, but may manifest almost immediately and every time when run on a multi-processor machine. There's a reason these are comically referred to as Heisenbugs, and you can basically imagine multiple processors as being multiple "observers" that cause a larger change in the operations characteristics
.
That said, there's not really a "class" of bugs/problems that you could consider unique to single processor machines. Whether or not a given race condition is noticably more likely to occur on a single processor isn't something you can easily classify, and it's a bug regardless of the architecture it's run on. "Never (or rarely)" means it will happen the minute it's run in production and is most critical that it not fail. Double-Checked locking is a classic example of just this topic. The pattern was considered state of the art and full proof for a very long time, used in lots of critical code running with high frequency on millions of computers until it finally failed in production and the experts were able to figure out why. (This topic also plays into the discussion of the hardware optimizations provided for threading purposes, as the memory model employed determines whether or not there's a race condition here.)
Thread Closed
This thread is kinda stale and has been closed but if you'd like to continue the conversation, please create a new thread in our Forums,
or Contact Us and let us know.