1 |
> > >> > So if I have 2 physical CPU's with 4 cores each and I enable SMP, |
2 |
I'm |
3 |
> > >> > using |
4 |
> > >> > 8 cores? Can NUMA be either enabled or disabled when using more |
5 |
than |
6 |
> > >> > one |
7 |
> > >> > physical CPU, or is it required? |
8 |
> > >> |
9 |
> > >> |
10 |
> > >> NUMA is a hardware architecture. It's how you access memory on a |
11 |
> > >> hardware level: NUMA = Non Uniform Memory Access vs a UMA |
12 |
architecture |
13 |
> > >> of typical (old/legacy) SMP systems (UMA = Uniform Memory Access). |
14 |
> > >> |
15 |
> > >> In a UMA system, all the memory belongs to all the sockets. In a NUMA |
16 |
> > >> system, each socket has it's "own" local memory. In modern (x86-64) |
17 |
> > >> processors, each socket has it's own memory controller so each socket |
18 |
> > >> controls its own local memory. If one socket runs out of memory it |
19 |
can |
20 |
> > >> ask another socket to lend him some memory. In a UMA system, no |
21 |
socket |
22 |
> > >> has to ask since memory is global and belongs to all sockets so if |
23 |
one |
24 |
> > >> socket uses up all the memory ... the rest "starve". In NUMA, there's |
25 |
> > >> more control over who uses what (be it cores or RAM). |
26 |
> > >> |
27 |
> > >> If you have a modern dual or quad (or higher #) socket system ... |
28 |
> > >> you've got NUMA architecture and you can't get rid of it, it's |
29 |
> > >> hardware, not software. |
30 |
> > > |
31 |
> > > So I must enable CONFIG_NUMA for more than one physical CPU, and |
32 |
disable it |
33 |
> > > for only one physical CPU? |
34 |
> > |
35 |
> > |
36 |
> > Yup. But ... Why would you want to disable a socket (CPU)? If you |
37 |
> > disable a socket (CPU) ... you lose the memory attached to that socket |
38 |
> > (CPU) not to mention you lose those cores ;) |
39 |
> |
40 |
> Sure but it sounds like if my system only has one CPU socket, CONFIG_NUMA |
41 |
should be disabled. |
42 |
|
43 |
I read this in make menuconfig: |
44 |
|
45 |
"The kernel will try to allocate memory used by a CPU on the local memory |
46 |
controller of the CPU and add some more NUMA awareness to the kernel. For |
47 |
64-bit this is recommended if the system is Intel Core i7 (or later), AMD |
48 |
Opteron, or EM64T NUMA." |
49 |
|
50 |
To be sure I have this right, I should disable CONFIG_NUMA on any system |
51 |
with a single physical CPU, even if it's an AMD Opteron? |
52 |
|
53 |
- Grant |