Multi-threading: multiple processors and multiple processes

| No Comments | No TrackBacks
I remember getting the multi-threaded t-shirt back in Mac System 7.

I think that for a lot of people, the relationship between processors and processes is often confusing. The reality that a task (like Photoshop or AfterEffects) can operate one or more processes on one or more processors simultaneously is a benefit of modern operating systems. Consider Photoshop, which has been able to use multiple processors by creating multiple processes for a long, long time (remember the Radius Rocket 4 core graphics processor card?). It did this independently of the operating system, too! Photoshop knows how to take an image operation, carve up an image into manageable chunks, and send the pieces to each of the available processors. This behavior used to be the purvey of custom programmers on mainframe systems like IBM, SGI and Sun. Today, with multiple cores per CPU being the norm, desktop operating systems like MacOS (a Unix derivative) and Windows (not so much, but now all NT-based) can now take advantage of these additional computing resources through advanced scheduling of tasks and meticulous record keeping.

Multi threading allows the operating system to allocate resources wherever they're needed, and also to release resources as tasks end. This part is critical to memory management, and is one of the toughest parts of getting multi-threading to work well and efficiently. If the OS can't properly recover assets claimed by a thread, then the system will eventually become unstable.

I had read a recent comment about adding multiple threading to a single application being time consuming and expensive. This is accurate. Multiple threading allows an application or task to spawn other tasks on the same or other processors that are related to the original application through shared memory resources and shared variable and register spaces. After Effects can send tasks into the background, where they will run while you are able to go back to work. Is there a cost to you in terms of performance? Of course, our overall performance suffers because the number of processors hasn't changed while we ask them to run more simultaneous processes. Now, since we measure productivity by our ability to layout and deliver projects, then we're all more productive with multi-threading. If I can get back to typing or editing video or manipulating a 3D environment while rendering proceeds in the background, then I am more productive. In the end, when I go home, I let the machine do its work and when I come back in the morning, then i have my completed tasks, ready to review.
Enhanced by Zemanta

No TrackBacks

TrackBack URL:

Leave a comment

About this Entry

This page contains a single entry by James Lockman published on January 27, 2010 3:42 PM.

Apple iPad a disappointment... was the previous entry in this blog.

Upgraded the blog to MovableType 5... is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.