Multi Core CPU vs Memory

Hi, I should know the answer to this but for some reason I don’t know.
Let’s say you have a large scene that takes up 10 GB of memory to render.
You are using a AMD Ryzen 3060x Chip with 24 cores (48 Threads)
your total amount of ram on the motherboard is 128 GB.
When you render an animation does blender Just render 1 frame at a time using all the cores as fast as possible? With the total memory being used only 10GB and the other 118 GB sitting idle?
Or is is it possible to say “Ok frames 1 through 100 get rendered by Cores 1 through 4. Cores 5 through 8 do frames 101 to 200” etc. With the memory being divided up per core?
I know it sounds like a odd question but I’m wondering how to get the maximum amount of performance out of the CPU and given memory amount.

Short version:
Each core renders its own part of the scene, looking up the scene data from RAM. Using more RAM isn’t going to increase performance in a situation like this, you either have enough or you dont.

In fact, running the same Blend 5 times may actually decrease performance, see below:

Longer version:
Have a look at memory hierarchies here. A computer has various levels of storage, this is a rough explanation;

  1. The scene is stored on your Hard Drive or Solid State Drive (Giga/Terabytes)
  2. To open the file, Blender and the scene are loaded into your RAM (Gigabytes)
  3. To get the data on the CPU, the memory is copied into the L1 (per core, Kilobytes) and L2/L3 (shared between cores, Megabytes)
  4. To actually perform calculations, the data is loaded into registers (Bytes) and then instructions tell the CPU to take data from 1 or more registers and store it in another. This result can then be stored in memory or used for further calculations.

Now no scene in Blender would fit within the cache of a CPU, so most rendering is done by accessing scene data stored in RAM and storing the data in the CPU cache.

As RAM (Random Access Memory) is randomly accessed, there isn’t a penalty for having multiple CPU cores accessing the same scene in RAM, they just read the part they need. In fact, there may be a performance impact with running the same scene 4 times as the amount of data that an be read from RAM per second is limited.

Finally, as the CPUs cache stores data read from memory, if the same data is repeatedly accessed then it is often kept in cache, meaning a slow read to RAM can be skipped. This includes cores sharing data in the L2/L3 cache.
Running Blender 4 times, even with the same scene means that the cache data can’t be reused between the cores on different Blender instances (it goes by memory addresses)

1 Like

Hi, Thanks for the info. I just built a new computer with a lot of ram and a 1080TI card.
So I’m experimenting with what works the best. CPU vs GPU/Optix etc.