[sysprof] libsysprof: apply selection to temporary allocations



commit e3cb30e4ee082ce9b105ac719e3bdd816c4690c4
Author: Christian Hergert <chergert redhat com>
Date:   Tue Feb 18 19:19:01 2020 -0800

    libsysprof: apply selection to temporary allocations

 src/libsysprof/sysprof-memprof-profile.c | 4 ++++
 1 file changed, 4 insertions(+)
---
diff --git a/src/libsysprof/sysprof-memprof-profile.c b/src/libsysprof/sysprof-memprof-profile.c
index 6129815..cbe87fd 100644
--- a/src/libsysprof/sysprof-memprof-profile.c
+++ b/src/libsysprof/sysprof-memprof-profile.c
@@ -442,6 +442,10 @@ temp_allocs_worker (Generate *g)
 
           frame_num++;
 
+          /* Short-circuit if we don't care about this frame */
+          if (!sysprof_selection_contains (g->selection, ev->frame.time))
+            continue;
+
           a.pid = ev->frame.pid;
           a.tid = ev->tid;
           a.time = ev->frame.time;


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