3

I have already looked for NUMA documentations for X86-64 processors, unfortunately I only found optimization documents for NUMA.

What I want is: how do I initialize NUMA in a system (this would include getting the system's memory topology and processor topology). Does anyone know a good documentation about NUMA for X86-64 AMD and Intel processors?

Pokechu22
  • 4,984
  • 9
  • 37
  • 62
prinzrainer
  • 319
  • 1
  • 6
  • 12

1 Answers1

5

I know that if you want the system topology, you can get that from the ACPI SLIT (System Locality Information Table) or SRAT (Static Resource Affinity Table). You can read more about this from the ACPI spec here (http://www.acpi.info/spec.htm), specifically sections 5.2.16 and 5.2.17.

Basically, you use the SRAT to determine which memory ranges are associated with which CPUs, and you use the SLIT to determine the relative cost of using a particular CPU/memory range. Both of these tables are optional, but in my experience, most NUMA systems at least have a useful SRAT.

As far as initialization goes, I don't think I can help much. You might want to look in to how processors are brought up on the Linux kernel (or a BSD kernel). You'll probably need to read up on local APICs too, as they are used to init x86 APs.

Rose Lynn Embry
  • 618
  • 3
  • 8
  • I still wonder if bochs is/will be supporting NUMA emulation(Do you some free emulator that has a debbugger on it that support NUMA and x2APIC?)...although I guess NUMA domains can always be implemented virtually even if the emulator/real machine has no NUMA support (just for the sake of NUMA emulation,even though without any performance gain)by modifying the ACPI tables..or hard coding it in kernel itself.... – prinzrainer Jun 09 '11 at 08:18
  • I'm not aware of any free emulator with NUMA support. You might try looking at the AMD SimNow! simulator, but I don't think it has multi CPU support or x2APICs (though it does simulate quite a bit of modern-ish hardware). Otherwise, I'd just use Bochs or Qemu in SMP mode (possibly even adding those ACPI tables). I haven't looked at the source for Qemu, but I know Bochs is fairly well written and you might consider modifying it for at least a primitive NUMA simulation. – Rose Lynn Embry Jun 09 '11 at 15:19