KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: 4D and Processor Affinity on Windows
PRODUCT: 4D | VERSION: 2004 | PLATFORM: Win
Published On: April 18, 2007
Your current browser may not allow you to download the asset. We recommend Mozilla Firefox or Google Chrome.
Log In

On Windows PC's with multiple processors it is possible to set the processor affinity for an application. This tells the operating system what processor the application should be assigned to when running. When applications run, remnants of them remain in the processors cache so processor affinity takes advantage of this in that future operations could be faster by using these remnants stored in the processor's cache.

However, there are potential conflicts using processor affinity. There is no affinity between separate physical chips so this poses a conflict for the scheduling algorithm. This is why applications that are not Symmetric multiprocessing (SMP) aware can seem slower or even appear to hang when trying to utilize multiple processors. The scheduling algorithm gets confused and has to sort out what is best to do.

Since 4D is not SMP aware, a "hard" processor affinity may be used, which only allows 4D to use a single processor. On Windows, follow these steps to set Processor Affinity for 4D:

1. Launch your 4D product

2. Launch the Task Manager

3. Locate 4D in the Task Manager, right-click and select 'Set Affinity'

4. In the resulting dialog, you can select which processor the process is specifically tied to

5. Select OK to set it

This setting will force 4D to use one processor.