[PATCH 4/5] qemu: Build command line for NUMA tuning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Just prepend numactl command line to qemu command line.
---
 src/qemu/qemu_command.c |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index 2205ed1..156fdfb 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -2762,7 +2762,23 @@ qemuBuildCommandLine(virConnectPtr conn,
         break;
     }
 
+#ifdef HAVE_NUMACTL
+    /* XXX: Logic here to build numactl commmand line need to be changed if
+     * more NUMA tuning related stuffs in future.
+     */
+    if (def->numatune.membind.nodeset) {
+        cmd = virCommandNewArgList(NUMACTL,
+                                   "-m",
+                                   def->numatune.membind.nodeset,
+                                   NULL);
+
+        virCommandAddArgList(cmd, emulator, "-S", NULL);
+    } else {
+        cmd = virCommandNewArgList(emulator, "-S", NULL);
+    }
+#else
     cmd = virCommandNewArgList(emulator, "-S", NULL);
+#endif
 
     virCommandAddEnvPassCommon(cmd);
 
-- 
1.7.4

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]