[ntp:hackers] Patches to reinstate rank variable and add
endkeyword.
Danny Mayer
mayer at gis.net
Sun Aug 7 15:36:39 UTC 2005
Brad Knowles wrote:
> At 7:27 AM +0100 2005-08-07, David J Taylor wrote:
>
>> Many of today's present processors and perhaps most of tomorrow's
>> will be
>> either hyperthreading, dual-core or both. Code which is not compatible
>> this will be a pain.
>
>
> Code based on eventlib will work just fine, without any changes, on
> multi-core/multi-processor systems. Code which is dependent on POSIX
> threads (or other form of threading) will be relatively non-portable,
> especially to older architectures.
>
> Since there should only ever be one process/thread that is updating
> the system clock, using a non-threaded model for ntpd will work just
> fine, so long as a little care is taken to handle multiprocessing with
> select() or other appropriate calls.
>
The advantage of using a multiprocessor and threads is that you can have
a different thread handling the I/O on a different processor as long
as you have just one thread handling clock changes. It is preferable to
have that thread stay on the one CPU. Some O/S's allow you to specify
the CPU on which the thread is to run.
I seem to remember somewhere that a single CPU currently is better than
a multiprocessor for ntpd. I think that PHK has done work on this.
Danny
More information about the hackers
mailing list