On Sat, Jan 04, 2020 at 09:27:30PM +0100, Klemens Nanni wrote:
> CPU strides provide means to effectively bind guests to certain specific
> phsyical cores by overallocating virtual CPUs (hardware threads) such
> that the sum of virtual CPUs and strides yields an integer multiple of
> the CPU dependent threads-per-core factor, e.g. on T2 based machines
> each CPU has 8 cores and each core has 8 threads. this makes for n times
> virtual CPUs to be managed in ldom.conf(5).
> 
> Diff below slightly extends the given example and tries to further
> clarify what strides do.  The example should match a T5120 machine for
> example which features 1 T2+ CPU.
> 
> It hopefully makes it clearer how "vcpu"s correspond to hardware threads
> not physical CPU cores.
> 
> Feedback? OK?
Ping.

How do others understand/read the stride parts?  Does this diff make it
any clearer?


Index: ldom.conf.5
===================================================================
RCS file: /cvs/src/usr.sbin/ldomctl/ldom.conf.5,v
retrieving revision 1.9
diff -u -p -r1.9 ldom.conf.5
--- ldom.conf.5 3 Dec 2019 21:07:03 -0000       1.9
+++ ldom.conf.5 12 Jan 2020 10:37:17 -0000
@@ -78,11 +78,11 @@ Configure the MTU of the interface.
 .El
 .El
 .Sh EXAMPLES
-Define a domain with 12 virtual cores, 4GB memory, two file based virtual disks
-and one virtual network interface:
+Define a domain with 12 virtual cores and 4 additionally allocated cores,
+4GB memory, two file based virtual disks and one virtual network interface:
 .Bd -literal -offset indent
 domain "puffy" {
-       vcpu 12
+       vcpu 12:4
        memory 4G
        vdisk "/home/puffy/vdisk0"
        vdisk "/home/puffy/vdisk1"
@@ -101,8 +101,10 @@ domain "salmah" {
 }
 .Ed
 .Pp
-On a machine with 32 cores and 64GB physical memory, this leaves 12 cores and
-58GB memory to the primary domain.
+On a machine with 1 CPU comprising 8 cores with 8 threads each and 64GB 
physical
+memory, this leaves 40 cores and 58GB memory to the primary domain.
+.Dq puffy
+will be assigned 16 threads of which 4 are not being used.
 .Sh SEE ALSO
 .Xr eeprom 8 ,
 .Xr ldomctl 8 ,

Reply via email to