Ok, just because you rarely encounter problems that require multiple workers working on the same data, doesn't mean the rest of us rarely encounter those problems. My main project at work would be greatly helped by threads that worked across Windows, Unix, and Linux. But I don't have them, so I've left it in non-threaded mode.
IPC::SharedCache works great when there's only a little bit of caching. I'm not sure it's great for handling multiple huge trees of objects, from a cursory glance at the CPAN doc.
Any large structure(s) of data where different subsections can be worked on independantly, but the results must be fed back to the main process would benefit from threads. One common area is XML processing - working on each tree in a different worker thread is often possible and even desirable, and then you'll want to amalgamate the results in a final structure so that you can save a new XML file, for example, which cannot easily be done by multiple forked processes due to the close-tags that need to line up properly.
|