tags:

views:

33

answers:

2

Hi

I am having an application which has a UI module and other supporting services. These other services have memory leaks and other thread synchronization issues. Hence in some machines especially quad core, dual core machines the services crash every now and then.

I know the best way to fix this is to clean up the memory leaks and synchonization issues.

But as a work around we set the processor affinity for 2 of those services and observed that the crash did not happen after that.

Now my question is Will my services take a performance hit as i am limiting them to using only one processor?

Edit 1: Note: These services are multi threaded.

+1  A: 

This certainly depends on whether those services rely on threading. If they are single-threaded you won't notice much difference.

In your case since services are multithreaded they might or might not experience perfomance penalty - this will depend on actual design, specifically on whether they rely on several threads being executed in parallel.

sharptooth
+1  A: 

(might better fit serverfault.com)

As the service creates multiple threads, most likely.

Furthermore, it's response time might increase, even though the system is not under load. If the CPU you are bound to is busy with another thread, it has to wait for that thread to give up its time slice. This may become notable with many small requests processed by the (or a) thread.

The perceived results may be subtle or devastating: You might run fine for a while, but go belly up when requests peak, dependent services (if any) may be slowed down.

peterchen