[sysprof] cli: add diskstat data source recording
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [sysprof] cli: add diskstat data source recording
- Date: Mon, 1 Jul 2019 21:46:51 +0000 (UTC)
commit f89d5830f2cfc7266d5093931a545a3ed7affda0
Author: Christian Hergert <chergert redhat com>
Date: Mon Jul 1 14:46:43 2019 -0700
cli: add diskstat data source recording
src/tools/sysprof-cli.c | 9 +++++++++
1 file changed, 9 insertions(+)
---
diff --git a/src/tools/sysprof-cli.c b/src/tools/sysprof-cli.c
index 384e65f..21e3076 100644
--- a/src/tools/sysprof-cli.c
+++ b/src/tools/sysprof-cli.c
@@ -82,6 +82,7 @@ main (gint argc,
gboolean no_battery = FALSE;
gboolean no_cpu = FALSE;
gboolean no_decode = FALSE;
+ gboolean no_disk = FALSE;
gboolean no_memory = FALSE;
gboolean no_network = FALSE;
gboolean no_perf = FALSE;
@@ -98,6 +99,7 @@ main (gint argc,
{ "force", 'f', 0, G_OPTION_ARG_NONE, &force, N_("Force overwrite the capture file") },
{ "no-battery", 0, 0, G_OPTION_ARG_NONE, &no_cpu, N_("Disable recording of battery statistics") },
{ "no-cpu", 0, 0, G_OPTION_ARG_NONE, &no_cpu, N_("Disable recording of CPU statistics") },
+ { "no-disk", 0, 0, G_OPTION_ARG_NONE, &no_disk, N_("Disable recording of Disk statistics") },
{ "no-perf", 0, 0, G_OPTION_ARG_NONE, &no_perf, N_("Do not record stacktraces using Linux perf") },
{ "no-decode", 0, 0, G_OPTION_ARG_NONE, &no_decode, N_("Do not append symbol name information from local
machine") },
{ "no-memory", 0, 0, G_OPTION_ARG_NONE, &no_memory, N_("Disable recording of memory statistics") },
@@ -247,6 +249,13 @@ main (gint argc,
}
#endif
+ if (!no_disk)
+ {
+ source = sysprof_diskstat_source_new ();
+ sysprof_profiler_add_source (profiler, source);
+ g_object_unref (source);
+ }
+
if (!no_decode)
{
/* Add __symbols__ rollup after recording to avoid loading
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]