POV-Ray : Newsgroups : povray.off-topic : Idle dreams : Re: Idle dreams Server Time
5 Sep 2024 19:24:58 EDT (-0400)
  Re: Idle dreams  
From: Warp
Date: 27 Aug 2009 17:36:02
Message: <4a96fc42@news.povray.org>
Orchid XP v8 <voi### [at] devnull> wrote:
> And this is the other Fun Thing. Given enough CPU cores, you will 
> eventually reach a point where the memory subsystem can't actually keep 
> up. The result is that the more cores you have, the more time they can 
> waste sitting idle.

  In theory you could still get an advantage if each core has its own
L1 cache and they perform heavy calculations on bunches of data which
fit those caches (and likewise the routine itself must obviously also
fit in the L1 cache).

  In other words, if the algorithm can be constructed to be of the type
"crunch 4 kB of data for several seconds, write the results to RAM and
read new 4 kB of data, repeat", then additional cores will give an
advantage.

  Of course many algorithms deal with a lot more data at a time than will
nicely fit in L1 cache, especially if the cache is shared among the cores,
so efficiency problems will start happening.

  (Ironically, with shared L1 cache systems you might end up in situations
where a single-threaded version of the algorithm actually runs faster than
a multithreaded version, or where the multithreaded one doesn't run any
faster than the single-threaded one.)

-- 
                                                          - Warp


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.