Index: trunk/src/VBox/ValidationKit/utils/misc/Makefile.kmk
===================================================================
--- trunk/src/VBox/ValidationKit/utils/misc/Makefile.kmk	(revision 96407)
+++ trunk/src/VBox/ValidationKit/utils/misc/Makefile.kmk	(revision 96583)
@@ -38,22 +38,35 @@
 include $(KBUILD_PATH)/subheader.kmk
 
+#
+# Load generator, optionally with an ring-0 IPI generator.
+#
 PROGRAMS += LoadGenerator
-LoadGenerator_TEMPLATE = VBoxValidationKitR3SupDrv
-LoadGenerator_SOURCES  = loadgenerator.cpp
+if1of ($(KBUILD_TARGET_ARCH),amd64)
+ ifdef VBOX_WITH_R0_MODULES
+  ifdef VBOX_WITH_VBOXR0_AS_DLL
+DLLS    += loadgeneratorR0
+  else
+SYSMODS += loadgeneratorR0
+  endif
+loadgeneratorR0_TEMPLATE := VBoxValidationKitR0
+loadgeneratorR0_SOURCES  := loadgeneratorR0.cpp
+ endif
+LoadGenerator_TEMPLATE := VBoxValidationKitR3SupDrv
+LoadGenerator_DEFS     := WITH_IPI_LOAD_GEN
+else
+LoadGenerator_TEMPLATE := VBoxValidationKitR3
+endif
+LoadGenerator_SOURCES  := loadgenerator.cpp
 
-ifdef VBOX_WITH_R0_MODULES
- ifdef VBOX_WITH_VBOXR0_AS_DLL
-  DLLS    += loadgeneratorR0
- else
-  SYSMODS += loadgeneratorR0
- endif
- loadgeneratorR0_TEMPLATE = VBoxValidationKitR0
- loadgeneratorR0_SOURCES = loadgeneratorR0.cpp
-endif
-
+#
+# vts_rm - Test cleanup utility similar to unix rm.
+#
 PROGRAMS += vts_rm
 vts_rm_TEMPLATE = VBoxValidationKitR3
 vts_rm_SOURCES  = vts_rm.cpp
 
+#
+# vts_tar - Tar for untarring and tarring test related stuff.
+#
 PROGRAMS += vts_tar
 vts_tar_TEMPLATE = VBoxValidationKitR3
@@ -61,4 +74,7 @@
 vts_tar_SOURCES  = vts_tar.cpp
 
+#
+# vts_shutdown - initiates a guest or host shut down / reboot.
+#
 PROGRAMS += vts_shutdown
 vts_shutdown_TEMPLATE = VBoxValidationKitR3
Index: trunk/src/VBox/ValidationKit/utils/misc/loadgenerator.cpp
===================================================================
--- trunk/src/VBox/ValidationKit/utils/misc/loadgenerator.cpp	(revision 96407)
+++ trunk/src/VBox/ValidationKit/utils/misc/loadgenerator.cpp	(revision 96583)
@@ -43,4 +43,5 @@
 #include <iprt/time.h>
 #include <iprt/initterm.h>
+#include <iprt/message.h>
 #include <iprt/string.h>
 #include <iprt/stream.h>
@@ -51,5 +52,7 @@
 #include <iprt/asm.h>
 #include <iprt/getopt.h>
-#include <VBox/sup.h>
+#ifdef WITH_IPI_LOAD_GEN
+# include <VBox/sup.h>
+#endif
 
 
@@ -59,11 +62,4 @@
 /** Whether the threads should quit or not. */
 static bool volatile    g_fQuit = false;
-static const char      *g_pszProgramName = NULL;
-
-
-/*********************************************************************************************************************************
-*   Internal Functions                                                                                                           *
-*********************************************************************************************************************************/
-static int Error(const char *pszFormat, ...);
 
 
@@ -86,4 +82,5 @@
 }
 
+#ifdef WITH_IPI_LOAD_GEN
 
 static int LoadGenIpiInit(void)
@@ -109,8 +106,8 @@
         }
         else
-            Error("SUPR3LoadServiceModule(%s): %Rrc\n", szPath, rc);
+            RTMsgError("SUPR3LoadServiceModule(%s): %Rrc", szPath, rc);
     }
     else
-        Error("RTPathAppPrivateArch: %Rrc\n", rc);
+        RTMsgError("RTPathAppPrivateArch: %Rrc", rc);
     return rc;
 }
@@ -126,5 +123,5 @@
         if (RT_FAILURE(rc))
         {
-            Error("SUPR3CallR0Service: %Rrc\n", rc);
+            RTMsgError("SUPR3CallR0Service: %Rrc", rc);
             break;
         }
@@ -140,25 +137,5 @@
 }
 
-
-static int Error(const char *pszFormat, ...)
-{
-    va_list va;
-    RTStrmPrintf(g_pStdErr, "%s: error: ", g_pszProgramName);
-    va_start(va, pszFormat);
-    RTStrmPrintfV(g_pStdErr, pszFormat, va);
-    va_end(va);
-    return 1;
-}
-
-
-static int SyntaxError(const char *pszFormat, ...)
-{
-    va_list va;
-    RTStrmPrintf(g_pStdErr, "%s: syntax error: ", g_pszProgramName);
-    va_start(va, pszFormat);
-    RTStrmPrintfV(g_pStdErr, pszFormat, va);
-    va_end(va);
-    return 1;
-}
+#endif
 
 
@@ -173,5 +150,7 @@
     {
         { "spin",   NULL,           LoadGenSpinThreadFunction },
+#ifdef WITH_IPI_LOAD_GEN
         { "ipi",    LoadGenIpiInit, LoadGenIpiThreadFunction },
+#endif
     };
     unsigned        iLoadType = 0;
@@ -185,9 +164,4 @@
 
     RTR3InitExe(argc, &argv, 0);
-
-    /*
-     * Set program name.
-     */
-    g_pszProgramName = RTPathFilename(argv[0]);
 
     /*
@@ -213,5 +187,5 @@
                 cThreads = ValueUnion.u64;
                 if (cThreads == 0 || cThreads > RT_ELEMENTS(s_aThreads))
-                    return SyntaxError("Requested number of threads, %RU32, is out of range (1..%d).\n",
+                    return RTMsgSyntax("Requested number of threads, %RU32, is out of range (1..%d).",
                                        cThreads, RT_ELEMENTS(s_aThreads) - 1);
                 break;
@@ -222,5 +196,5 @@
                 rc = RTStrToUInt64Ex(ValueUnion.psz, &psz, 0, &cNanoSeconds);
                 if (RT_FAILURE(rc))
-                    return SyntaxError("Failed reading the alleged number '%s' (option '%s', rc=%Rrc).\n",
+                    return RTMsgSyntax("Failed reading the alleged number '%s' (option '%s', rc=%Rrc).",
                                        ValueUnion.psz, rc);
                 while (*psz == ' ' || *psz == '\t')
@@ -240,8 +214,8 @@
                         u64Factor = UINT64_C(3600000000000);
                     else
-                        return SyntaxError("Unknown time suffix '%s'\n", psz);
+                        return RTMsgSyntax("Unknown time suffix '%s'", psz);
                     uint64_t u64 = cNanoSeconds * u64Factor;
                     if (u64 < cNanoSeconds || (u64 < u64Factor && u64))
-                        return SyntaxError("Time representation overflowed! (%RU64 * %RU64)\n",
+                        return RTMsgSyntax("Time representation overflowed! (%RU64 * %RU64)",
                                            psz, cNanoSeconds, u64Factor);
                     cNanoSeconds = u64;
@@ -275,5 +249,5 @@
                     }
                     else
-                        return SyntaxError("can't grok thread type '%s'\n",
+                        return RTMsgSyntax("can't grok thread type '%s'",
                                            ValueUnion.psz);
                 }
@@ -282,5 +256,5 @@
                     enmThreadType = (RTTHREADTYPE)u32;
                     if (enmThreadType <= RTTHREADTYPE_INVALID || enmThreadType >= RTTHREADTYPE_END)
-                        return SyntaxError("thread type '%d' is out of range (%d..%d)\n",
+                        return RTMsgSyntax("thread type '%d' is out of range (%d..%d)",
                                            ValueUnion.psz, RTTHREADTYPE_INVALID + 1, RTTHREADTYPE_END - 1);
                 }
@@ -302,16 +276,17 @@
                     }
                 if (ValueUnion.psz)
-                    return SyntaxError("Unknown load type '%s'.\n", ValueUnion.psz);
+                    return RTMsgSyntax("Unknown load type '%s'.", ValueUnion.psz);
                 break;
             }
 
             case 'h':
-                RTStrmPrintf(g_pStdOut,
-                             "Usage: %s [-p|--thread-type <type>] [-t|--timeout <sec|xxx[h|m|s|ms|ns]>] \\\n"
-                             "       %*s [-n|--number-of-threads <threads>] [-l|--load <loadtype>]\n"
-                             "\n"
-                             "Load types: spin, ipi.\n"
-                             ,
-                             g_pszProgramName, strlen(g_pszProgramName), "");
+                RTPrintf("Usage: %s [-p|--thread-type <type>] [-t|--timeout <sec|xxx[h|m|s|ms|ns]>] \\\n"
+                         "       %*s [-n|--number-of-threads <threads>] [-l|--load <loadtype>]\n"
+                         "\n"
+                         "Load types: "
+                         , RTProcShortName(), strlen(RTProcShortName()), "");
+                for (size_t i = 0; i < RT_ELEMENTS(s_aLoadTypes); i++)
+                    RTPrintf(i == 0 ? "%s (default)" : ", %s", s_aLoadTypes[i].pszName);
+                RTPrintf("\n");
                 return 1;
 
@@ -321,5 +296,5 @@
 
             case VINF_GETOPT_NOT_OPTION:
-                return SyntaxError("Unknown argument #%d: '%s'\n", GetState.iNext-1, ValueUnion.psz);
+                return RTMsgSyntax("Unknown argument #%d: '%s'", GetState.iNext-1, ValueUnion.psz);
 
             default:
@@ -335,5 +310,5 @@
         const unsigned cCpus = RTMpGetOnlineCount();
         if (cCpus * cThreads > RT_ELEMENTS(s_aThreads))
-            return SyntaxError("Requested number of threads, %RU32, is out of range (1..%d) when scaled by %d.\n",
+            return RTMsgSyntax("Requested number of threads, %RU32, is out of range (1..%d) when scaled by %d.",
                                cThreads, RT_ELEMENTS(s_aThreads) - 1, cCpus);
         cThreads *= cCpus;
@@ -370,5 +345,5 @@
         {
             ASMAtomicXchgBool(&g_fQuit, true);
-            RTStrmPrintf(g_pStdErr, "%s: failed to create thread #%d, rc=%Rrc\n", g_pszProgramName, i, rc);
+            RTMsgError("failed to create thread #%d: %Rrc", i, rc);
             while (i-- > 1)
                 RTThreadWait(s_aThreads[i], 1500, NULL);
